diff --git a/Makefile b/Makefile index 80f9e239..7a44ff19 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,4 @@ -VERSION=v5.2.0 +VERSION=v5.4.0 DOCKER_IMAGE="openapitools/openapi-generator-cli:$(VERSION)" THIS_OS := $(shell go env GOOS) @@ -6,62 +6,77 @@ CGO_ENABLED = 1 CGO_CFLAGS ?= SDKROOT ?= +CLIENTS = $(shell find clients -type f -name 'config.yaml' -exec dirname "{}" \; | sed 's_/v1__g' | sed 's_clients/__g') + +.PHONY: v1 client/go client/java client/javascript/ client/python client/rust/reqwest client/rust/hyper client/ruby client/typescript + ifeq (darwin,$(THIS_OS)) spec: CGO_ENABLED = 0 CGO_CFLAGS=-Wno-undef-prefix endif -.PHONY: spec spec: CC ?= $(shell go env CC) spec: GOOS=$(shell go env GOOS) spec: (cd generator && CGO_ENABLED=$(CGO_ENABLED) GOOS=$(GOOS) CC=$(CC) CGO_CFLAGS=$(CGO_CFLAGS) go build -o bin/generator && ./bin/generator ../v1/openapi.yaml) -.PHONY: test test: (cd ./v1 && go test ./... -v -count=1) -.PHONY: openapi -v1: spec - @echo "==> Building v1 OpenAPI Specification and clients..." +v1: test spec client/go client/java client/javascript/ client/python client/rust/reqwest client/rust/hyper client/ruby client/typescript + +client/go: + @echo "==> Building nomad-openapi client for go..." @docker run \ --rm \ --volume "$(PWD):/local" \ $(DOCKER_IMAGE) batch --clean /local/clients/go/v1/config.yaml + +client/java: + @echo "==> Building nomad-openapi client for java..." @docker run \ --rm \ --volume "$(PWD):/local" \ $(DOCKER_IMAGE) batch --clean /local/clients/java/v1/config.yaml + +client/javascript: + @echo "==> Building nomad-openapi client for javascript..." @docker run \ --rm \ --volume "$(PWD):/local" \ $(DOCKER_IMAGE) batch --clean /local/clients/javascript/v1/config.yaml + +client/python/: + @echo "==> Building nomad-openapi client for python using the stable generator..." @docker run \ --rm \ --volume "$(PWD):/local" \ $(DOCKER_IMAGE) batch --clean /local/clients/python/v1/config.yaml + +client/rust/reqwest: + @echo "==> Building nomad-openapi client for rust using the reqwest generator..." @docker run \ --rm \ --volume "$(PWD):/local" \ $(DOCKER_IMAGE) batch --clean /local/clients/rust/reqwest/v1/config.yaml + +client/rust/hyper: + @echo "==> Building nomad-openapi client for rust using the hyper generator..." @docker run \ --rm \ --volume "$(PWD):/local" \ $(DOCKER_IMAGE) batch --clean /local/clients/rust/hyper/v1/config.yaml + +client/ruby: + @echo "==> Building nomad-openapi client for ruby..." @docker run \ --rm \ --volume "$(shell pwd):/local" \ $(DOCKER_IMAGE) batch --clean /local/clients/ruby/v1/config.yaml + +client/typescript: + @echo "==> Building nomad-openapi client for typescript..." @docker run \ --rm \ --volume "$(shell pwd):/local" \ - $(DOCKER_IMAGE) batch --clean /local/clients/typescript/v1/config.yaml - - -.PHONY: update-nomad -update-nomad: - (cd generator && go get github.com/hashicorp/nomad) - (cd generator && go get github.com/hashicorp/nomad/api) - (cd generator && go mod tidy) - @go get github.com/hashicorp/nomad - @go mod tidy + $(DOCKER_IMAGE) batch --clean /local/clients/typescript/v1/config.yaml \ No newline at end of file diff --git a/clients/go/v1/.openapi-generator/VERSION b/clients/go/v1/.openapi-generator/VERSION index 7cbea073..1e20ec35 100644 --- a/clients/go/v1/.openapi-generator/VERSION +++ b/clients/go/v1/.openapi-generator/VERSION @@ -1 +1 @@ -5.2.0 \ No newline at end of file +5.4.0 \ No newline at end of file diff --git a/clients/go/v1/README.md b/clients/go/v1/README.md index 12ca7b70..39079933 100644 --- a/clients/go/v1/README.md +++ b/clients/go/v1/README.md @@ -22,7 +22,7 @@ go get golang.org/x/net/context Put the package under your project folder and add the following in import: ```golang -import sw "./client" +import client "github.com/hashicorp/nomad-openapi/clients/go/v1" ``` To use a proxy, set the environment variable `HTTP_PROXY`: @@ -40,7 +40,7 @@ Default configuration comes with `Servers` field that contains server objects as For using other server than the one defined on index 0 set context value `sw.ContextServerIndex` of type `int`. ```golang -ctx := context.WithValue(context.Background(), sw.ContextServerIndex, 1) +ctx := context.WithValue(context.Background(), client.ContextServerIndex, 1) ``` ### Templated Server URL @@ -48,7 +48,7 @@ ctx := context.WithValue(context.Background(), sw.ContextServerIndex, 1) Templated server URL is formatted using default variables from configuration or from context value `sw.ContextServerVariables` of type `map[string]string`. ```golang -ctx := context.WithValue(context.Background(), sw.ContextServerVariables, map[string]string{ +ctx := context.WithValue(context.Background(), client.ContextServerVariables, map[string]string{ "basePath": "v2", }) ``` @@ -58,14 +58,14 @@ Note, enum values are always validated and all unused variables are silently ign ### URLs Configuration per Operation Each operation can use different server URL defined using `OperationServers` map in the `Configuration`. -An operation is uniquely identifield by `"{classname}Service.{nickname}"` string. +An operation is uniquely identified by `"{classname}Service.{nickname}"` string. Similar rules for overriding default operation server index and variables applies by using `sw.ContextOperationServerIndices` and `sw.ContextOperationServerVariables` context maps. ``` -ctx := context.WithValue(context.Background(), sw.ContextOperationServerIndices, map[string]int{ +ctx := context.WithValue(context.Background(), client.ContextOperationServerIndices, map[string]int{ "{classname}Service.{nickname}": 2, }) -ctx = context.WithValue(context.Background(), sw.ContextOperationServerVariables, map[string]map[string]string{ +ctx = context.WithValue(context.Background(), client.ContextOperationServerVariables, map[string]map[string]string{ "{classname}Service.{nickname}": { "port": "8443", }, diff --git a/clients/go/v1/api/openapi.yaml b/clients/go/v1/api/openapi.yaml index 32ec720d..2f2ec4a2 100644 --- a/clients/go/v1/api/openapi.yaml +++ b/clients/go/v1/api/openapi.yaml @@ -7076,7 +7076,8 @@ paths: content: application/json: schema: - items: {} + items: + $ref: '#/components/schemas/Quotas' type: array headers: X-Nomad-Index: @@ -10604,7 +10605,8 @@ components: content: application/json: schema: - items: {} + items: + $ref: '#/components/schemas/Quotas' type: array headers: X-Nomad-Index: @@ -11200,6 +11202,7 @@ components: Rules: Rules ModifyIndex: 2147483647 Name: Name + nullable: true properties: CreateIndex: maximum: 1.8446744073709552E+19 @@ -11222,6 +11225,7 @@ components: Description: Description ModifyIndex: 2147483647 Name: Name + nullable: true properties: CreateIndex: maximum: 1.8446744073709552E+19 @@ -11249,6 +11253,7 @@ components: Global: true ModifyIndex: 2147483647 Name: Name + nullable: true properties: AccessorID: type: string @@ -11258,6 +11263,7 @@ components: type: integer CreateTime: format: date-time + nullable: true type: string Global: type: boolean @@ -11288,6 +11294,7 @@ components: Global: true ModifyIndex: 2147483647 Name: Name + nullable: true properties: AccessorID: type: string @@ -11297,6 +11304,7 @@ components: type: integer CreateTime: format: date-time + nullable: true type: string Global: type: boolean @@ -11319,6 +11327,7 @@ components: RTarget: RTarget Operand: Operand Weight: -101 + nullable: true properties: LTarget: type: string @@ -11337,6 +11346,7 @@ components: Timestamp: 2000-01-23T04:56:07.000+00:00 Healthy: true ModifyIndex: 2147483647 + nullable: true properties: Canary: type: boolean @@ -11348,12 +11358,14 @@ components: type: integer Timestamp: format: date-time + nullable: true type: string type: object AllocStopResponse: example: Index: 2147483647 EvalID: EvalID + nullable: true properties: EvalID: type: string @@ -11365,6 +11377,7 @@ components: AllocatedCpuResources: example: CpuShares: 9 + nullable: true properties: CpuShares: format: int64 @@ -11378,6 +11391,7 @@ components: Type: Type Vendor: Vendor Name: Name + nullable: true properties: DeviceIDs: items: @@ -11394,6 +11408,7 @@ components: example: MemoryMB: 3 MemoryMaxMB: 2 + nullable: true properties: MemoryMB: format: int64 @@ -11573,6 +11588,7 @@ components: Label: Label Value: 7 To: 2 + nullable: true properties: Shared: $ref: '#/components/schemas/AllocatedSharedResources' @@ -11662,6 +11678,7 @@ components: Label: Label Value: 7 To: 2 + nullable: true properties: DiskMB: format: int64 @@ -11764,6 +11781,7 @@ components: Type: Type Vendor: Vendor Name: Name + nullable: true properties: Cpu: $ref: '#/components/schemas/AllocatedCpuResources' @@ -11780,7 +11798,7 @@ components: type: object Allocation: example: - ModifyTime: 8 + ModifyTime: 9 PreemptedAllocations: - PreemptedAllocations - PreemptedAllocations @@ -11957,35 +11975,27 @@ components: To: 2 Name: Name Metrics: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -17314,23 +17324,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -17340,23 +17350,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -17371,7 +17381,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -17627,11 +17637,12 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID + nullable: true properties: AllocModifyIndex: maximum: 1.8446744073709552E+19 @@ -17904,23 +17915,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -17930,23 +17941,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -17961,7 +17972,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -17983,11 +17994,12 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID + nullable: true properties: AllocatedResources: $ref: '#/components/schemas/AllocatedResources' @@ -18054,35 +18066,27 @@ components: type: object AllocationMetric: example: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -18197,31 +18201,32 @@ components: Count: 2147483647 Name: Name MemoryMaxMB: 5 + nullable: true properties: AllocationTime: format: int64 type: integer ClassExhausted: additionalProperties: - type: integer + $ref: '#/components/schemas/int' type: object ClassFiltered: additionalProperties: - type: integer + $ref: '#/components/schemas/int' type: object CoalescedFailures: type: integer ConstraintFiltered: additionalProperties: - type: integer + $ref: '#/components/schemas/int' type: object DimensionExhausted: additionalProperties: - type: integer + $ref: '#/components/schemas/int' type: object NodesAvailable: additionalProperties: - type: integer + $ref: '#/components/schemas/int' type: object NodesEvaluated: type: integer @@ -18243,8 +18248,7 @@ components: type: array Scores: additionalProperties: - format: double - type: number + $ref: '#/components/schemas/float64' type: object type: object Attribute: @@ -18254,6 +18258,7 @@ components: String: String Unit: Unit Int: 2 + nullable: true properties: Bool: type: boolean @@ -18280,6 +18285,7 @@ components: EnableRedundancyZones: true ModifyIndex: 2147483647 CleanupDeadServers: true + nullable: true properties: CleanupDeadServers: type: boolean @@ -18323,6 +18329,7 @@ components: SupportsExpand: true SupportsGet: true SupportsCondition: true + nullable: true properties: SupportsAttachDetach: type: boolean @@ -18381,6 +18388,7 @@ components: SupportsCondition: true Healthy: true RequiresControllerPlugin: true + nullable: true properties: AllocID: type: string @@ -18400,6 +18408,7 @@ components: type: boolean UpdateTime: format: date-time + nullable: true type: string type: object CSIMountOptions: @@ -18408,6 +18417,7 @@ components: - MountFlags - MountFlags FSType: FSType + nullable: true properties: FSType: type: string @@ -18427,6 +18437,7 @@ components: key: Segments SupportsCondition: true SupportsStats: true + nullable: true properties: AccessibleTopology: $ref: '#/components/schemas/CSITopology' @@ -18665,23 +18676,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -18691,23 +18702,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -18722,7 +18733,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -18744,10 +18755,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - ModifyTime: 5 PreemptedAllocations: @@ -18935,23 +18946,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -18961,23 +18972,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -18992,7 +19003,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -19014,10 +19025,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID ControllersExpected: 0 NodesHealthy: 2 @@ -19061,6 +19072,7 @@ components: Version: Version ID: ID ModifyIndex: 2147483647 + nullable: true properties: Allocations: items: @@ -19110,6 +19122,7 @@ components: ID: ID ModifyIndex: 2147483647 Provider: Provider + nullable: true properties: ControllerRequired: type: boolean @@ -19154,6 +19167,7 @@ components: SourceVolumeID: SourceVolumeID ExternalSourceVolumeID: ExternalSourceVolumeID Name: Name + nullable: true properties: CreateTime: format: int64 @@ -19212,6 +19226,7 @@ components: ExternalSourceVolumeID: ExternalSourceVolumeID Name: Name Namespace: Namespace + nullable: true properties: Namespace: type: string @@ -19256,6 +19271,7 @@ components: SourceVolumeID: SourceVolumeID ExternalSourceVolumeID: ExternalSourceVolumeID Name: Name + nullable: true properties: KnownLeader: type: boolean @@ -19308,6 +19324,7 @@ components: SourceVolumeID: SourceVolumeID ExternalSourceVolumeID: ExternalSourceVolumeID Name: Name + nullable: true properties: KnownLeader: type: boolean @@ -19332,6 +19349,7 @@ components: example: Segments: key: Segments + nullable: true properties: Segments: additionalProperties: @@ -19350,6 +19368,7 @@ components: key: Segments - Segments: key: Segments + nullable: true properties: Preferred: items: @@ -19550,23 +19569,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -19576,23 +19595,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -19607,7 +19626,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -19629,10 +19648,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - ModifyTime: 5 PreemptedAllocations: @@ -19820,23 +19839,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -19846,23 +19865,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -19877,7 +19896,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -19899,10 +19918,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID RequestedTopologies: Preferred: @@ -19926,7 +19945,7 @@ components: SnapshotID: SnapshotID WriteAllocs: key: - ModifyTime: 8 + ModifyTime: 9 PreemptedAllocations: - PreemptedAllocations - PreemptedAllocations @@ -20103,35 +20122,27 @@ components: To: 2 Name: Name Metrics: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -25460,23 +25471,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -25486,23 +25497,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -25517,7 +25528,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -25773,10 +25784,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID CreateIndex: 2147483647 Capacity: 0 @@ -25792,7 +25803,7 @@ components: ControllersExpected: 6 ReadAllocs: key: - ModifyTime: 8 + ModifyTime: 9 PreemptedAllocations: - PreemptedAllocations - PreemptedAllocations @@ -25969,35 +25980,27 @@ components: To: 2 Name: Name Metrics: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -31326,23 +31329,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -31352,23 +31355,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -31383,7 +31386,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -31639,10 +31642,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID Parameters: key: Parameters @@ -31666,6 +31669,7 @@ components: FSType: FSType ModifyIndex: 2147483647 ProviderVersion: ProviderVersion + nullable: true properties: AccessMode: type: string @@ -31740,6 +31744,7 @@ components: $ref: '#/components/schemas/CSITopologyRequest' ResourceExhausted: format: date-time + nullable: true type: string Schedulable: type: boolean @@ -31766,6 +31771,7 @@ components: example: AccessMode: AccessMode AttachmentMode: AttachmentMode + nullable: true properties: AccessMode: type: string @@ -31963,23 +31969,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -31989,23 +31995,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -32020,7 +32026,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -32042,10 +32048,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - ModifyTime: 5 PreemptedAllocations: @@ -32233,23 +32239,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -32259,23 +32265,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -32290,7 +32296,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -32312,10 +32318,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID RequestedTopologies: Preferred: @@ -32339,7 +32345,7 @@ components: SnapshotID: SnapshotID WriteAllocs: key: - ModifyTime: 8 + ModifyTime: 9 PreemptedAllocations: - PreemptedAllocations - PreemptedAllocations @@ -32516,35 +32522,27 @@ components: To: 2 Name: Name Metrics: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -37873,23 +37871,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -37899,23 +37897,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -37930,7 +37928,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -38186,10 +38184,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID CreateIndex: 2147483647 Capacity: 0 @@ -38205,7 +38203,7 @@ components: ControllersExpected: 6 ReadAllocs: key: - ModifyTime: 8 + ModifyTime: 9 PreemptedAllocations: - PreemptedAllocations - PreemptedAllocations @@ -38382,35 +38380,27 @@ components: To: 2 Name: Name Metrics: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -43739,23 +43729,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -43765,23 +43755,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -43796,7 +43786,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -44052,10 +44042,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID Parameters: key: Parameters @@ -44267,23 +44257,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -44293,23 +44283,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -44324,7 +44314,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -44346,10 +44336,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - ModifyTime: 5 PreemptedAllocations: @@ -44537,23 +44527,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -44563,23 +44553,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -44594,7 +44584,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -44616,10 +44606,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID RequestedTopologies: Preferred: @@ -44643,7 +44633,7 @@ components: SnapshotID: SnapshotID WriteAllocs: key: - ModifyTime: 8 + ModifyTime: 9 PreemptedAllocations: - PreemptedAllocations - PreemptedAllocations @@ -44820,35 +44810,27 @@ components: To: 2 Name: Name Metrics: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -50177,23 +50159,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -50203,23 +50185,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -50234,7 +50216,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -50490,10 +50472,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID CreateIndex: 2147483647 Capacity: 0 @@ -50509,7 +50491,7 @@ components: ControllersExpected: 6 ReadAllocs: key: - ModifyTime: 8 + ModifyTime: 9 PreemptedAllocations: - PreemptedAllocations - PreemptedAllocations @@ -50686,35 +50668,27 @@ components: To: 2 Name: Name Metrics: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -56043,23 +56017,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -56069,23 +56043,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -56100,7 +56074,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -56356,10 +56330,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID Parameters: key: Parameters @@ -56386,6 +56360,7 @@ components: SecretID: SecretID Region: Region Namespace: Namespace + nullable: true properties: Namespace: type: string @@ -56411,6 +56386,7 @@ components: PublishedExternalNodeIDs: - PublishedExternalNodeIDs - PublishedExternalNodeIDs + nullable: true properties: CapacityBytes: format: int64 @@ -56460,6 +56436,7 @@ components: - PublishedExternalNodeIDs - PublishedExternalNodeIDs NextToken: NextToken + nullable: true properties: NextToken: type: string @@ -56492,6 +56469,7 @@ components: ID: ID AttachmentMode: AttachmentMode ModifyIndex: 2147483647 + nullable: true properties: AccessMode: type: string @@ -56529,6 +56507,7 @@ components: type: string ResourceExhausted: format: date-time + nullable: true type: string Schedulable: type: boolean @@ -56728,23 +56707,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -56754,23 +56733,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -56785,7 +56764,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -56807,10 +56786,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - ModifyTime: 5 PreemptedAllocations: @@ -56998,23 +56977,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -57024,23 +57003,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -57055,7 +57034,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -57077,10 +57056,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID RequestedTopologies: Preferred: @@ -57104,7 +57083,7 @@ components: SnapshotID: SnapshotID WriteAllocs: key: - ModifyTime: 8 + ModifyTime: 9 PreemptedAllocations: - PreemptedAllocations - PreemptedAllocations @@ -57281,35 +57260,27 @@ components: To: 2 Name: Name Metrics: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -62638,23 +62609,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -62664,23 +62635,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -62695,7 +62666,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -62951,10 +62922,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID CreateIndex: 2147483647 Capacity: 0 @@ -62970,7 +62941,7 @@ components: ControllersExpected: 6 ReadAllocs: key: - ModifyTime: 8 + ModifyTime: 9 PreemptedAllocations: - PreemptedAllocations - PreemptedAllocations @@ -63147,35 +63118,27 @@ components: To: 2 Name: Name Metrics: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -68504,23 +68467,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -68530,23 +68493,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -68561,7 +68524,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -68817,10 +68780,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID Parameters: key: Parameters @@ -69032,23 +68995,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -69058,23 +69021,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -69089,7 +69052,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -69111,10 +69074,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - ModifyTime: 5 PreemptedAllocations: @@ -69302,23 +69265,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -69328,23 +69291,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -69359,7 +69322,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -69381,10 +69344,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID RequestedTopologies: Preferred: @@ -69408,7 +69371,7 @@ components: SnapshotID: SnapshotID WriteAllocs: key: - ModifyTime: 8 + ModifyTime: 9 PreemptedAllocations: - PreemptedAllocations - PreemptedAllocations @@ -69585,35 +69548,27 @@ components: To: 2 Name: Name Metrics: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -74942,23 +74897,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -74968,23 +74923,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -74999,7 +74954,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -75255,10 +75210,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID CreateIndex: 2147483647 Capacity: 0 @@ -75274,7 +75229,7 @@ components: ControllersExpected: 6 ReadAllocs: key: - ModifyTime: 8 + ModifyTime: 9 PreemptedAllocations: - PreemptedAllocations - PreemptedAllocations @@ -75451,35 +75406,27 @@ components: To: 2 Name: Name Metrics: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -80808,23 +80755,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -80834,23 +80781,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -80865,7 +80812,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -81121,10 +81068,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID Parameters: key: Parameters @@ -81151,6 +81098,7 @@ components: SecretID: SecretID Region: Region Namespace: Namespace + nullable: true properties: Namespace: type: string @@ -81168,6 +81116,7 @@ components: Grace: 0 IgnoreWarnings: true Limit: 4 + nullable: true properties: Grace: format: int64 @@ -81182,6 +81131,7 @@ components: LTarget: LTarget RTarget: RTarget Operand: Operand + nullable: true properties: LTarget: type: string @@ -81193,6 +81143,7 @@ components: Consul: example: Namespace: Namespace + nullable: true properties: Namespace: type: string @@ -81422,6 +81373,7 @@ components: MaxFiles: 4 MaxFileSizeMB: 1 Name: Name + nullable: true properties: Gateway: $ref: '#/components/schemas/ConsulGateway' @@ -81443,6 +81395,7 @@ components: ListenerPort: ListenerPort Protocol: Protocol LocalPathPort: 4 + nullable: true properties: Path: items: @@ -81455,6 +81408,7 @@ components: ListenerPort: ListenerPort Protocol: Protocol LocalPathPort: 4 + nullable: true properties: ListenerPort: type: string @@ -81537,6 +81491,7 @@ components: Address: Address Port: 3 Name: Name + nullable: true properties: Address: type: string @@ -81558,6 +81513,7 @@ components: Address: Address Port: 3 Name: Name + nullable: true properties: Config: additionalProperties: {} @@ -81584,6 +81540,7 @@ components: - CipherSuites - CipherSuites TLSMaxVersion: TLSMaxVersion + nullable: true properties: CipherSuites: items: @@ -81628,6 +81585,7 @@ components: - CipherSuites - CipherSuites TLSMaxVersion: TLSMaxVersion + nullable: true properties: Listeners: items: @@ -81649,6 +81607,7 @@ components: Name: Name Port: 7 Protocol: Protocol + nullable: true properties: Port: type: integer @@ -81665,6 +81624,7 @@ components: - Hosts - Hosts Name: Name + nullable: true properties: Hosts: items: @@ -81680,6 +81640,7 @@ components: KeyFile: KeyFile Name: Name SNI: SNI + nullable: true properties: CAFile: type: string @@ -81696,6 +81657,7 @@ components: ConsulMeshGateway: example: Mode: Mode + nullable: true properties: Mode: type: string @@ -81731,6 +81693,7 @@ components: Mode: Mode LocalBindAddress: LocalBindAddress LocalServicePort: 0 + nullable: true properties: Config: additionalProperties: {} @@ -81783,6 +81746,7 @@ components: Tags: - Tags - Tags + nullable: true properties: DisableDefaultTCPCheck: type: boolean @@ -81808,6 +81772,7 @@ components: KeyFile: KeyFile Name: Name SNI: SNI + nullable: true properties: Services: items: @@ -81823,6 +81788,7 @@ components: MeshGateway: Mode: Mode LocalBindAddress: LocalBindAddress + nullable: true properties: Datacenter: type: string @@ -81850,6 +81816,7 @@ components: Servers: - Servers - Servers + nullable: true properties: Options: items: @@ -81892,6 +81859,7 @@ components: JobVersion: 2147483647 JobID: JobID ModifyIndex: 2147483647 + nullable: true properties: CreateIndex: maximum: 1.8446744073709552E+19 @@ -81946,6 +81914,7 @@ components: UnhealthyAllocationIDs: - UnhealthyAllocationIDs - UnhealthyAllocationIDs + nullable: true properties: DeploymentID: type: string @@ -81971,6 +81940,7 @@ components: SecretID: SecretID Region: Region Namespace: Namespace + nullable: true properties: DeploymentID: type: string @@ -81993,6 +81963,7 @@ components: SecretID: SecretID Region: Region Namespace: Namespace + nullable: true properties: All: type: boolean @@ -82023,6 +81994,7 @@ components: - PlacedCanaries UnhealthyAllocs: 7 AutoRevert: true + nullable: true properties: AutoRevert: type: boolean @@ -82045,6 +82017,7 @@ components: type: boolean RequireProgressBy: format: date-time + nullable: true type: string UnhealthyAllocs: type: integer @@ -82055,6 +82028,7 @@ components: SecretID: SecretID Region: Region Namespace: Namespace + nullable: true properties: DeploymentID: type: string @@ -82073,6 +82047,7 @@ components: RequestTime: 5 RevertedJobVersion: 2147483647 EvalID: EvalID + nullable: true properties: DeploymentModifyIndex: maximum: 1.8446744073709552E+19 @@ -82116,6 +82091,7 @@ components: InPlaceUpdate: 2147483647 Place: 2147483647 DestructiveUpdate: 2147483647 + nullable: true properties: Canary: maximum: 1.8446744073709552E+19 @@ -82153,6 +82129,7 @@ components: DispatchPayloadConfig: example: File: File + nullable: true properties: File: type: string @@ -82165,6 +82142,7 @@ components: StartedAt: 2000-01-23T04:56:07.000+00:00 UpdatedAt: 2000-01-23T04:56:07.000+00:00 AccessorID: AccessorID + nullable: true properties: AccessorID: type: string @@ -82174,17 +82152,20 @@ components: type: object StartedAt: format: date-time + nullable: true type: string Status: type: string UpdatedAt: format: date-time + nullable: true type: string type: object DrainSpec: example: IgnoreSystemJobs: true Deadline: 0 + nullable: true properties: Deadline: format: int64 @@ -82200,17 +82181,20 @@ components: IgnoreSystemJobs: true Deadline: 1 StartedAt: 2000-01-23T04:56:07.000+00:00 + nullable: true properties: Deadline: format: int64 type: integer ForceDeadline: format: date-time + nullable: true type: string IgnoreSystemJobs: type: boolean StartedAt: format: date-time + nullable: true type: string type: object DriverInfo: @@ -82221,6 +82205,7 @@ components: key: Attributes UpdateTime: 2000-01-23T04:56:07.000+00:00 Healthy: true + nullable: true properties: Attributes: additionalProperties: @@ -82234,6 +82219,7 @@ components: type: boolean UpdateTime: format: date-time + nullable: true type: string type: object Duration: @@ -82255,6 +82241,7 @@ components: EvalOptions: example: ForceReschedule: true + nullable: true properties: ForceReschedule: type: boolean @@ -82275,10 +82262,10 @@ components: RelatedEvals: - BlockedEval: BlockedEval Status: Status - ModifyTime: 7 + ModifyTime: 4 DeploymentID: DeploymentID - Priority: 1 - CreateTime: 2 + Priority: 7 + CreateTime: 3 Namespace: Namespace Type: Type CreateIndex: 2147483647 @@ -82293,10 +82280,10 @@ components: ModifyIndex: 2147483647 - BlockedEval: BlockedEval Status: Status - ModifyTime: 7 + ModifyTime: 4 DeploymentID: DeploymentID - Priority: 1 - CreateTime: 2 + Priority: 7 + CreateTime: 3 Namespace: Namespace Type: Type CreateIndex: 2147483647 @@ -82309,8 +82296,7 @@ components: WaitUntil: 2000-01-23T04:56:07.000+00:00 JobID: JobID ModifyIndex: 2147483647 - QueuedAllocations: - key: 9 + QueuedAllocations: {} BlockedEval: BlockedEval Status: Status DeploymentID: DeploymentID @@ -82318,35 +82304,27 @@ components: CreateTime: 6 FailedTGAllocs: key: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -82472,6 +82450,7 @@ components: Wait: 1 JobID: JobID ModifyIndex: 2147483647 + nullable: true properties: AnnotatePlan: type: boolean @@ -82527,7 +82506,7 @@ components: type: integer QueuedAllocations: additionalProperties: - type: integer + $ref: '#/components/schemas/int' type: object QuotaLimitReached: type: string @@ -82552,16 +82531,17 @@ components: type: integer WaitUntil: format: date-time + nullable: true type: string type: object EvaluationStub: example: BlockedEval: BlockedEval Status: Status - ModifyTime: 7 + ModifyTime: 4 DeploymentID: DeploymentID - Priority: 1 - CreateTime: 2 + Priority: 7 + CreateTime: 3 Namespace: Namespace Type: Type CreateIndex: 2147483647 @@ -82574,6 +82554,7 @@ components: WaitUntil: 2000-01-23T04:56:07.000+00:00 JobID: JobID ModifyIndex: 2147483647 + nullable: true properties: BlockedEval: type: string @@ -82617,6 +82598,7 @@ components: type: string WaitUntil: format: date-time + nullable: true type: string type: object FieldDiff: @@ -82628,6 +82610,7 @@ components: - Annotations Old: Old Name: Name + nullable: true properties: Annotations: items: @@ -82648,6 +82631,7 @@ components: - Scope - Scope ID: ID + nullable: true properties: ID: type: string @@ -82675,6 +82659,7 @@ components: Region: Region WaitTime: 1 AllowStale: true + nullable: true properties: AllowStale: type: boolean @@ -82734,6 +82719,7 @@ components: LastIndex: 2147483647 RequestTime: 1 KnownLeader: true + nullable: true properties: KnownLeader: type: boolean @@ -82766,6 +82752,7 @@ components: Labels: key: Labels Name: Name + nullable: true properties: Labels: additionalProperties: @@ -82783,6 +82770,7 @@ components: CIDR: CIDR Interface: Interface Name: Name + nullable: true properties: CIDR: type: string @@ -82797,6 +82785,7 @@ components: example: Path: Path ReadOnly: true + nullable: true properties: Path: type: string @@ -88008,6 +87997,7 @@ components: Payload: Payload ModifyIndex: 2147483647 NomadTokenID: NomadTokenID + nullable: true properties: Affinities: items: @@ -88111,6 +88101,7 @@ components: Dead: 0 Running: 1 Pending: 6 + nullable: true properties: Dead: format: int64 @@ -88132,6 +88123,7 @@ components: EvalID: EvalID KnownLeader: true JobModifyIndex: 2147483647 + nullable: true properties: EvalCreateIndex: maximum: 1.8446744073709552E+19 @@ -88300,8 +88292,7 @@ components: - null Name: Name Name: Name - Updates: - key: 2147483647 + Updates: {} Objects: - Type: Type Fields: @@ -88483,8 +88474,7 @@ components: - null Name: Name Name: Name - Updates: - key: 2147483647 + Updates: {} Objects: - Type: Type Fields: @@ -88585,6 +88575,7 @@ components: - null Name: Name ID: ID + nullable: true properties: Fields: items: @@ -88609,6 +88600,7 @@ components: key: Meta Payload: Payload JobID: JobID + nullable: true properties: JobID: type: string @@ -88628,6 +88620,7 @@ components: RequestTime: 5 JobCreateIndex: 2147483647 EvalID: EvalID + nullable: true properties: DispatchedJobID: type: string @@ -88657,6 +88650,7 @@ components: Region: Region JobID: JobID Namespace: Namespace + nullable: true properties: EvalOptions: $ref: '#/components/schemas/EvalOptions' @@ -88707,6 +88701,7 @@ components: - Datacenters ID: ID ModifyIndex: 2147483647 + nullable: true properties: CreateIndex: maximum: 1.8446744073709552E+19 @@ -93963,6 +93958,7 @@ components: ModifyIndex: 2147483647 NomadTokenID: NomadTokenID Namespace: Namespace + nullable: true properties: Diff: type: boolean @@ -94177,23 +94173,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -94203,23 +94199,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -94234,7 +94230,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -94256,10 +94252,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - ModifyTime: 5 PreemptedAllocations: @@ -94447,23 +94443,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -94473,23 +94469,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -94504,7 +94500,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -94526,10 +94522,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID NextPeriodicLaunch: 2000-01-23T04:56:07.000+00:00 Diff: @@ -94673,8 +94669,7 @@ components: - null Name: Name Name: Name - Updates: - key: 2147483647 + Updates: {} Objects: - Type: Type Fields: @@ -94856,8 +94851,7 @@ components: - null Name: Name Name: Name - Updates: - key: 2147483647 + Updates: {} Objects: - Type: Type Fields: @@ -94960,35 +94954,27 @@ components: ID: ID FailedTGAllocs: key: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -95118,10 +95104,10 @@ components: RelatedEvals: - BlockedEval: BlockedEval Status: Status - ModifyTime: 7 + ModifyTime: 4 DeploymentID: DeploymentID - Priority: 1 - CreateTime: 2 + Priority: 7 + CreateTime: 3 Namespace: Namespace Type: Type CreateIndex: 2147483647 @@ -95136,10 +95122,10 @@ components: ModifyIndex: 2147483647 - BlockedEval: BlockedEval Status: Status - ModifyTime: 7 + ModifyTime: 4 DeploymentID: DeploymentID - Priority: 1 - CreateTime: 2 + Priority: 7 + CreateTime: 3 Namespace: Namespace Type: Type CreateIndex: 2147483647 @@ -95152,8 +95138,7 @@ components: WaitUntil: 2000-01-23T04:56:07.000+00:00 JobID: JobID ModifyIndex: 2147483647 - QueuedAllocations: - key: 9 + QueuedAllocations: {} BlockedEval: BlockedEval Status: Status DeploymentID: DeploymentID @@ -95161,35 +95146,27 @@ components: CreateTime: 6 FailedTGAllocs: key: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -95329,10 +95306,10 @@ components: RelatedEvals: - BlockedEval: BlockedEval Status: Status - ModifyTime: 7 + ModifyTime: 4 DeploymentID: DeploymentID - Priority: 1 - CreateTime: 2 + Priority: 7 + CreateTime: 3 Namespace: Namespace Type: Type CreateIndex: 2147483647 @@ -95347,10 +95324,10 @@ components: ModifyIndex: 2147483647 - BlockedEval: BlockedEval Status: Status - ModifyTime: 7 + ModifyTime: 4 DeploymentID: DeploymentID - Priority: 1 - CreateTime: 2 + Priority: 7 + CreateTime: 3 Namespace: Namespace Type: Type CreateIndex: 2147483647 @@ -95363,8 +95340,7 @@ components: WaitUntil: 2000-01-23T04:56:07.000+00:00 JobID: JobID ModifyIndex: 2147483647 - QueuedAllocations: - key: 9 + QueuedAllocations: {} BlockedEval: BlockedEval Status: Status DeploymentID: DeploymentID @@ -95372,35 +95348,27 @@ components: CreateTime: 6 FailedTGAllocs: key: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -95528,6 +95496,7 @@ components: ModifyIndex: 2147483647 Warnings: Warnings JobModifyIndex: 2147483647 + nullable: true properties: Annotations: $ref: '#/components/schemas/PlanAnnotations' @@ -95547,6 +95516,7 @@ components: type: integer NextPeriodicLaunch: format: date-time + nullable: true type: string Warnings: type: string @@ -100765,6 +100735,7 @@ components: NomadTokenID: NomadTokenID Namespace: Namespace JobModifyIndex: 2147483647 + nullable: true properties: EnforceIndex: type: boolean @@ -100798,6 +100769,7 @@ components: KnownLeader: true Warnings: Warnings JobModifyIndex: 2147483647 + nullable: true properties: EvalCreateIndex: maximum: 1.8446744073709552E+19 @@ -100836,6 +100808,7 @@ components: JobID: JobID Namespace: Namespace EnforcePriorVersion: 2147483647 + nullable: true properties: ConsulToken: type: string @@ -100891,6 +100864,7 @@ components: JobID: JobID Namespace: Namespace JobModifyIndex: 2147483647 + nullable: true properties: JobCreateIndex: maximum: 1.8446744073709552E+19 @@ -100919,6 +100893,7 @@ components: JobVersion: 2147483647 JobID: JobID Namespace: Namespace + nullable: true properties: JobID: type: string @@ -100938,6 +100913,7 @@ components: JobStabilityResponse: example: Index: 2147483647 + nullable: true properties: Index: maximum: 1.8446744073709552E+19 @@ -100963,6 +100939,7 @@ components: JobID: JobID ModifyIndex: 2147483647 Namespace: Namespace + nullable: true properties: Children: $ref: '#/components/schemas/JobChildrenSummary' @@ -106192,6 +106169,7 @@ components: ModifyIndex: 2147483647 NomadTokenID: NomadTokenID Namespace: Namespace + nullable: true properties: Job: $ref: '#/components/schemas/Job' @@ -106210,6 +106188,7 @@ components: Error: Error DriverConfigValidated: true Warnings: Warnings + nullable: true properties: DriverConfigValidated: type: boolean @@ -106365,8 +106344,7 @@ components: - null Name: Name Name: Name - Updates: - key: 2147483647 + Updates: {} Objects: - Type: Type Fields: @@ -106548,8 +106526,7 @@ components: - null Name: Name Name: Name - Updates: - key: 2147483647 + Updates: {} Objects: - Type: Type Fields: @@ -106790,8 +106767,7 @@ components: - null Name: Name Name: Name - Updates: - key: 2147483647 + Updates: {} Objects: - Type: Type Fields: @@ -106973,8 +106949,7 @@ components: - null Name: Name Name: Name - Updates: - key: 2147483647 + Updates: {} Objects: - Type: Type Fields: @@ -117487,6 +117462,7 @@ components: LastIndex: 2147483647 RequestTime: 1 KnownLeader: true + nullable: true properties: Diffs: items: @@ -117516,6 +117492,7 @@ components: JobHCL: JobHCL hclv1: true Canonicalize: true + nullable: true properties: Canonicalize: type: boolean @@ -117597,6 +117574,7 @@ components: Labels: key: Labels Name: Name + nullable: true properties: Counters: items: @@ -117655,6 +117633,7 @@ components: - Datacenters Count: 9 Name: Name + nullable: true properties: Regions: items: @@ -117672,6 +117651,7 @@ components: - Datacenters Count: 9 Name: Name + nullable: true properties: Count: type: integer @@ -117712,6 +117692,7 @@ components: - EnabledTaskDrivers ModifyIndex: 2147483647 Name: Name + nullable: true properties: Capabilities: $ref: '#/components/schemas/NamespaceCapabilities' @@ -117742,6 +117723,7 @@ components: EnabledTaskDrivers: - EnabledTaskDrivers - EnabledTaskDrivers + nullable: true properties: DisabledTaskDrivers: items: @@ -117788,6 +117770,7 @@ components: To: 1 HostNetwork: HostNetwork MBits: 5 + nullable: true properties: CIDR: type: string @@ -118301,6 +118284,7 @@ components: Count: 2147483647 Name: Name MemoryMaxMB: 5 + nullable: true properties: Attributes: additionalProperties: @@ -118391,6 +118375,7 @@ components: - 46276 - 46276 TotalCpuCores: 60957 + nullable: true properties: CpuShares: format: int64 @@ -118413,6 +118398,7 @@ components: PciBusID: PciBusID ID: ID Healthy: true + nullable: true properties: HealthDescription: type: string @@ -118426,6 +118412,7 @@ components: NodeDeviceLocality: example: PciBusID: PciBusID + nullable: true properties: PciBusID: type: string @@ -118453,6 +118440,7 @@ components: Int: 2 Vendor: Vendor Name: Name + nullable: true properties: Attributes: additionalProperties: @@ -118472,6 +118460,7 @@ components: NodeDiskResources: example: DiskMB: 4 + nullable: true properties: DiskMB: format: int64 @@ -118486,6 +118475,7 @@ components: EvalIDs: - EvalIDs - EvalIDs + nullable: true properties: EvalCreateIndex: maximum: 1.8446744073709552E+19 @@ -118516,6 +118506,7 @@ components: EvalIDs: - EvalIDs - EvalIDs + nullable: true properties: EvalCreateIndex: maximum: 1.8446744073709552E+19 @@ -118545,6 +118536,7 @@ components: Message: Message Subsystem: Subsystem Timestamp: 2000-01-23T04:56:07.000+00:00 + nullable: true properties: CreateIndex: maximum: 1.8446744073709552E+19 @@ -118560,6 +118552,7 @@ components: type: string Timestamp: format: date-time + nullable: true type: string type: object NodeListStub: @@ -118727,6 +118720,7 @@ components: Datacenter: Datacenter ID: ID ModifyIndex: 2147483647 + nullable: true properties: Address: type: string @@ -118774,6 +118768,7 @@ components: NodeMemoryResources: example: MemoryMB: 1 + nullable: true properties: MemoryMB: format: int64 @@ -118786,6 +118781,7 @@ components: EvalIDs: - EvalIDs - EvalIDs + nullable: true properties: EvalCreateIndex: maximum: 1.8446744073709552E+19 @@ -118803,6 +118799,7 @@ components: NodeReservedCpuResources: example: CpuShares: 2147483647 + nullable: true properties: CpuShares: maximum: 1.8446744073709552E+19 @@ -118812,6 +118809,7 @@ components: NodeReservedDiskResources: example: DiskMB: 2147483647 + nullable: true properties: DiskMB: maximum: 1.8446744073709552E+19 @@ -118821,6 +118819,7 @@ components: NodeReservedMemoryResources: example: MemoryMB: 2147483647 + nullable: true properties: MemoryMB: maximum: 1.8446744073709552E+19 @@ -118830,6 +118829,7 @@ components: NodeReservedNetworkResources: example: ReservedHostPorts: ReservedHostPorts + nullable: true properties: ReservedHostPorts: type: string @@ -118844,6 +118844,7 @@ components: CpuShares: 2147483647 Disk: DiskMB: 2147483647 + nullable: true properties: Cpu: $ref: '#/components/schemas/NodeReservedCpuResources' @@ -118980,6 +118981,7 @@ components: Name: Name Disk: DiskMB: 4 + nullable: true properties: Cpu: $ref: '#/components/schemas/NodeCpuResources' @@ -119002,10 +119004,10 @@ components: type: object NodeScoreMeta: example: - NormScore: 0.4768402382624515 + NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 + Scores: {} + nullable: true properties: NodeID: type: string @@ -119014,8 +119016,7 @@ components: type: number Scores: additionalProperties: - format: double - type: number + $ref: '#/components/schemas/float64' type: object type: object NodeUpdateDrainRequest: @@ -119027,6 +119028,7 @@ components: key: Meta MarkEligible: true NodeID: NodeID + nullable: true properties: DrainSpec: $ref: '#/components/schemas/DrainSpec' @@ -119043,6 +119045,7 @@ components: example: Eligibility: Eligibility NodeID: NodeID + nullable: true properties: Eligibility: type: string @@ -119071,6 +119074,7 @@ components: - null - null Name: Name + nullable: true properties: Fields: items: @@ -119092,6 +119096,7 @@ components: ExpiresAt: 2000-01-23T04:56:07.000+00:00 AccessorID: AccessorID ModifyIndex: 2147483647 + nullable: true properties: AccessorID: type: string @@ -119101,6 +119106,7 @@ components: type: integer ExpiresAt: format: date-time + nullable: true type: string ModifyIndex: maximum: 1.8446744073709552E+19 @@ -119112,6 +119118,7 @@ components: OneTimeTokenExchangeRequest: example: OneTimeSecretID: OneTimeSecretID + nullable: true properties: OneTimeSecretID: type: string @@ -119145,6 +119152,7 @@ components: LastTerm: 2147483647 Name: Name Healthy: true + nullable: true properties: FailureTolerance: type: integer @@ -119164,6 +119172,7 @@ components: MetaRequired: - MetaRequired - MetaRequired + nullable: true properties: MetaOptional: items: @@ -119200,6 +119209,7 @@ components: EvalCreateIndex: 2147483647 Index: 2147483647 EvalID: EvalID + nullable: true properties: EvalCreateIndex: maximum: 1.8446744073709552E+19 @@ -119411,23 +119421,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -119437,23 +119447,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -119468,7 +119478,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -119490,10 +119500,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - ModifyTime: 5 PreemptedAllocations: @@ -119681,23 +119691,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -119707,23 +119717,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -119738,7 +119748,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -119760,11 +119770,12 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID + nullable: true properties: DesiredTGUpdates: additionalProperties: @@ -119781,6 +119792,7 @@ components: - 3.6160767 - 3.6160767 Name: Name + nullable: true properties: Name: type: string @@ -119796,6 +119808,7 @@ components: Value: 5 To: 1 HostNetwork: HostNetwork + nullable: true properties: HostNetwork: type: string @@ -119812,6 +119825,7 @@ components: Label: Label Value: 7 To: 2 + nullable: true properties: HostIP: type: string @@ -119828,6 +119842,7 @@ components: BatchSchedulerEnabled: true ServiceSchedulerEnabled: true SysBatchSchedulerEnabled: true + nullable: true properties: BatchSchedulerEnabled: type: boolean @@ -119955,6 +119970,7 @@ components: Count: 2147483647 Name: Name MemoryMaxMB: 5 + nullable: true properties: Hash: format: byte @@ -120201,6 +120217,7 @@ components: MemoryMaxMB: 5 ModifyIndex: 2147483647 Name: Name + nullable: true properties: CreateIndex: maximum: 1.8446744073709552E+19 @@ -120236,6 +120253,7 @@ components: Voter: true ID: ID RaftProtocol: RaftProtocol + nullable: true properties: Index: maximum: 1.8446744073709552E+19 @@ -120254,6 +120272,7 @@ components: Voter: true ID: ID RaftProtocol: RaftProtocol + nullable: true properties: Address: type: string @@ -120288,6 +120307,7 @@ components: Weight: -101 Count: 2147483647 Name: Name + nullable: true properties: Affinities: items: @@ -120307,8 +120327,9 @@ components: RescheduleEvent: example: PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID + nullable: true properties: PrevAllocID: type: string @@ -120347,11 +120368,12 @@ components: example: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID + nullable: true properties: Events: items: @@ -120472,6 +120494,7 @@ components: Count: 2147483647 Name: Name MemoryMaxMB: 5 + nullable: true properties: CPU: type: integer @@ -120524,6 +120547,7 @@ components: Sum: 7.061401241503109 Count: 0 Name: Name + nullable: true properties: Count: type: integer @@ -120563,6 +120587,7 @@ components: Time: 2147483647 Count: 5 EvalID: EvalID + nullable: true properties: Count: format: int64 @@ -120602,6 +120627,7 @@ components: ID: ID ModifyIndex: 2147483647 Namespace: Namespace + nullable: true properties: CreateIndex: maximum: 1.8446744073709552E+19 @@ -120642,6 +120668,7 @@ components: Enabled: true ID: ID ModifyIndex: 2147483647 + nullable: true properties: CreateIndex: maximum: 1.8446744073709552E+19 @@ -120675,6 +120702,7 @@ components: Region: Region Count: 0 Namespace: Namespace + nullable: true properties: Count: format: int64 @@ -120714,6 +120742,7 @@ components: RejectJobRegistration: true SchedulerAlgorithm: SchedulerAlgorithm ModifyIndex: 2147483647 + nullable: true properties: CreateIndex: maximum: 1.8446744073709552E+19 @@ -120753,6 +120782,7 @@ components: RejectJobRegistration: true SchedulerAlgorithm: SchedulerAlgorithm ModifyIndex: 2147483647 + nullable: true properties: KnownLeader: type: boolean @@ -120776,6 +120806,7 @@ components: Updated: true LastIndex: 2147483647 RequestTime: 6 + nullable: true properties: LastIndex: maximum: 1.8446744073709552E+19 @@ -120805,6 +120836,7 @@ components: Region: Region WaitTime: 1 AllowStale: true + nullable: true properties: AllowStale: type: boolean @@ -120856,6 +120888,7 @@ components: LastIndex: 2147483647 RequestTime: 1 KnownLeader: true + nullable: true properties: KnownLeader: type: boolean @@ -120896,6 +120929,7 @@ components: Healthy: true LastTerm: 2147483647 Name: Name + nullable: true properties: Address: type: string @@ -120922,6 +120956,7 @@ components: type: string StableSince: format: date-time + nullable: true type: string Version: type: string @@ -121243,6 +121278,7 @@ components: Grace: 0 IgnoreWarnings: true Limit: 4 + nullable: true properties: Address: type: string @@ -121323,6 +121359,7 @@ components: IgnoreWarnings: true Limit: 4 Interval: 7 + nullable: true properties: AddressMode: type: string @@ -121397,6 +121434,7 @@ components: Tags: - Tags - Tags + nullable: true properties: Address: type: string @@ -121559,6 +121597,7 @@ components: MaxFiles: 4 MaxFileSizeMB: 1 Name: Name + nullable: true properties: Config: additionalProperties: {} @@ -121599,6 +121638,7 @@ components: - Percent: 177 Value: Value Weight: -95 + nullable: true properties: Attribute: type: string @@ -121615,6 +121655,7 @@ components: example: Percent: 177 Value: Value + nullable: true properties: Percent: maximum: 255 @@ -122499,6 +122540,7 @@ components: LogConfig: MaxFiles: 4 MaxFileSizeMB: 1 + nullable: true properties: Affinities: items: @@ -122581,6 +122623,7 @@ components: GetterOptions: key: GetterOptions GetterSource: GetterSource + nullable: true properties: GetterHeaders: additionalProperties: @@ -122603,6 +122646,7 @@ components: Type: Type ID: ID MountDir: MountDir + nullable: true properties: HealthTimeout: format: int64 @@ -122677,6 +122721,7 @@ components: - null Name: Name Name: Name + nullable: true properties: Annotations: items: @@ -122699,23 +122744,23 @@ components: example: KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -122723,6 +122768,7 @@ components: key: Details DisplayMessage: DisplayMessage KillError: KillError + nullable: true properties: Details: additionalProperties: @@ -125327,6 +125373,7 @@ components: SizeMB: 6 Migrate: true Sticky: true + nullable: true properties: Affinities: items: @@ -125529,8 +125576,7 @@ components: - null Name: Name Name: Name - Updates: - key: 2147483647 + Updates: {} Objects: - Type: Type Fields: @@ -125573,6 +125619,7 @@ components: - null Name: Name Name: Name + nullable: true properties: Fields: items: @@ -125592,9 +125639,7 @@ components: type: string Updates: additionalProperties: - maximum: 1.8446744073709552E+19 - minimum: 0 - type: integer + $ref: '#/components/schemas/uint64' type: object type: object TaskGroupScaleStatus: @@ -125623,6 +125668,7 @@ components: Desired: 1 Healthy: 9 Placed: 3 + nullable: true properties: Desired: type: integer @@ -125648,6 +125694,7 @@ components: Starting: 4 Running: 2 Queued: 3 + nullable: true properties: Complete: type: integer @@ -125666,8 +125713,9 @@ components: type: object TaskHandle: example: - Version: 6 + Version: 0 DriverState: DriverState + nullable: true properties: DriverState: format: byte @@ -125679,6 +125727,7 @@ components: example: Hook: Hook Sidecar: true + nullable: true properties: Hook: type: string @@ -125690,23 +125739,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -125716,23 +125765,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -125747,8 +125796,9 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState + nullable: true properties: Events: items: @@ -125758,9 +125808,11 @@ components: type: boolean FinishedAt: format: date-time + nullable: true type: string LastRestart: format: date-time + nullable: true type: string Restarts: maximum: 1.8446744073709552E+19 @@ -125768,6 +125820,7 @@ components: type: integer StartedAt: format: date-time + nullable: true type: string State: type: string @@ -125820,6 +125873,7 @@ components: type: object Time: format: date-time + nullable: true type: string UpdateStrategy: example: @@ -125865,6 +125919,7 @@ components: Env: true Namespace: Namespace ChangeMode: ChangeMode + nullable: true properties: ChangeMode: type: string @@ -125909,6 +125964,7 @@ components: FSType: FSType Source: Source Name: Name + nullable: true properties: AccessMode: type: string diff --git a/clients/go/v1/api_acl.go b/clients/go/v1/api_acl.go index 675ec544..e3a48c51 100644 --- a/clients/go/v1/api_acl.go +++ b/clients/go/v1/api_acl.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -13,23 +13,23 @@ package client import ( "bytes" - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" + "context" + "io/ioutil" + "net/http" + "net/url" "strings" ) // Linger please var ( - _ _context.Context + _ context.Context ) // ACLApiService ACLApi service type ACLApiService service type ApiDeleteACLPolicyRequest struct { - ctx _context.Context + ctx context.Context ApiService *ACLApiService policyName string region *string @@ -38,34 +38,39 @@ type ApiDeleteACLPolicyRequest struct { idempotencyToken *string } +// Filters results based on the specified region. func (r ApiDeleteACLPolicyRequest) Region(region string) ApiDeleteACLPolicyRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiDeleteACLPolicyRequest) Namespace(namespace string) ApiDeleteACLPolicyRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiDeleteACLPolicyRequest) XNomadToken(xNomadToken string) ApiDeleteACLPolicyRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiDeleteACLPolicyRequest) IdempotencyToken(idempotencyToken string) ApiDeleteACLPolicyRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiDeleteACLPolicyRequest) Execute() (*_nethttp.Response, error) { +func (r ApiDeleteACLPolicyRequest) Execute() (*http.Response, error) { return r.ApiService.DeleteACLPolicyExecute(r) } /* - * DeleteACLPolicy Method for DeleteACLPolicy - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param policyName The ACL policy name. - * @return ApiDeleteACLPolicyRequest - */ -func (a *ACLApiService) DeleteACLPolicy(ctx _context.Context, policyName string) ApiDeleteACLPolicyRequest { +DeleteACLPolicy Method for DeleteACLPolicy + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param policyName The ACL policy name. + @return ApiDeleteACLPolicyRequest +*/ +func (a *ACLApiService) DeleteACLPolicy(ctx context.Context, policyName string) ApiDeleteACLPolicyRequest { return ApiDeleteACLPolicyRequest{ ApiService: a, ctx: ctx, @@ -73,29 +78,25 @@ func (a *ACLApiService) DeleteACLPolicy(ctx _context.Context, policyName string) } } -/* - * Execute executes the request - */ -func (a *ACLApiService) DeleteACLPolicyExecute(r ApiDeleteACLPolicyRequest) (*_nethttp.Response, error) { +// Execute executes the request +func (a *ACLApiService) DeleteACLPolicyExecute(r ApiDeleteACLPolicyRequest) (*http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodDelete + localVarHTTPMethod = http.MethodDelete localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ACLApiService.DeleteACLPolicy") if err != nil { - return nil, GenericOpenAPIError{error: err.Error()} + return nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/acl/policy/{policyName}" - localVarPath = strings.Replace(localVarPath, "{"+"policyName"+"}", _neturl.PathEscape(parameterToString(r.policyName, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"policyName"+"}", url.PathEscape(parameterToString(r.policyName, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -140,7 +141,7 @@ func (a *ACLApiService) DeleteACLPolicyExecute(r ApiDeleteACLPolicyRequest) (*_n } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return nil, err } @@ -150,15 +151,15 @@ func (a *ACLApiService) DeleteACLPolicyExecute(r ApiDeleteACLPolicyRequest) (*_n return localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -169,7 +170,7 @@ func (a *ACLApiService) DeleteACLPolicyExecute(r ApiDeleteACLPolicyRequest) (*_n } type ApiDeleteACLTokenRequest struct { - ctx _context.Context + ctx context.Context ApiService *ACLApiService tokenAccessor string region *string @@ -178,34 +179,39 @@ type ApiDeleteACLTokenRequest struct { idempotencyToken *string } +// Filters results based on the specified region. func (r ApiDeleteACLTokenRequest) Region(region string) ApiDeleteACLTokenRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiDeleteACLTokenRequest) Namespace(namespace string) ApiDeleteACLTokenRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiDeleteACLTokenRequest) XNomadToken(xNomadToken string) ApiDeleteACLTokenRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiDeleteACLTokenRequest) IdempotencyToken(idempotencyToken string) ApiDeleteACLTokenRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiDeleteACLTokenRequest) Execute() (*_nethttp.Response, error) { +func (r ApiDeleteACLTokenRequest) Execute() (*http.Response, error) { return r.ApiService.DeleteACLTokenExecute(r) } /* - * DeleteACLToken Method for DeleteACLToken - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param tokenAccessor The token accessor ID. - * @return ApiDeleteACLTokenRequest - */ -func (a *ACLApiService) DeleteACLToken(ctx _context.Context, tokenAccessor string) ApiDeleteACLTokenRequest { +DeleteACLToken Method for DeleteACLToken + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param tokenAccessor The token accessor ID. + @return ApiDeleteACLTokenRequest +*/ +func (a *ACLApiService) DeleteACLToken(ctx context.Context, tokenAccessor string) ApiDeleteACLTokenRequest { return ApiDeleteACLTokenRequest{ ApiService: a, ctx: ctx, @@ -213,29 +219,25 @@ func (a *ACLApiService) DeleteACLToken(ctx _context.Context, tokenAccessor strin } } -/* - * Execute executes the request - */ -func (a *ACLApiService) DeleteACLTokenExecute(r ApiDeleteACLTokenRequest) (*_nethttp.Response, error) { +// Execute executes the request +func (a *ACLApiService) DeleteACLTokenExecute(r ApiDeleteACLTokenRequest) (*http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodDelete + localVarHTTPMethod = http.MethodDelete localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ACLApiService.DeleteACLToken") if err != nil { - return nil, GenericOpenAPIError{error: err.Error()} + return nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/acl/token/{tokenAccessor}" - localVarPath = strings.Replace(localVarPath, "{"+"tokenAccessor"+"}", _neturl.PathEscape(parameterToString(r.tokenAccessor, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"tokenAccessor"+"}", url.PathEscape(parameterToString(r.tokenAccessor, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -280,7 +282,7 @@ func (a *ACLApiService) DeleteACLTokenExecute(r ApiDeleteACLTokenRequest) (*_net } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return nil, err } @@ -290,15 +292,15 @@ func (a *ACLApiService) DeleteACLTokenExecute(r ApiDeleteACLTokenRequest) (*_net return localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -309,7 +311,7 @@ func (a *ACLApiService) DeleteACLTokenExecute(r ApiDeleteACLTokenRequest) (*_net } type ApiGetACLPoliciesRequest struct { - ctx _context.Context + ctx context.Context ApiService *ACLApiService region *string namespace *string @@ -322,83 +324,89 @@ type ApiGetACLPoliciesRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetACLPoliciesRequest) Region(region string) ApiGetACLPoliciesRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetACLPoliciesRequest) Namespace(namespace string) ApiGetACLPoliciesRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetACLPoliciesRequest) Index(index int32) ApiGetACLPoliciesRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetACLPoliciesRequest) Wait(wait string) ApiGetACLPoliciesRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetACLPoliciesRequest) Stale(stale string) ApiGetACLPoliciesRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetACLPoliciesRequest) Prefix(prefix string) ApiGetACLPoliciesRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetACLPoliciesRequest) XNomadToken(xNomadToken string) ApiGetACLPoliciesRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetACLPoliciesRequest) PerPage(perPage int32) ApiGetACLPoliciesRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetACLPoliciesRequest) NextToken(nextToken string) ApiGetACLPoliciesRequest { r.nextToken = &nextToken return r } -func (r ApiGetACLPoliciesRequest) Execute() ([]ACLPolicyListStub, *_nethttp.Response, error) { +func (r ApiGetACLPoliciesRequest) Execute() ([]ACLPolicyListStub, *http.Response, error) { return r.ApiService.GetACLPoliciesExecute(r) } /* - * GetACLPolicies Method for GetACLPolicies - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiGetACLPoliciesRequest - */ -func (a *ACLApiService) GetACLPolicies(ctx _context.Context) ApiGetACLPoliciesRequest { +GetACLPolicies Method for GetACLPolicies + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiGetACLPoliciesRequest +*/ +func (a *ACLApiService) GetACLPolicies(ctx context.Context) ApiGetACLPoliciesRequest { return ApiGetACLPoliciesRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return []ACLPolicyListStub - */ -func (a *ACLApiService) GetACLPoliciesExecute(r ApiGetACLPoliciesRequest) ([]ACLPolicyListStub, *_nethttp.Response, error) { +// Execute executes the request +// @return []ACLPolicyListStub +func (a *ACLApiService) GetACLPoliciesExecute(r ApiGetACLPoliciesRequest) ([]ACLPolicyListStub, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile localVarReturnValue []ACLPolicyListStub ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ACLApiService.GetACLPolicies") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/acl/policies" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -458,7 +466,7 @@ func (a *ACLApiService) GetACLPoliciesExecute(r ApiGetACLPoliciesRequest) ([]ACL } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -468,15 +476,15 @@ func (a *ACLApiService) GetACLPoliciesExecute(r ApiGetACLPoliciesRequest) ([]ACL return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -485,7 +493,7 @@ func (a *ACLApiService) GetACLPoliciesExecute(r ApiGetACLPoliciesRequest) ([]ACL err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -496,7 +504,7 @@ func (a *ACLApiService) GetACLPoliciesExecute(r ApiGetACLPoliciesRequest) ([]ACL } type ApiGetACLPolicyRequest struct { - ctx _context.Context + ctx context.Context ApiService *ACLApiService policyName string region *string @@ -510,54 +518,64 @@ type ApiGetACLPolicyRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetACLPolicyRequest) Region(region string) ApiGetACLPolicyRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetACLPolicyRequest) Namespace(namespace string) ApiGetACLPolicyRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetACLPolicyRequest) Index(index int32) ApiGetACLPolicyRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetACLPolicyRequest) Wait(wait string) ApiGetACLPolicyRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetACLPolicyRequest) Stale(stale string) ApiGetACLPolicyRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetACLPolicyRequest) Prefix(prefix string) ApiGetACLPolicyRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetACLPolicyRequest) XNomadToken(xNomadToken string) ApiGetACLPolicyRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetACLPolicyRequest) PerPage(perPage int32) ApiGetACLPolicyRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetACLPolicyRequest) NextToken(nextToken string) ApiGetACLPolicyRequest { r.nextToken = &nextToken return r } -func (r ApiGetACLPolicyRequest) Execute() (ACLPolicy, *_nethttp.Response, error) { +func (r ApiGetACLPolicyRequest) Execute() (*ACLPolicy, *http.Response, error) { return r.ApiService.GetACLPolicyExecute(r) } /* - * GetACLPolicy Method for GetACLPolicy - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param policyName The ACL policy name. - * @return ApiGetACLPolicyRequest - */ -func (a *ACLApiService) GetACLPolicy(ctx _context.Context, policyName string) ApiGetACLPolicyRequest { +GetACLPolicy Method for GetACLPolicy + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param policyName The ACL policy name. + @return ApiGetACLPolicyRequest +*/ +func (a *ACLApiService) GetACLPolicy(ctx context.Context, policyName string) ApiGetACLPolicyRequest { return ApiGetACLPolicyRequest{ ApiService: a, ctx: ctx, @@ -565,31 +583,27 @@ func (a *ACLApiService) GetACLPolicy(ctx _context.Context, policyName string) Ap } } -/* - * Execute executes the request - * @return ACLPolicy - */ -func (a *ACLApiService) GetACLPolicyExecute(r ApiGetACLPolicyRequest) (ACLPolicy, *_nethttp.Response, error) { +// Execute executes the request +// @return ACLPolicy +func (a *ACLApiService) GetACLPolicyExecute(r ApiGetACLPolicyRequest) (*ACLPolicy, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ACLPolicy + formFiles []formFile + localVarReturnValue *ACLPolicy ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ACLApiService.GetACLPolicy") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/acl/policy/{policyName}" - localVarPath = strings.Replace(localVarPath, "{"+"policyName"+"}", _neturl.PathEscape(parameterToString(r.policyName, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"policyName"+"}", url.PathEscape(parameterToString(r.policyName, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -649,7 +663,7 @@ func (a *ACLApiService) GetACLPolicyExecute(r ApiGetACLPolicyRequest) (ACLPolicy } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -659,15 +673,15 @@ func (a *ACLApiService) GetACLPolicyExecute(r ApiGetACLPolicyRequest) (ACLPolicy return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -676,7 +690,7 @@ func (a *ACLApiService) GetACLPolicyExecute(r ApiGetACLPolicyRequest) (ACLPolicy err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -687,7 +701,7 @@ func (a *ACLApiService) GetACLPolicyExecute(r ApiGetACLPolicyRequest) (ACLPolicy } type ApiGetACLTokenRequest struct { - ctx _context.Context + ctx context.Context ApiService *ACLApiService tokenAccessor string region *string @@ -701,54 +715,64 @@ type ApiGetACLTokenRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetACLTokenRequest) Region(region string) ApiGetACLTokenRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetACLTokenRequest) Namespace(namespace string) ApiGetACLTokenRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetACLTokenRequest) Index(index int32) ApiGetACLTokenRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetACLTokenRequest) Wait(wait string) ApiGetACLTokenRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetACLTokenRequest) Stale(stale string) ApiGetACLTokenRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetACLTokenRequest) Prefix(prefix string) ApiGetACLTokenRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetACLTokenRequest) XNomadToken(xNomadToken string) ApiGetACLTokenRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetACLTokenRequest) PerPage(perPage int32) ApiGetACLTokenRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetACLTokenRequest) NextToken(nextToken string) ApiGetACLTokenRequest { r.nextToken = &nextToken return r } -func (r ApiGetACLTokenRequest) Execute() (ACLToken, *_nethttp.Response, error) { +func (r ApiGetACLTokenRequest) Execute() (*ACLToken, *http.Response, error) { return r.ApiService.GetACLTokenExecute(r) } /* - * GetACLToken Method for GetACLToken - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param tokenAccessor The token accessor ID. - * @return ApiGetACLTokenRequest - */ -func (a *ACLApiService) GetACLToken(ctx _context.Context, tokenAccessor string) ApiGetACLTokenRequest { +GetACLToken Method for GetACLToken + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param tokenAccessor The token accessor ID. + @return ApiGetACLTokenRequest +*/ +func (a *ACLApiService) GetACLToken(ctx context.Context, tokenAccessor string) ApiGetACLTokenRequest { return ApiGetACLTokenRequest{ ApiService: a, ctx: ctx, @@ -756,31 +780,27 @@ func (a *ACLApiService) GetACLToken(ctx _context.Context, tokenAccessor string) } } -/* - * Execute executes the request - * @return ACLToken - */ -func (a *ACLApiService) GetACLTokenExecute(r ApiGetACLTokenRequest) (ACLToken, *_nethttp.Response, error) { +// Execute executes the request +// @return ACLToken +func (a *ACLApiService) GetACLTokenExecute(r ApiGetACLTokenRequest) (*ACLToken, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ACLToken + formFiles []formFile + localVarReturnValue *ACLToken ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ACLApiService.GetACLToken") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/acl/token/{tokenAccessor}" - localVarPath = strings.Replace(localVarPath, "{"+"tokenAccessor"+"}", _neturl.PathEscape(parameterToString(r.tokenAccessor, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"tokenAccessor"+"}", url.PathEscape(parameterToString(r.tokenAccessor, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -840,7 +860,7 @@ func (a *ACLApiService) GetACLTokenExecute(r ApiGetACLTokenRequest) (ACLToken, * } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -850,15 +870,15 @@ func (a *ACLApiService) GetACLTokenExecute(r ApiGetACLTokenRequest) (ACLToken, * return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -867,7 +887,7 @@ func (a *ACLApiService) GetACLTokenExecute(r ApiGetACLTokenRequest) (ACLToken, * err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -878,7 +898,7 @@ func (a *ACLApiService) GetACLTokenExecute(r ApiGetACLTokenRequest) (ACLToken, * } type ApiGetACLTokenSelfRequest struct { - ctx _context.Context + ctx context.Context ApiService *ACLApiService region *string namespace *string @@ -891,83 +911,89 @@ type ApiGetACLTokenSelfRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetACLTokenSelfRequest) Region(region string) ApiGetACLTokenSelfRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetACLTokenSelfRequest) Namespace(namespace string) ApiGetACLTokenSelfRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetACLTokenSelfRequest) Index(index int32) ApiGetACLTokenSelfRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetACLTokenSelfRequest) Wait(wait string) ApiGetACLTokenSelfRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetACLTokenSelfRequest) Stale(stale string) ApiGetACLTokenSelfRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetACLTokenSelfRequest) Prefix(prefix string) ApiGetACLTokenSelfRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetACLTokenSelfRequest) XNomadToken(xNomadToken string) ApiGetACLTokenSelfRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetACLTokenSelfRequest) PerPage(perPage int32) ApiGetACLTokenSelfRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetACLTokenSelfRequest) NextToken(nextToken string) ApiGetACLTokenSelfRequest { r.nextToken = &nextToken return r } -func (r ApiGetACLTokenSelfRequest) Execute() (ACLToken, *_nethttp.Response, error) { +func (r ApiGetACLTokenSelfRequest) Execute() (*ACLToken, *http.Response, error) { return r.ApiService.GetACLTokenSelfExecute(r) } /* - * GetACLTokenSelf Method for GetACLTokenSelf - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiGetACLTokenSelfRequest - */ -func (a *ACLApiService) GetACLTokenSelf(ctx _context.Context) ApiGetACLTokenSelfRequest { +GetACLTokenSelf Method for GetACLTokenSelf + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiGetACLTokenSelfRequest +*/ +func (a *ACLApiService) GetACLTokenSelf(ctx context.Context) ApiGetACLTokenSelfRequest { return ApiGetACLTokenSelfRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return ACLToken - */ -func (a *ACLApiService) GetACLTokenSelfExecute(r ApiGetACLTokenSelfRequest) (ACLToken, *_nethttp.Response, error) { +// Execute executes the request +// @return ACLToken +func (a *ACLApiService) GetACLTokenSelfExecute(r ApiGetACLTokenSelfRequest) (*ACLToken, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ACLToken + formFiles []formFile + localVarReturnValue *ACLToken ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ACLApiService.GetACLTokenSelf") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/acl/token" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -1027,7 +1053,7 @@ func (a *ACLApiService) GetACLTokenSelfExecute(r ApiGetACLTokenSelfRequest) (ACL } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -1037,15 +1063,15 @@ func (a *ACLApiService) GetACLTokenSelfExecute(r ApiGetACLTokenSelfRequest) (ACL return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -1054,7 +1080,7 @@ func (a *ACLApiService) GetACLTokenSelfExecute(r ApiGetACLTokenSelfRequest) (ACL err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -1065,7 +1091,7 @@ func (a *ACLApiService) GetACLTokenSelfExecute(r ApiGetACLTokenSelfRequest) (ACL } type ApiGetACLTokensRequest struct { - ctx _context.Context + ctx context.Context ApiService *ACLApiService region *string namespace *string @@ -1078,83 +1104,89 @@ type ApiGetACLTokensRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetACLTokensRequest) Region(region string) ApiGetACLTokensRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetACLTokensRequest) Namespace(namespace string) ApiGetACLTokensRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetACLTokensRequest) Index(index int32) ApiGetACLTokensRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetACLTokensRequest) Wait(wait string) ApiGetACLTokensRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetACLTokensRequest) Stale(stale string) ApiGetACLTokensRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetACLTokensRequest) Prefix(prefix string) ApiGetACLTokensRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetACLTokensRequest) XNomadToken(xNomadToken string) ApiGetACLTokensRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetACLTokensRequest) PerPage(perPage int32) ApiGetACLTokensRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetACLTokensRequest) NextToken(nextToken string) ApiGetACLTokensRequest { r.nextToken = &nextToken return r } -func (r ApiGetACLTokensRequest) Execute() ([]ACLTokenListStub, *_nethttp.Response, error) { +func (r ApiGetACLTokensRequest) Execute() ([]ACLTokenListStub, *http.Response, error) { return r.ApiService.GetACLTokensExecute(r) } /* - * GetACLTokens Method for GetACLTokens - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiGetACLTokensRequest - */ -func (a *ACLApiService) GetACLTokens(ctx _context.Context) ApiGetACLTokensRequest { +GetACLTokens Method for GetACLTokens + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiGetACLTokensRequest +*/ +func (a *ACLApiService) GetACLTokens(ctx context.Context) ApiGetACLTokensRequest { return ApiGetACLTokensRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return []ACLTokenListStub - */ -func (a *ACLApiService) GetACLTokensExecute(r ApiGetACLTokensRequest) ([]ACLTokenListStub, *_nethttp.Response, error) { +// Execute executes the request +// @return []ACLTokenListStub +func (a *ACLApiService) GetACLTokensExecute(r ApiGetACLTokensRequest) ([]ACLTokenListStub, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile localVarReturnValue []ACLTokenListStub ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ACLApiService.GetACLTokens") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/acl/tokens" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -1214,7 +1246,7 @@ func (a *ACLApiService) GetACLTokensExecute(r ApiGetACLTokensRequest) ([]ACLToke } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -1224,15 +1256,15 @@ func (a *ACLApiService) GetACLTokensExecute(r ApiGetACLTokensRequest) ([]ACLToke return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -1241,7 +1273,7 @@ func (a *ACLApiService) GetACLTokensExecute(r ApiGetACLTokensRequest) ([]ACLToke err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -1252,7 +1284,7 @@ func (a *ACLApiService) GetACLTokensExecute(r ApiGetACLTokensRequest) ([]ACLToke } type ApiPostACLBootstrapRequest struct { - ctx _context.Context + ctx context.Context ApiService *ACLApiService region *string namespace *string @@ -1260,63 +1292,64 @@ type ApiPostACLBootstrapRequest struct { idempotencyToken *string } +// Filters results based on the specified region. func (r ApiPostACLBootstrapRequest) Region(region string) ApiPostACLBootstrapRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiPostACLBootstrapRequest) Namespace(namespace string) ApiPostACLBootstrapRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiPostACLBootstrapRequest) XNomadToken(xNomadToken string) ApiPostACLBootstrapRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiPostACLBootstrapRequest) IdempotencyToken(idempotencyToken string) ApiPostACLBootstrapRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiPostACLBootstrapRequest) Execute() (ACLToken, *_nethttp.Response, error) { +func (r ApiPostACLBootstrapRequest) Execute() (*ACLToken, *http.Response, error) { return r.ApiService.PostACLBootstrapExecute(r) } /* - * PostACLBootstrap Method for PostACLBootstrap - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiPostACLBootstrapRequest - */ -func (a *ACLApiService) PostACLBootstrap(ctx _context.Context) ApiPostACLBootstrapRequest { +PostACLBootstrap Method for PostACLBootstrap + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiPostACLBootstrapRequest +*/ +func (a *ACLApiService) PostACLBootstrap(ctx context.Context) ApiPostACLBootstrapRequest { return ApiPostACLBootstrapRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return ACLToken - */ -func (a *ACLApiService) PostACLBootstrapExecute(r ApiPostACLBootstrapRequest) (ACLToken, *_nethttp.Response, error) { +// Execute executes the request +// @return ACLToken +func (a *ACLApiService) PostACLBootstrapExecute(r ApiPostACLBootstrapRequest) (*ACLToken, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ACLToken + formFiles []formFile + localVarReturnValue *ACLToken ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ACLApiService.PostACLBootstrap") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/acl/bootstrap" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -1361,7 +1394,7 @@ func (a *ACLApiService) PostACLBootstrapExecute(r ApiPostACLBootstrapRequest) (A } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -1371,15 +1404,15 @@ func (a *ACLApiService) PostACLBootstrapExecute(r ApiPostACLBootstrapRequest) (A return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -1388,7 +1421,7 @@ func (a *ACLApiService) PostACLBootstrapExecute(r ApiPostACLBootstrapRequest) (A err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -1399,7 +1432,7 @@ func (a *ACLApiService) PostACLBootstrapExecute(r ApiPostACLBootstrapRequest) (A } type ApiPostACLPolicyRequest struct { - ctx _context.Context + ctx context.Context ApiService *ACLApiService policyName string aCLPolicy *ACLPolicy @@ -1413,34 +1446,39 @@ func (r ApiPostACLPolicyRequest) ACLPolicy(aCLPolicy ACLPolicy) ApiPostACLPolicy r.aCLPolicy = &aCLPolicy return r } +// Filters results based on the specified region. func (r ApiPostACLPolicyRequest) Region(region string) ApiPostACLPolicyRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiPostACLPolicyRequest) Namespace(namespace string) ApiPostACLPolicyRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiPostACLPolicyRequest) XNomadToken(xNomadToken string) ApiPostACLPolicyRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiPostACLPolicyRequest) IdempotencyToken(idempotencyToken string) ApiPostACLPolicyRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiPostACLPolicyRequest) Execute() (*_nethttp.Response, error) { +func (r ApiPostACLPolicyRequest) Execute() (*http.Response, error) { return r.ApiService.PostACLPolicyExecute(r) } /* - * PostACLPolicy Method for PostACLPolicy - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param policyName The ACL policy name. - * @return ApiPostACLPolicyRequest - */ -func (a *ACLApiService) PostACLPolicy(ctx _context.Context, policyName string) ApiPostACLPolicyRequest { +PostACLPolicy Method for PostACLPolicy + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param policyName The ACL policy name. + @return ApiPostACLPolicyRequest +*/ +func (a *ACLApiService) PostACLPolicy(ctx context.Context, policyName string) ApiPostACLPolicyRequest { return ApiPostACLPolicyRequest{ ApiService: a, ctx: ctx, @@ -1448,29 +1486,25 @@ func (a *ACLApiService) PostACLPolicy(ctx _context.Context, policyName string) A } } -/* - * Execute executes the request - */ -func (a *ACLApiService) PostACLPolicyExecute(r ApiPostACLPolicyRequest) (*_nethttp.Response, error) { +// Execute executes the request +func (a *ACLApiService) PostACLPolicyExecute(r ApiPostACLPolicyRequest) (*http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ACLApiService.PostACLPolicy") if err != nil { - return nil, GenericOpenAPIError{error: err.Error()} + return nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/acl/policy/{policyName}" - localVarPath = strings.Replace(localVarPath, "{"+"policyName"+"}", _neturl.PathEscape(parameterToString(r.policyName, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"policyName"+"}", url.PathEscape(parameterToString(r.policyName, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.aCLPolicy == nil { return nil, reportError("aCLPolicy is required and must be specified") } @@ -1520,7 +1554,7 @@ func (a *ACLApiService) PostACLPolicyExecute(r ApiPostACLPolicyRequest) (*_netht } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return nil, err } @@ -1530,15 +1564,15 @@ func (a *ACLApiService) PostACLPolicyExecute(r ApiPostACLPolicyRequest) (*_netht return localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -1549,7 +1583,7 @@ func (a *ACLApiService) PostACLPolicyExecute(r ApiPostACLPolicyRequest) (*_netht } type ApiPostACLTokenRequest struct { - ctx _context.Context + ctx context.Context ApiService *ACLApiService tokenAccessor string aCLToken *ACLToken @@ -1563,34 +1597,39 @@ func (r ApiPostACLTokenRequest) ACLToken(aCLToken ACLToken) ApiPostACLTokenReque r.aCLToken = &aCLToken return r } +// Filters results based on the specified region. func (r ApiPostACLTokenRequest) Region(region string) ApiPostACLTokenRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiPostACLTokenRequest) Namespace(namespace string) ApiPostACLTokenRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiPostACLTokenRequest) XNomadToken(xNomadToken string) ApiPostACLTokenRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiPostACLTokenRequest) IdempotencyToken(idempotencyToken string) ApiPostACLTokenRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiPostACLTokenRequest) Execute() (ACLToken, *_nethttp.Response, error) { +func (r ApiPostACLTokenRequest) Execute() (*ACLToken, *http.Response, error) { return r.ApiService.PostACLTokenExecute(r) } /* - * PostACLToken Method for PostACLToken - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param tokenAccessor The token accessor ID. - * @return ApiPostACLTokenRequest - */ -func (a *ACLApiService) PostACLToken(ctx _context.Context, tokenAccessor string) ApiPostACLTokenRequest { +PostACLToken Method for PostACLToken + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param tokenAccessor The token accessor ID. + @return ApiPostACLTokenRequest +*/ +func (a *ACLApiService) PostACLToken(ctx context.Context, tokenAccessor string) ApiPostACLTokenRequest { return ApiPostACLTokenRequest{ ApiService: a, ctx: ctx, @@ -1598,31 +1637,27 @@ func (a *ACLApiService) PostACLToken(ctx _context.Context, tokenAccessor string) } } -/* - * Execute executes the request - * @return ACLToken - */ -func (a *ACLApiService) PostACLTokenExecute(r ApiPostACLTokenRequest) (ACLToken, *_nethttp.Response, error) { +// Execute executes the request +// @return ACLToken +func (a *ACLApiService) PostACLTokenExecute(r ApiPostACLTokenRequest) (*ACLToken, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ACLToken + formFiles []formFile + localVarReturnValue *ACLToken ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ACLApiService.PostACLToken") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/acl/token/{tokenAccessor}" - localVarPath = strings.Replace(localVarPath, "{"+"tokenAccessor"+"}", _neturl.PathEscape(parameterToString(r.tokenAccessor, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"tokenAccessor"+"}", url.PathEscape(parameterToString(r.tokenAccessor, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.aCLToken == nil { return localVarReturnValue, nil, reportError("aCLToken is required and must be specified") } @@ -1672,7 +1707,7 @@ func (a *ACLApiService) PostACLTokenExecute(r ApiPostACLTokenRequest) (ACLToken, } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -1682,15 +1717,15 @@ func (a *ACLApiService) PostACLTokenExecute(r ApiPostACLTokenRequest) (ACLToken, return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -1699,7 +1734,7 @@ func (a *ACLApiService) PostACLTokenExecute(r ApiPostACLTokenRequest) (ACLToken, err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -1710,7 +1745,7 @@ func (a *ACLApiService) PostACLTokenExecute(r ApiPostACLTokenRequest) (ACLToken, } type ApiPostACLTokenOnetimeRequest struct { - ctx _context.Context + ctx context.Context ApiService *ACLApiService region *string namespace *string @@ -1718,63 +1753,64 @@ type ApiPostACLTokenOnetimeRequest struct { idempotencyToken *string } +// Filters results based on the specified region. func (r ApiPostACLTokenOnetimeRequest) Region(region string) ApiPostACLTokenOnetimeRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiPostACLTokenOnetimeRequest) Namespace(namespace string) ApiPostACLTokenOnetimeRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiPostACLTokenOnetimeRequest) XNomadToken(xNomadToken string) ApiPostACLTokenOnetimeRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiPostACLTokenOnetimeRequest) IdempotencyToken(idempotencyToken string) ApiPostACLTokenOnetimeRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiPostACLTokenOnetimeRequest) Execute() (OneTimeToken, *_nethttp.Response, error) { +func (r ApiPostACLTokenOnetimeRequest) Execute() (*OneTimeToken, *http.Response, error) { return r.ApiService.PostACLTokenOnetimeExecute(r) } /* - * PostACLTokenOnetime Method for PostACLTokenOnetime - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiPostACLTokenOnetimeRequest - */ -func (a *ACLApiService) PostACLTokenOnetime(ctx _context.Context) ApiPostACLTokenOnetimeRequest { +PostACLTokenOnetime Method for PostACLTokenOnetime + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiPostACLTokenOnetimeRequest +*/ +func (a *ACLApiService) PostACLTokenOnetime(ctx context.Context) ApiPostACLTokenOnetimeRequest { return ApiPostACLTokenOnetimeRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return OneTimeToken - */ -func (a *ACLApiService) PostACLTokenOnetimeExecute(r ApiPostACLTokenOnetimeRequest) (OneTimeToken, *_nethttp.Response, error) { +// Execute executes the request +// @return OneTimeToken +func (a *ACLApiService) PostACLTokenOnetimeExecute(r ApiPostACLTokenOnetimeRequest) (*OneTimeToken, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue OneTimeToken + formFiles []formFile + localVarReturnValue *OneTimeToken ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ACLApiService.PostACLTokenOnetime") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/acl/token/onetime" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -1819,7 +1855,7 @@ func (a *ACLApiService) PostACLTokenOnetimeExecute(r ApiPostACLTokenOnetimeReque } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -1829,15 +1865,15 @@ func (a *ACLApiService) PostACLTokenOnetimeExecute(r ApiPostACLTokenOnetimeReque return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -1846,7 +1882,7 @@ func (a *ACLApiService) PostACLTokenOnetimeExecute(r ApiPostACLTokenOnetimeReque err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -1857,7 +1893,7 @@ func (a *ACLApiService) PostACLTokenOnetimeExecute(r ApiPostACLTokenOnetimeReque } type ApiPostACLTokenOnetimeExchangeRequest struct { - ctx _context.Context + ctx context.Context ApiService *ACLApiService oneTimeTokenExchangeRequest *OneTimeTokenExchangeRequest region *string @@ -1870,63 +1906,64 @@ func (r ApiPostACLTokenOnetimeExchangeRequest) OneTimeTokenExchangeRequest(oneTi r.oneTimeTokenExchangeRequest = &oneTimeTokenExchangeRequest return r } +// Filters results based on the specified region. func (r ApiPostACLTokenOnetimeExchangeRequest) Region(region string) ApiPostACLTokenOnetimeExchangeRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiPostACLTokenOnetimeExchangeRequest) Namespace(namespace string) ApiPostACLTokenOnetimeExchangeRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiPostACLTokenOnetimeExchangeRequest) XNomadToken(xNomadToken string) ApiPostACLTokenOnetimeExchangeRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiPostACLTokenOnetimeExchangeRequest) IdempotencyToken(idempotencyToken string) ApiPostACLTokenOnetimeExchangeRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiPostACLTokenOnetimeExchangeRequest) Execute() (ACLToken, *_nethttp.Response, error) { +func (r ApiPostACLTokenOnetimeExchangeRequest) Execute() (*ACLToken, *http.Response, error) { return r.ApiService.PostACLTokenOnetimeExchangeExecute(r) } /* - * PostACLTokenOnetimeExchange Method for PostACLTokenOnetimeExchange - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiPostACLTokenOnetimeExchangeRequest - */ -func (a *ACLApiService) PostACLTokenOnetimeExchange(ctx _context.Context) ApiPostACLTokenOnetimeExchangeRequest { +PostACLTokenOnetimeExchange Method for PostACLTokenOnetimeExchange + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiPostACLTokenOnetimeExchangeRequest +*/ +func (a *ACLApiService) PostACLTokenOnetimeExchange(ctx context.Context) ApiPostACLTokenOnetimeExchangeRequest { return ApiPostACLTokenOnetimeExchangeRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return ACLToken - */ -func (a *ACLApiService) PostACLTokenOnetimeExchangeExecute(r ApiPostACLTokenOnetimeExchangeRequest) (ACLToken, *_nethttp.Response, error) { +// Execute executes the request +// @return ACLToken +func (a *ACLApiService) PostACLTokenOnetimeExchangeExecute(r ApiPostACLTokenOnetimeExchangeRequest) (*ACLToken, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ACLToken + formFiles []formFile + localVarReturnValue *ACLToken ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ACLApiService.PostACLTokenOnetimeExchange") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/acl/token/onetime/exchange" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.oneTimeTokenExchangeRequest == nil { return localVarReturnValue, nil, reportError("oneTimeTokenExchangeRequest is required and must be specified") } @@ -1976,7 +2013,7 @@ func (a *ACLApiService) PostACLTokenOnetimeExchangeExecute(r ApiPostACLTokenOnet } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -1986,15 +2023,15 @@ func (a *ACLApiService) PostACLTokenOnetimeExchangeExecute(r ApiPostACLTokenOnet return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -2003,7 +2040,7 @@ func (a *ACLApiService) PostACLTokenOnetimeExchangeExecute(r ApiPostACLTokenOnet err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } diff --git a/clients/go/v1/api_allocations.go b/clients/go/v1/api_allocations.go index 47bcd502..6e6bd4db 100644 --- a/clients/go/v1/api_allocations.go +++ b/clients/go/v1/api_allocations.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -13,23 +13,23 @@ package client import ( "bytes" - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" + "context" + "io/ioutil" + "net/http" + "net/url" "strings" ) // Linger please var ( - _ _context.Context + _ context.Context ) // AllocationsApiService AllocationsApi service type AllocationsApiService service type ApiGetAllocationRequest struct { - ctx _context.Context + ctx context.Context ApiService *AllocationsApiService allocID string region *string @@ -43,54 +43,64 @@ type ApiGetAllocationRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetAllocationRequest) Region(region string) ApiGetAllocationRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetAllocationRequest) Namespace(namespace string) ApiGetAllocationRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetAllocationRequest) Index(index int32) ApiGetAllocationRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetAllocationRequest) Wait(wait string) ApiGetAllocationRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetAllocationRequest) Stale(stale string) ApiGetAllocationRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetAllocationRequest) Prefix(prefix string) ApiGetAllocationRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetAllocationRequest) XNomadToken(xNomadToken string) ApiGetAllocationRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetAllocationRequest) PerPage(perPage int32) ApiGetAllocationRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetAllocationRequest) NextToken(nextToken string) ApiGetAllocationRequest { r.nextToken = &nextToken return r } -func (r ApiGetAllocationRequest) Execute() (Allocation, *_nethttp.Response, error) { +func (r ApiGetAllocationRequest) Execute() (*Allocation, *http.Response, error) { return r.ApiService.GetAllocationExecute(r) } /* - * GetAllocation Method for GetAllocation - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param allocID Allocation ID. - * @return ApiGetAllocationRequest - */ -func (a *AllocationsApiService) GetAllocation(ctx _context.Context, allocID string) ApiGetAllocationRequest { +GetAllocation Method for GetAllocation + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param allocID Allocation ID. + @return ApiGetAllocationRequest +*/ +func (a *AllocationsApiService) GetAllocation(ctx context.Context, allocID string) ApiGetAllocationRequest { return ApiGetAllocationRequest{ ApiService: a, ctx: ctx, @@ -98,31 +108,27 @@ func (a *AllocationsApiService) GetAllocation(ctx _context.Context, allocID stri } } -/* - * Execute executes the request - * @return Allocation - */ -func (a *AllocationsApiService) GetAllocationExecute(r ApiGetAllocationRequest) (Allocation, *_nethttp.Response, error) { +// Execute executes the request +// @return Allocation +func (a *AllocationsApiService) GetAllocationExecute(r ApiGetAllocationRequest) (*Allocation, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue Allocation + formFiles []formFile + localVarReturnValue *Allocation ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "AllocationsApiService.GetAllocation") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/allocation/{allocID}" - localVarPath = strings.Replace(localVarPath, "{"+"allocID"+"}", _neturl.PathEscape(parameterToString(r.allocID, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"allocID"+"}", url.PathEscape(parameterToString(r.allocID, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -182,7 +188,7 @@ func (a *AllocationsApiService) GetAllocationExecute(r ApiGetAllocationRequest) } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -192,15 +198,15 @@ func (a *AllocationsApiService) GetAllocationExecute(r ApiGetAllocationRequest) return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -209,7 +215,7 @@ func (a *AllocationsApiService) GetAllocationExecute(r ApiGetAllocationRequest) err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -220,7 +226,7 @@ func (a *AllocationsApiService) GetAllocationExecute(r ApiGetAllocationRequest) } type ApiGetAllocationServicesRequest struct { - ctx _context.Context + ctx context.Context ApiService *AllocationsApiService allocID string region *string @@ -234,54 +240,64 @@ type ApiGetAllocationServicesRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetAllocationServicesRequest) Region(region string) ApiGetAllocationServicesRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetAllocationServicesRequest) Namespace(namespace string) ApiGetAllocationServicesRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetAllocationServicesRequest) Index(index int32) ApiGetAllocationServicesRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetAllocationServicesRequest) Wait(wait string) ApiGetAllocationServicesRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetAllocationServicesRequest) Stale(stale string) ApiGetAllocationServicesRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetAllocationServicesRequest) Prefix(prefix string) ApiGetAllocationServicesRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetAllocationServicesRequest) XNomadToken(xNomadToken string) ApiGetAllocationServicesRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetAllocationServicesRequest) PerPage(perPage int32) ApiGetAllocationServicesRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetAllocationServicesRequest) NextToken(nextToken string) ApiGetAllocationServicesRequest { r.nextToken = &nextToken return r } -func (r ApiGetAllocationServicesRequest) Execute() ([]ServiceRegistration, *_nethttp.Response, error) { +func (r ApiGetAllocationServicesRequest) Execute() ([]ServiceRegistration, *http.Response, error) { return r.ApiService.GetAllocationServicesExecute(r) } /* - * GetAllocationServices Method for GetAllocationServices - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param allocID Allocation ID. - * @return ApiGetAllocationServicesRequest - */ -func (a *AllocationsApiService) GetAllocationServices(ctx _context.Context, allocID string) ApiGetAllocationServicesRequest { +GetAllocationServices Method for GetAllocationServices + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param allocID Allocation ID. + @return ApiGetAllocationServicesRequest +*/ +func (a *AllocationsApiService) GetAllocationServices(ctx context.Context, allocID string) ApiGetAllocationServicesRequest { return ApiGetAllocationServicesRequest{ ApiService: a, ctx: ctx, @@ -289,31 +305,27 @@ func (a *AllocationsApiService) GetAllocationServices(ctx _context.Context, allo } } -/* - * Execute executes the request - * @return []ServiceRegistration - */ -func (a *AllocationsApiService) GetAllocationServicesExecute(r ApiGetAllocationServicesRequest) ([]ServiceRegistration, *_nethttp.Response, error) { +// Execute executes the request +// @return []ServiceRegistration +func (a *AllocationsApiService) GetAllocationServicesExecute(r ApiGetAllocationServicesRequest) ([]ServiceRegistration, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile localVarReturnValue []ServiceRegistration ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "AllocationsApiService.GetAllocationServices") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/allocation/{allocID}/services" - localVarPath = strings.Replace(localVarPath, "{"+"allocID"+"}", _neturl.PathEscape(parameterToString(r.allocID, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"allocID"+"}", url.PathEscape(parameterToString(r.allocID, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -373,7 +385,7 @@ func (a *AllocationsApiService) GetAllocationServicesExecute(r ApiGetAllocationS } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -383,15 +395,15 @@ func (a *AllocationsApiService) GetAllocationServicesExecute(r ApiGetAllocationS return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -400,7 +412,7 @@ func (a *AllocationsApiService) GetAllocationServicesExecute(r ApiGetAllocationS err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -411,7 +423,7 @@ func (a *AllocationsApiService) GetAllocationServicesExecute(r ApiGetAllocationS } type ApiGetAllocationsRequest struct { - ctx _context.Context + ctx context.Context ApiService *AllocationsApiService region *string namespace *string @@ -426,91 +438,99 @@ type ApiGetAllocationsRequest struct { taskStates *bool } +// Filters results based on the specified region. func (r ApiGetAllocationsRequest) Region(region string) ApiGetAllocationsRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetAllocationsRequest) Namespace(namespace string) ApiGetAllocationsRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetAllocationsRequest) Index(index int32) ApiGetAllocationsRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetAllocationsRequest) Wait(wait string) ApiGetAllocationsRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetAllocationsRequest) Stale(stale string) ApiGetAllocationsRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetAllocationsRequest) Prefix(prefix string) ApiGetAllocationsRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetAllocationsRequest) XNomadToken(xNomadToken string) ApiGetAllocationsRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetAllocationsRequest) PerPage(perPage int32) ApiGetAllocationsRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetAllocationsRequest) NextToken(nextToken string) ApiGetAllocationsRequest { r.nextToken = &nextToken return r } +// Flag indicating whether to include resources in response. func (r ApiGetAllocationsRequest) Resources(resources bool) ApiGetAllocationsRequest { r.resources = &resources return r } +// Flag indicating whether to include task states in response. func (r ApiGetAllocationsRequest) TaskStates(taskStates bool) ApiGetAllocationsRequest { r.taskStates = &taskStates return r } -func (r ApiGetAllocationsRequest) Execute() ([]AllocationListStub, *_nethttp.Response, error) { +func (r ApiGetAllocationsRequest) Execute() ([]AllocationListStub, *http.Response, error) { return r.ApiService.GetAllocationsExecute(r) } /* - * GetAllocations Method for GetAllocations - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiGetAllocationsRequest - */ -func (a *AllocationsApiService) GetAllocations(ctx _context.Context) ApiGetAllocationsRequest { +GetAllocations Method for GetAllocations + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiGetAllocationsRequest +*/ +func (a *AllocationsApiService) GetAllocations(ctx context.Context) ApiGetAllocationsRequest { return ApiGetAllocationsRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return []AllocationListStub - */ -func (a *AllocationsApiService) GetAllocationsExecute(r ApiGetAllocationsRequest) ([]AllocationListStub, *_nethttp.Response, error) { +// Execute executes the request +// @return []AllocationListStub +func (a *AllocationsApiService) GetAllocationsExecute(r ApiGetAllocationsRequest) ([]AllocationListStub, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile localVarReturnValue []AllocationListStub ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "AllocationsApiService.GetAllocations") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/allocations" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -576,7 +596,7 @@ func (a *AllocationsApiService) GetAllocationsExecute(r ApiGetAllocationsRequest } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -586,15 +606,15 @@ func (a *AllocationsApiService) GetAllocationsExecute(r ApiGetAllocationsRequest return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -603,7 +623,7 @@ func (a *AllocationsApiService) GetAllocationsExecute(r ApiGetAllocationsRequest err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -614,7 +634,7 @@ func (a *AllocationsApiService) GetAllocationsExecute(r ApiGetAllocationsRequest } type ApiPostAllocationStopRequest struct { - ctx _context.Context + ctx context.Context ApiService *AllocationsApiService allocID string region *string @@ -629,58 +649,69 @@ type ApiPostAllocationStopRequest struct { noShutdownDelay *bool } +// Filters results based on the specified region. func (r ApiPostAllocationStopRequest) Region(region string) ApiPostAllocationStopRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiPostAllocationStopRequest) Namespace(namespace string) ApiPostAllocationStopRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiPostAllocationStopRequest) Index(index int32) ApiPostAllocationStopRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiPostAllocationStopRequest) Wait(wait string) ApiPostAllocationStopRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiPostAllocationStopRequest) Stale(stale string) ApiPostAllocationStopRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiPostAllocationStopRequest) Prefix(prefix string) ApiPostAllocationStopRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiPostAllocationStopRequest) XNomadToken(xNomadToken string) ApiPostAllocationStopRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiPostAllocationStopRequest) PerPage(perPage int32) ApiPostAllocationStopRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiPostAllocationStopRequest) NextToken(nextToken string) ApiPostAllocationStopRequest { r.nextToken = &nextToken return r } +// Flag indicating whether to delay shutdown when requesting an allocation stop. func (r ApiPostAllocationStopRequest) NoShutdownDelay(noShutdownDelay bool) ApiPostAllocationStopRequest { r.noShutdownDelay = &noShutdownDelay return r } -func (r ApiPostAllocationStopRequest) Execute() (AllocStopResponse, *_nethttp.Response, error) { +func (r ApiPostAllocationStopRequest) Execute() (*AllocStopResponse, *http.Response, error) { return r.ApiService.PostAllocationStopExecute(r) } /* - * PostAllocationStop Method for PostAllocationStop - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param allocID Allocation ID. - * @return ApiPostAllocationStopRequest - */ -func (a *AllocationsApiService) PostAllocationStop(ctx _context.Context, allocID string) ApiPostAllocationStopRequest { +PostAllocationStop Method for PostAllocationStop + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param allocID Allocation ID. + @return ApiPostAllocationStopRequest +*/ +func (a *AllocationsApiService) PostAllocationStop(ctx context.Context, allocID string) ApiPostAllocationStopRequest { return ApiPostAllocationStopRequest{ ApiService: a, ctx: ctx, @@ -688,31 +719,27 @@ func (a *AllocationsApiService) PostAllocationStop(ctx _context.Context, allocID } } -/* - * Execute executes the request - * @return AllocStopResponse - */ -func (a *AllocationsApiService) PostAllocationStopExecute(r ApiPostAllocationStopRequest) (AllocStopResponse, *_nethttp.Response, error) { +// Execute executes the request +// @return AllocStopResponse +func (a *AllocationsApiService) PostAllocationStopExecute(r ApiPostAllocationStopRequest) (*AllocStopResponse, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue AllocStopResponse + formFiles []formFile + localVarReturnValue *AllocStopResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "AllocationsApiService.PostAllocationStop") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/allocation/{allocID}/stop" - localVarPath = strings.Replace(localVarPath, "{"+"allocID"+"}", _neturl.PathEscape(parameterToString(r.allocID, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"allocID"+"}", url.PathEscape(parameterToString(r.allocID, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -775,7 +802,7 @@ func (a *AllocationsApiService) PostAllocationStopExecute(r ApiPostAllocationSto } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -785,15 +812,15 @@ func (a *AllocationsApiService) PostAllocationStopExecute(r ApiPostAllocationSto return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -802,7 +829,7 @@ func (a *AllocationsApiService) PostAllocationStopExecute(r ApiPostAllocationSto err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } diff --git a/clients/go/v1/api_deployments.go b/clients/go/v1/api_deployments.go index e98b6626..bf036a97 100644 --- a/clients/go/v1/api_deployments.go +++ b/clients/go/v1/api_deployments.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -13,23 +13,23 @@ package client import ( "bytes" - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" + "context" + "io/ioutil" + "net/http" + "net/url" "strings" ) // Linger please var ( - _ _context.Context + _ context.Context ) // DeploymentsApiService DeploymentsApi service type DeploymentsApiService service type ApiGetDeploymentRequest struct { - ctx _context.Context + ctx context.Context ApiService *DeploymentsApiService deploymentID string region *string @@ -43,54 +43,64 @@ type ApiGetDeploymentRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetDeploymentRequest) Region(region string) ApiGetDeploymentRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetDeploymentRequest) Namespace(namespace string) ApiGetDeploymentRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetDeploymentRequest) Index(index int32) ApiGetDeploymentRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetDeploymentRequest) Wait(wait string) ApiGetDeploymentRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetDeploymentRequest) Stale(stale string) ApiGetDeploymentRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetDeploymentRequest) Prefix(prefix string) ApiGetDeploymentRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetDeploymentRequest) XNomadToken(xNomadToken string) ApiGetDeploymentRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetDeploymentRequest) PerPage(perPage int32) ApiGetDeploymentRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetDeploymentRequest) NextToken(nextToken string) ApiGetDeploymentRequest { r.nextToken = &nextToken return r } -func (r ApiGetDeploymentRequest) Execute() (Deployment, *_nethttp.Response, error) { +func (r ApiGetDeploymentRequest) Execute() (*Deployment, *http.Response, error) { return r.ApiService.GetDeploymentExecute(r) } /* - * GetDeployment Method for GetDeployment - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param deploymentID Deployment ID. - * @return ApiGetDeploymentRequest - */ -func (a *DeploymentsApiService) GetDeployment(ctx _context.Context, deploymentID string) ApiGetDeploymentRequest { +GetDeployment Method for GetDeployment + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param deploymentID Deployment ID. + @return ApiGetDeploymentRequest +*/ +func (a *DeploymentsApiService) GetDeployment(ctx context.Context, deploymentID string) ApiGetDeploymentRequest { return ApiGetDeploymentRequest{ ApiService: a, ctx: ctx, @@ -98,31 +108,27 @@ func (a *DeploymentsApiService) GetDeployment(ctx _context.Context, deploymentID } } -/* - * Execute executes the request - * @return Deployment - */ -func (a *DeploymentsApiService) GetDeploymentExecute(r ApiGetDeploymentRequest) (Deployment, *_nethttp.Response, error) { +// Execute executes the request +// @return Deployment +func (a *DeploymentsApiService) GetDeploymentExecute(r ApiGetDeploymentRequest) (*Deployment, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue Deployment + formFiles []formFile + localVarReturnValue *Deployment ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "DeploymentsApiService.GetDeployment") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/deployment/{deploymentID}" - localVarPath = strings.Replace(localVarPath, "{"+"deploymentID"+"}", _neturl.PathEscape(parameterToString(r.deploymentID, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"deploymentID"+"}", url.PathEscape(parameterToString(r.deploymentID, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -182,7 +188,7 @@ func (a *DeploymentsApiService) GetDeploymentExecute(r ApiGetDeploymentRequest) } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -192,15 +198,15 @@ func (a *DeploymentsApiService) GetDeploymentExecute(r ApiGetDeploymentRequest) return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -209,7 +215,7 @@ func (a *DeploymentsApiService) GetDeploymentExecute(r ApiGetDeploymentRequest) err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -220,7 +226,7 @@ func (a *DeploymentsApiService) GetDeploymentExecute(r ApiGetDeploymentRequest) } type ApiGetDeploymentAllocationsRequest struct { - ctx _context.Context + ctx context.Context ApiService *DeploymentsApiService deploymentID string region *string @@ -234,54 +240,64 @@ type ApiGetDeploymentAllocationsRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetDeploymentAllocationsRequest) Region(region string) ApiGetDeploymentAllocationsRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetDeploymentAllocationsRequest) Namespace(namespace string) ApiGetDeploymentAllocationsRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetDeploymentAllocationsRequest) Index(index int32) ApiGetDeploymentAllocationsRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetDeploymentAllocationsRequest) Wait(wait string) ApiGetDeploymentAllocationsRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetDeploymentAllocationsRequest) Stale(stale string) ApiGetDeploymentAllocationsRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetDeploymentAllocationsRequest) Prefix(prefix string) ApiGetDeploymentAllocationsRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetDeploymentAllocationsRequest) XNomadToken(xNomadToken string) ApiGetDeploymentAllocationsRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetDeploymentAllocationsRequest) PerPage(perPage int32) ApiGetDeploymentAllocationsRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetDeploymentAllocationsRequest) NextToken(nextToken string) ApiGetDeploymentAllocationsRequest { r.nextToken = &nextToken return r } -func (r ApiGetDeploymentAllocationsRequest) Execute() ([]AllocationListStub, *_nethttp.Response, error) { +func (r ApiGetDeploymentAllocationsRequest) Execute() ([]AllocationListStub, *http.Response, error) { return r.ApiService.GetDeploymentAllocationsExecute(r) } /* - * GetDeploymentAllocations Method for GetDeploymentAllocations - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param deploymentID Deployment ID. - * @return ApiGetDeploymentAllocationsRequest - */ -func (a *DeploymentsApiService) GetDeploymentAllocations(ctx _context.Context, deploymentID string) ApiGetDeploymentAllocationsRequest { +GetDeploymentAllocations Method for GetDeploymentAllocations + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param deploymentID Deployment ID. + @return ApiGetDeploymentAllocationsRequest +*/ +func (a *DeploymentsApiService) GetDeploymentAllocations(ctx context.Context, deploymentID string) ApiGetDeploymentAllocationsRequest { return ApiGetDeploymentAllocationsRequest{ ApiService: a, ctx: ctx, @@ -289,31 +305,27 @@ func (a *DeploymentsApiService) GetDeploymentAllocations(ctx _context.Context, d } } -/* - * Execute executes the request - * @return []AllocationListStub - */ -func (a *DeploymentsApiService) GetDeploymentAllocationsExecute(r ApiGetDeploymentAllocationsRequest) ([]AllocationListStub, *_nethttp.Response, error) { +// Execute executes the request +// @return []AllocationListStub +func (a *DeploymentsApiService) GetDeploymentAllocationsExecute(r ApiGetDeploymentAllocationsRequest) ([]AllocationListStub, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile localVarReturnValue []AllocationListStub ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "DeploymentsApiService.GetDeploymentAllocations") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/deployment/allocations/{deploymentID}" - localVarPath = strings.Replace(localVarPath, "{"+"deploymentID"+"}", _neturl.PathEscape(parameterToString(r.deploymentID, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"deploymentID"+"}", url.PathEscape(parameterToString(r.deploymentID, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -373,7 +385,7 @@ func (a *DeploymentsApiService) GetDeploymentAllocationsExecute(r ApiGetDeployme } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -383,15 +395,15 @@ func (a *DeploymentsApiService) GetDeploymentAllocationsExecute(r ApiGetDeployme return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -400,7 +412,7 @@ func (a *DeploymentsApiService) GetDeploymentAllocationsExecute(r ApiGetDeployme err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -411,7 +423,7 @@ func (a *DeploymentsApiService) GetDeploymentAllocationsExecute(r ApiGetDeployme } type ApiGetDeploymentsRequest struct { - ctx _context.Context + ctx context.Context ApiService *DeploymentsApiService region *string namespace *string @@ -424,83 +436,89 @@ type ApiGetDeploymentsRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetDeploymentsRequest) Region(region string) ApiGetDeploymentsRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetDeploymentsRequest) Namespace(namespace string) ApiGetDeploymentsRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetDeploymentsRequest) Index(index int32) ApiGetDeploymentsRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetDeploymentsRequest) Wait(wait string) ApiGetDeploymentsRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetDeploymentsRequest) Stale(stale string) ApiGetDeploymentsRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetDeploymentsRequest) Prefix(prefix string) ApiGetDeploymentsRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetDeploymentsRequest) XNomadToken(xNomadToken string) ApiGetDeploymentsRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetDeploymentsRequest) PerPage(perPage int32) ApiGetDeploymentsRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetDeploymentsRequest) NextToken(nextToken string) ApiGetDeploymentsRequest { r.nextToken = &nextToken return r } -func (r ApiGetDeploymentsRequest) Execute() ([]Deployment, *_nethttp.Response, error) { +func (r ApiGetDeploymentsRequest) Execute() ([]Deployment, *http.Response, error) { return r.ApiService.GetDeploymentsExecute(r) } /* - * GetDeployments Method for GetDeployments - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiGetDeploymentsRequest - */ -func (a *DeploymentsApiService) GetDeployments(ctx _context.Context) ApiGetDeploymentsRequest { +GetDeployments Method for GetDeployments + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiGetDeploymentsRequest +*/ +func (a *DeploymentsApiService) GetDeployments(ctx context.Context) ApiGetDeploymentsRequest { return ApiGetDeploymentsRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return []Deployment - */ -func (a *DeploymentsApiService) GetDeploymentsExecute(r ApiGetDeploymentsRequest) ([]Deployment, *_nethttp.Response, error) { +// Execute executes the request +// @return []Deployment +func (a *DeploymentsApiService) GetDeploymentsExecute(r ApiGetDeploymentsRequest) ([]Deployment, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile localVarReturnValue []Deployment ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "DeploymentsApiService.GetDeployments") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/deployments" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -560,7 +578,7 @@ func (a *DeploymentsApiService) GetDeploymentsExecute(r ApiGetDeploymentsRequest } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -570,15 +588,15 @@ func (a *DeploymentsApiService) GetDeploymentsExecute(r ApiGetDeploymentsRequest return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -587,7 +605,7 @@ func (a *DeploymentsApiService) GetDeploymentsExecute(r ApiGetDeploymentsRequest err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -598,7 +616,7 @@ func (a *DeploymentsApiService) GetDeploymentsExecute(r ApiGetDeploymentsRequest } type ApiPostDeploymentAllocationHealthRequest struct { - ctx _context.Context + ctx context.Context ApiService *DeploymentsApiService deploymentID string deploymentAllocHealthRequest *DeploymentAllocHealthRequest @@ -612,34 +630,39 @@ func (r ApiPostDeploymentAllocationHealthRequest) DeploymentAllocHealthRequest(d r.deploymentAllocHealthRequest = &deploymentAllocHealthRequest return r } +// Filters results based on the specified region. func (r ApiPostDeploymentAllocationHealthRequest) Region(region string) ApiPostDeploymentAllocationHealthRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiPostDeploymentAllocationHealthRequest) Namespace(namespace string) ApiPostDeploymentAllocationHealthRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiPostDeploymentAllocationHealthRequest) XNomadToken(xNomadToken string) ApiPostDeploymentAllocationHealthRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiPostDeploymentAllocationHealthRequest) IdempotencyToken(idempotencyToken string) ApiPostDeploymentAllocationHealthRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiPostDeploymentAllocationHealthRequest) Execute() (DeploymentUpdateResponse, *_nethttp.Response, error) { +func (r ApiPostDeploymentAllocationHealthRequest) Execute() (*DeploymentUpdateResponse, *http.Response, error) { return r.ApiService.PostDeploymentAllocationHealthExecute(r) } /* - * PostDeploymentAllocationHealth Method for PostDeploymentAllocationHealth - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param deploymentID Deployment ID. - * @return ApiPostDeploymentAllocationHealthRequest - */ -func (a *DeploymentsApiService) PostDeploymentAllocationHealth(ctx _context.Context, deploymentID string) ApiPostDeploymentAllocationHealthRequest { +PostDeploymentAllocationHealth Method for PostDeploymentAllocationHealth + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param deploymentID Deployment ID. + @return ApiPostDeploymentAllocationHealthRequest +*/ +func (a *DeploymentsApiService) PostDeploymentAllocationHealth(ctx context.Context, deploymentID string) ApiPostDeploymentAllocationHealthRequest { return ApiPostDeploymentAllocationHealthRequest{ ApiService: a, ctx: ctx, @@ -647,31 +670,27 @@ func (a *DeploymentsApiService) PostDeploymentAllocationHealth(ctx _context.Cont } } -/* - * Execute executes the request - * @return DeploymentUpdateResponse - */ -func (a *DeploymentsApiService) PostDeploymentAllocationHealthExecute(r ApiPostDeploymentAllocationHealthRequest) (DeploymentUpdateResponse, *_nethttp.Response, error) { +// Execute executes the request +// @return DeploymentUpdateResponse +func (a *DeploymentsApiService) PostDeploymentAllocationHealthExecute(r ApiPostDeploymentAllocationHealthRequest) (*DeploymentUpdateResponse, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeploymentUpdateResponse + formFiles []formFile + localVarReturnValue *DeploymentUpdateResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "DeploymentsApiService.PostDeploymentAllocationHealth") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/deployment/allocation-health/{deploymentID}" - localVarPath = strings.Replace(localVarPath, "{"+"deploymentID"+"}", _neturl.PathEscape(parameterToString(r.deploymentID, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"deploymentID"+"}", url.PathEscape(parameterToString(r.deploymentID, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.deploymentAllocHealthRequest == nil { return localVarReturnValue, nil, reportError("deploymentAllocHealthRequest is required and must be specified") } @@ -721,7 +740,7 @@ func (a *DeploymentsApiService) PostDeploymentAllocationHealthExecute(r ApiPostD } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -731,15 +750,15 @@ func (a *DeploymentsApiService) PostDeploymentAllocationHealthExecute(r ApiPostD return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -748,7 +767,7 @@ func (a *DeploymentsApiService) PostDeploymentAllocationHealthExecute(r ApiPostD err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -759,7 +778,7 @@ func (a *DeploymentsApiService) PostDeploymentAllocationHealthExecute(r ApiPostD } type ApiPostDeploymentFailRequest struct { - ctx _context.Context + ctx context.Context ApiService *DeploymentsApiService deploymentID string region *string @@ -768,34 +787,39 @@ type ApiPostDeploymentFailRequest struct { idempotencyToken *string } +// Filters results based on the specified region. func (r ApiPostDeploymentFailRequest) Region(region string) ApiPostDeploymentFailRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiPostDeploymentFailRequest) Namespace(namespace string) ApiPostDeploymentFailRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiPostDeploymentFailRequest) XNomadToken(xNomadToken string) ApiPostDeploymentFailRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiPostDeploymentFailRequest) IdempotencyToken(idempotencyToken string) ApiPostDeploymentFailRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiPostDeploymentFailRequest) Execute() (DeploymentUpdateResponse, *_nethttp.Response, error) { +func (r ApiPostDeploymentFailRequest) Execute() (*DeploymentUpdateResponse, *http.Response, error) { return r.ApiService.PostDeploymentFailExecute(r) } /* - * PostDeploymentFail Method for PostDeploymentFail - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param deploymentID Deployment ID. - * @return ApiPostDeploymentFailRequest - */ -func (a *DeploymentsApiService) PostDeploymentFail(ctx _context.Context, deploymentID string) ApiPostDeploymentFailRequest { +PostDeploymentFail Method for PostDeploymentFail + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param deploymentID Deployment ID. + @return ApiPostDeploymentFailRequest +*/ +func (a *DeploymentsApiService) PostDeploymentFail(ctx context.Context, deploymentID string) ApiPostDeploymentFailRequest { return ApiPostDeploymentFailRequest{ ApiService: a, ctx: ctx, @@ -803,31 +827,27 @@ func (a *DeploymentsApiService) PostDeploymentFail(ctx _context.Context, deploym } } -/* - * Execute executes the request - * @return DeploymentUpdateResponse - */ -func (a *DeploymentsApiService) PostDeploymentFailExecute(r ApiPostDeploymentFailRequest) (DeploymentUpdateResponse, *_nethttp.Response, error) { +// Execute executes the request +// @return DeploymentUpdateResponse +func (a *DeploymentsApiService) PostDeploymentFailExecute(r ApiPostDeploymentFailRequest) (*DeploymentUpdateResponse, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeploymentUpdateResponse + formFiles []formFile + localVarReturnValue *DeploymentUpdateResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "DeploymentsApiService.PostDeploymentFail") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/deployment/fail/{deploymentID}" - localVarPath = strings.Replace(localVarPath, "{"+"deploymentID"+"}", _neturl.PathEscape(parameterToString(r.deploymentID, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"deploymentID"+"}", url.PathEscape(parameterToString(r.deploymentID, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -872,7 +892,7 @@ func (a *DeploymentsApiService) PostDeploymentFailExecute(r ApiPostDeploymentFai } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -882,15 +902,15 @@ func (a *DeploymentsApiService) PostDeploymentFailExecute(r ApiPostDeploymentFai return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -899,7 +919,7 @@ func (a *DeploymentsApiService) PostDeploymentFailExecute(r ApiPostDeploymentFai err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -910,7 +930,7 @@ func (a *DeploymentsApiService) PostDeploymentFailExecute(r ApiPostDeploymentFai } type ApiPostDeploymentPauseRequest struct { - ctx _context.Context + ctx context.Context ApiService *DeploymentsApiService deploymentID string deploymentPauseRequest *DeploymentPauseRequest @@ -924,34 +944,39 @@ func (r ApiPostDeploymentPauseRequest) DeploymentPauseRequest(deploymentPauseReq r.deploymentPauseRequest = &deploymentPauseRequest return r } +// Filters results based on the specified region. func (r ApiPostDeploymentPauseRequest) Region(region string) ApiPostDeploymentPauseRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiPostDeploymentPauseRequest) Namespace(namespace string) ApiPostDeploymentPauseRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiPostDeploymentPauseRequest) XNomadToken(xNomadToken string) ApiPostDeploymentPauseRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiPostDeploymentPauseRequest) IdempotencyToken(idempotencyToken string) ApiPostDeploymentPauseRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiPostDeploymentPauseRequest) Execute() (DeploymentUpdateResponse, *_nethttp.Response, error) { +func (r ApiPostDeploymentPauseRequest) Execute() (*DeploymentUpdateResponse, *http.Response, error) { return r.ApiService.PostDeploymentPauseExecute(r) } /* - * PostDeploymentPause Method for PostDeploymentPause - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param deploymentID Deployment ID. - * @return ApiPostDeploymentPauseRequest - */ -func (a *DeploymentsApiService) PostDeploymentPause(ctx _context.Context, deploymentID string) ApiPostDeploymentPauseRequest { +PostDeploymentPause Method for PostDeploymentPause + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param deploymentID Deployment ID. + @return ApiPostDeploymentPauseRequest +*/ +func (a *DeploymentsApiService) PostDeploymentPause(ctx context.Context, deploymentID string) ApiPostDeploymentPauseRequest { return ApiPostDeploymentPauseRequest{ ApiService: a, ctx: ctx, @@ -959,31 +984,27 @@ func (a *DeploymentsApiService) PostDeploymentPause(ctx _context.Context, deploy } } -/* - * Execute executes the request - * @return DeploymentUpdateResponse - */ -func (a *DeploymentsApiService) PostDeploymentPauseExecute(r ApiPostDeploymentPauseRequest) (DeploymentUpdateResponse, *_nethttp.Response, error) { +// Execute executes the request +// @return DeploymentUpdateResponse +func (a *DeploymentsApiService) PostDeploymentPauseExecute(r ApiPostDeploymentPauseRequest) (*DeploymentUpdateResponse, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeploymentUpdateResponse + formFiles []formFile + localVarReturnValue *DeploymentUpdateResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "DeploymentsApiService.PostDeploymentPause") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/deployment/pause/{deploymentID}" - localVarPath = strings.Replace(localVarPath, "{"+"deploymentID"+"}", _neturl.PathEscape(parameterToString(r.deploymentID, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"deploymentID"+"}", url.PathEscape(parameterToString(r.deploymentID, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.deploymentPauseRequest == nil { return localVarReturnValue, nil, reportError("deploymentPauseRequest is required and must be specified") } @@ -1033,7 +1054,7 @@ func (a *DeploymentsApiService) PostDeploymentPauseExecute(r ApiPostDeploymentPa } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -1043,15 +1064,15 @@ func (a *DeploymentsApiService) PostDeploymentPauseExecute(r ApiPostDeploymentPa return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -1060,7 +1081,7 @@ func (a *DeploymentsApiService) PostDeploymentPauseExecute(r ApiPostDeploymentPa err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -1071,7 +1092,7 @@ func (a *DeploymentsApiService) PostDeploymentPauseExecute(r ApiPostDeploymentPa } type ApiPostDeploymentPromoteRequest struct { - ctx _context.Context + ctx context.Context ApiService *DeploymentsApiService deploymentID string deploymentPromoteRequest *DeploymentPromoteRequest @@ -1085,34 +1106,39 @@ func (r ApiPostDeploymentPromoteRequest) DeploymentPromoteRequest(deploymentProm r.deploymentPromoteRequest = &deploymentPromoteRequest return r } +// Filters results based on the specified region. func (r ApiPostDeploymentPromoteRequest) Region(region string) ApiPostDeploymentPromoteRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiPostDeploymentPromoteRequest) Namespace(namespace string) ApiPostDeploymentPromoteRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiPostDeploymentPromoteRequest) XNomadToken(xNomadToken string) ApiPostDeploymentPromoteRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiPostDeploymentPromoteRequest) IdempotencyToken(idempotencyToken string) ApiPostDeploymentPromoteRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiPostDeploymentPromoteRequest) Execute() (DeploymentUpdateResponse, *_nethttp.Response, error) { +func (r ApiPostDeploymentPromoteRequest) Execute() (*DeploymentUpdateResponse, *http.Response, error) { return r.ApiService.PostDeploymentPromoteExecute(r) } /* - * PostDeploymentPromote Method for PostDeploymentPromote - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param deploymentID Deployment ID. - * @return ApiPostDeploymentPromoteRequest - */ -func (a *DeploymentsApiService) PostDeploymentPromote(ctx _context.Context, deploymentID string) ApiPostDeploymentPromoteRequest { +PostDeploymentPromote Method for PostDeploymentPromote + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param deploymentID Deployment ID. + @return ApiPostDeploymentPromoteRequest +*/ +func (a *DeploymentsApiService) PostDeploymentPromote(ctx context.Context, deploymentID string) ApiPostDeploymentPromoteRequest { return ApiPostDeploymentPromoteRequest{ ApiService: a, ctx: ctx, @@ -1120,31 +1146,27 @@ func (a *DeploymentsApiService) PostDeploymentPromote(ctx _context.Context, depl } } -/* - * Execute executes the request - * @return DeploymentUpdateResponse - */ -func (a *DeploymentsApiService) PostDeploymentPromoteExecute(r ApiPostDeploymentPromoteRequest) (DeploymentUpdateResponse, *_nethttp.Response, error) { +// Execute executes the request +// @return DeploymentUpdateResponse +func (a *DeploymentsApiService) PostDeploymentPromoteExecute(r ApiPostDeploymentPromoteRequest) (*DeploymentUpdateResponse, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeploymentUpdateResponse + formFiles []formFile + localVarReturnValue *DeploymentUpdateResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "DeploymentsApiService.PostDeploymentPromote") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/deployment/promote/{deploymentID}" - localVarPath = strings.Replace(localVarPath, "{"+"deploymentID"+"}", _neturl.PathEscape(parameterToString(r.deploymentID, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"deploymentID"+"}", url.PathEscape(parameterToString(r.deploymentID, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.deploymentPromoteRequest == nil { return localVarReturnValue, nil, reportError("deploymentPromoteRequest is required and must be specified") } @@ -1194,7 +1216,7 @@ func (a *DeploymentsApiService) PostDeploymentPromoteExecute(r ApiPostDeployment } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -1204,15 +1226,15 @@ func (a *DeploymentsApiService) PostDeploymentPromoteExecute(r ApiPostDeployment return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -1221,7 +1243,7 @@ func (a *DeploymentsApiService) PostDeploymentPromoteExecute(r ApiPostDeployment err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -1232,7 +1254,7 @@ func (a *DeploymentsApiService) PostDeploymentPromoteExecute(r ApiPostDeployment } type ApiPostDeploymentUnblockRequest struct { - ctx _context.Context + ctx context.Context ApiService *DeploymentsApiService deploymentID string deploymentUnblockRequest *DeploymentUnblockRequest @@ -1246,34 +1268,39 @@ func (r ApiPostDeploymentUnblockRequest) DeploymentUnblockRequest(deploymentUnbl r.deploymentUnblockRequest = &deploymentUnblockRequest return r } +// Filters results based on the specified region. func (r ApiPostDeploymentUnblockRequest) Region(region string) ApiPostDeploymentUnblockRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiPostDeploymentUnblockRequest) Namespace(namespace string) ApiPostDeploymentUnblockRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiPostDeploymentUnblockRequest) XNomadToken(xNomadToken string) ApiPostDeploymentUnblockRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiPostDeploymentUnblockRequest) IdempotencyToken(idempotencyToken string) ApiPostDeploymentUnblockRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiPostDeploymentUnblockRequest) Execute() (DeploymentUpdateResponse, *_nethttp.Response, error) { +func (r ApiPostDeploymentUnblockRequest) Execute() (*DeploymentUpdateResponse, *http.Response, error) { return r.ApiService.PostDeploymentUnblockExecute(r) } /* - * PostDeploymentUnblock Method for PostDeploymentUnblock - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param deploymentID Deployment ID. - * @return ApiPostDeploymentUnblockRequest - */ -func (a *DeploymentsApiService) PostDeploymentUnblock(ctx _context.Context, deploymentID string) ApiPostDeploymentUnblockRequest { +PostDeploymentUnblock Method for PostDeploymentUnblock + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param deploymentID Deployment ID. + @return ApiPostDeploymentUnblockRequest +*/ +func (a *DeploymentsApiService) PostDeploymentUnblock(ctx context.Context, deploymentID string) ApiPostDeploymentUnblockRequest { return ApiPostDeploymentUnblockRequest{ ApiService: a, ctx: ctx, @@ -1281,31 +1308,27 @@ func (a *DeploymentsApiService) PostDeploymentUnblock(ctx _context.Context, depl } } -/* - * Execute executes the request - * @return DeploymentUpdateResponse - */ -func (a *DeploymentsApiService) PostDeploymentUnblockExecute(r ApiPostDeploymentUnblockRequest) (DeploymentUpdateResponse, *_nethttp.Response, error) { +// Execute executes the request +// @return DeploymentUpdateResponse +func (a *DeploymentsApiService) PostDeploymentUnblockExecute(r ApiPostDeploymentUnblockRequest) (*DeploymentUpdateResponse, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeploymentUpdateResponse + formFiles []formFile + localVarReturnValue *DeploymentUpdateResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "DeploymentsApiService.PostDeploymentUnblock") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/deployment/unblock/{deploymentID}" - localVarPath = strings.Replace(localVarPath, "{"+"deploymentID"+"}", _neturl.PathEscape(parameterToString(r.deploymentID, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"deploymentID"+"}", url.PathEscape(parameterToString(r.deploymentID, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.deploymentUnblockRequest == nil { return localVarReturnValue, nil, reportError("deploymentUnblockRequest is required and must be specified") } @@ -1355,7 +1378,7 @@ func (a *DeploymentsApiService) PostDeploymentUnblockExecute(r ApiPostDeployment } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -1365,15 +1388,15 @@ func (a *DeploymentsApiService) PostDeploymentUnblockExecute(r ApiPostDeployment return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -1382,7 +1405,7 @@ func (a *DeploymentsApiService) PostDeploymentUnblockExecute(r ApiPostDeployment err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } diff --git a/clients/go/v1/api_enterprise.go b/clients/go/v1/api_enterprise.go index 00f34ce4..dec77d49 100644 --- a/clients/go/v1/api_enterprise.go +++ b/clients/go/v1/api_enterprise.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -13,23 +13,23 @@ package client import ( "bytes" - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" + "context" + "io/ioutil" + "net/http" + "net/url" "strings" ) // Linger please var ( - _ _context.Context + _ context.Context ) // EnterpriseApiService EnterpriseApi service type EnterpriseApiService service type ApiCreateQuotaSpecRequest struct { - ctx _context.Context + ctx context.Context ApiService *EnterpriseApiService quotaSpec *QuotaSpec region *string @@ -42,61 +42,62 @@ func (r ApiCreateQuotaSpecRequest) QuotaSpec(quotaSpec QuotaSpec) ApiCreateQuota r.quotaSpec = "aSpec return r } +// Filters results based on the specified region. func (r ApiCreateQuotaSpecRequest) Region(region string) ApiCreateQuotaSpecRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiCreateQuotaSpecRequest) Namespace(namespace string) ApiCreateQuotaSpecRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiCreateQuotaSpecRequest) XNomadToken(xNomadToken string) ApiCreateQuotaSpecRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiCreateQuotaSpecRequest) IdempotencyToken(idempotencyToken string) ApiCreateQuotaSpecRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiCreateQuotaSpecRequest) Execute() (*_nethttp.Response, error) { +func (r ApiCreateQuotaSpecRequest) Execute() (*http.Response, error) { return r.ApiService.CreateQuotaSpecExecute(r) } /* - * CreateQuotaSpec Method for CreateQuotaSpec - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiCreateQuotaSpecRequest - */ -func (a *EnterpriseApiService) CreateQuotaSpec(ctx _context.Context) ApiCreateQuotaSpecRequest { +CreateQuotaSpec Method for CreateQuotaSpec + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiCreateQuotaSpecRequest +*/ +func (a *EnterpriseApiService) CreateQuotaSpec(ctx context.Context) ApiCreateQuotaSpecRequest { return ApiCreateQuotaSpecRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - */ -func (a *EnterpriseApiService) CreateQuotaSpecExecute(r ApiCreateQuotaSpecRequest) (*_nethttp.Response, error) { +// Execute executes the request +func (a *EnterpriseApiService) CreateQuotaSpecExecute(r ApiCreateQuotaSpecRequest) (*http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "EnterpriseApiService.CreateQuotaSpec") if err != nil { - return nil, GenericOpenAPIError{error: err.Error()} + return nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/quota" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.quotaSpec == nil { return nil, reportError("quotaSpec is required and must be specified") } @@ -146,7 +147,7 @@ func (a *EnterpriseApiService) CreateQuotaSpecExecute(r ApiCreateQuotaSpecReques } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return nil, err } @@ -156,15 +157,15 @@ func (a *EnterpriseApiService) CreateQuotaSpecExecute(r ApiCreateQuotaSpecReques return localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -175,7 +176,7 @@ func (a *EnterpriseApiService) CreateQuotaSpecExecute(r ApiCreateQuotaSpecReques } type ApiDeleteQuotaSpecRequest struct { - ctx _context.Context + ctx context.Context ApiService *EnterpriseApiService specName string region *string @@ -184,34 +185,39 @@ type ApiDeleteQuotaSpecRequest struct { idempotencyToken *string } +// Filters results based on the specified region. func (r ApiDeleteQuotaSpecRequest) Region(region string) ApiDeleteQuotaSpecRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiDeleteQuotaSpecRequest) Namespace(namespace string) ApiDeleteQuotaSpecRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiDeleteQuotaSpecRequest) XNomadToken(xNomadToken string) ApiDeleteQuotaSpecRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiDeleteQuotaSpecRequest) IdempotencyToken(idempotencyToken string) ApiDeleteQuotaSpecRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiDeleteQuotaSpecRequest) Execute() (*_nethttp.Response, error) { +func (r ApiDeleteQuotaSpecRequest) Execute() (*http.Response, error) { return r.ApiService.DeleteQuotaSpecExecute(r) } /* - * DeleteQuotaSpec Method for DeleteQuotaSpec - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param specName The quota spec identifier. - * @return ApiDeleteQuotaSpecRequest - */ -func (a *EnterpriseApiService) DeleteQuotaSpec(ctx _context.Context, specName string) ApiDeleteQuotaSpecRequest { +DeleteQuotaSpec Method for DeleteQuotaSpec + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param specName The quota spec identifier. + @return ApiDeleteQuotaSpecRequest +*/ +func (a *EnterpriseApiService) DeleteQuotaSpec(ctx context.Context, specName string) ApiDeleteQuotaSpecRequest { return ApiDeleteQuotaSpecRequest{ ApiService: a, ctx: ctx, @@ -219,29 +225,25 @@ func (a *EnterpriseApiService) DeleteQuotaSpec(ctx _context.Context, specName st } } -/* - * Execute executes the request - */ -func (a *EnterpriseApiService) DeleteQuotaSpecExecute(r ApiDeleteQuotaSpecRequest) (*_nethttp.Response, error) { +// Execute executes the request +func (a *EnterpriseApiService) DeleteQuotaSpecExecute(r ApiDeleteQuotaSpecRequest) (*http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodDelete + localVarHTTPMethod = http.MethodDelete localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "EnterpriseApiService.DeleteQuotaSpec") if err != nil { - return nil, GenericOpenAPIError{error: err.Error()} + return nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/quota/{specName}" - localVarPath = strings.Replace(localVarPath, "{"+"specName"+"}", _neturl.PathEscape(parameterToString(r.specName, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"specName"+"}", url.PathEscape(parameterToString(r.specName, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -286,7 +288,7 @@ func (a *EnterpriseApiService) DeleteQuotaSpecExecute(r ApiDeleteQuotaSpecReques } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return nil, err } @@ -296,15 +298,15 @@ func (a *EnterpriseApiService) DeleteQuotaSpecExecute(r ApiDeleteQuotaSpecReques return localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -315,7 +317,7 @@ func (a *EnterpriseApiService) DeleteQuotaSpecExecute(r ApiDeleteQuotaSpecReques } type ApiGetQuotaSpecRequest struct { - ctx _context.Context + ctx context.Context ApiService *EnterpriseApiService specName string region *string @@ -329,54 +331,64 @@ type ApiGetQuotaSpecRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetQuotaSpecRequest) Region(region string) ApiGetQuotaSpecRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetQuotaSpecRequest) Namespace(namespace string) ApiGetQuotaSpecRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetQuotaSpecRequest) Index(index int32) ApiGetQuotaSpecRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetQuotaSpecRequest) Wait(wait string) ApiGetQuotaSpecRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetQuotaSpecRequest) Stale(stale string) ApiGetQuotaSpecRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetQuotaSpecRequest) Prefix(prefix string) ApiGetQuotaSpecRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetQuotaSpecRequest) XNomadToken(xNomadToken string) ApiGetQuotaSpecRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetQuotaSpecRequest) PerPage(perPage int32) ApiGetQuotaSpecRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetQuotaSpecRequest) NextToken(nextToken string) ApiGetQuotaSpecRequest { r.nextToken = &nextToken return r } -func (r ApiGetQuotaSpecRequest) Execute() (QuotaSpec, *_nethttp.Response, error) { +func (r ApiGetQuotaSpecRequest) Execute() (*QuotaSpec, *http.Response, error) { return r.ApiService.GetQuotaSpecExecute(r) } /* - * GetQuotaSpec Method for GetQuotaSpec - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param specName The quota spec identifier. - * @return ApiGetQuotaSpecRequest - */ -func (a *EnterpriseApiService) GetQuotaSpec(ctx _context.Context, specName string) ApiGetQuotaSpecRequest { +GetQuotaSpec Method for GetQuotaSpec + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param specName The quota spec identifier. + @return ApiGetQuotaSpecRequest +*/ +func (a *EnterpriseApiService) GetQuotaSpec(ctx context.Context, specName string) ApiGetQuotaSpecRequest { return ApiGetQuotaSpecRequest{ ApiService: a, ctx: ctx, @@ -384,31 +396,27 @@ func (a *EnterpriseApiService) GetQuotaSpec(ctx _context.Context, specName strin } } -/* - * Execute executes the request - * @return QuotaSpec - */ -func (a *EnterpriseApiService) GetQuotaSpecExecute(r ApiGetQuotaSpecRequest) (QuotaSpec, *_nethttp.Response, error) { +// Execute executes the request +// @return QuotaSpec +func (a *EnterpriseApiService) GetQuotaSpecExecute(r ApiGetQuotaSpecRequest) (*QuotaSpec, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue QuotaSpec + formFiles []formFile + localVarReturnValue *QuotaSpec ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "EnterpriseApiService.GetQuotaSpec") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/quota/{specName}" - localVarPath = strings.Replace(localVarPath, "{"+"specName"+"}", _neturl.PathEscape(parameterToString(r.specName, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"specName"+"}", url.PathEscape(parameterToString(r.specName, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -468,7 +476,7 @@ func (a *EnterpriseApiService) GetQuotaSpecExecute(r ApiGetQuotaSpecRequest) (Qu } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -478,15 +486,15 @@ func (a *EnterpriseApiService) GetQuotaSpecExecute(r ApiGetQuotaSpecRequest) (Qu return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -495,7 +503,7 @@ func (a *EnterpriseApiService) GetQuotaSpecExecute(r ApiGetQuotaSpecRequest) (Qu err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -506,7 +514,7 @@ func (a *EnterpriseApiService) GetQuotaSpecExecute(r ApiGetQuotaSpecRequest) (Qu } type ApiGetQuotasRequest struct { - ctx _context.Context + ctx context.Context ApiService *EnterpriseApiService region *string namespace *string @@ -519,83 +527,89 @@ type ApiGetQuotasRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetQuotasRequest) Region(region string) ApiGetQuotasRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetQuotasRequest) Namespace(namespace string) ApiGetQuotasRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetQuotasRequest) Index(index int32) ApiGetQuotasRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetQuotasRequest) Wait(wait string) ApiGetQuotasRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetQuotasRequest) Stale(stale string) ApiGetQuotasRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetQuotasRequest) Prefix(prefix string) ApiGetQuotasRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetQuotasRequest) XNomadToken(xNomadToken string) ApiGetQuotasRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetQuotasRequest) PerPage(perPage int32) ApiGetQuotasRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetQuotasRequest) NextToken(nextToken string) ApiGetQuotasRequest { r.nextToken = &nextToken return r } -func (r ApiGetQuotasRequest) Execute() ([]interface{}, *_nethttp.Response, error) { +func (r ApiGetQuotasRequest) Execute() ([]interface{}, *http.Response, error) { return r.ApiService.GetQuotasExecute(r) } /* - * GetQuotas Method for GetQuotas - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiGetQuotasRequest - */ -func (a *EnterpriseApiService) GetQuotas(ctx _context.Context) ApiGetQuotasRequest { +GetQuotas Method for GetQuotas + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiGetQuotasRequest +*/ +func (a *EnterpriseApiService) GetQuotas(ctx context.Context) ApiGetQuotasRequest { return ApiGetQuotasRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return []interface{} - */ -func (a *EnterpriseApiService) GetQuotasExecute(r ApiGetQuotasRequest) ([]interface{}, *_nethttp.Response, error) { +// Execute executes the request +// @return []interface{} +func (a *EnterpriseApiService) GetQuotasExecute(r ApiGetQuotasRequest) ([]interface{}, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile localVarReturnValue []interface{} ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "EnterpriseApiService.GetQuotas") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/quotas" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -655,7 +669,7 @@ func (a *EnterpriseApiService) GetQuotasExecute(r ApiGetQuotasRequest) ([]interf } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -665,15 +679,15 @@ func (a *EnterpriseApiService) GetQuotasExecute(r ApiGetQuotasRequest) ([]interf return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -682,7 +696,7 @@ func (a *EnterpriseApiService) GetQuotasExecute(r ApiGetQuotasRequest) ([]interf err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -693,7 +707,7 @@ func (a *EnterpriseApiService) GetQuotasExecute(r ApiGetQuotasRequest) ([]interf } type ApiPostQuotaSpecRequest struct { - ctx _context.Context + ctx context.Context ApiService *EnterpriseApiService specName string quotaSpec *QuotaSpec @@ -707,34 +721,39 @@ func (r ApiPostQuotaSpecRequest) QuotaSpec(quotaSpec QuotaSpec) ApiPostQuotaSpec r.quotaSpec = "aSpec return r } +// Filters results based on the specified region. func (r ApiPostQuotaSpecRequest) Region(region string) ApiPostQuotaSpecRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiPostQuotaSpecRequest) Namespace(namespace string) ApiPostQuotaSpecRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiPostQuotaSpecRequest) XNomadToken(xNomadToken string) ApiPostQuotaSpecRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiPostQuotaSpecRequest) IdempotencyToken(idempotencyToken string) ApiPostQuotaSpecRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiPostQuotaSpecRequest) Execute() (*_nethttp.Response, error) { +func (r ApiPostQuotaSpecRequest) Execute() (*http.Response, error) { return r.ApiService.PostQuotaSpecExecute(r) } /* - * PostQuotaSpec Method for PostQuotaSpec - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param specName The quota spec identifier. - * @return ApiPostQuotaSpecRequest - */ -func (a *EnterpriseApiService) PostQuotaSpec(ctx _context.Context, specName string) ApiPostQuotaSpecRequest { +PostQuotaSpec Method for PostQuotaSpec + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param specName The quota spec identifier. + @return ApiPostQuotaSpecRequest +*/ +func (a *EnterpriseApiService) PostQuotaSpec(ctx context.Context, specName string) ApiPostQuotaSpecRequest { return ApiPostQuotaSpecRequest{ ApiService: a, ctx: ctx, @@ -742,29 +761,25 @@ func (a *EnterpriseApiService) PostQuotaSpec(ctx _context.Context, specName stri } } -/* - * Execute executes the request - */ -func (a *EnterpriseApiService) PostQuotaSpecExecute(r ApiPostQuotaSpecRequest) (*_nethttp.Response, error) { +// Execute executes the request +func (a *EnterpriseApiService) PostQuotaSpecExecute(r ApiPostQuotaSpecRequest) (*http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "EnterpriseApiService.PostQuotaSpec") if err != nil { - return nil, GenericOpenAPIError{error: err.Error()} + return nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/quota/{specName}" - localVarPath = strings.Replace(localVarPath, "{"+"specName"+"}", _neturl.PathEscape(parameterToString(r.specName, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"specName"+"}", url.PathEscape(parameterToString(r.specName, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.quotaSpec == nil { return nil, reportError("quotaSpec is required and must be specified") } @@ -814,7 +829,7 @@ func (a *EnterpriseApiService) PostQuotaSpecExecute(r ApiPostQuotaSpecRequest) ( } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return nil, err } @@ -824,15 +839,15 @@ func (a *EnterpriseApiService) PostQuotaSpecExecute(r ApiPostQuotaSpecRequest) ( return localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } diff --git a/clients/go/v1/api_evaluations.go b/clients/go/v1/api_evaluations.go index 3565bb97..c0ef0326 100644 --- a/clients/go/v1/api_evaluations.go +++ b/clients/go/v1/api_evaluations.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -13,23 +13,23 @@ package client import ( "bytes" - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" + "context" + "io/ioutil" + "net/http" + "net/url" "strings" ) // Linger please var ( - _ _context.Context + _ context.Context ) // EvaluationsApiService EvaluationsApi service type EvaluationsApiService service type ApiGetEvaluationRequest struct { - ctx _context.Context + ctx context.Context ApiService *EvaluationsApiService evalID string region *string @@ -43,54 +43,64 @@ type ApiGetEvaluationRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetEvaluationRequest) Region(region string) ApiGetEvaluationRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetEvaluationRequest) Namespace(namespace string) ApiGetEvaluationRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetEvaluationRequest) Index(index int32) ApiGetEvaluationRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetEvaluationRequest) Wait(wait string) ApiGetEvaluationRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetEvaluationRequest) Stale(stale string) ApiGetEvaluationRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetEvaluationRequest) Prefix(prefix string) ApiGetEvaluationRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetEvaluationRequest) XNomadToken(xNomadToken string) ApiGetEvaluationRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetEvaluationRequest) PerPage(perPage int32) ApiGetEvaluationRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetEvaluationRequest) NextToken(nextToken string) ApiGetEvaluationRequest { r.nextToken = &nextToken return r } -func (r ApiGetEvaluationRequest) Execute() (Evaluation, *_nethttp.Response, error) { +func (r ApiGetEvaluationRequest) Execute() (*Evaluation, *http.Response, error) { return r.ApiService.GetEvaluationExecute(r) } /* - * GetEvaluation Method for GetEvaluation - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param evalID Evaluation ID. - * @return ApiGetEvaluationRequest - */ -func (a *EvaluationsApiService) GetEvaluation(ctx _context.Context, evalID string) ApiGetEvaluationRequest { +GetEvaluation Method for GetEvaluation + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param evalID Evaluation ID. + @return ApiGetEvaluationRequest +*/ +func (a *EvaluationsApiService) GetEvaluation(ctx context.Context, evalID string) ApiGetEvaluationRequest { return ApiGetEvaluationRequest{ ApiService: a, ctx: ctx, @@ -98,31 +108,27 @@ func (a *EvaluationsApiService) GetEvaluation(ctx _context.Context, evalID strin } } -/* - * Execute executes the request - * @return Evaluation - */ -func (a *EvaluationsApiService) GetEvaluationExecute(r ApiGetEvaluationRequest) (Evaluation, *_nethttp.Response, error) { +// Execute executes the request +// @return Evaluation +func (a *EvaluationsApiService) GetEvaluationExecute(r ApiGetEvaluationRequest) (*Evaluation, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue Evaluation + formFiles []formFile + localVarReturnValue *Evaluation ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "EvaluationsApiService.GetEvaluation") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/evaluation/{evalID}" - localVarPath = strings.Replace(localVarPath, "{"+"evalID"+"}", _neturl.PathEscape(parameterToString(r.evalID, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"evalID"+"}", url.PathEscape(parameterToString(r.evalID, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -182,7 +188,7 @@ func (a *EvaluationsApiService) GetEvaluationExecute(r ApiGetEvaluationRequest) } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -192,15 +198,15 @@ func (a *EvaluationsApiService) GetEvaluationExecute(r ApiGetEvaluationRequest) return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -209,7 +215,7 @@ func (a *EvaluationsApiService) GetEvaluationExecute(r ApiGetEvaluationRequest) err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -220,7 +226,7 @@ func (a *EvaluationsApiService) GetEvaluationExecute(r ApiGetEvaluationRequest) } type ApiGetEvaluationAllocationsRequest struct { - ctx _context.Context + ctx context.Context ApiService *EvaluationsApiService evalID string region *string @@ -234,54 +240,64 @@ type ApiGetEvaluationAllocationsRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetEvaluationAllocationsRequest) Region(region string) ApiGetEvaluationAllocationsRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetEvaluationAllocationsRequest) Namespace(namespace string) ApiGetEvaluationAllocationsRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetEvaluationAllocationsRequest) Index(index int32) ApiGetEvaluationAllocationsRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetEvaluationAllocationsRequest) Wait(wait string) ApiGetEvaluationAllocationsRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetEvaluationAllocationsRequest) Stale(stale string) ApiGetEvaluationAllocationsRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetEvaluationAllocationsRequest) Prefix(prefix string) ApiGetEvaluationAllocationsRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetEvaluationAllocationsRequest) XNomadToken(xNomadToken string) ApiGetEvaluationAllocationsRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetEvaluationAllocationsRequest) PerPage(perPage int32) ApiGetEvaluationAllocationsRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetEvaluationAllocationsRequest) NextToken(nextToken string) ApiGetEvaluationAllocationsRequest { r.nextToken = &nextToken return r } -func (r ApiGetEvaluationAllocationsRequest) Execute() ([]AllocationListStub, *_nethttp.Response, error) { +func (r ApiGetEvaluationAllocationsRequest) Execute() ([]AllocationListStub, *http.Response, error) { return r.ApiService.GetEvaluationAllocationsExecute(r) } /* - * GetEvaluationAllocations Method for GetEvaluationAllocations - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param evalID Evaluation ID. - * @return ApiGetEvaluationAllocationsRequest - */ -func (a *EvaluationsApiService) GetEvaluationAllocations(ctx _context.Context, evalID string) ApiGetEvaluationAllocationsRequest { +GetEvaluationAllocations Method for GetEvaluationAllocations + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param evalID Evaluation ID. + @return ApiGetEvaluationAllocationsRequest +*/ +func (a *EvaluationsApiService) GetEvaluationAllocations(ctx context.Context, evalID string) ApiGetEvaluationAllocationsRequest { return ApiGetEvaluationAllocationsRequest{ ApiService: a, ctx: ctx, @@ -289,31 +305,27 @@ func (a *EvaluationsApiService) GetEvaluationAllocations(ctx _context.Context, e } } -/* - * Execute executes the request - * @return []AllocationListStub - */ -func (a *EvaluationsApiService) GetEvaluationAllocationsExecute(r ApiGetEvaluationAllocationsRequest) ([]AllocationListStub, *_nethttp.Response, error) { +// Execute executes the request +// @return []AllocationListStub +func (a *EvaluationsApiService) GetEvaluationAllocationsExecute(r ApiGetEvaluationAllocationsRequest) ([]AllocationListStub, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile localVarReturnValue []AllocationListStub ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "EvaluationsApiService.GetEvaluationAllocations") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/evaluation/{evalID}/allocations" - localVarPath = strings.Replace(localVarPath, "{"+"evalID"+"}", _neturl.PathEscape(parameterToString(r.evalID, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"evalID"+"}", url.PathEscape(parameterToString(r.evalID, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -373,7 +385,7 @@ func (a *EvaluationsApiService) GetEvaluationAllocationsExecute(r ApiGetEvaluati } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -383,15 +395,15 @@ func (a *EvaluationsApiService) GetEvaluationAllocationsExecute(r ApiGetEvaluati return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -400,7 +412,7 @@ func (a *EvaluationsApiService) GetEvaluationAllocationsExecute(r ApiGetEvaluati err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -411,7 +423,7 @@ func (a *EvaluationsApiService) GetEvaluationAllocationsExecute(r ApiGetEvaluati } type ApiGetEvaluationsRequest struct { - ctx _context.Context + ctx context.Context ApiService *EvaluationsApiService region *string namespace *string @@ -424,83 +436,89 @@ type ApiGetEvaluationsRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetEvaluationsRequest) Region(region string) ApiGetEvaluationsRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetEvaluationsRequest) Namespace(namespace string) ApiGetEvaluationsRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetEvaluationsRequest) Index(index int32) ApiGetEvaluationsRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetEvaluationsRequest) Wait(wait string) ApiGetEvaluationsRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetEvaluationsRequest) Stale(stale string) ApiGetEvaluationsRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetEvaluationsRequest) Prefix(prefix string) ApiGetEvaluationsRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetEvaluationsRequest) XNomadToken(xNomadToken string) ApiGetEvaluationsRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetEvaluationsRequest) PerPage(perPage int32) ApiGetEvaluationsRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetEvaluationsRequest) NextToken(nextToken string) ApiGetEvaluationsRequest { r.nextToken = &nextToken return r } -func (r ApiGetEvaluationsRequest) Execute() ([]Evaluation, *_nethttp.Response, error) { +func (r ApiGetEvaluationsRequest) Execute() ([]Evaluation, *http.Response, error) { return r.ApiService.GetEvaluationsExecute(r) } /* - * GetEvaluations Method for GetEvaluations - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiGetEvaluationsRequest - */ -func (a *EvaluationsApiService) GetEvaluations(ctx _context.Context) ApiGetEvaluationsRequest { +GetEvaluations Method for GetEvaluations + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiGetEvaluationsRequest +*/ +func (a *EvaluationsApiService) GetEvaluations(ctx context.Context) ApiGetEvaluationsRequest { return ApiGetEvaluationsRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return []Evaluation - */ -func (a *EvaluationsApiService) GetEvaluationsExecute(r ApiGetEvaluationsRequest) ([]Evaluation, *_nethttp.Response, error) { +// Execute executes the request +// @return []Evaluation +func (a *EvaluationsApiService) GetEvaluationsExecute(r ApiGetEvaluationsRequest) ([]Evaluation, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile localVarReturnValue []Evaluation ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "EvaluationsApiService.GetEvaluations") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/evaluations" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -560,7 +578,7 @@ func (a *EvaluationsApiService) GetEvaluationsExecute(r ApiGetEvaluationsRequest } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -570,15 +588,15 @@ func (a *EvaluationsApiService) GetEvaluationsExecute(r ApiGetEvaluationsRequest return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -587,7 +605,7 @@ func (a *EvaluationsApiService) GetEvaluationsExecute(r ApiGetEvaluationsRequest err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } diff --git a/clients/go/v1/api_jobs.go b/clients/go/v1/api_jobs.go index d354d249..d9b98310 100644 --- a/clients/go/v1/api_jobs.go +++ b/clients/go/v1/api_jobs.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -13,23 +13,23 @@ package client import ( "bytes" - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" + "context" + "io/ioutil" + "net/http" + "net/url" "strings" ) // Linger please var ( - _ _context.Context + _ context.Context ) // JobsApiService JobsApi service type JobsApiService service type ApiDeleteJobRequest struct { - ctx _context.Context + ctx context.Context ApiService *JobsApiService jobName string region *string @@ -40,42 +40,49 @@ type ApiDeleteJobRequest struct { global *bool } +// Filters results based on the specified region. func (r ApiDeleteJobRequest) Region(region string) ApiDeleteJobRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiDeleteJobRequest) Namespace(namespace string) ApiDeleteJobRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiDeleteJobRequest) XNomadToken(xNomadToken string) ApiDeleteJobRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiDeleteJobRequest) IdempotencyToken(idempotencyToken string) ApiDeleteJobRequest { r.idempotencyToken = &idempotencyToken return r } +// Boolean flag indicating whether to purge allocations of the job after deleting. func (r ApiDeleteJobRequest) Purge(purge bool) ApiDeleteJobRequest { r.purge = &purge return r } +// Boolean flag indicating whether the operation should apply to all instances of the job globally. func (r ApiDeleteJobRequest) Global(global bool) ApiDeleteJobRequest { r.global = &global return r } -func (r ApiDeleteJobRequest) Execute() (JobDeregisterResponse, *_nethttp.Response, error) { +func (r ApiDeleteJobRequest) Execute() (*JobDeregisterResponse, *http.Response, error) { return r.ApiService.DeleteJobExecute(r) } /* - * DeleteJob Method for DeleteJob - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param jobName The job identifier. - * @return ApiDeleteJobRequest - */ -func (a *JobsApiService) DeleteJob(ctx _context.Context, jobName string) ApiDeleteJobRequest { +DeleteJob Method for DeleteJob + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param jobName The job identifier. + @return ApiDeleteJobRequest +*/ +func (a *JobsApiService) DeleteJob(ctx context.Context, jobName string) ApiDeleteJobRequest { return ApiDeleteJobRequest{ ApiService: a, ctx: ctx, @@ -83,31 +90,27 @@ func (a *JobsApiService) DeleteJob(ctx _context.Context, jobName string) ApiDele } } -/* - * Execute executes the request - * @return JobDeregisterResponse - */ -func (a *JobsApiService) DeleteJobExecute(r ApiDeleteJobRequest) (JobDeregisterResponse, *_nethttp.Response, error) { +// Execute executes the request +// @return JobDeregisterResponse +func (a *JobsApiService) DeleteJobExecute(r ApiDeleteJobRequest) (*JobDeregisterResponse, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodDelete + localVarHTTPMethod = http.MethodDelete localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue JobDeregisterResponse + formFiles []formFile + localVarReturnValue *JobDeregisterResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "JobsApiService.DeleteJob") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/job/{jobName}" - localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", _neturl.PathEscape(parameterToString(r.jobName, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", url.PathEscape(parameterToString(r.jobName, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -158,7 +161,7 @@ func (a *JobsApiService) DeleteJobExecute(r ApiDeleteJobRequest) (JobDeregisterR } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -168,15 +171,15 @@ func (a *JobsApiService) DeleteJobExecute(r ApiDeleteJobRequest) (JobDeregisterR return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -185,7 +188,7 @@ func (a *JobsApiService) DeleteJobExecute(r ApiDeleteJobRequest) (JobDeregisterR err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -196,7 +199,7 @@ func (a *JobsApiService) DeleteJobExecute(r ApiDeleteJobRequest) (JobDeregisterR } type ApiGetJobRequest struct { - ctx _context.Context + ctx context.Context ApiService *JobsApiService jobName string region *string @@ -210,54 +213,64 @@ type ApiGetJobRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetJobRequest) Region(region string) ApiGetJobRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetJobRequest) Namespace(namespace string) ApiGetJobRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetJobRequest) Index(index int32) ApiGetJobRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetJobRequest) Wait(wait string) ApiGetJobRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetJobRequest) Stale(stale string) ApiGetJobRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetJobRequest) Prefix(prefix string) ApiGetJobRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetJobRequest) XNomadToken(xNomadToken string) ApiGetJobRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetJobRequest) PerPage(perPage int32) ApiGetJobRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetJobRequest) NextToken(nextToken string) ApiGetJobRequest { r.nextToken = &nextToken return r } -func (r ApiGetJobRequest) Execute() (Job, *_nethttp.Response, error) { +func (r ApiGetJobRequest) Execute() (*Job, *http.Response, error) { return r.ApiService.GetJobExecute(r) } /* - * GetJob Method for GetJob - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param jobName The job identifier. - * @return ApiGetJobRequest - */ -func (a *JobsApiService) GetJob(ctx _context.Context, jobName string) ApiGetJobRequest { +GetJob Method for GetJob + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param jobName The job identifier. + @return ApiGetJobRequest +*/ +func (a *JobsApiService) GetJob(ctx context.Context, jobName string) ApiGetJobRequest { return ApiGetJobRequest{ ApiService: a, ctx: ctx, @@ -265,31 +278,27 @@ func (a *JobsApiService) GetJob(ctx _context.Context, jobName string) ApiGetJobR } } -/* - * Execute executes the request - * @return Job - */ -func (a *JobsApiService) GetJobExecute(r ApiGetJobRequest) (Job, *_nethttp.Response, error) { +// Execute executes the request +// @return Job +func (a *JobsApiService) GetJobExecute(r ApiGetJobRequest) (*Job, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue Job + formFiles []formFile + localVarReturnValue *Job ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "JobsApiService.GetJob") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/job/{jobName}" - localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", _neturl.PathEscape(parameterToString(r.jobName, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", url.PathEscape(parameterToString(r.jobName, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -349,7 +358,7 @@ func (a *JobsApiService) GetJobExecute(r ApiGetJobRequest) (Job, *_nethttp.Respo } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -359,15 +368,15 @@ func (a *JobsApiService) GetJobExecute(r ApiGetJobRequest) (Job, *_nethttp.Respo return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -376,7 +385,7 @@ func (a *JobsApiService) GetJobExecute(r ApiGetJobRequest) (Job, *_nethttp.Respo err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -387,7 +396,7 @@ func (a *JobsApiService) GetJobExecute(r ApiGetJobRequest) (Job, *_nethttp.Respo } type ApiGetJobAllocationsRequest struct { - ctx _context.Context + ctx context.Context ApiService *JobsApiService jobName string region *string @@ -402,58 +411,69 @@ type ApiGetJobAllocationsRequest struct { all *bool } +// Filters results based on the specified region. func (r ApiGetJobAllocationsRequest) Region(region string) ApiGetJobAllocationsRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetJobAllocationsRequest) Namespace(namespace string) ApiGetJobAllocationsRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetJobAllocationsRequest) Index(index int32) ApiGetJobAllocationsRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetJobAllocationsRequest) Wait(wait string) ApiGetJobAllocationsRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetJobAllocationsRequest) Stale(stale string) ApiGetJobAllocationsRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetJobAllocationsRequest) Prefix(prefix string) ApiGetJobAllocationsRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetJobAllocationsRequest) XNomadToken(xNomadToken string) ApiGetJobAllocationsRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetJobAllocationsRequest) PerPage(perPage int32) ApiGetJobAllocationsRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetJobAllocationsRequest) NextToken(nextToken string) ApiGetJobAllocationsRequest { r.nextToken = &nextToken return r } +// Specifies whether the list of allocations should include allocations from a previously registered job with the same ID. This is possible if the job is deregistered and reregistered. func (r ApiGetJobAllocationsRequest) All(all bool) ApiGetJobAllocationsRequest { r.all = &all return r } -func (r ApiGetJobAllocationsRequest) Execute() ([]AllocationListStub, *_nethttp.Response, error) { +func (r ApiGetJobAllocationsRequest) Execute() ([]AllocationListStub, *http.Response, error) { return r.ApiService.GetJobAllocationsExecute(r) } /* - * GetJobAllocations Method for GetJobAllocations - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param jobName The job identifier. - * @return ApiGetJobAllocationsRequest - */ -func (a *JobsApiService) GetJobAllocations(ctx _context.Context, jobName string) ApiGetJobAllocationsRequest { +GetJobAllocations Method for GetJobAllocations + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param jobName The job identifier. + @return ApiGetJobAllocationsRequest +*/ +func (a *JobsApiService) GetJobAllocations(ctx context.Context, jobName string) ApiGetJobAllocationsRequest { return ApiGetJobAllocationsRequest{ ApiService: a, ctx: ctx, @@ -461,31 +481,27 @@ func (a *JobsApiService) GetJobAllocations(ctx _context.Context, jobName string) } } -/* - * Execute executes the request - * @return []AllocationListStub - */ -func (a *JobsApiService) GetJobAllocationsExecute(r ApiGetJobAllocationsRequest) ([]AllocationListStub, *_nethttp.Response, error) { +// Execute executes the request +// @return []AllocationListStub +func (a *JobsApiService) GetJobAllocationsExecute(r ApiGetJobAllocationsRequest) ([]AllocationListStub, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile localVarReturnValue []AllocationListStub ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "JobsApiService.GetJobAllocations") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/job/{jobName}/allocations" - localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", _neturl.PathEscape(parameterToString(r.jobName, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", url.PathEscape(parameterToString(r.jobName, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -548,7 +564,7 @@ func (a *JobsApiService) GetJobAllocationsExecute(r ApiGetJobAllocationsRequest) } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -558,15 +574,15 @@ func (a *JobsApiService) GetJobAllocationsExecute(r ApiGetJobAllocationsRequest) return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -575,7 +591,7 @@ func (a *JobsApiService) GetJobAllocationsExecute(r ApiGetJobAllocationsRequest) err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -586,7 +602,7 @@ func (a *JobsApiService) GetJobAllocationsExecute(r ApiGetJobAllocationsRequest) } type ApiGetJobDeploymentRequest struct { - ctx _context.Context + ctx context.Context ApiService *JobsApiService jobName string region *string @@ -600,54 +616,64 @@ type ApiGetJobDeploymentRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetJobDeploymentRequest) Region(region string) ApiGetJobDeploymentRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetJobDeploymentRequest) Namespace(namespace string) ApiGetJobDeploymentRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetJobDeploymentRequest) Index(index int32) ApiGetJobDeploymentRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetJobDeploymentRequest) Wait(wait string) ApiGetJobDeploymentRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetJobDeploymentRequest) Stale(stale string) ApiGetJobDeploymentRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetJobDeploymentRequest) Prefix(prefix string) ApiGetJobDeploymentRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetJobDeploymentRequest) XNomadToken(xNomadToken string) ApiGetJobDeploymentRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetJobDeploymentRequest) PerPage(perPage int32) ApiGetJobDeploymentRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetJobDeploymentRequest) NextToken(nextToken string) ApiGetJobDeploymentRequest { r.nextToken = &nextToken return r } -func (r ApiGetJobDeploymentRequest) Execute() (Deployment, *_nethttp.Response, error) { +func (r ApiGetJobDeploymentRequest) Execute() (*Deployment, *http.Response, error) { return r.ApiService.GetJobDeploymentExecute(r) } /* - * GetJobDeployment Method for GetJobDeployment - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param jobName The job identifier. - * @return ApiGetJobDeploymentRequest - */ -func (a *JobsApiService) GetJobDeployment(ctx _context.Context, jobName string) ApiGetJobDeploymentRequest { +GetJobDeployment Method for GetJobDeployment + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param jobName The job identifier. + @return ApiGetJobDeploymentRequest +*/ +func (a *JobsApiService) GetJobDeployment(ctx context.Context, jobName string) ApiGetJobDeploymentRequest { return ApiGetJobDeploymentRequest{ ApiService: a, ctx: ctx, @@ -655,31 +681,27 @@ func (a *JobsApiService) GetJobDeployment(ctx _context.Context, jobName string) } } -/* - * Execute executes the request - * @return Deployment - */ -func (a *JobsApiService) GetJobDeploymentExecute(r ApiGetJobDeploymentRequest) (Deployment, *_nethttp.Response, error) { +// Execute executes the request +// @return Deployment +func (a *JobsApiService) GetJobDeploymentExecute(r ApiGetJobDeploymentRequest) (*Deployment, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue Deployment + formFiles []formFile + localVarReturnValue *Deployment ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "JobsApiService.GetJobDeployment") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/job/{jobName}/deployment" - localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", _neturl.PathEscape(parameterToString(r.jobName, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", url.PathEscape(parameterToString(r.jobName, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -739,7 +761,7 @@ func (a *JobsApiService) GetJobDeploymentExecute(r ApiGetJobDeploymentRequest) ( } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -749,15 +771,15 @@ func (a *JobsApiService) GetJobDeploymentExecute(r ApiGetJobDeploymentRequest) ( return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -766,7 +788,7 @@ func (a *JobsApiService) GetJobDeploymentExecute(r ApiGetJobDeploymentRequest) ( err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -777,7 +799,7 @@ func (a *JobsApiService) GetJobDeploymentExecute(r ApiGetJobDeploymentRequest) ( } type ApiGetJobDeploymentsRequest struct { - ctx _context.Context + ctx context.Context ApiService *JobsApiService jobName string region *string @@ -792,58 +814,69 @@ type ApiGetJobDeploymentsRequest struct { all *int32 } +// Filters results based on the specified region. func (r ApiGetJobDeploymentsRequest) Region(region string) ApiGetJobDeploymentsRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetJobDeploymentsRequest) Namespace(namespace string) ApiGetJobDeploymentsRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetJobDeploymentsRequest) Index(index int32) ApiGetJobDeploymentsRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetJobDeploymentsRequest) Wait(wait string) ApiGetJobDeploymentsRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetJobDeploymentsRequest) Stale(stale string) ApiGetJobDeploymentsRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetJobDeploymentsRequest) Prefix(prefix string) ApiGetJobDeploymentsRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetJobDeploymentsRequest) XNomadToken(xNomadToken string) ApiGetJobDeploymentsRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetJobDeploymentsRequest) PerPage(perPage int32) ApiGetJobDeploymentsRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetJobDeploymentsRequest) NextToken(nextToken string) ApiGetJobDeploymentsRequest { r.nextToken = &nextToken return r } +// Flag indicating whether to constrain by job creation index or not. func (r ApiGetJobDeploymentsRequest) All(all int32) ApiGetJobDeploymentsRequest { r.all = &all return r } -func (r ApiGetJobDeploymentsRequest) Execute() ([]Deployment, *_nethttp.Response, error) { +func (r ApiGetJobDeploymentsRequest) Execute() ([]Deployment, *http.Response, error) { return r.ApiService.GetJobDeploymentsExecute(r) } /* - * GetJobDeployments Method for GetJobDeployments - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param jobName The job identifier. - * @return ApiGetJobDeploymentsRequest - */ -func (a *JobsApiService) GetJobDeployments(ctx _context.Context, jobName string) ApiGetJobDeploymentsRequest { +GetJobDeployments Method for GetJobDeployments + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param jobName The job identifier. + @return ApiGetJobDeploymentsRequest +*/ +func (a *JobsApiService) GetJobDeployments(ctx context.Context, jobName string) ApiGetJobDeploymentsRequest { return ApiGetJobDeploymentsRequest{ ApiService: a, ctx: ctx, @@ -851,31 +884,27 @@ func (a *JobsApiService) GetJobDeployments(ctx _context.Context, jobName string) } } -/* - * Execute executes the request - * @return []Deployment - */ -func (a *JobsApiService) GetJobDeploymentsExecute(r ApiGetJobDeploymentsRequest) ([]Deployment, *_nethttp.Response, error) { +// Execute executes the request +// @return []Deployment +func (a *JobsApiService) GetJobDeploymentsExecute(r ApiGetJobDeploymentsRequest) ([]Deployment, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile localVarReturnValue []Deployment ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "JobsApiService.GetJobDeployments") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/job/{jobName}/deployments" - localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", _neturl.PathEscape(parameterToString(r.jobName, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", url.PathEscape(parameterToString(r.jobName, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -938,7 +967,7 @@ func (a *JobsApiService) GetJobDeploymentsExecute(r ApiGetJobDeploymentsRequest) } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -948,15 +977,15 @@ func (a *JobsApiService) GetJobDeploymentsExecute(r ApiGetJobDeploymentsRequest) return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -965,7 +994,7 @@ func (a *JobsApiService) GetJobDeploymentsExecute(r ApiGetJobDeploymentsRequest) err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -976,7 +1005,7 @@ func (a *JobsApiService) GetJobDeploymentsExecute(r ApiGetJobDeploymentsRequest) } type ApiGetJobEvaluationsRequest struct { - ctx _context.Context + ctx context.Context ApiService *JobsApiService jobName string region *string @@ -990,54 +1019,64 @@ type ApiGetJobEvaluationsRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetJobEvaluationsRequest) Region(region string) ApiGetJobEvaluationsRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetJobEvaluationsRequest) Namespace(namespace string) ApiGetJobEvaluationsRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetJobEvaluationsRequest) Index(index int32) ApiGetJobEvaluationsRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetJobEvaluationsRequest) Wait(wait string) ApiGetJobEvaluationsRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetJobEvaluationsRequest) Stale(stale string) ApiGetJobEvaluationsRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetJobEvaluationsRequest) Prefix(prefix string) ApiGetJobEvaluationsRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetJobEvaluationsRequest) XNomadToken(xNomadToken string) ApiGetJobEvaluationsRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetJobEvaluationsRequest) PerPage(perPage int32) ApiGetJobEvaluationsRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetJobEvaluationsRequest) NextToken(nextToken string) ApiGetJobEvaluationsRequest { r.nextToken = &nextToken return r } -func (r ApiGetJobEvaluationsRequest) Execute() ([]Evaluation, *_nethttp.Response, error) { +func (r ApiGetJobEvaluationsRequest) Execute() ([]Evaluation, *http.Response, error) { return r.ApiService.GetJobEvaluationsExecute(r) } /* - * GetJobEvaluations Method for GetJobEvaluations - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param jobName The job identifier. - * @return ApiGetJobEvaluationsRequest - */ -func (a *JobsApiService) GetJobEvaluations(ctx _context.Context, jobName string) ApiGetJobEvaluationsRequest { +GetJobEvaluations Method for GetJobEvaluations + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param jobName The job identifier. + @return ApiGetJobEvaluationsRequest +*/ +func (a *JobsApiService) GetJobEvaluations(ctx context.Context, jobName string) ApiGetJobEvaluationsRequest { return ApiGetJobEvaluationsRequest{ ApiService: a, ctx: ctx, @@ -1045,31 +1084,27 @@ func (a *JobsApiService) GetJobEvaluations(ctx _context.Context, jobName string) } } -/* - * Execute executes the request - * @return []Evaluation - */ -func (a *JobsApiService) GetJobEvaluationsExecute(r ApiGetJobEvaluationsRequest) ([]Evaluation, *_nethttp.Response, error) { +// Execute executes the request +// @return []Evaluation +func (a *JobsApiService) GetJobEvaluationsExecute(r ApiGetJobEvaluationsRequest) ([]Evaluation, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile localVarReturnValue []Evaluation ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "JobsApiService.GetJobEvaluations") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/job/{jobName}/evaluations" - localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", _neturl.PathEscape(parameterToString(r.jobName, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", url.PathEscape(parameterToString(r.jobName, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -1129,7 +1164,7 @@ func (a *JobsApiService) GetJobEvaluationsExecute(r ApiGetJobEvaluationsRequest) } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -1139,15 +1174,15 @@ func (a *JobsApiService) GetJobEvaluationsExecute(r ApiGetJobEvaluationsRequest) return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -1156,7 +1191,7 @@ func (a *JobsApiService) GetJobEvaluationsExecute(r ApiGetJobEvaluationsRequest) err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -1167,7 +1202,7 @@ func (a *JobsApiService) GetJobEvaluationsExecute(r ApiGetJobEvaluationsRequest) } type ApiGetJobScaleStatusRequest struct { - ctx _context.Context + ctx context.Context ApiService *JobsApiService jobName string region *string @@ -1181,54 +1216,64 @@ type ApiGetJobScaleStatusRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetJobScaleStatusRequest) Region(region string) ApiGetJobScaleStatusRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetJobScaleStatusRequest) Namespace(namespace string) ApiGetJobScaleStatusRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetJobScaleStatusRequest) Index(index int32) ApiGetJobScaleStatusRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetJobScaleStatusRequest) Wait(wait string) ApiGetJobScaleStatusRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetJobScaleStatusRequest) Stale(stale string) ApiGetJobScaleStatusRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetJobScaleStatusRequest) Prefix(prefix string) ApiGetJobScaleStatusRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetJobScaleStatusRequest) XNomadToken(xNomadToken string) ApiGetJobScaleStatusRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetJobScaleStatusRequest) PerPage(perPage int32) ApiGetJobScaleStatusRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetJobScaleStatusRequest) NextToken(nextToken string) ApiGetJobScaleStatusRequest { r.nextToken = &nextToken return r } -func (r ApiGetJobScaleStatusRequest) Execute() (JobScaleStatusResponse, *_nethttp.Response, error) { +func (r ApiGetJobScaleStatusRequest) Execute() (*JobScaleStatusResponse, *http.Response, error) { return r.ApiService.GetJobScaleStatusExecute(r) } /* - * GetJobScaleStatus Method for GetJobScaleStatus - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param jobName The job identifier. - * @return ApiGetJobScaleStatusRequest - */ -func (a *JobsApiService) GetJobScaleStatus(ctx _context.Context, jobName string) ApiGetJobScaleStatusRequest { +GetJobScaleStatus Method for GetJobScaleStatus + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param jobName The job identifier. + @return ApiGetJobScaleStatusRequest +*/ +func (a *JobsApiService) GetJobScaleStatus(ctx context.Context, jobName string) ApiGetJobScaleStatusRequest { return ApiGetJobScaleStatusRequest{ ApiService: a, ctx: ctx, @@ -1236,31 +1281,27 @@ func (a *JobsApiService) GetJobScaleStatus(ctx _context.Context, jobName string) } } -/* - * Execute executes the request - * @return JobScaleStatusResponse - */ -func (a *JobsApiService) GetJobScaleStatusExecute(r ApiGetJobScaleStatusRequest) (JobScaleStatusResponse, *_nethttp.Response, error) { +// Execute executes the request +// @return JobScaleStatusResponse +func (a *JobsApiService) GetJobScaleStatusExecute(r ApiGetJobScaleStatusRequest) (*JobScaleStatusResponse, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue JobScaleStatusResponse + formFiles []formFile + localVarReturnValue *JobScaleStatusResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "JobsApiService.GetJobScaleStatus") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/job/{jobName}/scale" - localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", _neturl.PathEscape(parameterToString(r.jobName, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", url.PathEscape(parameterToString(r.jobName, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -1320,7 +1361,7 @@ func (a *JobsApiService) GetJobScaleStatusExecute(r ApiGetJobScaleStatusRequest) } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -1330,15 +1371,15 @@ func (a *JobsApiService) GetJobScaleStatusExecute(r ApiGetJobScaleStatusRequest) return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -1347,7 +1388,7 @@ func (a *JobsApiService) GetJobScaleStatusExecute(r ApiGetJobScaleStatusRequest) err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -1358,7 +1399,7 @@ func (a *JobsApiService) GetJobScaleStatusExecute(r ApiGetJobScaleStatusRequest) } type ApiGetJobSummaryRequest struct { - ctx _context.Context + ctx context.Context ApiService *JobsApiService jobName string region *string @@ -1372,54 +1413,64 @@ type ApiGetJobSummaryRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetJobSummaryRequest) Region(region string) ApiGetJobSummaryRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetJobSummaryRequest) Namespace(namespace string) ApiGetJobSummaryRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetJobSummaryRequest) Index(index int32) ApiGetJobSummaryRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetJobSummaryRequest) Wait(wait string) ApiGetJobSummaryRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetJobSummaryRequest) Stale(stale string) ApiGetJobSummaryRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetJobSummaryRequest) Prefix(prefix string) ApiGetJobSummaryRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetJobSummaryRequest) XNomadToken(xNomadToken string) ApiGetJobSummaryRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetJobSummaryRequest) PerPage(perPage int32) ApiGetJobSummaryRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetJobSummaryRequest) NextToken(nextToken string) ApiGetJobSummaryRequest { r.nextToken = &nextToken return r } -func (r ApiGetJobSummaryRequest) Execute() (JobSummary, *_nethttp.Response, error) { +func (r ApiGetJobSummaryRequest) Execute() (*JobSummary, *http.Response, error) { return r.ApiService.GetJobSummaryExecute(r) } /* - * GetJobSummary Method for GetJobSummary - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param jobName The job identifier. - * @return ApiGetJobSummaryRequest - */ -func (a *JobsApiService) GetJobSummary(ctx _context.Context, jobName string) ApiGetJobSummaryRequest { +GetJobSummary Method for GetJobSummary + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param jobName The job identifier. + @return ApiGetJobSummaryRequest +*/ +func (a *JobsApiService) GetJobSummary(ctx context.Context, jobName string) ApiGetJobSummaryRequest { return ApiGetJobSummaryRequest{ ApiService: a, ctx: ctx, @@ -1427,31 +1478,27 @@ func (a *JobsApiService) GetJobSummary(ctx _context.Context, jobName string) Api } } -/* - * Execute executes the request - * @return JobSummary - */ -func (a *JobsApiService) GetJobSummaryExecute(r ApiGetJobSummaryRequest) (JobSummary, *_nethttp.Response, error) { +// Execute executes the request +// @return JobSummary +func (a *JobsApiService) GetJobSummaryExecute(r ApiGetJobSummaryRequest) (*JobSummary, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue JobSummary + formFiles []formFile + localVarReturnValue *JobSummary ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "JobsApiService.GetJobSummary") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/job/{jobName}/summary" - localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", _neturl.PathEscape(parameterToString(r.jobName, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", url.PathEscape(parameterToString(r.jobName, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -1511,7 +1558,7 @@ func (a *JobsApiService) GetJobSummaryExecute(r ApiGetJobSummaryRequest) (JobSum } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -1521,15 +1568,15 @@ func (a *JobsApiService) GetJobSummaryExecute(r ApiGetJobSummaryRequest) (JobSum return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -1538,7 +1585,7 @@ func (a *JobsApiService) GetJobSummaryExecute(r ApiGetJobSummaryRequest) (JobSum err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -1549,7 +1596,7 @@ func (a *JobsApiService) GetJobSummaryExecute(r ApiGetJobSummaryRequest) (JobSum } type ApiGetJobVersionsRequest struct { - ctx _context.Context + ctx context.Context ApiService *JobsApiService jobName string region *string @@ -1564,58 +1611,69 @@ type ApiGetJobVersionsRequest struct { diffs *bool } +// Filters results based on the specified region. func (r ApiGetJobVersionsRequest) Region(region string) ApiGetJobVersionsRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetJobVersionsRequest) Namespace(namespace string) ApiGetJobVersionsRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetJobVersionsRequest) Index(index int32) ApiGetJobVersionsRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetJobVersionsRequest) Wait(wait string) ApiGetJobVersionsRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetJobVersionsRequest) Stale(stale string) ApiGetJobVersionsRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetJobVersionsRequest) Prefix(prefix string) ApiGetJobVersionsRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetJobVersionsRequest) XNomadToken(xNomadToken string) ApiGetJobVersionsRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetJobVersionsRequest) PerPage(perPage int32) ApiGetJobVersionsRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetJobVersionsRequest) NextToken(nextToken string) ApiGetJobVersionsRequest { r.nextToken = &nextToken return r } +// Boolean flag indicating whether to compute job diffs. func (r ApiGetJobVersionsRequest) Diffs(diffs bool) ApiGetJobVersionsRequest { r.diffs = &diffs return r } -func (r ApiGetJobVersionsRequest) Execute() (JobVersionsResponse, *_nethttp.Response, error) { +func (r ApiGetJobVersionsRequest) Execute() (*JobVersionsResponse, *http.Response, error) { return r.ApiService.GetJobVersionsExecute(r) } /* - * GetJobVersions Method for GetJobVersions - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param jobName The job identifier. - * @return ApiGetJobVersionsRequest - */ -func (a *JobsApiService) GetJobVersions(ctx _context.Context, jobName string) ApiGetJobVersionsRequest { +GetJobVersions Method for GetJobVersions + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param jobName The job identifier. + @return ApiGetJobVersionsRequest +*/ +func (a *JobsApiService) GetJobVersions(ctx context.Context, jobName string) ApiGetJobVersionsRequest { return ApiGetJobVersionsRequest{ ApiService: a, ctx: ctx, @@ -1623,31 +1681,27 @@ func (a *JobsApiService) GetJobVersions(ctx _context.Context, jobName string) Ap } } -/* - * Execute executes the request - * @return JobVersionsResponse - */ -func (a *JobsApiService) GetJobVersionsExecute(r ApiGetJobVersionsRequest) (JobVersionsResponse, *_nethttp.Response, error) { +// Execute executes the request +// @return JobVersionsResponse +func (a *JobsApiService) GetJobVersionsExecute(r ApiGetJobVersionsRequest) (*JobVersionsResponse, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue JobVersionsResponse + formFiles []formFile + localVarReturnValue *JobVersionsResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "JobsApiService.GetJobVersions") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/job/{jobName}/versions" - localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", _neturl.PathEscape(parameterToString(r.jobName, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", url.PathEscape(parameterToString(r.jobName, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -1710,7 +1764,7 @@ func (a *JobsApiService) GetJobVersionsExecute(r ApiGetJobVersionsRequest) (JobV } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -1720,15 +1774,15 @@ func (a *JobsApiService) GetJobVersionsExecute(r ApiGetJobVersionsRequest) (JobV return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -1737,7 +1791,7 @@ func (a *JobsApiService) GetJobVersionsExecute(r ApiGetJobVersionsRequest) (JobV err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -1748,7 +1802,7 @@ func (a *JobsApiService) GetJobVersionsExecute(r ApiGetJobVersionsRequest) (JobV } type ApiGetJobsRequest struct { - ctx _context.Context + ctx context.Context ApiService *JobsApiService region *string namespace *string @@ -1761,83 +1815,89 @@ type ApiGetJobsRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetJobsRequest) Region(region string) ApiGetJobsRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetJobsRequest) Namespace(namespace string) ApiGetJobsRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetJobsRequest) Index(index int32) ApiGetJobsRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetJobsRequest) Wait(wait string) ApiGetJobsRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetJobsRequest) Stale(stale string) ApiGetJobsRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetJobsRequest) Prefix(prefix string) ApiGetJobsRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetJobsRequest) XNomadToken(xNomadToken string) ApiGetJobsRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetJobsRequest) PerPage(perPage int32) ApiGetJobsRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetJobsRequest) NextToken(nextToken string) ApiGetJobsRequest { r.nextToken = &nextToken return r } -func (r ApiGetJobsRequest) Execute() ([]JobListStub, *_nethttp.Response, error) { +func (r ApiGetJobsRequest) Execute() ([]JobListStub, *http.Response, error) { return r.ApiService.GetJobsExecute(r) } /* - * GetJobs Method for GetJobs - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiGetJobsRequest - */ -func (a *JobsApiService) GetJobs(ctx _context.Context) ApiGetJobsRequest { +GetJobs Method for GetJobs + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiGetJobsRequest +*/ +func (a *JobsApiService) GetJobs(ctx context.Context) ApiGetJobsRequest { return ApiGetJobsRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return []JobListStub - */ -func (a *JobsApiService) GetJobsExecute(r ApiGetJobsRequest) ([]JobListStub, *_nethttp.Response, error) { +// Execute executes the request +// @return []JobListStub +func (a *JobsApiService) GetJobsExecute(r ApiGetJobsRequest) ([]JobListStub, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile localVarReturnValue []JobListStub ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "JobsApiService.GetJobs") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/jobs" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -1897,7 +1957,7 @@ func (a *JobsApiService) GetJobsExecute(r ApiGetJobsRequest) ([]JobListStub, *_n } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -1907,15 +1967,15 @@ func (a *JobsApiService) GetJobsExecute(r ApiGetJobsRequest) ([]JobListStub, *_n return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -1924,7 +1984,7 @@ func (a *JobsApiService) GetJobsExecute(r ApiGetJobsRequest) ([]JobListStub, *_n err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -1935,7 +1995,7 @@ func (a *JobsApiService) GetJobsExecute(r ApiGetJobsRequest) ([]JobListStub, *_n } type ApiPostJobRequest struct { - ctx _context.Context + ctx context.Context ApiService *JobsApiService jobName string jobRegisterRequest *JobRegisterRequest @@ -1949,34 +2009,39 @@ func (r ApiPostJobRequest) JobRegisterRequest(jobRegisterRequest JobRegisterRequ r.jobRegisterRequest = &jobRegisterRequest return r } +// Filters results based on the specified region. func (r ApiPostJobRequest) Region(region string) ApiPostJobRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiPostJobRequest) Namespace(namespace string) ApiPostJobRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiPostJobRequest) XNomadToken(xNomadToken string) ApiPostJobRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiPostJobRequest) IdempotencyToken(idempotencyToken string) ApiPostJobRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiPostJobRequest) Execute() (JobRegisterResponse, *_nethttp.Response, error) { +func (r ApiPostJobRequest) Execute() (*JobRegisterResponse, *http.Response, error) { return r.ApiService.PostJobExecute(r) } /* - * PostJob Method for PostJob - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param jobName The job identifier. - * @return ApiPostJobRequest - */ -func (a *JobsApiService) PostJob(ctx _context.Context, jobName string) ApiPostJobRequest { +PostJob Method for PostJob + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param jobName The job identifier. + @return ApiPostJobRequest +*/ +func (a *JobsApiService) PostJob(ctx context.Context, jobName string) ApiPostJobRequest { return ApiPostJobRequest{ ApiService: a, ctx: ctx, @@ -1984,31 +2049,27 @@ func (a *JobsApiService) PostJob(ctx _context.Context, jobName string) ApiPostJo } } -/* - * Execute executes the request - * @return JobRegisterResponse - */ -func (a *JobsApiService) PostJobExecute(r ApiPostJobRequest) (JobRegisterResponse, *_nethttp.Response, error) { +// Execute executes the request +// @return JobRegisterResponse +func (a *JobsApiService) PostJobExecute(r ApiPostJobRequest) (*JobRegisterResponse, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue JobRegisterResponse + formFiles []formFile + localVarReturnValue *JobRegisterResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "JobsApiService.PostJob") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/job/{jobName}" - localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", _neturl.PathEscape(parameterToString(r.jobName, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", url.PathEscape(parameterToString(r.jobName, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.jobRegisterRequest == nil { return localVarReturnValue, nil, reportError("jobRegisterRequest is required and must be specified") } @@ -2058,7 +2119,7 @@ func (a *JobsApiService) PostJobExecute(r ApiPostJobRequest) (JobRegisterRespons } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -2068,15 +2129,15 @@ func (a *JobsApiService) PostJobExecute(r ApiPostJobRequest) (JobRegisterRespons return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -2085,7 +2146,7 @@ func (a *JobsApiService) PostJobExecute(r ApiPostJobRequest) (JobRegisterRespons err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -2096,7 +2157,7 @@ func (a *JobsApiService) PostJobExecute(r ApiPostJobRequest) (JobRegisterRespons } type ApiPostJobDispatchRequest struct { - ctx _context.Context + ctx context.Context ApiService *JobsApiService jobName string jobDispatchRequest *JobDispatchRequest @@ -2110,34 +2171,39 @@ func (r ApiPostJobDispatchRequest) JobDispatchRequest(jobDispatchRequest JobDisp r.jobDispatchRequest = &jobDispatchRequest return r } +// Filters results based on the specified region. func (r ApiPostJobDispatchRequest) Region(region string) ApiPostJobDispatchRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiPostJobDispatchRequest) Namespace(namespace string) ApiPostJobDispatchRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiPostJobDispatchRequest) XNomadToken(xNomadToken string) ApiPostJobDispatchRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiPostJobDispatchRequest) IdempotencyToken(idempotencyToken string) ApiPostJobDispatchRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiPostJobDispatchRequest) Execute() (JobDispatchResponse, *_nethttp.Response, error) { +func (r ApiPostJobDispatchRequest) Execute() (*JobDispatchResponse, *http.Response, error) { return r.ApiService.PostJobDispatchExecute(r) } /* - * PostJobDispatch Method for PostJobDispatch - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param jobName The job identifier. - * @return ApiPostJobDispatchRequest - */ -func (a *JobsApiService) PostJobDispatch(ctx _context.Context, jobName string) ApiPostJobDispatchRequest { +PostJobDispatch Method for PostJobDispatch + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param jobName The job identifier. + @return ApiPostJobDispatchRequest +*/ +func (a *JobsApiService) PostJobDispatch(ctx context.Context, jobName string) ApiPostJobDispatchRequest { return ApiPostJobDispatchRequest{ ApiService: a, ctx: ctx, @@ -2145,31 +2211,27 @@ func (a *JobsApiService) PostJobDispatch(ctx _context.Context, jobName string) A } } -/* - * Execute executes the request - * @return JobDispatchResponse - */ -func (a *JobsApiService) PostJobDispatchExecute(r ApiPostJobDispatchRequest) (JobDispatchResponse, *_nethttp.Response, error) { +// Execute executes the request +// @return JobDispatchResponse +func (a *JobsApiService) PostJobDispatchExecute(r ApiPostJobDispatchRequest) (*JobDispatchResponse, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue JobDispatchResponse + formFiles []formFile + localVarReturnValue *JobDispatchResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "JobsApiService.PostJobDispatch") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/job/{jobName}/dispatch" - localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", _neturl.PathEscape(parameterToString(r.jobName, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", url.PathEscape(parameterToString(r.jobName, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.jobDispatchRequest == nil { return localVarReturnValue, nil, reportError("jobDispatchRequest is required and must be specified") } @@ -2219,7 +2281,7 @@ func (a *JobsApiService) PostJobDispatchExecute(r ApiPostJobDispatchRequest) (Jo } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -2229,15 +2291,15 @@ func (a *JobsApiService) PostJobDispatchExecute(r ApiPostJobDispatchRequest) (Jo return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -2246,7 +2308,7 @@ func (a *JobsApiService) PostJobDispatchExecute(r ApiPostJobDispatchRequest) (Jo err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -2257,7 +2319,7 @@ func (a *JobsApiService) PostJobDispatchExecute(r ApiPostJobDispatchRequest) (Jo } type ApiPostJobEvaluateRequest struct { - ctx _context.Context + ctx context.Context ApiService *JobsApiService jobName string jobEvaluateRequest *JobEvaluateRequest @@ -2271,34 +2333,39 @@ func (r ApiPostJobEvaluateRequest) JobEvaluateRequest(jobEvaluateRequest JobEval r.jobEvaluateRequest = &jobEvaluateRequest return r } +// Filters results based on the specified region. func (r ApiPostJobEvaluateRequest) Region(region string) ApiPostJobEvaluateRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiPostJobEvaluateRequest) Namespace(namespace string) ApiPostJobEvaluateRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiPostJobEvaluateRequest) XNomadToken(xNomadToken string) ApiPostJobEvaluateRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiPostJobEvaluateRequest) IdempotencyToken(idempotencyToken string) ApiPostJobEvaluateRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiPostJobEvaluateRequest) Execute() (JobRegisterResponse, *_nethttp.Response, error) { +func (r ApiPostJobEvaluateRequest) Execute() (*JobRegisterResponse, *http.Response, error) { return r.ApiService.PostJobEvaluateExecute(r) } /* - * PostJobEvaluate Method for PostJobEvaluate - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param jobName The job identifier. - * @return ApiPostJobEvaluateRequest - */ -func (a *JobsApiService) PostJobEvaluate(ctx _context.Context, jobName string) ApiPostJobEvaluateRequest { +PostJobEvaluate Method for PostJobEvaluate + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param jobName The job identifier. + @return ApiPostJobEvaluateRequest +*/ +func (a *JobsApiService) PostJobEvaluate(ctx context.Context, jobName string) ApiPostJobEvaluateRequest { return ApiPostJobEvaluateRequest{ ApiService: a, ctx: ctx, @@ -2306,31 +2373,27 @@ func (a *JobsApiService) PostJobEvaluate(ctx _context.Context, jobName string) A } } -/* - * Execute executes the request - * @return JobRegisterResponse - */ -func (a *JobsApiService) PostJobEvaluateExecute(r ApiPostJobEvaluateRequest) (JobRegisterResponse, *_nethttp.Response, error) { +// Execute executes the request +// @return JobRegisterResponse +func (a *JobsApiService) PostJobEvaluateExecute(r ApiPostJobEvaluateRequest) (*JobRegisterResponse, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue JobRegisterResponse + formFiles []formFile + localVarReturnValue *JobRegisterResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "JobsApiService.PostJobEvaluate") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/job/{jobName}/evaluate" - localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", _neturl.PathEscape(parameterToString(r.jobName, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", url.PathEscape(parameterToString(r.jobName, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.jobEvaluateRequest == nil { return localVarReturnValue, nil, reportError("jobEvaluateRequest is required and must be specified") } @@ -2380,7 +2443,7 @@ func (a *JobsApiService) PostJobEvaluateExecute(r ApiPostJobEvaluateRequest) (Jo } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -2390,15 +2453,15 @@ func (a *JobsApiService) PostJobEvaluateExecute(r ApiPostJobEvaluateRequest) (Jo return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -2407,7 +2470,7 @@ func (a *JobsApiService) PostJobEvaluateExecute(r ApiPostJobEvaluateRequest) (Jo err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -2418,7 +2481,7 @@ func (a *JobsApiService) PostJobEvaluateExecute(r ApiPostJobEvaluateRequest) (Jo } type ApiPostJobParseRequest struct { - ctx _context.Context + ctx context.Context ApiService *JobsApiService jobsParseRequest *JobsParseRequest } @@ -2428,46 +2491,43 @@ func (r ApiPostJobParseRequest) JobsParseRequest(jobsParseRequest JobsParseReque return r } -func (r ApiPostJobParseRequest) Execute() (Job, *_nethttp.Response, error) { +func (r ApiPostJobParseRequest) Execute() (*Job, *http.Response, error) { return r.ApiService.PostJobParseExecute(r) } /* - * PostJobParse Method for PostJobParse - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiPostJobParseRequest - */ -func (a *JobsApiService) PostJobParse(ctx _context.Context) ApiPostJobParseRequest { +PostJobParse Method for PostJobParse + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiPostJobParseRequest +*/ +func (a *JobsApiService) PostJobParse(ctx context.Context) ApiPostJobParseRequest { return ApiPostJobParseRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return Job - */ -func (a *JobsApiService) PostJobParseExecute(r ApiPostJobParseRequest) (Job, *_nethttp.Response, error) { +// Execute executes the request +// @return Job +func (a *JobsApiService) PostJobParseExecute(r ApiPostJobParseRequest) (*Job, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue Job + formFiles []formFile + localVarReturnValue *Job ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "JobsApiService.PostJobParse") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/jobs/parse" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.jobsParseRequest == nil { return localVarReturnValue, nil, reportError("jobsParseRequest is required and must be specified") } @@ -2505,7 +2565,7 @@ func (a *JobsApiService) PostJobParseExecute(r ApiPostJobParseRequest) (Job, *_n } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -2515,15 +2575,15 @@ func (a *JobsApiService) PostJobParseExecute(r ApiPostJobParseRequest) (Job, *_n return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -2532,7 +2592,7 @@ func (a *JobsApiService) PostJobParseExecute(r ApiPostJobParseRequest) (Job, *_n err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -2543,7 +2603,7 @@ func (a *JobsApiService) PostJobParseExecute(r ApiPostJobParseRequest) (Job, *_n } type ApiPostJobPeriodicForceRequest struct { - ctx _context.Context + ctx context.Context ApiService *JobsApiService jobName string region *string @@ -2552,34 +2612,39 @@ type ApiPostJobPeriodicForceRequest struct { idempotencyToken *string } +// Filters results based on the specified region. func (r ApiPostJobPeriodicForceRequest) Region(region string) ApiPostJobPeriodicForceRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiPostJobPeriodicForceRequest) Namespace(namespace string) ApiPostJobPeriodicForceRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiPostJobPeriodicForceRequest) XNomadToken(xNomadToken string) ApiPostJobPeriodicForceRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiPostJobPeriodicForceRequest) IdempotencyToken(idempotencyToken string) ApiPostJobPeriodicForceRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiPostJobPeriodicForceRequest) Execute() (PeriodicForceResponse, *_nethttp.Response, error) { +func (r ApiPostJobPeriodicForceRequest) Execute() (*PeriodicForceResponse, *http.Response, error) { return r.ApiService.PostJobPeriodicForceExecute(r) } /* - * PostJobPeriodicForce Method for PostJobPeriodicForce - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param jobName The job identifier. - * @return ApiPostJobPeriodicForceRequest - */ -func (a *JobsApiService) PostJobPeriodicForce(ctx _context.Context, jobName string) ApiPostJobPeriodicForceRequest { +PostJobPeriodicForce Method for PostJobPeriodicForce + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param jobName The job identifier. + @return ApiPostJobPeriodicForceRequest +*/ +func (a *JobsApiService) PostJobPeriodicForce(ctx context.Context, jobName string) ApiPostJobPeriodicForceRequest { return ApiPostJobPeriodicForceRequest{ ApiService: a, ctx: ctx, @@ -2587,31 +2652,27 @@ func (a *JobsApiService) PostJobPeriodicForce(ctx _context.Context, jobName stri } } -/* - * Execute executes the request - * @return PeriodicForceResponse - */ -func (a *JobsApiService) PostJobPeriodicForceExecute(r ApiPostJobPeriodicForceRequest) (PeriodicForceResponse, *_nethttp.Response, error) { +// Execute executes the request +// @return PeriodicForceResponse +func (a *JobsApiService) PostJobPeriodicForceExecute(r ApiPostJobPeriodicForceRequest) (*PeriodicForceResponse, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue PeriodicForceResponse + formFiles []formFile + localVarReturnValue *PeriodicForceResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "JobsApiService.PostJobPeriodicForce") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/job/{jobName}/periodic/force" - localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", _neturl.PathEscape(parameterToString(r.jobName, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", url.PathEscape(parameterToString(r.jobName, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -2656,7 +2717,7 @@ func (a *JobsApiService) PostJobPeriodicForceExecute(r ApiPostJobPeriodicForceRe } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -2666,15 +2727,15 @@ func (a *JobsApiService) PostJobPeriodicForceExecute(r ApiPostJobPeriodicForceRe return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -2683,7 +2744,7 @@ func (a *JobsApiService) PostJobPeriodicForceExecute(r ApiPostJobPeriodicForceRe err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -2694,7 +2755,7 @@ func (a *JobsApiService) PostJobPeriodicForceExecute(r ApiPostJobPeriodicForceRe } type ApiPostJobPlanRequest struct { - ctx _context.Context + ctx context.Context ApiService *JobsApiService jobName string jobPlanRequest *JobPlanRequest @@ -2708,34 +2769,39 @@ func (r ApiPostJobPlanRequest) JobPlanRequest(jobPlanRequest JobPlanRequest) Api r.jobPlanRequest = &jobPlanRequest return r } +// Filters results based on the specified region. func (r ApiPostJobPlanRequest) Region(region string) ApiPostJobPlanRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiPostJobPlanRequest) Namespace(namespace string) ApiPostJobPlanRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiPostJobPlanRequest) XNomadToken(xNomadToken string) ApiPostJobPlanRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiPostJobPlanRequest) IdempotencyToken(idempotencyToken string) ApiPostJobPlanRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiPostJobPlanRequest) Execute() (JobPlanResponse, *_nethttp.Response, error) { +func (r ApiPostJobPlanRequest) Execute() (*JobPlanResponse, *http.Response, error) { return r.ApiService.PostJobPlanExecute(r) } /* - * PostJobPlan Method for PostJobPlan - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param jobName The job identifier. - * @return ApiPostJobPlanRequest - */ -func (a *JobsApiService) PostJobPlan(ctx _context.Context, jobName string) ApiPostJobPlanRequest { +PostJobPlan Method for PostJobPlan + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param jobName The job identifier. + @return ApiPostJobPlanRequest +*/ +func (a *JobsApiService) PostJobPlan(ctx context.Context, jobName string) ApiPostJobPlanRequest { return ApiPostJobPlanRequest{ ApiService: a, ctx: ctx, @@ -2743,31 +2809,27 @@ func (a *JobsApiService) PostJobPlan(ctx _context.Context, jobName string) ApiPo } } -/* - * Execute executes the request - * @return JobPlanResponse - */ -func (a *JobsApiService) PostJobPlanExecute(r ApiPostJobPlanRequest) (JobPlanResponse, *_nethttp.Response, error) { +// Execute executes the request +// @return JobPlanResponse +func (a *JobsApiService) PostJobPlanExecute(r ApiPostJobPlanRequest) (*JobPlanResponse, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue JobPlanResponse + formFiles []formFile + localVarReturnValue *JobPlanResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "JobsApiService.PostJobPlan") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/job/{jobName}/plan" - localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", _neturl.PathEscape(parameterToString(r.jobName, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", url.PathEscape(parameterToString(r.jobName, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.jobPlanRequest == nil { return localVarReturnValue, nil, reportError("jobPlanRequest is required and must be specified") } @@ -2817,7 +2879,7 @@ func (a *JobsApiService) PostJobPlanExecute(r ApiPostJobPlanRequest) (JobPlanRes } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -2827,15 +2889,15 @@ func (a *JobsApiService) PostJobPlanExecute(r ApiPostJobPlanRequest) (JobPlanRes return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -2844,7 +2906,7 @@ func (a *JobsApiService) PostJobPlanExecute(r ApiPostJobPlanRequest) (JobPlanRes err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -2855,7 +2917,7 @@ func (a *JobsApiService) PostJobPlanExecute(r ApiPostJobPlanRequest) (JobPlanRes } type ApiPostJobRevertRequest struct { - ctx _context.Context + ctx context.Context ApiService *JobsApiService jobName string jobRevertRequest *JobRevertRequest @@ -2869,34 +2931,39 @@ func (r ApiPostJobRevertRequest) JobRevertRequest(jobRevertRequest JobRevertRequ r.jobRevertRequest = &jobRevertRequest return r } +// Filters results based on the specified region. func (r ApiPostJobRevertRequest) Region(region string) ApiPostJobRevertRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiPostJobRevertRequest) Namespace(namespace string) ApiPostJobRevertRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiPostJobRevertRequest) XNomadToken(xNomadToken string) ApiPostJobRevertRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiPostJobRevertRequest) IdempotencyToken(idempotencyToken string) ApiPostJobRevertRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiPostJobRevertRequest) Execute() (JobRegisterResponse, *_nethttp.Response, error) { +func (r ApiPostJobRevertRequest) Execute() (*JobRegisterResponse, *http.Response, error) { return r.ApiService.PostJobRevertExecute(r) } /* - * PostJobRevert Method for PostJobRevert - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param jobName The job identifier. - * @return ApiPostJobRevertRequest - */ -func (a *JobsApiService) PostJobRevert(ctx _context.Context, jobName string) ApiPostJobRevertRequest { +PostJobRevert Method for PostJobRevert + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param jobName The job identifier. + @return ApiPostJobRevertRequest +*/ +func (a *JobsApiService) PostJobRevert(ctx context.Context, jobName string) ApiPostJobRevertRequest { return ApiPostJobRevertRequest{ ApiService: a, ctx: ctx, @@ -2904,31 +2971,27 @@ func (a *JobsApiService) PostJobRevert(ctx _context.Context, jobName string) Api } } -/* - * Execute executes the request - * @return JobRegisterResponse - */ -func (a *JobsApiService) PostJobRevertExecute(r ApiPostJobRevertRequest) (JobRegisterResponse, *_nethttp.Response, error) { +// Execute executes the request +// @return JobRegisterResponse +func (a *JobsApiService) PostJobRevertExecute(r ApiPostJobRevertRequest) (*JobRegisterResponse, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue JobRegisterResponse + formFiles []formFile + localVarReturnValue *JobRegisterResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "JobsApiService.PostJobRevert") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/job/{jobName}/revert" - localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", _neturl.PathEscape(parameterToString(r.jobName, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", url.PathEscape(parameterToString(r.jobName, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.jobRevertRequest == nil { return localVarReturnValue, nil, reportError("jobRevertRequest is required and must be specified") } @@ -2978,7 +3041,7 @@ func (a *JobsApiService) PostJobRevertExecute(r ApiPostJobRevertRequest) (JobReg } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -2988,15 +3051,15 @@ func (a *JobsApiService) PostJobRevertExecute(r ApiPostJobRevertRequest) (JobReg return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -3005,7 +3068,7 @@ func (a *JobsApiService) PostJobRevertExecute(r ApiPostJobRevertRequest) (JobReg err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -3016,7 +3079,7 @@ func (a *JobsApiService) PostJobRevertExecute(r ApiPostJobRevertRequest) (JobReg } type ApiPostJobScalingRequestRequest struct { - ctx _context.Context + ctx context.Context ApiService *JobsApiService jobName string scalingRequest *ScalingRequest @@ -3030,34 +3093,39 @@ func (r ApiPostJobScalingRequestRequest) ScalingRequest(scalingRequest ScalingRe r.scalingRequest = &scalingRequest return r } +// Filters results based on the specified region. func (r ApiPostJobScalingRequestRequest) Region(region string) ApiPostJobScalingRequestRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiPostJobScalingRequestRequest) Namespace(namespace string) ApiPostJobScalingRequestRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiPostJobScalingRequestRequest) XNomadToken(xNomadToken string) ApiPostJobScalingRequestRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiPostJobScalingRequestRequest) IdempotencyToken(idempotencyToken string) ApiPostJobScalingRequestRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiPostJobScalingRequestRequest) Execute() (JobRegisterResponse, *_nethttp.Response, error) { +func (r ApiPostJobScalingRequestRequest) Execute() (*JobRegisterResponse, *http.Response, error) { return r.ApiService.PostJobScalingRequestExecute(r) } /* - * PostJobScalingRequest Method for PostJobScalingRequest - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param jobName The job identifier. - * @return ApiPostJobScalingRequestRequest - */ -func (a *JobsApiService) PostJobScalingRequest(ctx _context.Context, jobName string) ApiPostJobScalingRequestRequest { +PostJobScalingRequest Method for PostJobScalingRequest + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param jobName The job identifier. + @return ApiPostJobScalingRequestRequest +*/ +func (a *JobsApiService) PostJobScalingRequest(ctx context.Context, jobName string) ApiPostJobScalingRequestRequest { return ApiPostJobScalingRequestRequest{ ApiService: a, ctx: ctx, @@ -3065,31 +3133,27 @@ func (a *JobsApiService) PostJobScalingRequest(ctx _context.Context, jobName str } } -/* - * Execute executes the request - * @return JobRegisterResponse - */ -func (a *JobsApiService) PostJobScalingRequestExecute(r ApiPostJobScalingRequestRequest) (JobRegisterResponse, *_nethttp.Response, error) { +// Execute executes the request +// @return JobRegisterResponse +func (a *JobsApiService) PostJobScalingRequestExecute(r ApiPostJobScalingRequestRequest) (*JobRegisterResponse, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue JobRegisterResponse + formFiles []formFile + localVarReturnValue *JobRegisterResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "JobsApiService.PostJobScalingRequest") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/job/{jobName}/scale" - localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", _neturl.PathEscape(parameterToString(r.jobName, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", url.PathEscape(parameterToString(r.jobName, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.scalingRequest == nil { return localVarReturnValue, nil, reportError("scalingRequest is required and must be specified") } @@ -3139,7 +3203,7 @@ func (a *JobsApiService) PostJobScalingRequestExecute(r ApiPostJobScalingRequest } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -3149,15 +3213,15 @@ func (a *JobsApiService) PostJobScalingRequestExecute(r ApiPostJobScalingRequest return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -3166,7 +3230,7 @@ func (a *JobsApiService) PostJobScalingRequestExecute(r ApiPostJobScalingRequest err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -3177,7 +3241,7 @@ func (a *JobsApiService) PostJobScalingRequestExecute(r ApiPostJobScalingRequest } type ApiPostJobStabilityRequest struct { - ctx _context.Context + ctx context.Context ApiService *JobsApiService jobName string jobStabilityRequest *JobStabilityRequest @@ -3191,34 +3255,39 @@ func (r ApiPostJobStabilityRequest) JobStabilityRequest(jobStabilityRequest JobS r.jobStabilityRequest = &jobStabilityRequest return r } +// Filters results based on the specified region. func (r ApiPostJobStabilityRequest) Region(region string) ApiPostJobStabilityRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiPostJobStabilityRequest) Namespace(namespace string) ApiPostJobStabilityRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiPostJobStabilityRequest) XNomadToken(xNomadToken string) ApiPostJobStabilityRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiPostJobStabilityRequest) IdempotencyToken(idempotencyToken string) ApiPostJobStabilityRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiPostJobStabilityRequest) Execute() (JobStabilityResponse, *_nethttp.Response, error) { +func (r ApiPostJobStabilityRequest) Execute() (*JobStabilityResponse, *http.Response, error) { return r.ApiService.PostJobStabilityExecute(r) } /* - * PostJobStability Method for PostJobStability - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param jobName The job identifier. - * @return ApiPostJobStabilityRequest - */ -func (a *JobsApiService) PostJobStability(ctx _context.Context, jobName string) ApiPostJobStabilityRequest { +PostJobStability Method for PostJobStability + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param jobName The job identifier. + @return ApiPostJobStabilityRequest +*/ +func (a *JobsApiService) PostJobStability(ctx context.Context, jobName string) ApiPostJobStabilityRequest { return ApiPostJobStabilityRequest{ ApiService: a, ctx: ctx, @@ -3226,31 +3295,27 @@ func (a *JobsApiService) PostJobStability(ctx _context.Context, jobName string) } } -/* - * Execute executes the request - * @return JobStabilityResponse - */ -func (a *JobsApiService) PostJobStabilityExecute(r ApiPostJobStabilityRequest) (JobStabilityResponse, *_nethttp.Response, error) { +// Execute executes the request +// @return JobStabilityResponse +func (a *JobsApiService) PostJobStabilityExecute(r ApiPostJobStabilityRequest) (*JobStabilityResponse, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue JobStabilityResponse + formFiles []formFile + localVarReturnValue *JobStabilityResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "JobsApiService.PostJobStability") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/job/{jobName}/stable" - localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", _neturl.PathEscape(parameterToString(r.jobName, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"jobName"+"}", url.PathEscape(parameterToString(r.jobName, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.jobStabilityRequest == nil { return localVarReturnValue, nil, reportError("jobStabilityRequest is required and must be specified") } @@ -3300,7 +3365,7 @@ func (a *JobsApiService) PostJobStabilityExecute(r ApiPostJobStabilityRequest) ( } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -3310,15 +3375,15 @@ func (a *JobsApiService) PostJobStabilityExecute(r ApiPostJobStabilityRequest) ( return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -3327,7 +3392,7 @@ func (a *JobsApiService) PostJobStabilityExecute(r ApiPostJobStabilityRequest) ( err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -3338,7 +3403,7 @@ func (a *JobsApiService) PostJobStabilityExecute(r ApiPostJobStabilityRequest) ( } type ApiPostJobValidateRequestRequest struct { - ctx _context.Context + ctx context.Context ApiService *JobsApiService jobValidateRequest *JobValidateRequest region *string @@ -3351,63 +3416,64 @@ func (r ApiPostJobValidateRequestRequest) JobValidateRequest(jobValidateRequest r.jobValidateRequest = &jobValidateRequest return r } +// Filters results based on the specified region. func (r ApiPostJobValidateRequestRequest) Region(region string) ApiPostJobValidateRequestRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiPostJobValidateRequestRequest) Namespace(namespace string) ApiPostJobValidateRequestRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiPostJobValidateRequestRequest) XNomadToken(xNomadToken string) ApiPostJobValidateRequestRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiPostJobValidateRequestRequest) IdempotencyToken(idempotencyToken string) ApiPostJobValidateRequestRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiPostJobValidateRequestRequest) Execute() (JobValidateResponse, *_nethttp.Response, error) { +func (r ApiPostJobValidateRequestRequest) Execute() (*JobValidateResponse, *http.Response, error) { return r.ApiService.PostJobValidateRequestExecute(r) } /* - * PostJobValidateRequest Method for PostJobValidateRequest - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiPostJobValidateRequestRequest - */ -func (a *JobsApiService) PostJobValidateRequest(ctx _context.Context) ApiPostJobValidateRequestRequest { +PostJobValidateRequest Method for PostJobValidateRequest + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiPostJobValidateRequestRequest +*/ +func (a *JobsApiService) PostJobValidateRequest(ctx context.Context) ApiPostJobValidateRequestRequest { return ApiPostJobValidateRequestRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return JobValidateResponse - */ -func (a *JobsApiService) PostJobValidateRequestExecute(r ApiPostJobValidateRequestRequest) (JobValidateResponse, *_nethttp.Response, error) { +// Execute executes the request +// @return JobValidateResponse +func (a *JobsApiService) PostJobValidateRequestExecute(r ApiPostJobValidateRequestRequest) (*JobValidateResponse, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue JobValidateResponse + formFiles []formFile + localVarReturnValue *JobValidateResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "JobsApiService.PostJobValidateRequest") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/validate/job" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.jobValidateRequest == nil { return localVarReturnValue, nil, reportError("jobValidateRequest is required and must be specified") } @@ -3457,7 +3523,7 @@ func (a *JobsApiService) PostJobValidateRequestExecute(r ApiPostJobValidateReque } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -3467,15 +3533,15 @@ func (a *JobsApiService) PostJobValidateRequestExecute(r ApiPostJobValidateReque return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -3484,7 +3550,7 @@ func (a *JobsApiService) PostJobValidateRequestExecute(r ApiPostJobValidateReque err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -3495,7 +3561,7 @@ func (a *JobsApiService) PostJobValidateRequestExecute(r ApiPostJobValidateReque } type ApiRegisterJobRequest struct { - ctx _context.Context + ctx context.Context ApiService *JobsApiService jobRegisterRequest *JobRegisterRequest region *string @@ -3508,63 +3574,64 @@ func (r ApiRegisterJobRequest) JobRegisterRequest(jobRegisterRequest JobRegister r.jobRegisterRequest = &jobRegisterRequest return r } +// Filters results based on the specified region. func (r ApiRegisterJobRequest) Region(region string) ApiRegisterJobRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiRegisterJobRequest) Namespace(namespace string) ApiRegisterJobRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiRegisterJobRequest) XNomadToken(xNomadToken string) ApiRegisterJobRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiRegisterJobRequest) IdempotencyToken(idempotencyToken string) ApiRegisterJobRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiRegisterJobRequest) Execute() (JobRegisterResponse, *_nethttp.Response, error) { +func (r ApiRegisterJobRequest) Execute() (*JobRegisterResponse, *http.Response, error) { return r.ApiService.RegisterJobExecute(r) } /* - * RegisterJob Method for RegisterJob - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiRegisterJobRequest - */ -func (a *JobsApiService) RegisterJob(ctx _context.Context) ApiRegisterJobRequest { +RegisterJob Method for RegisterJob + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiRegisterJobRequest +*/ +func (a *JobsApiService) RegisterJob(ctx context.Context) ApiRegisterJobRequest { return ApiRegisterJobRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return JobRegisterResponse - */ -func (a *JobsApiService) RegisterJobExecute(r ApiRegisterJobRequest) (JobRegisterResponse, *_nethttp.Response, error) { +// Execute executes the request +// @return JobRegisterResponse +func (a *JobsApiService) RegisterJobExecute(r ApiRegisterJobRequest) (*JobRegisterResponse, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue JobRegisterResponse + formFiles []formFile + localVarReturnValue *JobRegisterResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "JobsApiService.RegisterJob") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/jobs" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.jobRegisterRequest == nil { return localVarReturnValue, nil, reportError("jobRegisterRequest is required and must be specified") } @@ -3614,7 +3681,7 @@ func (a *JobsApiService) RegisterJobExecute(r ApiRegisterJobRequest) (JobRegiste } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -3624,15 +3691,15 @@ func (a *JobsApiService) RegisterJobExecute(r ApiRegisterJobRequest) (JobRegiste return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -3641,7 +3708,7 @@ func (a *JobsApiService) RegisterJobExecute(r ApiRegisterJobRequest) (JobRegiste err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } diff --git a/clients/go/v1/api_metrics.go b/clients/go/v1/api_metrics.go index 3419b2e5..676e9ae9 100644 --- a/clients/go/v1/api_metrics.go +++ b/clients/go/v1/api_metrics.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -13,71 +13,69 @@ package client import ( "bytes" - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" + "context" + "io/ioutil" + "net/http" + "net/url" ) // Linger please var ( - _ _context.Context + _ context.Context ) // MetricsApiService MetricsApi service type MetricsApiService service type ApiGetMetricsSummaryRequest struct { - ctx _context.Context + ctx context.Context ApiService *MetricsApiService format *string } +// The format the user requested for the metrics summary (e.g. prometheus) func (r ApiGetMetricsSummaryRequest) Format(format string) ApiGetMetricsSummaryRequest { r.format = &format return r } -func (r ApiGetMetricsSummaryRequest) Execute() (MetricsSummary, *_nethttp.Response, error) { +func (r ApiGetMetricsSummaryRequest) Execute() (*MetricsSummary, *http.Response, error) { return r.ApiService.GetMetricsSummaryExecute(r) } /* - * GetMetricsSummary Method for GetMetricsSummary - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiGetMetricsSummaryRequest - */ -func (a *MetricsApiService) GetMetricsSummary(ctx _context.Context) ApiGetMetricsSummaryRequest { +GetMetricsSummary Method for GetMetricsSummary + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiGetMetricsSummaryRequest +*/ +func (a *MetricsApiService) GetMetricsSummary(ctx context.Context) ApiGetMetricsSummaryRequest { return ApiGetMetricsSummaryRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return MetricsSummary - */ -func (a *MetricsApiService) GetMetricsSummaryExecute(r ApiGetMetricsSummaryRequest) (MetricsSummary, *_nethttp.Response, error) { +// Execute executes the request +// @return MetricsSummary +func (a *MetricsApiService) GetMetricsSummaryExecute(r ApiGetMetricsSummaryRequest) (*MetricsSummary, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue MetricsSummary + formFiles []formFile + localVarReturnValue *MetricsSummary ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "MetricsApiService.GetMetricsSummary") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/metrics" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.format != nil { localVarQueryParams.Add("format", parameterToString(*r.format, "")) @@ -113,7 +111,7 @@ func (a *MetricsApiService) GetMetricsSummaryExecute(r ApiGetMetricsSummaryReque } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -123,15 +121,15 @@ func (a *MetricsApiService) GetMetricsSummaryExecute(r ApiGetMetricsSummaryReque return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -140,7 +138,7 @@ func (a *MetricsApiService) GetMetricsSummaryExecute(r ApiGetMetricsSummaryReque err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } diff --git a/clients/go/v1/api_namespaces.go b/clients/go/v1/api_namespaces.go index 82d27829..655d9fdb 100644 --- a/clients/go/v1/api_namespaces.go +++ b/clients/go/v1/api_namespaces.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -13,23 +13,23 @@ package client import ( "bytes" - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" + "context" + "io/ioutil" + "net/http" + "net/url" "strings" ) // Linger please var ( - _ _context.Context + _ context.Context ) // NamespacesApiService NamespacesApi service type NamespacesApiService service type ApiCreateNamespaceRequest struct { - ctx _context.Context + ctx context.Context ApiService *NamespacesApiService region *string namespace *string @@ -37,61 +37,62 @@ type ApiCreateNamespaceRequest struct { idempotencyToken *string } +// Filters results based on the specified region. func (r ApiCreateNamespaceRequest) Region(region string) ApiCreateNamespaceRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiCreateNamespaceRequest) Namespace(namespace string) ApiCreateNamespaceRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiCreateNamespaceRequest) XNomadToken(xNomadToken string) ApiCreateNamespaceRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiCreateNamespaceRequest) IdempotencyToken(idempotencyToken string) ApiCreateNamespaceRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiCreateNamespaceRequest) Execute() (*_nethttp.Response, error) { +func (r ApiCreateNamespaceRequest) Execute() (*http.Response, error) { return r.ApiService.CreateNamespaceExecute(r) } /* - * CreateNamespace Method for CreateNamespace - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiCreateNamespaceRequest - */ -func (a *NamespacesApiService) CreateNamespace(ctx _context.Context) ApiCreateNamespaceRequest { +CreateNamespace Method for CreateNamespace + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiCreateNamespaceRequest +*/ +func (a *NamespacesApiService) CreateNamespace(ctx context.Context) ApiCreateNamespaceRequest { return ApiCreateNamespaceRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - */ -func (a *NamespacesApiService) CreateNamespaceExecute(r ApiCreateNamespaceRequest) (*_nethttp.Response, error) { +// Execute executes the request +func (a *NamespacesApiService) CreateNamespaceExecute(r ApiCreateNamespaceRequest) (*http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NamespacesApiService.CreateNamespace") if err != nil { - return nil, GenericOpenAPIError{error: err.Error()} + return nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/namespace" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -136,7 +137,7 @@ func (a *NamespacesApiService) CreateNamespaceExecute(r ApiCreateNamespaceReques } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return nil, err } @@ -146,15 +147,15 @@ func (a *NamespacesApiService) CreateNamespaceExecute(r ApiCreateNamespaceReques return localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -165,7 +166,7 @@ func (a *NamespacesApiService) CreateNamespaceExecute(r ApiCreateNamespaceReques } type ApiDeleteNamespaceRequest struct { - ctx _context.Context + ctx context.Context ApiService *NamespacesApiService namespaceName string region *string @@ -174,34 +175,39 @@ type ApiDeleteNamespaceRequest struct { idempotencyToken *string } +// Filters results based on the specified region. func (r ApiDeleteNamespaceRequest) Region(region string) ApiDeleteNamespaceRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiDeleteNamespaceRequest) Namespace(namespace string) ApiDeleteNamespaceRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiDeleteNamespaceRequest) XNomadToken(xNomadToken string) ApiDeleteNamespaceRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiDeleteNamespaceRequest) IdempotencyToken(idempotencyToken string) ApiDeleteNamespaceRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiDeleteNamespaceRequest) Execute() (*_nethttp.Response, error) { +func (r ApiDeleteNamespaceRequest) Execute() (*http.Response, error) { return r.ApiService.DeleteNamespaceExecute(r) } /* - * DeleteNamespace Method for DeleteNamespace - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param namespaceName The namespace identifier. - * @return ApiDeleteNamespaceRequest - */ -func (a *NamespacesApiService) DeleteNamespace(ctx _context.Context, namespaceName string) ApiDeleteNamespaceRequest { +DeleteNamespace Method for DeleteNamespace + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param namespaceName The namespace identifier. + @return ApiDeleteNamespaceRequest +*/ +func (a *NamespacesApiService) DeleteNamespace(ctx context.Context, namespaceName string) ApiDeleteNamespaceRequest { return ApiDeleteNamespaceRequest{ ApiService: a, ctx: ctx, @@ -209,29 +215,25 @@ func (a *NamespacesApiService) DeleteNamespace(ctx _context.Context, namespaceNa } } -/* - * Execute executes the request - */ -func (a *NamespacesApiService) DeleteNamespaceExecute(r ApiDeleteNamespaceRequest) (*_nethttp.Response, error) { +// Execute executes the request +func (a *NamespacesApiService) DeleteNamespaceExecute(r ApiDeleteNamespaceRequest) (*http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodDelete + localVarHTTPMethod = http.MethodDelete localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NamespacesApiService.DeleteNamespace") if err != nil { - return nil, GenericOpenAPIError{error: err.Error()} + return nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/namespace/{namespaceName}" - localVarPath = strings.Replace(localVarPath, "{"+"namespaceName"+"}", _neturl.PathEscape(parameterToString(r.namespaceName, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"namespaceName"+"}", url.PathEscape(parameterToString(r.namespaceName, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -276,7 +278,7 @@ func (a *NamespacesApiService) DeleteNamespaceExecute(r ApiDeleteNamespaceReques } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return nil, err } @@ -286,15 +288,15 @@ func (a *NamespacesApiService) DeleteNamespaceExecute(r ApiDeleteNamespaceReques return localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -305,7 +307,7 @@ func (a *NamespacesApiService) DeleteNamespaceExecute(r ApiDeleteNamespaceReques } type ApiGetNamespaceRequest struct { - ctx _context.Context + ctx context.Context ApiService *NamespacesApiService namespaceName string region *string @@ -319,54 +321,64 @@ type ApiGetNamespaceRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetNamespaceRequest) Region(region string) ApiGetNamespaceRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetNamespaceRequest) Namespace(namespace string) ApiGetNamespaceRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetNamespaceRequest) Index(index int32) ApiGetNamespaceRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetNamespaceRequest) Wait(wait string) ApiGetNamespaceRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetNamespaceRequest) Stale(stale string) ApiGetNamespaceRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetNamespaceRequest) Prefix(prefix string) ApiGetNamespaceRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetNamespaceRequest) XNomadToken(xNomadToken string) ApiGetNamespaceRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetNamespaceRequest) PerPage(perPage int32) ApiGetNamespaceRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetNamespaceRequest) NextToken(nextToken string) ApiGetNamespaceRequest { r.nextToken = &nextToken return r } -func (r ApiGetNamespaceRequest) Execute() (Namespace, *_nethttp.Response, error) { +func (r ApiGetNamespaceRequest) Execute() (*Namespace, *http.Response, error) { return r.ApiService.GetNamespaceExecute(r) } /* - * GetNamespace Method for GetNamespace - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param namespaceName The namespace identifier. - * @return ApiGetNamespaceRequest - */ -func (a *NamespacesApiService) GetNamespace(ctx _context.Context, namespaceName string) ApiGetNamespaceRequest { +GetNamespace Method for GetNamespace + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param namespaceName The namespace identifier. + @return ApiGetNamespaceRequest +*/ +func (a *NamespacesApiService) GetNamespace(ctx context.Context, namespaceName string) ApiGetNamespaceRequest { return ApiGetNamespaceRequest{ ApiService: a, ctx: ctx, @@ -374,31 +386,27 @@ func (a *NamespacesApiService) GetNamespace(ctx _context.Context, namespaceName } } -/* - * Execute executes the request - * @return Namespace - */ -func (a *NamespacesApiService) GetNamespaceExecute(r ApiGetNamespaceRequest) (Namespace, *_nethttp.Response, error) { +// Execute executes the request +// @return Namespace +func (a *NamespacesApiService) GetNamespaceExecute(r ApiGetNamespaceRequest) (*Namespace, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue Namespace + formFiles []formFile + localVarReturnValue *Namespace ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NamespacesApiService.GetNamespace") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/namespace/{namespaceName}" - localVarPath = strings.Replace(localVarPath, "{"+"namespaceName"+"}", _neturl.PathEscape(parameterToString(r.namespaceName, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"namespaceName"+"}", url.PathEscape(parameterToString(r.namespaceName, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -458,7 +466,7 @@ func (a *NamespacesApiService) GetNamespaceExecute(r ApiGetNamespaceRequest) (Na } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -468,15 +476,15 @@ func (a *NamespacesApiService) GetNamespaceExecute(r ApiGetNamespaceRequest) (Na return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -485,7 +493,7 @@ func (a *NamespacesApiService) GetNamespaceExecute(r ApiGetNamespaceRequest) (Na err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -496,7 +504,7 @@ func (a *NamespacesApiService) GetNamespaceExecute(r ApiGetNamespaceRequest) (Na } type ApiGetNamespacesRequest struct { - ctx _context.Context + ctx context.Context ApiService *NamespacesApiService region *string namespace *string @@ -509,83 +517,89 @@ type ApiGetNamespacesRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetNamespacesRequest) Region(region string) ApiGetNamespacesRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetNamespacesRequest) Namespace(namespace string) ApiGetNamespacesRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetNamespacesRequest) Index(index int32) ApiGetNamespacesRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetNamespacesRequest) Wait(wait string) ApiGetNamespacesRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetNamespacesRequest) Stale(stale string) ApiGetNamespacesRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetNamespacesRequest) Prefix(prefix string) ApiGetNamespacesRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetNamespacesRequest) XNomadToken(xNomadToken string) ApiGetNamespacesRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetNamespacesRequest) PerPage(perPage int32) ApiGetNamespacesRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetNamespacesRequest) NextToken(nextToken string) ApiGetNamespacesRequest { r.nextToken = &nextToken return r } -func (r ApiGetNamespacesRequest) Execute() ([]Namespace, *_nethttp.Response, error) { +func (r ApiGetNamespacesRequest) Execute() ([]Namespace, *http.Response, error) { return r.ApiService.GetNamespacesExecute(r) } /* - * GetNamespaces Method for GetNamespaces - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiGetNamespacesRequest - */ -func (a *NamespacesApiService) GetNamespaces(ctx _context.Context) ApiGetNamespacesRequest { +GetNamespaces Method for GetNamespaces + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiGetNamespacesRequest +*/ +func (a *NamespacesApiService) GetNamespaces(ctx context.Context) ApiGetNamespacesRequest { return ApiGetNamespacesRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return []Namespace - */ -func (a *NamespacesApiService) GetNamespacesExecute(r ApiGetNamespacesRequest) ([]Namespace, *_nethttp.Response, error) { +// Execute executes the request +// @return []Namespace +func (a *NamespacesApiService) GetNamespacesExecute(r ApiGetNamespacesRequest) ([]Namespace, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile localVarReturnValue []Namespace ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NamespacesApiService.GetNamespaces") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/namespaces" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -645,7 +659,7 @@ func (a *NamespacesApiService) GetNamespacesExecute(r ApiGetNamespacesRequest) ( } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -655,15 +669,15 @@ func (a *NamespacesApiService) GetNamespacesExecute(r ApiGetNamespacesRequest) ( return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -672,7 +686,7 @@ func (a *NamespacesApiService) GetNamespacesExecute(r ApiGetNamespacesRequest) ( err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -683,7 +697,7 @@ func (a *NamespacesApiService) GetNamespacesExecute(r ApiGetNamespacesRequest) ( } type ApiPostNamespaceRequest struct { - ctx _context.Context + ctx context.Context ApiService *NamespacesApiService namespaceName string namespace2 *Namespace @@ -697,34 +711,39 @@ func (r ApiPostNamespaceRequest) Namespace2(namespace2 Namespace) ApiPostNamespa r.namespace2 = &namespace2 return r } +// Filters results based on the specified region. func (r ApiPostNamespaceRequest) Region(region string) ApiPostNamespaceRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiPostNamespaceRequest) Namespace(namespace string) ApiPostNamespaceRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiPostNamespaceRequest) XNomadToken(xNomadToken string) ApiPostNamespaceRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiPostNamespaceRequest) IdempotencyToken(idempotencyToken string) ApiPostNamespaceRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiPostNamespaceRequest) Execute() (*_nethttp.Response, error) { +func (r ApiPostNamespaceRequest) Execute() (*http.Response, error) { return r.ApiService.PostNamespaceExecute(r) } /* - * PostNamespace Method for PostNamespace - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param namespaceName The namespace identifier. - * @return ApiPostNamespaceRequest - */ -func (a *NamespacesApiService) PostNamespace(ctx _context.Context, namespaceName string) ApiPostNamespaceRequest { +PostNamespace Method for PostNamespace + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param namespaceName The namespace identifier. + @return ApiPostNamespaceRequest +*/ +func (a *NamespacesApiService) PostNamespace(ctx context.Context, namespaceName string) ApiPostNamespaceRequest { return ApiPostNamespaceRequest{ ApiService: a, ctx: ctx, @@ -732,29 +751,25 @@ func (a *NamespacesApiService) PostNamespace(ctx _context.Context, namespaceName } } -/* - * Execute executes the request - */ -func (a *NamespacesApiService) PostNamespaceExecute(r ApiPostNamespaceRequest) (*_nethttp.Response, error) { +// Execute executes the request +func (a *NamespacesApiService) PostNamespaceExecute(r ApiPostNamespaceRequest) (*http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NamespacesApiService.PostNamespace") if err != nil { - return nil, GenericOpenAPIError{error: err.Error()} + return nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/namespace/{namespaceName}" - localVarPath = strings.Replace(localVarPath, "{"+"namespaceName"+"}", _neturl.PathEscape(parameterToString(r.namespaceName, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"namespaceName"+"}", url.PathEscape(parameterToString(r.namespaceName, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.namespace2 == nil { return nil, reportError("namespace2 is required and must be specified") } @@ -804,7 +819,7 @@ func (a *NamespacesApiService) PostNamespaceExecute(r ApiPostNamespaceRequest) ( } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return nil, err } @@ -814,15 +829,15 @@ func (a *NamespacesApiService) PostNamespaceExecute(r ApiPostNamespaceRequest) ( return localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } diff --git a/clients/go/v1/api_nodes.go b/clients/go/v1/api_nodes.go index baf29761..bcfdcb34 100644 --- a/clients/go/v1/api_nodes.go +++ b/clients/go/v1/api_nodes.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -13,23 +13,23 @@ package client import ( "bytes" - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" + "context" + "io/ioutil" + "net/http" + "net/url" "strings" ) // Linger please var ( - _ _context.Context + _ context.Context ) // NodesApiService NodesApi service type NodesApiService service type ApiGetNodeRequest struct { - ctx _context.Context + ctx context.Context ApiService *NodesApiService nodeId string region *string @@ -43,54 +43,64 @@ type ApiGetNodeRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetNodeRequest) Region(region string) ApiGetNodeRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetNodeRequest) Namespace(namespace string) ApiGetNodeRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetNodeRequest) Index(index int32) ApiGetNodeRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetNodeRequest) Wait(wait string) ApiGetNodeRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetNodeRequest) Stale(stale string) ApiGetNodeRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetNodeRequest) Prefix(prefix string) ApiGetNodeRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetNodeRequest) XNomadToken(xNomadToken string) ApiGetNodeRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetNodeRequest) PerPage(perPage int32) ApiGetNodeRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetNodeRequest) NextToken(nextToken string) ApiGetNodeRequest { r.nextToken = &nextToken return r } -func (r ApiGetNodeRequest) Execute() (Node, *_nethttp.Response, error) { +func (r ApiGetNodeRequest) Execute() (*Node, *http.Response, error) { return r.ApiService.GetNodeExecute(r) } /* - * GetNode Method for GetNode - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param nodeId The ID of the node. - * @return ApiGetNodeRequest - */ -func (a *NodesApiService) GetNode(ctx _context.Context, nodeId string) ApiGetNodeRequest { +GetNode Method for GetNode + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param nodeId The ID of the node. + @return ApiGetNodeRequest +*/ +func (a *NodesApiService) GetNode(ctx context.Context, nodeId string) ApiGetNodeRequest { return ApiGetNodeRequest{ ApiService: a, ctx: ctx, @@ -98,31 +108,27 @@ func (a *NodesApiService) GetNode(ctx _context.Context, nodeId string) ApiGetNod } } -/* - * Execute executes the request - * @return Node - */ -func (a *NodesApiService) GetNodeExecute(r ApiGetNodeRequest) (Node, *_nethttp.Response, error) { +// Execute executes the request +// @return Node +func (a *NodesApiService) GetNodeExecute(r ApiGetNodeRequest) (*Node, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue Node + formFiles []formFile + localVarReturnValue *Node ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NodesApiService.GetNode") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/node/{nodeId}" - localVarPath = strings.Replace(localVarPath, "{"+"nodeId"+"}", _neturl.PathEscape(parameterToString(r.nodeId, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"nodeId"+"}", url.PathEscape(parameterToString(r.nodeId, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -182,7 +188,7 @@ func (a *NodesApiService) GetNodeExecute(r ApiGetNodeRequest) (Node, *_nethttp.R } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -192,15 +198,15 @@ func (a *NodesApiService) GetNodeExecute(r ApiGetNodeRequest) (Node, *_nethttp.R return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -209,7 +215,7 @@ func (a *NodesApiService) GetNodeExecute(r ApiGetNodeRequest) (Node, *_nethttp.R err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -220,7 +226,7 @@ func (a *NodesApiService) GetNodeExecute(r ApiGetNodeRequest) (Node, *_nethttp.R } type ApiGetNodeAllocationsRequest struct { - ctx _context.Context + ctx context.Context ApiService *NodesApiService nodeId string region *string @@ -234,54 +240,64 @@ type ApiGetNodeAllocationsRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetNodeAllocationsRequest) Region(region string) ApiGetNodeAllocationsRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetNodeAllocationsRequest) Namespace(namespace string) ApiGetNodeAllocationsRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetNodeAllocationsRequest) Index(index int32) ApiGetNodeAllocationsRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetNodeAllocationsRequest) Wait(wait string) ApiGetNodeAllocationsRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetNodeAllocationsRequest) Stale(stale string) ApiGetNodeAllocationsRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetNodeAllocationsRequest) Prefix(prefix string) ApiGetNodeAllocationsRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetNodeAllocationsRequest) XNomadToken(xNomadToken string) ApiGetNodeAllocationsRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetNodeAllocationsRequest) PerPage(perPage int32) ApiGetNodeAllocationsRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetNodeAllocationsRequest) NextToken(nextToken string) ApiGetNodeAllocationsRequest { r.nextToken = &nextToken return r } -func (r ApiGetNodeAllocationsRequest) Execute() ([]AllocationListStub, *_nethttp.Response, error) { +func (r ApiGetNodeAllocationsRequest) Execute() ([]AllocationListStub, *http.Response, error) { return r.ApiService.GetNodeAllocationsExecute(r) } /* - * GetNodeAllocations Method for GetNodeAllocations - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param nodeId The ID of the node. - * @return ApiGetNodeAllocationsRequest - */ -func (a *NodesApiService) GetNodeAllocations(ctx _context.Context, nodeId string) ApiGetNodeAllocationsRequest { +GetNodeAllocations Method for GetNodeAllocations + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param nodeId The ID of the node. + @return ApiGetNodeAllocationsRequest +*/ +func (a *NodesApiService) GetNodeAllocations(ctx context.Context, nodeId string) ApiGetNodeAllocationsRequest { return ApiGetNodeAllocationsRequest{ ApiService: a, ctx: ctx, @@ -289,31 +305,27 @@ func (a *NodesApiService) GetNodeAllocations(ctx _context.Context, nodeId string } } -/* - * Execute executes the request - * @return []AllocationListStub - */ -func (a *NodesApiService) GetNodeAllocationsExecute(r ApiGetNodeAllocationsRequest) ([]AllocationListStub, *_nethttp.Response, error) { +// Execute executes the request +// @return []AllocationListStub +func (a *NodesApiService) GetNodeAllocationsExecute(r ApiGetNodeAllocationsRequest) ([]AllocationListStub, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile localVarReturnValue []AllocationListStub ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NodesApiService.GetNodeAllocations") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/node/{nodeId}/allocations" - localVarPath = strings.Replace(localVarPath, "{"+"nodeId"+"}", _neturl.PathEscape(parameterToString(r.nodeId, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"nodeId"+"}", url.PathEscape(parameterToString(r.nodeId, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -373,7 +385,7 @@ func (a *NodesApiService) GetNodeAllocationsExecute(r ApiGetNodeAllocationsReque } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -383,15 +395,15 @@ func (a *NodesApiService) GetNodeAllocationsExecute(r ApiGetNodeAllocationsReque return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -400,7 +412,7 @@ func (a *NodesApiService) GetNodeAllocationsExecute(r ApiGetNodeAllocationsReque err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -411,7 +423,7 @@ func (a *NodesApiService) GetNodeAllocationsExecute(r ApiGetNodeAllocationsReque } type ApiGetNodesRequest struct { - ctx _context.Context + ctx context.Context ApiService *NodesApiService region *string namespace *string @@ -425,87 +437,94 @@ type ApiGetNodesRequest struct { resources *bool } +// Filters results based on the specified region. func (r ApiGetNodesRequest) Region(region string) ApiGetNodesRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetNodesRequest) Namespace(namespace string) ApiGetNodesRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetNodesRequest) Index(index int32) ApiGetNodesRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetNodesRequest) Wait(wait string) ApiGetNodesRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetNodesRequest) Stale(stale string) ApiGetNodesRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetNodesRequest) Prefix(prefix string) ApiGetNodesRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetNodesRequest) XNomadToken(xNomadToken string) ApiGetNodesRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetNodesRequest) PerPage(perPage int32) ApiGetNodesRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetNodesRequest) NextToken(nextToken string) ApiGetNodesRequest { r.nextToken = &nextToken return r } +// Whether or not to include the NodeResources and ReservedResources fields in the response. func (r ApiGetNodesRequest) Resources(resources bool) ApiGetNodesRequest { r.resources = &resources return r } -func (r ApiGetNodesRequest) Execute() ([]NodeListStub, *_nethttp.Response, error) { +func (r ApiGetNodesRequest) Execute() ([]NodeListStub, *http.Response, error) { return r.ApiService.GetNodesExecute(r) } /* - * GetNodes Method for GetNodes - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiGetNodesRequest - */ -func (a *NodesApiService) GetNodes(ctx _context.Context) ApiGetNodesRequest { +GetNodes Method for GetNodes + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiGetNodesRequest +*/ +func (a *NodesApiService) GetNodes(ctx context.Context) ApiGetNodesRequest { return ApiGetNodesRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return []NodeListStub - */ -func (a *NodesApiService) GetNodesExecute(r ApiGetNodesRequest) ([]NodeListStub, *_nethttp.Response, error) { +// Execute executes the request +// @return []NodeListStub +func (a *NodesApiService) GetNodesExecute(r ApiGetNodesRequest) ([]NodeListStub, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile localVarReturnValue []NodeListStub ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NodesApiService.GetNodes") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/nodes" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -568,7 +587,7 @@ func (a *NodesApiService) GetNodesExecute(r ApiGetNodesRequest) ([]NodeListStub, } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -578,15 +597,15 @@ func (a *NodesApiService) GetNodesExecute(r ApiGetNodesRequest) ([]NodeListStub, return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -595,7 +614,7 @@ func (a *NodesApiService) GetNodesExecute(r ApiGetNodesRequest) ([]NodeListStub, err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -606,7 +625,7 @@ func (a *NodesApiService) GetNodesExecute(r ApiGetNodesRequest) ([]NodeListStub, } type ApiUpdateNodeDrainRequest struct { - ctx _context.Context + ctx context.Context ApiService *NodesApiService nodeId string nodeUpdateDrainRequest *NodeUpdateDrainRequest @@ -625,54 +644,64 @@ func (r ApiUpdateNodeDrainRequest) NodeUpdateDrainRequest(nodeUpdateDrainRequest r.nodeUpdateDrainRequest = &nodeUpdateDrainRequest return r } +// Filters results based on the specified region. func (r ApiUpdateNodeDrainRequest) Region(region string) ApiUpdateNodeDrainRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiUpdateNodeDrainRequest) Namespace(namespace string) ApiUpdateNodeDrainRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiUpdateNodeDrainRequest) Index(index int32) ApiUpdateNodeDrainRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiUpdateNodeDrainRequest) Wait(wait string) ApiUpdateNodeDrainRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiUpdateNodeDrainRequest) Stale(stale string) ApiUpdateNodeDrainRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiUpdateNodeDrainRequest) Prefix(prefix string) ApiUpdateNodeDrainRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiUpdateNodeDrainRequest) XNomadToken(xNomadToken string) ApiUpdateNodeDrainRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiUpdateNodeDrainRequest) PerPage(perPage int32) ApiUpdateNodeDrainRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiUpdateNodeDrainRequest) NextToken(nextToken string) ApiUpdateNodeDrainRequest { r.nextToken = &nextToken return r } -func (r ApiUpdateNodeDrainRequest) Execute() (NodeDrainUpdateResponse, *_nethttp.Response, error) { +func (r ApiUpdateNodeDrainRequest) Execute() (*NodeDrainUpdateResponse, *http.Response, error) { return r.ApiService.UpdateNodeDrainExecute(r) } /* - * UpdateNodeDrain Method for UpdateNodeDrain - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param nodeId The ID of the node. - * @return ApiUpdateNodeDrainRequest - */ -func (a *NodesApiService) UpdateNodeDrain(ctx _context.Context, nodeId string) ApiUpdateNodeDrainRequest { +UpdateNodeDrain Method for UpdateNodeDrain + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param nodeId The ID of the node. + @return ApiUpdateNodeDrainRequest +*/ +func (a *NodesApiService) UpdateNodeDrain(ctx context.Context, nodeId string) ApiUpdateNodeDrainRequest { return ApiUpdateNodeDrainRequest{ ApiService: a, ctx: ctx, @@ -680,31 +709,27 @@ func (a *NodesApiService) UpdateNodeDrain(ctx _context.Context, nodeId string) A } } -/* - * Execute executes the request - * @return NodeDrainUpdateResponse - */ -func (a *NodesApiService) UpdateNodeDrainExecute(r ApiUpdateNodeDrainRequest) (NodeDrainUpdateResponse, *_nethttp.Response, error) { +// Execute executes the request +// @return NodeDrainUpdateResponse +func (a *NodesApiService) UpdateNodeDrainExecute(r ApiUpdateNodeDrainRequest) (*NodeDrainUpdateResponse, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue NodeDrainUpdateResponse + formFiles []formFile + localVarReturnValue *NodeDrainUpdateResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NodesApiService.UpdateNodeDrain") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/node/{nodeId}/drain" - localVarPath = strings.Replace(localVarPath, "{"+"nodeId"+"}", _neturl.PathEscape(parameterToString(r.nodeId, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"nodeId"+"}", url.PathEscape(parameterToString(r.nodeId, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.nodeUpdateDrainRequest == nil { return localVarReturnValue, nil, reportError("nodeUpdateDrainRequest is required and must be specified") } @@ -769,7 +794,7 @@ func (a *NodesApiService) UpdateNodeDrainExecute(r ApiUpdateNodeDrainRequest) (N } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -779,15 +804,15 @@ func (a *NodesApiService) UpdateNodeDrainExecute(r ApiUpdateNodeDrainRequest) (N return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -796,7 +821,7 @@ func (a *NodesApiService) UpdateNodeDrainExecute(r ApiUpdateNodeDrainRequest) (N err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -807,7 +832,7 @@ func (a *NodesApiService) UpdateNodeDrainExecute(r ApiUpdateNodeDrainRequest) (N } type ApiUpdateNodeEligibilityRequest struct { - ctx _context.Context + ctx context.Context ApiService *NodesApiService nodeId string nodeUpdateEligibilityRequest *NodeUpdateEligibilityRequest @@ -826,54 +851,64 @@ func (r ApiUpdateNodeEligibilityRequest) NodeUpdateEligibilityRequest(nodeUpdate r.nodeUpdateEligibilityRequest = &nodeUpdateEligibilityRequest return r } +// Filters results based on the specified region. func (r ApiUpdateNodeEligibilityRequest) Region(region string) ApiUpdateNodeEligibilityRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiUpdateNodeEligibilityRequest) Namespace(namespace string) ApiUpdateNodeEligibilityRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiUpdateNodeEligibilityRequest) Index(index int32) ApiUpdateNodeEligibilityRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiUpdateNodeEligibilityRequest) Wait(wait string) ApiUpdateNodeEligibilityRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiUpdateNodeEligibilityRequest) Stale(stale string) ApiUpdateNodeEligibilityRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiUpdateNodeEligibilityRequest) Prefix(prefix string) ApiUpdateNodeEligibilityRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiUpdateNodeEligibilityRequest) XNomadToken(xNomadToken string) ApiUpdateNodeEligibilityRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiUpdateNodeEligibilityRequest) PerPage(perPage int32) ApiUpdateNodeEligibilityRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiUpdateNodeEligibilityRequest) NextToken(nextToken string) ApiUpdateNodeEligibilityRequest { r.nextToken = &nextToken return r } -func (r ApiUpdateNodeEligibilityRequest) Execute() (NodeEligibilityUpdateResponse, *_nethttp.Response, error) { +func (r ApiUpdateNodeEligibilityRequest) Execute() (*NodeEligibilityUpdateResponse, *http.Response, error) { return r.ApiService.UpdateNodeEligibilityExecute(r) } /* - * UpdateNodeEligibility Method for UpdateNodeEligibility - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param nodeId The ID of the node. - * @return ApiUpdateNodeEligibilityRequest - */ -func (a *NodesApiService) UpdateNodeEligibility(ctx _context.Context, nodeId string) ApiUpdateNodeEligibilityRequest { +UpdateNodeEligibility Method for UpdateNodeEligibility + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param nodeId The ID of the node. + @return ApiUpdateNodeEligibilityRequest +*/ +func (a *NodesApiService) UpdateNodeEligibility(ctx context.Context, nodeId string) ApiUpdateNodeEligibilityRequest { return ApiUpdateNodeEligibilityRequest{ ApiService: a, ctx: ctx, @@ -881,31 +916,27 @@ func (a *NodesApiService) UpdateNodeEligibility(ctx _context.Context, nodeId str } } -/* - * Execute executes the request - * @return NodeEligibilityUpdateResponse - */ -func (a *NodesApiService) UpdateNodeEligibilityExecute(r ApiUpdateNodeEligibilityRequest) (NodeEligibilityUpdateResponse, *_nethttp.Response, error) { +// Execute executes the request +// @return NodeEligibilityUpdateResponse +func (a *NodesApiService) UpdateNodeEligibilityExecute(r ApiUpdateNodeEligibilityRequest) (*NodeEligibilityUpdateResponse, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue NodeEligibilityUpdateResponse + formFiles []formFile + localVarReturnValue *NodeEligibilityUpdateResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NodesApiService.UpdateNodeEligibility") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/node/{nodeId}/eligibility" - localVarPath = strings.Replace(localVarPath, "{"+"nodeId"+"}", _neturl.PathEscape(parameterToString(r.nodeId, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"nodeId"+"}", url.PathEscape(parameterToString(r.nodeId, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.nodeUpdateEligibilityRequest == nil { return localVarReturnValue, nil, reportError("nodeUpdateEligibilityRequest is required and must be specified") } @@ -970,7 +1001,7 @@ func (a *NodesApiService) UpdateNodeEligibilityExecute(r ApiUpdateNodeEligibilit } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -980,15 +1011,15 @@ func (a *NodesApiService) UpdateNodeEligibilityExecute(r ApiUpdateNodeEligibilit return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -997,7 +1028,7 @@ func (a *NodesApiService) UpdateNodeEligibilityExecute(r ApiUpdateNodeEligibilit err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -1008,7 +1039,7 @@ func (a *NodesApiService) UpdateNodeEligibilityExecute(r ApiUpdateNodeEligibilit } type ApiUpdateNodePurgeRequest struct { - ctx _context.Context + ctx context.Context ApiService *NodesApiService nodeId string region *string @@ -1022,54 +1053,64 @@ type ApiUpdateNodePurgeRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiUpdateNodePurgeRequest) Region(region string) ApiUpdateNodePurgeRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiUpdateNodePurgeRequest) Namespace(namespace string) ApiUpdateNodePurgeRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiUpdateNodePurgeRequest) Index(index int32) ApiUpdateNodePurgeRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiUpdateNodePurgeRequest) Wait(wait string) ApiUpdateNodePurgeRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiUpdateNodePurgeRequest) Stale(stale string) ApiUpdateNodePurgeRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiUpdateNodePurgeRequest) Prefix(prefix string) ApiUpdateNodePurgeRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiUpdateNodePurgeRequest) XNomadToken(xNomadToken string) ApiUpdateNodePurgeRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiUpdateNodePurgeRequest) PerPage(perPage int32) ApiUpdateNodePurgeRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiUpdateNodePurgeRequest) NextToken(nextToken string) ApiUpdateNodePurgeRequest { r.nextToken = &nextToken return r } -func (r ApiUpdateNodePurgeRequest) Execute() (NodePurgeResponse, *_nethttp.Response, error) { +func (r ApiUpdateNodePurgeRequest) Execute() (*NodePurgeResponse, *http.Response, error) { return r.ApiService.UpdateNodePurgeExecute(r) } /* - * UpdateNodePurge Method for UpdateNodePurge - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param nodeId The ID of the node. - * @return ApiUpdateNodePurgeRequest - */ -func (a *NodesApiService) UpdateNodePurge(ctx _context.Context, nodeId string) ApiUpdateNodePurgeRequest { +UpdateNodePurge Method for UpdateNodePurge + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param nodeId The ID of the node. + @return ApiUpdateNodePurgeRequest +*/ +func (a *NodesApiService) UpdateNodePurge(ctx context.Context, nodeId string) ApiUpdateNodePurgeRequest { return ApiUpdateNodePurgeRequest{ ApiService: a, ctx: ctx, @@ -1077,31 +1118,27 @@ func (a *NodesApiService) UpdateNodePurge(ctx _context.Context, nodeId string) A } } -/* - * Execute executes the request - * @return NodePurgeResponse - */ -func (a *NodesApiService) UpdateNodePurgeExecute(r ApiUpdateNodePurgeRequest) (NodePurgeResponse, *_nethttp.Response, error) { +// Execute executes the request +// @return NodePurgeResponse +func (a *NodesApiService) UpdateNodePurgeExecute(r ApiUpdateNodePurgeRequest) (*NodePurgeResponse, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue NodePurgeResponse + formFiles []formFile + localVarReturnValue *NodePurgeResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NodesApiService.UpdateNodePurge") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/node/{nodeId}/purge" - localVarPath = strings.Replace(localVarPath, "{"+"nodeId"+"}", _neturl.PathEscape(parameterToString(r.nodeId, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"nodeId"+"}", url.PathEscape(parameterToString(r.nodeId, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -1161,7 +1198,7 @@ func (a *NodesApiService) UpdateNodePurgeExecute(r ApiUpdateNodePurgeRequest) (N } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -1171,15 +1208,15 @@ func (a *NodesApiService) UpdateNodePurgeExecute(r ApiUpdateNodePurgeRequest) (N return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -1188,7 +1225,7 @@ func (a *NodesApiService) UpdateNodePurgeExecute(r ApiUpdateNodePurgeRequest) (N err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } diff --git a/clients/go/v1/api_operator.go b/clients/go/v1/api_operator.go index a533175c..c21989fa 100644 --- a/clients/go/v1/api_operator.go +++ b/clients/go/v1/api_operator.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -13,22 +13,22 @@ package client import ( "bytes" - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" + "context" + "io/ioutil" + "net/http" + "net/url" ) // Linger please var ( - _ _context.Context + _ context.Context ) // OperatorApiService OperatorApi service type OperatorApiService service type ApiDeleteOperatorRaftPeerRequest struct { - ctx _context.Context + ctx context.Context ApiService *OperatorApiService region *string namespace *string @@ -36,61 +36,62 @@ type ApiDeleteOperatorRaftPeerRequest struct { idempotencyToken *string } +// Filters results based on the specified region. func (r ApiDeleteOperatorRaftPeerRequest) Region(region string) ApiDeleteOperatorRaftPeerRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiDeleteOperatorRaftPeerRequest) Namespace(namespace string) ApiDeleteOperatorRaftPeerRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiDeleteOperatorRaftPeerRequest) XNomadToken(xNomadToken string) ApiDeleteOperatorRaftPeerRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiDeleteOperatorRaftPeerRequest) IdempotencyToken(idempotencyToken string) ApiDeleteOperatorRaftPeerRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiDeleteOperatorRaftPeerRequest) Execute() (*_nethttp.Response, error) { +func (r ApiDeleteOperatorRaftPeerRequest) Execute() (*http.Response, error) { return r.ApiService.DeleteOperatorRaftPeerExecute(r) } /* - * DeleteOperatorRaftPeer Method for DeleteOperatorRaftPeer - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiDeleteOperatorRaftPeerRequest - */ -func (a *OperatorApiService) DeleteOperatorRaftPeer(ctx _context.Context) ApiDeleteOperatorRaftPeerRequest { +DeleteOperatorRaftPeer Method for DeleteOperatorRaftPeer + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiDeleteOperatorRaftPeerRequest +*/ +func (a *OperatorApiService) DeleteOperatorRaftPeer(ctx context.Context) ApiDeleteOperatorRaftPeerRequest { return ApiDeleteOperatorRaftPeerRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - */ -func (a *OperatorApiService) DeleteOperatorRaftPeerExecute(r ApiDeleteOperatorRaftPeerRequest) (*_nethttp.Response, error) { +// Execute executes the request +func (a *OperatorApiService) DeleteOperatorRaftPeerExecute(r ApiDeleteOperatorRaftPeerRequest) (*http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodDelete + localVarHTTPMethod = http.MethodDelete localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "OperatorApiService.DeleteOperatorRaftPeer") if err != nil { - return nil, GenericOpenAPIError{error: err.Error()} + return nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/operator/raft/peer" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -135,7 +136,7 @@ func (a *OperatorApiService) DeleteOperatorRaftPeerExecute(r ApiDeleteOperatorRa } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return nil, err } @@ -145,15 +146,15 @@ func (a *OperatorApiService) DeleteOperatorRaftPeerExecute(r ApiDeleteOperatorRa return localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -164,7 +165,7 @@ func (a *OperatorApiService) DeleteOperatorRaftPeerExecute(r ApiDeleteOperatorRa } type ApiGetOperatorAutopilotConfigurationRequest struct { - ctx _context.Context + ctx context.Context ApiService *OperatorApiService region *string namespace *string @@ -177,83 +178,89 @@ type ApiGetOperatorAutopilotConfigurationRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetOperatorAutopilotConfigurationRequest) Region(region string) ApiGetOperatorAutopilotConfigurationRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetOperatorAutopilotConfigurationRequest) Namespace(namespace string) ApiGetOperatorAutopilotConfigurationRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetOperatorAutopilotConfigurationRequest) Index(index int32) ApiGetOperatorAutopilotConfigurationRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetOperatorAutopilotConfigurationRequest) Wait(wait string) ApiGetOperatorAutopilotConfigurationRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetOperatorAutopilotConfigurationRequest) Stale(stale string) ApiGetOperatorAutopilotConfigurationRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetOperatorAutopilotConfigurationRequest) Prefix(prefix string) ApiGetOperatorAutopilotConfigurationRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetOperatorAutopilotConfigurationRequest) XNomadToken(xNomadToken string) ApiGetOperatorAutopilotConfigurationRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetOperatorAutopilotConfigurationRequest) PerPage(perPage int32) ApiGetOperatorAutopilotConfigurationRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetOperatorAutopilotConfigurationRequest) NextToken(nextToken string) ApiGetOperatorAutopilotConfigurationRequest { r.nextToken = &nextToken return r } -func (r ApiGetOperatorAutopilotConfigurationRequest) Execute() (AutopilotConfiguration, *_nethttp.Response, error) { +func (r ApiGetOperatorAutopilotConfigurationRequest) Execute() (*AutopilotConfiguration, *http.Response, error) { return r.ApiService.GetOperatorAutopilotConfigurationExecute(r) } /* - * GetOperatorAutopilotConfiguration Method for GetOperatorAutopilotConfiguration - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiGetOperatorAutopilotConfigurationRequest - */ -func (a *OperatorApiService) GetOperatorAutopilotConfiguration(ctx _context.Context) ApiGetOperatorAutopilotConfigurationRequest { +GetOperatorAutopilotConfiguration Method for GetOperatorAutopilotConfiguration + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiGetOperatorAutopilotConfigurationRequest +*/ +func (a *OperatorApiService) GetOperatorAutopilotConfiguration(ctx context.Context) ApiGetOperatorAutopilotConfigurationRequest { return ApiGetOperatorAutopilotConfigurationRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return AutopilotConfiguration - */ -func (a *OperatorApiService) GetOperatorAutopilotConfigurationExecute(r ApiGetOperatorAutopilotConfigurationRequest) (AutopilotConfiguration, *_nethttp.Response, error) { +// Execute executes the request +// @return AutopilotConfiguration +func (a *OperatorApiService) GetOperatorAutopilotConfigurationExecute(r ApiGetOperatorAutopilotConfigurationRequest) (*AutopilotConfiguration, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue AutopilotConfiguration + formFiles []formFile + localVarReturnValue *AutopilotConfiguration ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "OperatorApiService.GetOperatorAutopilotConfiguration") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/operator/autopilot/configuration" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -313,7 +320,7 @@ func (a *OperatorApiService) GetOperatorAutopilotConfigurationExecute(r ApiGetOp } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -323,15 +330,15 @@ func (a *OperatorApiService) GetOperatorAutopilotConfigurationExecute(r ApiGetOp return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -340,7 +347,7 @@ func (a *OperatorApiService) GetOperatorAutopilotConfigurationExecute(r ApiGetOp err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -351,7 +358,7 @@ func (a *OperatorApiService) GetOperatorAutopilotConfigurationExecute(r ApiGetOp } type ApiGetOperatorAutopilotHealthRequest struct { - ctx _context.Context + ctx context.Context ApiService *OperatorApiService region *string namespace *string @@ -364,83 +371,89 @@ type ApiGetOperatorAutopilotHealthRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetOperatorAutopilotHealthRequest) Region(region string) ApiGetOperatorAutopilotHealthRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetOperatorAutopilotHealthRequest) Namespace(namespace string) ApiGetOperatorAutopilotHealthRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetOperatorAutopilotHealthRequest) Index(index int32) ApiGetOperatorAutopilotHealthRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetOperatorAutopilotHealthRequest) Wait(wait string) ApiGetOperatorAutopilotHealthRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetOperatorAutopilotHealthRequest) Stale(stale string) ApiGetOperatorAutopilotHealthRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetOperatorAutopilotHealthRequest) Prefix(prefix string) ApiGetOperatorAutopilotHealthRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetOperatorAutopilotHealthRequest) XNomadToken(xNomadToken string) ApiGetOperatorAutopilotHealthRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetOperatorAutopilotHealthRequest) PerPage(perPage int32) ApiGetOperatorAutopilotHealthRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetOperatorAutopilotHealthRequest) NextToken(nextToken string) ApiGetOperatorAutopilotHealthRequest { r.nextToken = &nextToken return r } -func (r ApiGetOperatorAutopilotHealthRequest) Execute() (OperatorHealthReply, *_nethttp.Response, error) { +func (r ApiGetOperatorAutopilotHealthRequest) Execute() (*OperatorHealthReply, *http.Response, error) { return r.ApiService.GetOperatorAutopilotHealthExecute(r) } /* - * GetOperatorAutopilotHealth Method for GetOperatorAutopilotHealth - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiGetOperatorAutopilotHealthRequest - */ -func (a *OperatorApiService) GetOperatorAutopilotHealth(ctx _context.Context) ApiGetOperatorAutopilotHealthRequest { +GetOperatorAutopilotHealth Method for GetOperatorAutopilotHealth + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiGetOperatorAutopilotHealthRequest +*/ +func (a *OperatorApiService) GetOperatorAutopilotHealth(ctx context.Context) ApiGetOperatorAutopilotHealthRequest { return ApiGetOperatorAutopilotHealthRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return OperatorHealthReply - */ -func (a *OperatorApiService) GetOperatorAutopilotHealthExecute(r ApiGetOperatorAutopilotHealthRequest) (OperatorHealthReply, *_nethttp.Response, error) { +// Execute executes the request +// @return OperatorHealthReply +func (a *OperatorApiService) GetOperatorAutopilotHealthExecute(r ApiGetOperatorAutopilotHealthRequest) (*OperatorHealthReply, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue OperatorHealthReply + formFiles []formFile + localVarReturnValue *OperatorHealthReply ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "OperatorApiService.GetOperatorAutopilotHealth") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/operator/autopilot/health" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -500,7 +513,7 @@ func (a *OperatorApiService) GetOperatorAutopilotHealthExecute(r ApiGetOperatorA } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -510,15 +523,15 @@ func (a *OperatorApiService) GetOperatorAutopilotHealthExecute(r ApiGetOperatorA return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -527,7 +540,7 @@ func (a *OperatorApiService) GetOperatorAutopilotHealthExecute(r ApiGetOperatorA err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -538,7 +551,7 @@ func (a *OperatorApiService) GetOperatorAutopilotHealthExecute(r ApiGetOperatorA } type ApiGetOperatorRaftConfigurationRequest struct { - ctx _context.Context + ctx context.Context ApiService *OperatorApiService region *string namespace *string @@ -551,83 +564,89 @@ type ApiGetOperatorRaftConfigurationRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetOperatorRaftConfigurationRequest) Region(region string) ApiGetOperatorRaftConfigurationRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetOperatorRaftConfigurationRequest) Namespace(namespace string) ApiGetOperatorRaftConfigurationRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetOperatorRaftConfigurationRequest) Index(index int32) ApiGetOperatorRaftConfigurationRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetOperatorRaftConfigurationRequest) Wait(wait string) ApiGetOperatorRaftConfigurationRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetOperatorRaftConfigurationRequest) Stale(stale string) ApiGetOperatorRaftConfigurationRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetOperatorRaftConfigurationRequest) Prefix(prefix string) ApiGetOperatorRaftConfigurationRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetOperatorRaftConfigurationRequest) XNomadToken(xNomadToken string) ApiGetOperatorRaftConfigurationRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetOperatorRaftConfigurationRequest) PerPage(perPage int32) ApiGetOperatorRaftConfigurationRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetOperatorRaftConfigurationRequest) NextToken(nextToken string) ApiGetOperatorRaftConfigurationRequest { r.nextToken = &nextToken return r } -func (r ApiGetOperatorRaftConfigurationRequest) Execute() (RaftConfiguration, *_nethttp.Response, error) { +func (r ApiGetOperatorRaftConfigurationRequest) Execute() (*RaftConfiguration, *http.Response, error) { return r.ApiService.GetOperatorRaftConfigurationExecute(r) } /* - * GetOperatorRaftConfiguration Method for GetOperatorRaftConfiguration - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiGetOperatorRaftConfigurationRequest - */ -func (a *OperatorApiService) GetOperatorRaftConfiguration(ctx _context.Context) ApiGetOperatorRaftConfigurationRequest { +GetOperatorRaftConfiguration Method for GetOperatorRaftConfiguration + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiGetOperatorRaftConfigurationRequest +*/ +func (a *OperatorApiService) GetOperatorRaftConfiguration(ctx context.Context) ApiGetOperatorRaftConfigurationRequest { return ApiGetOperatorRaftConfigurationRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return RaftConfiguration - */ -func (a *OperatorApiService) GetOperatorRaftConfigurationExecute(r ApiGetOperatorRaftConfigurationRequest) (RaftConfiguration, *_nethttp.Response, error) { +// Execute executes the request +// @return RaftConfiguration +func (a *OperatorApiService) GetOperatorRaftConfigurationExecute(r ApiGetOperatorRaftConfigurationRequest) (*RaftConfiguration, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue RaftConfiguration + formFiles []formFile + localVarReturnValue *RaftConfiguration ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "OperatorApiService.GetOperatorRaftConfiguration") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/operator/raft/configuration" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -687,7 +706,7 @@ func (a *OperatorApiService) GetOperatorRaftConfigurationExecute(r ApiGetOperato } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -697,15 +716,15 @@ func (a *OperatorApiService) GetOperatorRaftConfigurationExecute(r ApiGetOperato return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -714,7 +733,7 @@ func (a *OperatorApiService) GetOperatorRaftConfigurationExecute(r ApiGetOperato err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -725,7 +744,7 @@ func (a *OperatorApiService) GetOperatorRaftConfigurationExecute(r ApiGetOperato } type ApiGetOperatorSchedulerConfigurationRequest struct { - ctx _context.Context + ctx context.Context ApiService *OperatorApiService region *string namespace *string @@ -738,83 +757,89 @@ type ApiGetOperatorSchedulerConfigurationRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetOperatorSchedulerConfigurationRequest) Region(region string) ApiGetOperatorSchedulerConfigurationRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetOperatorSchedulerConfigurationRequest) Namespace(namespace string) ApiGetOperatorSchedulerConfigurationRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetOperatorSchedulerConfigurationRequest) Index(index int32) ApiGetOperatorSchedulerConfigurationRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetOperatorSchedulerConfigurationRequest) Wait(wait string) ApiGetOperatorSchedulerConfigurationRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetOperatorSchedulerConfigurationRequest) Stale(stale string) ApiGetOperatorSchedulerConfigurationRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetOperatorSchedulerConfigurationRequest) Prefix(prefix string) ApiGetOperatorSchedulerConfigurationRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetOperatorSchedulerConfigurationRequest) XNomadToken(xNomadToken string) ApiGetOperatorSchedulerConfigurationRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetOperatorSchedulerConfigurationRequest) PerPage(perPage int32) ApiGetOperatorSchedulerConfigurationRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetOperatorSchedulerConfigurationRequest) NextToken(nextToken string) ApiGetOperatorSchedulerConfigurationRequest { r.nextToken = &nextToken return r } -func (r ApiGetOperatorSchedulerConfigurationRequest) Execute() (SchedulerConfigurationResponse, *_nethttp.Response, error) { +func (r ApiGetOperatorSchedulerConfigurationRequest) Execute() (*SchedulerConfigurationResponse, *http.Response, error) { return r.ApiService.GetOperatorSchedulerConfigurationExecute(r) } /* - * GetOperatorSchedulerConfiguration Method for GetOperatorSchedulerConfiguration - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiGetOperatorSchedulerConfigurationRequest - */ -func (a *OperatorApiService) GetOperatorSchedulerConfiguration(ctx _context.Context) ApiGetOperatorSchedulerConfigurationRequest { +GetOperatorSchedulerConfiguration Method for GetOperatorSchedulerConfiguration + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiGetOperatorSchedulerConfigurationRequest +*/ +func (a *OperatorApiService) GetOperatorSchedulerConfiguration(ctx context.Context) ApiGetOperatorSchedulerConfigurationRequest { return ApiGetOperatorSchedulerConfigurationRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return SchedulerConfigurationResponse - */ -func (a *OperatorApiService) GetOperatorSchedulerConfigurationExecute(r ApiGetOperatorSchedulerConfigurationRequest) (SchedulerConfigurationResponse, *_nethttp.Response, error) { +// Execute executes the request +// @return SchedulerConfigurationResponse +func (a *OperatorApiService) GetOperatorSchedulerConfigurationExecute(r ApiGetOperatorSchedulerConfigurationRequest) (*SchedulerConfigurationResponse, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue SchedulerConfigurationResponse + formFiles []formFile + localVarReturnValue *SchedulerConfigurationResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "OperatorApiService.GetOperatorSchedulerConfiguration") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/operator/scheduler/configuration" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -874,7 +899,7 @@ func (a *OperatorApiService) GetOperatorSchedulerConfigurationExecute(r ApiGetOp } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -884,15 +909,15 @@ func (a *OperatorApiService) GetOperatorSchedulerConfigurationExecute(r ApiGetOp return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -901,7 +926,7 @@ func (a *OperatorApiService) GetOperatorSchedulerConfigurationExecute(r ApiGetOp err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -912,7 +937,7 @@ func (a *OperatorApiService) GetOperatorSchedulerConfigurationExecute(r ApiGetOp } type ApiPostOperatorSchedulerConfigurationRequest struct { - ctx _context.Context + ctx context.Context ApiService *OperatorApiService schedulerConfiguration *SchedulerConfiguration region *string @@ -925,63 +950,64 @@ func (r ApiPostOperatorSchedulerConfigurationRequest) SchedulerConfiguration(sch r.schedulerConfiguration = &schedulerConfiguration return r } +// Filters results based on the specified region. func (r ApiPostOperatorSchedulerConfigurationRequest) Region(region string) ApiPostOperatorSchedulerConfigurationRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiPostOperatorSchedulerConfigurationRequest) Namespace(namespace string) ApiPostOperatorSchedulerConfigurationRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiPostOperatorSchedulerConfigurationRequest) XNomadToken(xNomadToken string) ApiPostOperatorSchedulerConfigurationRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiPostOperatorSchedulerConfigurationRequest) IdempotencyToken(idempotencyToken string) ApiPostOperatorSchedulerConfigurationRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiPostOperatorSchedulerConfigurationRequest) Execute() (SchedulerSetConfigurationResponse, *_nethttp.Response, error) { +func (r ApiPostOperatorSchedulerConfigurationRequest) Execute() (*SchedulerSetConfigurationResponse, *http.Response, error) { return r.ApiService.PostOperatorSchedulerConfigurationExecute(r) } /* - * PostOperatorSchedulerConfiguration Method for PostOperatorSchedulerConfiguration - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiPostOperatorSchedulerConfigurationRequest - */ -func (a *OperatorApiService) PostOperatorSchedulerConfiguration(ctx _context.Context) ApiPostOperatorSchedulerConfigurationRequest { +PostOperatorSchedulerConfiguration Method for PostOperatorSchedulerConfiguration + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiPostOperatorSchedulerConfigurationRequest +*/ +func (a *OperatorApiService) PostOperatorSchedulerConfiguration(ctx context.Context) ApiPostOperatorSchedulerConfigurationRequest { return ApiPostOperatorSchedulerConfigurationRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return SchedulerSetConfigurationResponse - */ -func (a *OperatorApiService) PostOperatorSchedulerConfigurationExecute(r ApiPostOperatorSchedulerConfigurationRequest) (SchedulerSetConfigurationResponse, *_nethttp.Response, error) { +// Execute executes the request +// @return SchedulerSetConfigurationResponse +func (a *OperatorApiService) PostOperatorSchedulerConfigurationExecute(r ApiPostOperatorSchedulerConfigurationRequest) (*SchedulerSetConfigurationResponse, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue SchedulerSetConfigurationResponse + formFiles []formFile + localVarReturnValue *SchedulerSetConfigurationResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "OperatorApiService.PostOperatorSchedulerConfiguration") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/operator/scheduler/configuration" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.schedulerConfiguration == nil { return localVarReturnValue, nil, reportError("schedulerConfiguration is required and must be specified") } @@ -1031,7 +1057,7 @@ func (a *OperatorApiService) PostOperatorSchedulerConfigurationExecute(r ApiPost } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -1041,15 +1067,15 @@ func (a *OperatorApiService) PostOperatorSchedulerConfigurationExecute(r ApiPost return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -1058,7 +1084,7 @@ func (a *OperatorApiService) PostOperatorSchedulerConfigurationExecute(r ApiPost err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -1069,7 +1095,7 @@ func (a *OperatorApiService) PostOperatorSchedulerConfigurationExecute(r ApiPost } type ApiPutOperatorAutopilotConfigurationRequest struct { - ctx _context.Context + ctx context.Context ApiService *OperatorApiService autopilotConfiguration *AutopilotConfiguration region *string @@ -1082,63 +1108,64 @@ func (r ApiPutOperatorAutopilotConfigurationRequest) AutopilotConfiguration(auto r.autopilotConfiguration = &autopilotConfiguration return r } +// Filters results based on the specified region. func (r ApiPutOperatorAutopilotConfigurationRequest) Region(region string) ApiPutOperatorAutopilotConfigurationRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiPutOperatorAutopilotConfigurationRequest) Namespace(namespace string) ApiPutOperatorAutopilotConfigurationRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiPutOperatorAutopilotConfigurationRequest) XNomadToken(xNomadToken string) ApiPutOperatorAutopilotConfigurationRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiPutOperatorAutopilotConfigurationRequest) IdempotencyToken(idempotencyToken string) ApiPutOperatorAutopilotConfigurationRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiPutOperatorAutopilotConfigurationRequest) Execute() (bool, *_nethttp.Response, error) { +func (r ApiPutOperatorAutopilotConfigurationRequest) Execute() (bool, *http.Response, error) { return r.ApiService.PutOperatorAutopilotConfigurationExecute(r) } /* - * PutOperatorAutopilotConfiguration Method for PutOperatorAutopilotConfiguration - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiPutOperatorAutopilotConfigurationRequest - */ -func (a *OperatorApiService) PutOperatorAutopilotConfiguration(ctx _context.Context) ApiPutOperatorAutopilotConfigurationRequest { +PutOperatorAutopilotConfiguration Method for PutOperatorAutopilotConfiguration + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiPutOperatorAutopilotConfigurationRequest +*/ +func (a *OperatorApiService) PutOperatorAutopilotConfiguration(ctx context.Context) ApiPutOperatorAutopilotConfigurationRequest { return ApiPutOperatorAutopilotConfigurationRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return bool - */ -func (a *OperatorApiService) PutOperatorAutopilotConfigurationExecute(r ApiPutOperatorAutopilotConfigurationRequest) (bool, *_nethttp.Response, error) { +// Execute executes the request +// @return bool +func (a *OperatorApiService) PutOperatorAutopilotConfigurationExecute(r ApiPutOperatorAutopilotConfigurationRequest) (bool, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPut + localVarHTTPMethod = http.MethodPut localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile localVarReturnValue bool ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "OperatorApiService.PutOperatorAutopilotConfiguration") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/operator/autopilot/configuration" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.autopilotConfiguration == nil { return localVarReturnValue, nil, reportError("autopilotConfiguration is required and must be specified") } @@ -1188,7 +1215,7 @@ func (a *OperatorApiService) PutOperatorAutopilotConfigurationExecute(r ApiPutOp } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -1198,15 +1225,15 @@ func (a *OperatorApiService) PutOperatorAutopilotConfigurationExecute(r ApiPutOp return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -1215,7 +1242,7 @@ func (a *OperatorApiService) PutOperatorAutopilotConfigurationExecute(r ApiPutOp err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } diff --git a/clients/go/v1/api_plugins.go b/clients/go/v1/api_plugins.go index ab1ddbc4..3eb66325 100644 --- a/clients/go/v1/api_plugins.go +++ b/clients/go/v1/api_plugins.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -13,23 +13,23 @@ package client import ( "bytes" - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" + "context" + "io/ioutil" + "net/http" + "net/url" "strings" ) // Linger please var ( - _ _context.Context + _ context.Context ) // PluginsApiService PluginsApi service type PluginsApiService service type ApiGetPluginCSIRequest struct { - ctx _context.Context + ctx context.Context ApiService *PluginsApiService pluginID string region *string @@ -43,54 +43,64 @@ type ApiGetPluginCSIRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetPluginCSIRequest) Region(region string) ApiGetPluginCSIRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetPluginCSIRequest) Namespace(namespace string) ApiGetPluginCSIRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetPluginCSIRequest) Index(index int32) ApiGetPluginCSIRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetPluginCSIRequest) Wait(wait string) ApiGetPluginCSIRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetPluginCSIRequest) Stale(stale string) ApiGetPluginCSIRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetPluginCSIRequest) Prefix(prefix string) ApiGetPluginCSIRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetPluginCSIRequest) XNomadToken(xNomadToken string) ApiGetPluginCSIRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetPluginCSIRequest) PerPage(perPage int32) ApiGetPluginCSIRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetPluginCSIRequest) NextToken(nextToken string) ApiGetPluginCSIRequest { r.nextToken = &nextToken return r } -func (r ApiGetPluginCSIRequest) Execute() ([]CSIPlugin, *_nethttp.Response, error) { +func (r ApiGetPluginCSIRequest) Execute() ([]CSIPlugin, *http.Response, error) { return r.ApiService.GetPluginCSIExecute(r) } /* - * GetPluginCSI Method for GetPluginCSI - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param pluginID The CSI plugin identifier. - * @return ApiGetPluginCSIRequest - */ -func (a *PluginsApiService) GetPluginCSI(ctx _context.Context, pluginID string) ApiGetPluginCSIRequest { +GetPluginCSI Method for GetPluginCSI + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param pluginID The CSI plugin identifier. + @return ApiGetPluginCSIRequest +*/ +func (a *PluginsApiService) GetPluginCSI(ctx context.Context, pluginID string) ApiGetPluginCSIRequest { return ApiGetPluginCSIRequest{ ApiService: a, ctx: ctx, @@ -98,31 +108,27 @@ func (a *PluginsApiService) GetPluginCSI(ctx _context.Context, pluginID string) } } -/* - * Execute executes the request - * @return []CSIPlugin - */ -func (a *PluginsApiService) GetPluginCSIExecute(r ApiGetPluginCSIRequest) ([]CSIPlugin, *_nethttp.Response, error) { +// Execute executes the request +// @return []CSIPlugin +func (a *PluginsApiService) GetPluginCSIExecute(r ApiGetPluginCSIRequest) ([]CSIPlugin, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile localVarReturnValue []CSIPlugin ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "PluginsApiService.GetPluginCSI") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/plugin/csi/{pluginID}" - localVarPath = strings.Replace(localVarPath, "{"+"pluginID"+"}", _neturl.PathEscape(parameterToString(r.pluginID, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"pluginID"+"}", url.PathEscape(parameterToString(r.pluginID, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -182,7 +188,7 @@ func (a *PluginsApiService) GetPluginCSIExecute(r ApiGetPluginCSIRequest) ([]CSI } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -192,15 +198,15 @@ func (a *PluginsApiService) GetPluginCSIExecute(r ApiGetPluginCSIRequest) ([]CSI return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -209,7 +215,7 @@ func (a *PluginsApiService) GetPluginCSIExecute(r ApiGetPluginCSIRequest) ([]CSI err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -220,7 +226,7 @@ func (a *PluginsApiService) GetPluginCSIExecute(r ApiGetPluginCSIRequest) ([]CSI } type ApiGetPluginsRequest struct { - ctx _context.Context + ctx context.Context ApiService *PluginsApiService region *string namespace *string @@ -233,83 +239,89 @@ type ApiGetPluginsRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetPluginsRequest) Region(region string) ApiGetPluginsRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetPluginsRequest) Namespace(namespace string) ApiGetPluginsRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetPluginsRequest) Index(index int32) ApiGetPluginsRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetPluginsRequest) Wait(wait string) ApiGetPluginsRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetPluginsRequest) Stale(stale string) ApiGetPluginsRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetPluginsRequest) Prefix(prefix string) ApiGetPluginsRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetPluginsRequest) XNomadToken(xNomadToken string) ApiGetPluginsRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetPluginsRequest) PerPage(perPage int32) ApiGetPluginsRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetPluginsRequest) NextToken(nextToken string) ApiGetPluginsRequest { r.nextToken = &nextToken return r } -func (r ApiGetPluginsRequest) Execute() ([]CSIPluginListStub, *_nethttp.Response, error) { +func (r ApiGetPluginsRequest) Execute() ([]CSIPluginListStub, *http.Response, error) { return r.ApiService.GetPluginsExecute(r) } /* - * GetPlugins Method for GetPlugins - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiGetPluginsRequest - */ -func (a *PluginsApiService) GetPlugins(ctx _context.Context) ApiGetPluginsRequest { +GetPlugins Method for GetPlugins + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiGetPluginsRequest +*/ +func (a *PluginsApiService) GetPlugins(ctx context.Context) ApiGetPluginsRequest { return ApiGetPluginsRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return []CSIPluginListStub - */ -func (a *PluginsApiService) GetPluginsExecute(r ApiGetPluginsRequest) ([]CSIPluginListStub, *_nethttp.Response, error) { +// Execute executes the request +// @return []CSIPluginListStub +func (a *PluginsApiService) GetPluginsExecute(r ApiGetPluginsRequest) ([]CSIPluginListStub, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile localVarReturnValue []CSIPluginListStub ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "PluginsApiService.GetPlugins") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/plugins" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -369,7 +381,7 @@ func (a *PluginsApiService) GetPluginsExecute(r ApiGetPluginsRequest) ([]CSIPlug } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -379,15 +391,15 @@ func (a *PluginsApiService) GetPluginsExecute(r ApiGetPluginsRequest) ([]CSIPlug return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -396,7 +408,7 @@ func (a *PluginsApiService) GetPluginsExecute(r ApiGetPluginsRequest) ([]CSIPlug err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } diff --git a/clients/go/v1/api_regions.go b/clients/go/v1/api_regions.go index e6829f41..ed327631 100644 --- a/clients/go/v1/api_regions.go +++ b/clients/go/v1/api_regions.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -13,66 +13,63 @@ package client import ( "bytes" - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" + "context" + "io/ioutil" + "net/http" + "net/url" ) // Linger please var ( - _ _context.Context + _ context.Context ) // RegionsApiService RegionsApi service type RegionsApiService service type ApiGetRegionsRequest struct { - ctx _context.Context + ctx context.Context ApiService *RegionsApiService } -func (r ApiGetRegionsRequest) Execute() ([]string, *_nethttp.Response, error) { +func (r ApiGetRegionsRequest) Execute() ([]string, *http.Response, error) { return r.ApiService.GetRegionsExecute(r) } /* - * GetRegions Method for GetRegions - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiGetRegionsRequest - */ -func (a *RegionsApiService) GetRegions(ctx _context.Context) ApiGetRegionsRequest { +GetRegions Method for GetRegions + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiGetRegionsRequest +*/ +func (a *RegionsApiService) GetRegions(ctx context.Context) ApiGetRegionsRequest { return ApiGetRegionsRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return []string - */ -func (a *RegionsApiService) GetRegionsExecute(r ApiGetRegionsRequest) ([]string, *_nethttp.Response, error) { +// Execute executes the request +// @return []string +func (a *RegionsApiService) GetRegionsExecute(r ApiGetRegionsRequest) ([]string, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile localVarReturnValue []string ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "RegionsApiService.GetRegions") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/regions" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} // to determine the Content-Type header localVarHTTPContentTypes := []string{} @@ -105,7 +102,7 @@ func (a *RegionsApiService) GetRegionsExecute(r ApiGetRegionsRequest) ([]string, } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -115,15 +112,15 @@ func (a *RegionsApiService) GetRegionsExecute(r ApiGetRegionsRequest) ([]string, return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -132,7 +129,7 @@ func (a *RegionsApiService) GetRegionsExecute(r ApiGetRegionsRequest) ([]string, err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } diff --git a/clients/go/v1/api_scaling.go b/clients/go/v1/api_scaling.go index b8f26019..5e76c63d 100644 --- a/clients/go/v1/api_scaling.go +++ b/clients/go/v1/api_scaling.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -13,23 +13,23 @@ package client import ( "bytes" - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" + "context" + "io/ioutil" + "net/http" + "net/url" "strings" ) // Linger please var ( - _ _context.Context + _ context.Context ) // ScalingApiService ScalingApi service type ScalingApiService service type ApiGetScalingPoliciesRequest struct { - ctx _context.Context + ctx context.Context ApiService *ScalingApiService region *string namespace *string @@ -42,83 +42,89 @@ type ApiGetScalingPoliciesRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetScalingPoliciesRequest) Region(region string) ApiGetScalingPoliciesRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetScalingPoliciesRequest) Namespace(namespace string) ApiGetScalingPoliciesRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetScalingPoliciesRequest) Index(index int32) ApiGetScalingPoliciesRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetScalingPoliciesRequest) Wait(wait string) ApiGetScalingPoliciesRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetScalingPoliciesRequest) Stale(stale string) ApiGetScalingPoliciesRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetScalingPoliciesRequest) Prefix(prefix string) ApiGetScalingPoliciesRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetScalingPoliciesRequest) XNomadToken(xNomadToken string) ApiGetScalingPoliciesRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetScalingPoliciesRequest) PerPage(perPage int32) ApiGetScalingPoliciesRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetScalingPoliciesRequest) NextToken(nextToken string) ApiGetScalingPoliciesRequest { r.nextToken = &nextToken return r } -func (r ApiGetScalingPoliciesRequest) Execute() ([]ScalingPolicyListStub, *_nethttp.Response, error) { +func (r ApiGetScalingPoliciesRequest) Execute() ([]ScalingPolicyListStub, *http.Response, error) { return r.ApiService.GetScalingPoliciesExecute(r) } /* - * GetScalingPolicies Method for GetScalingPolicies - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiGetScalingPoliciesRequest - */ -func (a *ScalingApiService) GetScalingPolicies(ctx _context.Context) ApiGetScalingPoliciesRequest { +GetScalingPolicies Method for GetScalingPolicies + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiGetScalingPoliciesRequest +*/ +func (a *ScalingApiService) GetScalingPolicies(ctx context.Context) ApiGetScalingPoliciesRequest { return ApiGetScalingPoliciesRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return []ScalingPolicyListStub - */ -func (a *ScalingApiService) GetScalingPoliciesExecute(r ApiGetScalingPoliciesRequest) ([]ScalingPolicyListStub, *_nethttp.Response, error) { +// Execute executes the request +// @return []ScalingPolicyListStub +func (a *ScalingApiService) GetScalingPoliciesExecute(r ApiGetScalingPoliciesRequest) ([]ScalingPolicyListStub, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile localVarReturnValue []ScalingPolicyListStub ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ScalingApiService.GetScalingPolicies") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/scaling/policies" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -178,7 +184,7 @@ func (a *ScalingApiService) GetScalingPoliciesExecute(r ApiGetScalingPoliciesReq } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -188,15 +194,15 @@ func (a *ScalingApiService) GetScalingPoliciesExecute(r ApiGetScalingPoliciesReq return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -205,7 +211,7 @@ func (a *ScalingApiService) GetScalingPoliciesExecute(r ApiGetScalingPoliciesReq err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -216,7 +222,7 @@ func (a *ScalingApiService) GetScalingPoliciesExecute(r ApiGetScalingPoliciesReq } type ApiGetScalingPolicyRequest struct { - ctx _context.Context + ctx context.Context ApiService *ScalingApiService policyID string region *string @@ -230,54 +236,64 @@ type ApiGetScalingPolicyRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetScalingPolicyRequest) Region(region string) ApiGetScalingPolicyRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetScalingPolicyRequest) Namespace(namespace string) ApiGetScalingPolicyRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetScalingPolicyRequest) Index(index int32) ApiGetScalingPolicyRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetScalingPolicyRequest) Wait(wait string) ApiGetScalingPolicyRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetScalingPolicyRequest) Stale(stale string) ApiGetScalingPolicyRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetScalingPolicyRequest) Prefix(prefix string) ApiGetScalingPolicyRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetScalingPolicyRequest) XNomadToken(xNomadToken string) ApiGetScalingPolicyRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetScalingPolicyRequest) PerPage(perPage int32) ApiGetScalingPolicyRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetScalingPolicyRequest) NextToken(nextToken string) ApiGetScalingPolicyRequest { r.nextToken = &nextToken return r } -func (r ApiGetScalingPolicyRequest) Execute() (ScalingPolicy, *_nethttp.Response, error) { +func (r ApiGetScalingPolicyRequest) Execute() (*ScalingPolicy, *http.Response, error) { return r.ApiService.GetScalingPolicyExecute(r) } /* - * GetScalingPolicy Method for GetScalingPolicy - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param policyID The scaling policy identifier. - * @return ApiGetScalingPolicyRequest - */ -func (a *ScalingApiService) GetScalingPolicy(ctx _context.Context, policyID string) ApiGetScalingPolicyRequest { +GetScalingPolicy Method for GetScalingPolicy + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param policyID The scaling policy identifier. + @return ApiGetScalingPolicyRequest +*/ +func (a *ScalingApiService) GetScalingPolicy(ctx context.Context, policyID string) ApiGetScalingPolicyRequest { return ApiGetScalingPolicyRequest{ ApiService: a, ctx: ctx, @@ -285,31 +301,27 @@ func (a *ScalingApiService) GetScalingPolicy(ctx _context.Context, policyID stri } } -/* - * Execute executes the request - * @return ScalingPolicy - */ -func (a *ScalingApiService) GetScalingPolicyExecute(r ApiGetScalingPolicyRequest) (ScalingPolicy, *_nethttp.Response, error) { +// Execute executes the request +// @return ScalingPolicy +func (a *ScalingApiService) GetScalingPolicyExecute(r ApiGetScalingPolicyRequest) (*ScalingPolicy, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ScalingPolicy + formFiles []formFile + localVarReturnValue *ScalingPolicy ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ScalingApiService.GetScalingPolicy") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/scaling/policy/{policyID}" - localVarPath = strings.Replace(localVarPath, "{"+"policyID"+"}", _neturl.PathEscape(parameterToString(r.policyID, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"policyID"+"}", url.PathEscape(parameterToString(r.policyID, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -369,7 +381,7 @@ func (a *ScalingApiService) GetScalingPolicyExecute(r ApiGetScalingPolicyRequest } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -379,15 +391,15 @@ func (a *ScalingApiService) GetScalingPolicyExecute(r ApiGetScalingPolicyRequest return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -396,7 +408,7 @@ func (a *ScalingApiService) GetScalingPolicyExecute(r ApiGetScalingPolicyRequest err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } diff --git a/clients/go/v1/api_search.go b/clients/go/v1/api_search.go index 0544c91a..5222e918 100644 --- a/clients/go/v1/api_search.go +++ b/clients/go/v1/api_search.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -13,22 +13,22 @@ package client import ( "bytes" - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" + "context" + "io/ioutil" + "net/http" + "net/url" ) // Linger please var ( - _ _context.Context + _ context.Context ) // SearchApiService SearchApi service type SearchApiService service type ApiGetFuzzySearchRequest struct { - ctx _context.Context + ctx context.Context ApiService *SearchApiService fuzzySearchRequest *FuzzySearchRequest region *string @@ -46,83 +46,89 @@ func (r ApiGetFuzzySearchRequest) FuzzySearchRequest(fuzzySearchRequest FuzzySea r.fuzzySearchRequest = &fuzzySearchRequest return r } +// Filters results based on the specified region. func (r ApiGetFuzzySearchRequest) Region(region string) ApiGetFuzzySearchRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetFuzzySearchRequest) Namespace(namespace string) ApiGetFuzzySearchRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetFuzzySearchRequest) Index(index int32) ApiGetFuzzySearchRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetFuzzySearchRequest) Wait(wait string) ApiGetFuzzySearchRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetFuzzySearchRequest) Stale(stale string) ApiGetFuzzySearchRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetFuzzySearchRequest) Prefix(prefix string) ApiGetFuzzySearchRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetFuzzySearchRequest) XNomadToken(xNomadToken string) ApiGetFuzzySearchRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetFuzzySearchRequest) PerPage(perPage int32) ApiGetFuzzySearchRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetFuzzySearchRequest) NextToken(nextToken string) ApiGetFuzzySearchRequest { r.nextToken = &nextToken return r } -func (r ApiGetFuzzySearchRequest) Execute() (FuzzySearchResponse, *_nethttp.Response, error) { +func (r ApiGetFuzzySearchRequest) Execute() (*FuzzySearchResponse, *http.Response, error) { return r.ApiService.GetFuzzySearchExecute(r) } /* - * GetFuzzySearch Method for GetFuzzySearch - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiGetFuzzySearchRequest - */ -func (a *SearchApiService) GetFuzzySearch(ctx _context.Context) ApiGetFuzzySearchRequest { +GetFuzzySearch Method for GetFuzzySearch + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiGetFuzzySearchRequest +*/ +func (a *SearchApiService) GetFuzzySearch(ctx context.Context) ApiGetFuzzySearchRequest { return ApiGetFuzzySearchRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return FuzzySearchResponse - */ -func (a *SearchApiService) GetFuzzySearchExecute(r ApiGetFuzzySearchRequest) (FuzzySearchResponse, *_nethttp.Response, error) { +// Execute executes the request +// @return FuzzySearchResponse +func (a *SearchApiService) GetFuzzySearchExecute(r ApiGetFuzzySearchRequest) (*FuzzySearchResponse, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue FuzzySearchResponse + formFiles []formFile + localVarReturnValue *FuzzySearchResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "SearchApiService.GetFuzzySearch") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/search/fuzzy" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.fuzzySearchRequest == nil { return localVarReturnValue, nil, reportError("fuzzySearchRequest is required and must be specified") } @@ -187,7 +193,7 @@ func (a *SearchApiService) GetFuzzySearchExecute(r ApiGetFuzzySearchRequest) (Fu } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -197,15 +203,15 @@ func (a *SearchApiService) GetFuzzySearchExecute(r ApiGetFuzzySearchRequest) (Fu return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -214,7 +220,7 @@ func (a *SearchApiService) GetFuzzySearchExecute(r ApiGetFuzzySearchRequest) (Fu err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -225,7 +231,7 @@ func (a *SearchApiService) GetFuzzySearchExecute(r ApiGetFuzzySearchRequest) (Fu } type ApiGetSearchRequest struct { - ctx _context.Context + ctx context.Context ApiService *SearchApiService searchRequest *SearchRequest region *string @@ -243,83 +249,89 @@ func (r ApiGetSearchRequest) SearchRequest(searchRequest SearchRequest) ApiGetSe r.searchRequest = &searchRequest return r } +// Filters results based on the specified region. func (r ApiGetSearchRequest) Region(region string) ApiGetSearchRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetSearchRequest) Namespace(namespace string) ApiGetSearchRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetSearchRequest) Index(index int32) ApiGetSearchRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetSearchRequest) Wait(wait string) ApiGetSearchRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetSearchRequest) Stale(stale string) ApiGetSearchRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetSearchRequest) Prefix(prefix string) ApiGetSearchRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetSearchRequest) XNomadToken(xNomadToken string) ApiGetSearchRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetSearchRequest) PerPage(perPage int32) ApiGetSearchRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetSearchRequest) NextToken(nextToken string) ApiGetSearchRequest { r.nextToken = &nextToken return r } -func (r ApiGetSearchRequest) Execute() (SearchResponse, *_nethttp.Response, error) { +func (r ApiGetSearchRequest) Execute() (*SearchResponse, *http.Response, error) { return r.ApiService.GetSearchExecute(r) } /* - * GetSearch Method for GetSearch - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiGetSearchRequest - */ -func (a *SearchApiService) GetSearch(ctx _context.Context) ApiGetSearchRequest { +GetSearch Method for GetSearch + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiGetSearchRequest +*/ +func (a *SearchApiService) GetSearch(ctx context.Context) ApiGetSearchRequest { return ApiGetSearchRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return SearchResponse - */ -func (a *SearchApiService) GetSearchExecute(r ApiGetSearchRequest) (SearchResponse, *_nethttp.Response, error) { +// Execute executes the request +// @return SearchResponse +func (a *SearchApiService) GetSearchExecute(r ApiGetSearchRequest) (*SearchResponse, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue SearchResponse + formFiles []formFile + localVarReturnValue *SearchResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "SearchApiService.GetSearch") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/search" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.searchRequest == nil { return localVarReturnValue, nil, reportError("searchRequest is required and must be specified") } @@ -384,7 +396,7 @@ func (a *SearchApiService) GetSearchExecute(r ApiGetSearchRequest) (SearchRespon } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -394,15 +406,15 @@ func (a *SearchApiService) GetSearchExecute(r ApiGetSearchRequest) (SearchRespon return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -411,7 +423,7 @@ func (a *SearchApiService) GetSearchExecute(r ApiGetSearchRequest) (SearchRespon err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } diff --git a/clients/go/v1/api_status.go b/clients/go/v1/api_status.go index 49c546fd..21460b19 100644 --- a/clients/go/v1/api_status.go +++ b/clients/go/v1/api_status.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -13,22 +13,22 @@ package client import ( "bytes" - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" + "context" + "io/ioutil" + "net/http" + "net/url" ) // Linger please var ( - _ _context.Context + _ context.Context ) // StatusApiService StatusApi service type StatusApiService service type ApiGetStatusLeaderRequest struct { - ctx _context.Context + ctx context.Context ApiService *StatusApiService region *string namespace *string @@ -41,83 +41,89 @@ type ApiGetStatusLeaderRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetStatusLeaderRequest) Region(region string) ApiGetStatusLeaderRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetStatusLeaderRequest) Namespace(namespace string) ApiGetStatusLeaderRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetStatusLeaderRequest) Index(index int32) ApiGetStatusLeaderRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetStatusLeaderRequest) Wait(wait string) ApiGetStatusLeaderRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetStatusLeaderRequest) Stale(stale string) ApiGetStatusLeaderRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetStatusLeaderRequest) Prefix(prefix string) ApiGetStatusLeaderRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetStatusLeaderRequest) XNomadToken(xNomadToken string) ApiGetStatusLeaderRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetStatusLeaderRequest) PerPage(perPage int32) ApiGetStatusLeaderRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetStatusLeaderRequest) NextToken(nextToken string) ApiGetStatusLeaderRequest { r.nextToken = &nextToken return r } -func (r ApiGetStatusLeaderRequest) Execute() (string, *_nethttp.Response, error) { +func (r ApiGetStatusLeaderRequest) Execute() (string, *http.Response, error) { return r.ApiService.GetStatusLeaderExecute(r) } /* - * GetStatusLeader Method for GetStatusLeader - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiGetStatusLeaderRequest - */ -func (a *StatusApiService) GetStatusLeader(ctx _context.Context) ApiGetStatusLeaderRequest { +GetStatusLeader Method for GetStatusLeader + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiGetStatusLeaderRequest +*/ +func (a *StatusApiService) GetStatusLeader(ctx context.Context) ApiGetStatusLeaderRequest { return ApiGetStatusLeaderRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return string - */ -func (a *StatusApiService) GetStatusLeaderExecute(r ApiGetStatusLeaderRequest) (string, *_nethttp.Response, error) { +// Execute executes the request +// @return string +func (a *StatusApiService) GetStatusLeaderExecute(r ApiGetStatusLeaderRequest) (string, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile localVarReturnValue string ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "StatusApiService.GetStatusLeader") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/status/leader" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -177,7 +183,7 @@ func (a *StatusApiService) GetStatusLeaderExecute(r ApiGetStatusLeaderRequest) ( } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -187,15 +193,15 @@ func (a *StatusApiService) GetStatusLeaderExecute(r ApiGetStatusLeaderRequest) ( return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -204,7 +210,7 @@ func (a *StatusApiService) GetStatusLeaderExecute(r ApiGetStatusLeaderRequest) ( err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -215,7 +221,7 @@ func (a *StatusApiService) GetStatusLeaderExecute(r ApiGetStatusLeaderRequest) ( } type ApiGetStatusPeersRequest struct { - ctx _context.Context + ctx context.Context ApiService *StatusApiService region *string namespace *string @@ -228,83 +234,89 @@ type ApiGetStatusPeersRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetStatusPeersRequest) Region(region string) ApiGetStatusPeersRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetStatusPeersRequest) Namespace(namespace string) ApiGetStatusPeersRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetStatusPeersRequest) Index(index int32) ApiGetStatusPeersRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetStatusPeersRequest) Wait(wait string) ApiGetStatusPeersRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetStatusPeersRequest) Stale(stale string) ApiGetStatusPeersRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetStatusPeersRequest) Prefix(prefix string) ApiGetStatusPeersRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetStatusPeersRequest) XNomadToken(xNomadToken string) ApiGetStatusPeersRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetStatusPeersRequest) PerPage(perPage int32) ApiGetStatusPeersRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetStatusPeersRequest) NextToken(nextToken string) ApiGetStatusPeersRequest { r.nextToken = &nextToken return r } -func (r ApiGetStatusPeersRequest) Execute() ([]string, *_nethttp.Response, error) { +func (r ApiGetStatusPeersRequest) Execute() ([]string, *http.Response, error) { return r.ApiService.GetStatusPeersExecute(r) } /* - * GetStatusPeers Method for GetStatusPeers - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiGetStatusPeersRequest - */ -func (a *StatusApiService) GetStatusPeers(ctx _context.Context) ApiGetStatusPeersRequest { +GetStatusPeers Method for GetStatusPeers + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiGetStatusPeersRequest +*/ +func (a *StatusApiService) GetStatusPeers(ctx context.Context) ApiGetStatusPeersRequest { return ApiGetStatusPeersRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return []string - */ -func (a *StatusApiService) GetStatusPeersExecute(r ApiGetStatusPeersRequest) ([]string, *_nethttp.Response, error) { +// Execute executes the request +// @return []string +func (a *StatusApiService) GetStatusPeersExecute(r ApiGetStatusPeersRequest) ([]string, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile localVarReturnValue []string ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "StatusApiService.GetStatusPeers") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/status/peers" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -364,7 +376,7 @@ func (a *StatusApiService) GetStatusPeersExecute(r ApiGetStatusPeersRequest) ([] } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -374,15 +386,15 @@ func (a *StatusApiService) GetStatusPeersExecute(r ApiGetStatusPeersRequest) ([] return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -391,7 +403,7 @@ func (a *StatusApiService) GetStatusPeersExecute(r ApiGetStatusPeersRequest) ([] err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } diff --git a/clients/go/v1/api_system.go b/clients/go/v1/api_system.go index 3a9273c8..1da480b0 100644 --- a/clients/go/v1/api_system.go +++ b/clients/go/v1/api_system.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -13,22 +13,22 @@ package client import ( "bytes" - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" + "context" + "io/ioutil" + "net/http" + "net/url" ) // Linger please var ( - _ _context.Context + _ context.Context ) // SystemApiService SystemApi service type SystemApiService service type ApiPutSystemGCRequest struct { - ctx _context.Context + ctx context.Context ApiService *SystemApiService region *string namespace *string @@ -36,61 +36,62 @@ type ApiPutSystemGCRequest struct { idempotencyToken *string } +// Filters results based on the specified region. func (r ApiPutSystemGCRequest) Region(region string) ApiPutSystemGCRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiPutSystemGCRequest) Namespace(namespace string) ApiPutSystemGCRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiPutSystemGCRequest) XNomadToken(xNomadToken string) ApiPutSystemGCRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiPutSystemGCRequest) IdempotencyToken(idempotencyToken string) ApiPutSystemGCRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiPutSystemGCRequest) Execute() (*_nethttp.Response, error) { +func (r ApiPutSystemGCRequest) Execute() (*http.Response, error) { return r.ApiService.PutSystemGCExecute(r) } /* - * PutSystemGC Method for PutSystemGC - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiPutSystemGCRequest - */ -func (a *SystemApiService) PutSystemGC(ctx _context.Context) ApiPutSystemGCRequest { +PutSystemGC Method for PutSystemGC + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiPutSystemGCRequest +*/ +func (a *SystemApiService) PutSystemGC(ctx context.Context) ApiPutSystemGCRequest { return ApiPutSystemGCRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - */ -func (a *SystemApiService) PutSystemGCExecute(r ApiPutSystemGCRequest) (*_nethttp.Response, error) { +// Execute executes the request +func (a *SystemApiService) PutSystemGCExecute(r ApiPutSystemGCRequest) (*http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPut + localVarHTTPMethod = http.MethodPut localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "SystemApiService.PutSystemGC") if err != nil { - return nil, GenericOpenAPIError{error: err.Error()} + return nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/system/gc" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -135,7 +136,7 @@ func (a *SystemApiService) PutSystemGCExecute(r ApiPutSystemGCRequest) (*_nethtt } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return nil, err } @@ -145,15 +146,15 @@ func (a *SystemApiService) PutSystemGCExecute(r ApiPutSystemGCRequest) (*_nethtt return localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -164,7 +165,7 @@ func (a *SystemApiService) PutSystemGCExecute(r ApiPutSystemGCRequest) (*_nethtt } type ApiPutSystemReconcileSummariesRequest struct { - ctx _context.Context + ctx context.Context ApiService *SystemApiService region *string namespace *string @@ -172,61 +173,62 @@ type ApiPutSystemReconcileSummariesRequest struct { idempotencyToken *string } +// Filters results based on the specified region. func (r ApiPutSystemReconcileSummariesRequest) Region(region string) ApiPutSystemReconcileSummariesRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiPutSystemReconcileSummariesRequest) Namespace(namespace string) ApiPutSystemReconcileSummariesRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiPutSystemReconcileSummariesRequest) XNomadToken(xNomadToken string) ApiPutSystemReconcileSummariesRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiPutSystemReconcileSummariesRequest) IdempotencyToken(idempotencyToken string) ApiPutSystemReconcileSummariesRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiPutSystemReconcileSummariesRequest) Execute() (*_nethttp.Response, error) { +func (r ApiPutSystemReconcileSummariesRequest) Execute() (*http.Response, error) { return r.ApiService.PutSystemReconcileSummariesExecute(r) } /* - * PutSystemReconcileSummaries Method for PutSystemReconcileSummaries - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiPutSystemReconcileSummariesRequest - */ -func (a *SystemApiService) PutSystemReconcileSummaries(ctx _context.Context) ApiPutSystemReconcileSummariesRequest { +PutSystemReconcileSummaries Method for PutSystemReconcileSummaries + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiPutSystemReconcileSummariesRequest +*/ +func (a *SystemApiService) PutSystemReconcileSummaries(ctx context.Context) ApiPutSystemReconcileSummariesRequest { return ApiPutSystemReconcileSummariesRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - */ -func (a *SystemApiService) PutSystemReconcileSummariesExecute(r ApiPutSystemReconcileSummariesRequest) (*_nethttp.Response, error) { +// Execute executes the request +func (a *SystemApiService) PutSystemReconcileSummariesExecute(r ApiPutSystemReconcileSummariesRequest) (*http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPut + localVarHTTPMethod = http.MethodPut localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "SystemApiService.PutSystemReconcileSummaries") if err != nil { - return nil, GenericOpenAPIError{error: err.Error()} + return nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/system/reconcile/summaries" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -271,7 +273,7 @@ func (a *SystemApiService) PutSystemReconcileSummariesExecute(r ApiPutSystemReco } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return nil, err } @@ -281,15 +283,15 @@ func (a *SystemApiService) PutSystemReconcileSummariesExecute(r ApiPutSystemReco return localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } diff --git a/clients/go/v1/api_volumes.go b/clients/go/v1/api_volumes.go index 70a70346..54e48a48 100644 --- a/clients/go/v1/api_volumes.go +++ b/clients/go/v1/api_volumes.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -13,23 +13,23 @@ package client import ( "bytes" - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" + "context" + "io/ioutil" + "net/http" + "net/url" "strings" ) // Linger please var ( - _ _context.Context + _ context.Context ) // VolumesApiService VolumesApi service type VolumesApiService service type ApiCreateVolumeRequest struct { - ctx _context.Context + ctx context.Context ApiService *VolumesApiService volumeId string action string @@ -44,35 +44,40 @@ func (r ApiCreateVolumeRequest) CSIVolumeCreateRequest(cSIVolumeCreateRequest CS r.cSIVolumeCreateRequest = &cSIVolumeCreateRequest return r } +// Filters results based on the specified region. func (r ApiCreateVolumeRequest) Region(region string) ApiCreateVolumeRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiCreateVolumeRequest) Namespace(namespace string) ApiCreateVolumeRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiCreateVolumeRequest) XNomadToken(xNomadToken string) ApiCreateVolumeRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiCreateVolumeRequest) IdempotencyToken(idempotencyToken string) ApiCreateVolumeRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiCreateVolumeRequest) Execute() (*_nethttp.Response, error) { +func (r ApiCreateVolumeRequest) Execute() (*http.Response, error) { return r.ApiService.CreateVolumeExecute(r) } /* - * CreateVolume Method for CreateVolume - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param volumeId Volume unique identifier. - * @param action The action to perform on the Volume (create, detach, delete). - * @return ApiCreateVolumeRequest - */ -func (a *VolumesApiService) CreateVolume(ctx _context.Context, volumeId string, action string) ApiCreateVolumeRequest { +CreateVolume Method for CreateVolume + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param volumeId Volume unique identifier. + @param action The action to perform on the Volume (create, detach, delete). + @return ApiCreateVolumeRequest +*/ +func (a *VolumesApiService) CreateVolume(ctx context.Context, volumeId string, action string) ApiCreateVolumeRequest { return ApiCreateVolumeRequest{ ApiService: a, ctx: ctx, @@ -81,30 +86,26 @@ func (a *VolumesApiService) CreateVolume(ctx _context.Context, volumeId string, } } -/* - * Execute executes the request - */ -func (a *VolumesApiService) CreateVolumeExecute(r ApiCreateVolumeRequest) (*_nethttp.Response, error) { +// Execute executes the request +func (a *VolumesApiService) CreateVolumeExecute(r ApiCreateVolumeRequest) (*http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VolumesApiService.CreateVolume") if err != nil { - return nil, GenericOpenAPIError{error: err.Error()} + return nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/volume/csi/{volumeId}/{action}" - localVarPath = strings.Replace(localVarPath, "{"+"volumeId"+"}", _neturl.PathEscape(parameterToString(r.volumeId, "")), -1) - localVarPath = strings.Replace(localVarPath, "{"+"action"+"}", _neturl.PathEscape(parameterToString(r.action, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"volumeId"+"}", url.PathEscape(parameterToString(r.volumeId, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"action"+"}", url.PathEscape(parameterToString(r.action, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.cSIVolumeCreateRequest == nil { return nil, reportError("cSIVolumeCreateRequest is required and must be specified") } @@ -154,7 +155,7 @@ func (a *VolumesApiService) CreateVolumeExecute(r ApiCreateVolumeRequest) (*_net } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return nil, err } @@ -164,15 +165,15 @@ func (a *VolumesApiService) CreateVolumeExecute(r ApiCreateVolumeRequest) (*_net return localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -183,7 +184,7 @@ func (a *VolumesApiService) CreateVolumeExecute(r ApiCreateVolumeRequest) (*_net } type ApiDeleteSnapshotRequest struct { - ctx _context.Context + ctx context.Context ApiService *VolumesApiService region *string namespace *string @@ -193,69 +194,72 @@ type ApiDeleteSnapshotRequest struct { snapshotId *string } +// Filters results based on the specified region. func (r ApiDeleteSnapshotRequest) Region(region string) ApiDeleteSnapshotRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiDeleteSnapshotRequest) Namespace(namespace string) ApiDeleteSnapshotRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiDeleteSnapshotRequest) XNomadToken(xNomadToken string) ApiDeleteSnapshotRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiDeleteSnapshotRequest) IdempotencyToken(idempotencyToken string) ApiDeleteSnapshotRequest { r.idempotencyToken = &idempotencyToken return r } +// Filters volume lists by plugin ID. func (r ApiDeleteSnapshotRequest) PluginId(pluginId string) ApiDeleteSnapshotRequest { r.pluginId = &pluginId return r } +// The ID of the snapshot to target. func (r ApiDeleteSnapshotRequest) SnapshotId(snapshotId string) ApiDeleteSnapshotRequest { r.snapshotId = &snapshotId return r } -func (r ApiDeleteSnapshotRequest) Execute() (*_nethttp.Response, error) { +func (r ApiDeleteSnapshotRequest) Execute() (*http.Response, error) { return r.ApiService.DeleteSnapshotExecute(r) } /* - * DeleteSnapshot Method for DeleteSnapshot - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiDeleteSnapshotRequest - */ -func (a *VolumesApiService) DeleteSnapshot(ctx _context.Context) ApiDeleteSnapshotRequest { +DeleteSnapshot Method for DeleteSnapshot + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiDeleteSnapshotRequest +*/ +func (a *VolumesApiService) DeleteSnapshot(ctx context.Context) ApiDeleteSnapshotRequest { return ApiDeleteSnapshotRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - */ -func (a *VolumesApiService) DeleteSnapshotExecute(r ApiDeleteSnapshotRequest) (*_nethttp.Response, error) { +// Execute executes the request +func (a *VolumesApiService) DeleteSnapshotExecute(r ApiDeleteSnapshotRequest) (*http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodDelete + localVarHTTPMethod = http.MethodDelete localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VolumesApiService.DeleteSnapshot") if err != nil { - return nil, GenericOpenAPIError{error: err.Error()} + return nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/volumes/snapshot" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -306,7 +310,7 @@ func (a *VolumesApiService) DeleteSnapshotExecute(r ApiDeleteSnapshotRequest) (* } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return nil, err } @@ -316,15 +320,15 @@ func (a *VolumesApiService) DeleteSnapshotExecute(r ApiDeleteSnapshotRequest) (* return localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -335,7 +339,7 @@ func (a *VolumesApiService) DeleteSnapshotExecute(r ApiDeleteSnapshotRequest) (* } type ApiDeleteVolumeRegistrationRequest struct { - ctx _context.Context + ctx context.Context ApiService *VolumesApiService volumeId string region *string @@ -345,38 +349,44 @@ type ApiDeleteVolumeRegistrationRequest struct { force *string } +// Filters results based on the specified region. func (r ApiDeleteVolumeRegistrationRequest) Region(region string) ApiDeleteVolumeRegistrationRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiDeleteVolumeRegistrationRequest) Namespace(namespace string) ApiDeleteVolumeRegistrationRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiDeleteVolumeRegistrationRequest) XNomadToken(xNomadToken string) ApiDeleteVolumeRegistrationRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiDeleteVolumeRegistrationRequest) IdempotencyToken(idempotencyToken string) ApiDeleteVolumeRegistrationRequest { r.idempotencyToken = &idempotencyToken return r } +// Used to force the de-registration of a volume. func (r ApiDeleteVolumeRegistrationRequest) Force(force string) ApiDeleteVolumeRegistrationRequest { r.force = &force return r } -func (r ApiDeleteVolumeRegistrationRequest) Execute() (*_nethttp.Response, error) { +func (r ApiDeleteVolumeRegistrationRequest) Execute() (*http.Response, error) { return r.ApiService.DeleteVolumeRegistrationExecute(r) } /* - * DeleteVolumeRegistration Method for DeleteVolumeRegistration - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param volumeId Volume unique identifier. - * @return ApiDeleteVolumeRegistrationRequest - */ -func (a *VolumesApiService) DeleteVolumeRegistration(ctx _context.Context, volumeId string) ApiDeleteVolumeRegistrationRequest { +DeleteVolumeRegistration Method for DeleteVolumeRegistration + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param volumeId Volume unique identifier. + @return ApiDeleteVolumeRegistrationRequest +*/ +func (a *VolumesApiService) DeleteVolumeRegistration(ctx context.Context, volumeId string) ApiDeleteVolumeRegistrationRequest { return ApiDeleteVolumeRegistrationRequest{ ApiService: a, ctx: ctx, @@ -384,29 +394,25 @@ func (a *VolumesApiService) DeleteVolumeRegistration(ctx _context.Context, volum } } -/* - * Execute executes the request - */ -func (a *VolumesApiService) DeleteVolumeRegistrationExecute(r ApiDeleteVolumeRegistrationRequest) (*_nethttp.Response, error) { +// Execute executes the request +func (a *VolumesApiService) DeleteVolumeRegistrationExecute(r ApiDeleteVolumeRegistrationRequest) (*http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodDelete + localVarHTTPMethod = http.MethodDelete localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VolumesApiService.DeleteVolumeRegistration") if err != nil { - return nil, GenericOpenAPIError{error: err.Error()} + return nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/volume/csi/{volumeId}" - localVarPath = strings.Replace(localVarPath, "{"+"volumeId"+"}", _neturl.PathEscape(parameterToString(r.volumeId, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"volumeId"+"}", url.PathEscape(parameterToString(r.volumeId, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -454,7 +460,7 @@ func (a *VolumesApiService) DeleteVolumeRegistrationExecute(r ApiDeleteVolumeReg } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return nil, err } @@ -464,15 +470,15 @@ func (a *VolumesApiService) DeleteVolumeRegistrationExecute(r ApiDeleteVolumeReg return localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -483,7 +489,7 @@ func (a *VolumesApiService) DeleteVolumeRegistrationExecute(r ApiDeleteVolumeReg } type ApiDetachOrDeleteVolumeRequest struct { - ctx _context.Context + ctx context.Context ApiService *VolumesApiService volumeId string action string @@ -494,39 +500,45 @@ type ApiDetachOrDeleteVolumeRequest struct { node *string } +// Filters results based on the specified region. func (r ApiDetachOrDeleteVolumeRequest) Region(region string) ApiDetachOrDeleteVolumeRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiDetachOrDeleteVolumeRequest) Namespace(namespace string) ApiDetachOrDeleteVolumeRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiDetachOrDeleteVolumeRequest) XNomadToken(xNomadToken string) ApiDetachOrDeleteVolumeRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiDetachOrDeleteVolumeRequest) IdempotencyToken(idempotencyToken string) ApiDetachOrDeleteVolumeRequest { r.idempotencyToken = &idempotencyToken return r } +// Specifies node to target volume operation for. func (r ApiDetachOrDeleteVolumeRequest) Node(node string) ApiDetachOrDeleteVolumeRequest { r.node = &node return r } -func (r ApiDetachOrDeleteVolumeRequest) Execute() (*_nethttp.Response, error) { +func (r ApiDetachOrDeleteVolumeRequest) Execute() (*http.Response, error) { return r.ApiService.DetachOrDeleteVolumeExecute(r) } /* - * DetachOrDeleteVolume Method for DetachOrDeleteVolume - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param volumeId Volume unique identifier. - * @param action The action to perform on the Volume (create, detach, delete). - * @return ApiDetachOrDeleteVolumeRequest - */ -func (a *VolumesApiService) DetachOrDeleteVolume(ctx _context.Context, volumeId string, action string) ApiDetachOrDeleteVolumeRequest { +DetachOrDeleteVolume Method for DetachOrDeleteVolume + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param volumeId Volume unique identifier. + @param action The action to perform on the Volume (create, detach, delete). + @return ApiDetachOrDeleteVolumeRequest +*/ +func (a *VolumesApiService) DetachOrDeleteVolume(ctx context.Context, volumeId string, action string) ApiDetachOrDeleteVolumeRequest { return ApiDetachOrDeleteVolumeRequest{ ApiService: a, ctx: ctx, @@ -535,30 +547,26 @@ func (a *VolumesApiService) DetachOrDeleteVolume(ctx _context.Context, volumeId } } -/* - * Execute executes the request - */ -func (a *VolumesApiService) DetachOrDeleteVolumeExecute(r ApiDetachOrDeleteVolumeRequest) (*_nethttp.Response, error) { +// Execute executes the request +func (a *VolumesApiService) DetachOrDeleteVolumeExecute(r ApiDetachOrDeleteVolumeRequest) (*http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodDelete + localVarHTTPMethod = http.MethodDelete localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VolumesApiService.DetachOrDeleteVolume") if err != nil { - return nil, GenericOpenAPIError{error: err.Error()} + return nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/volume/csi/{volumeId}/{action}" - localVarPath = strings.Replace(localVarPath, "{"+"volumeId"+"}", _neturl.PathEscape(parameterToString(r.volumeId, "")), -1) - localVarPath = strings.Replace(localVarPath, "{"+"action"+"}", _neturl.PathEscape(parameterToString(r.action, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"volumeId"+"}", url.PathEscape(parameterToString(r.volumeId, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"action"+"}", url.PathEscape(parameterToString(r.action, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -606,7 +614,7 @@ func (a *VolumesApiService) DetachOrDeleteVolumeExecute(r ApiDetachOrDeleteVolum } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return nil, err } @@ -616,15 +624,15 @@ func (a *VolumesApiService) DetachOrDeleteVolumeExecute(r ApiDetachOrDeleteVolum return localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -635,7 +643,7 @@ func (a *VolumesApiService) DetachOrDeleteVolumeExecute(r ApiDetachOrDeleteVolum } type ApiGetExternalVolumesRequest struct { - ctx _context.Context + ctx context.Context ApiService *VolumesApiService region *string namespace *string @@ -649,87 +657,94 @@ type ApiGetExternalVolumesRequest struct { pluginId *string } +// Filters results based on the specified region. func (r ApiGetExternalVolumesRequest) Region(region string) ApiGetExternalVolumesRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetExternalVolumesRequest) Namespace(namespace string) ApiGetExternalVolumesRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetExternalVolumesRequest) Index(index int32) ApiGetExternalVolumesRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetExternalVolumesRequest) Wait(wait string) ApiGetExternalVolumesRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetExternalVolumesRequest) Stale(stale string) ApiGetExternalVolumesRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetExternalVolumesRequest) Prefix(prefix string) ApiGetExternalVolumesRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetExternalVolumesRequest) XNomadToken(xNomadToken string) ApiGetExternalVolumesRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetExternalVolumesRequest) PerPage(perPage int32) ApiGetExternalVolumesRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetExternalVolumesRequest) NextToken(nextToken string) ApiGetExternalVolumesRequest { r.nextToken = &nextToken return r } +// Filters volume lists by plugin ID. func (r ApiGetExternalVolumesRequest) PluginId(pluginId string) ApiGetExternalVolumesRequest { r.pluginId = &pluginId return r } -func (r ApiGetExternalVolumesRequest) Execute() (CSIVolumeListExternalResponse, *_nethttp.Response, error) { +func (r ApiGetExternalVolumesRequest) Execute() (*CSIVolumeListExternalResponse, *http.Response, error) { return r.ApiService.GetExternalVolumesExecute(r) } /* - * GetExternalVolumes Method for GetExternalVolumes - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiGetExternalVolumesRequest - */ -func (a *VolumesApiService) GetExternalVolumes(ctx _context.Context) ApiGetExternalVolumesRequest { +GetExternalVolumes Method for GetExternalVolumes + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiGetExternalVolumesRequest +*/ +func (a *VolumesApiService) GetExternalVolumes(ctx context.Context) ApiGetExternalVolumesRequest { return ApiGetExternalVolumesRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return CSIVolumeListExternalResponse - */ -func (a *VolumesApiService) GetExternalVolumesExecute(r ApiGetExternalVolumesRequest) (CSIVolumeListExternalResponse, *_nethttp.Response, error) { +// Execute executes the request +// @return CSIVolumeListExternalResponse +func (a *VolumesApiService) GetExternalVolumesExecute(r ApiGetExternalVolumesRequest) (*CSIVolumeListExternalResponse, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CSIVolumeListExternalResponse + formFiles []formFile + localVarReturnValue *CSIVolumeListExternalResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VolumesApiService.GetExternalVolumes") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/volumes/external" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -792,7 +807,7 @@ func (a *VolumesApiService) GetExternalVolumesExecute(r ApiGetExternalVolumesReq } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -802,15 +817,15 @@ func (a *VolumesApiService) GetExternalVolumesExecute(r ApiGetExternalVolumesReq return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -819,7 +834,7 @@ func (a *VolumesApiService) GetExternalVolumesExecute(r ApiGetExternalVolumesReq err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -830,7 +845,7 @@ func (a *VolumesApiService) GetExternalVolumesExecute(r ApiGetExternalVolumesReq } type ApiGetSnapshotsRequest struct { - ctx _context.Context + ctx context.Context ApiService *VolumesApiService region *string namespace *string @@ -844,87 +859,94 @@ type ApiGetSnapshotsRequest struct { pluginId *string } +// Filters results based on the specified region. func (r ApiGetSnapshotsRequest) Region(region string) ApiGetSnapshotsRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetSnapshotsRequest) Namespace(namespace string) ApiGetSnapshotsRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetSnapshotsRequest) Index(index int32) ApiGetSnapshotsRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetSnapshotsRequest) Wait(wait string) ApiGetSnapshotsRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetSnapshotsRequest) Stale(stale string) ApiGetSnapshotsRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetSnapshotsRequest) Prefix(prefix string) ApiGetSnapshotsRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetSnapshotsRequest) XNomadToken(xNomadToken string) ApiGetSnapshotsRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetSnapshotsRequest) PerPage(perPage int32) ApiGetSnapshotsRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetSnapshotsRequest) NextToken(nextToken string) ApiGetSnapshotsRequest { r.nextToken = &nextToken return r } +// Filters volume lists by plugin ID. func (r ApiGetSnapshotsRequest) PluginId(pluginId string) ApiGetSnapshotsRequest { r.pluginId = &pluginId return r } -func (r ApiGetSnapshotsRequest) Execute() (CSISnapshotListResponse, *_nethttp.Response, error) { +func (r ApiGetSnapshotsRequest) Execute() (*CSISnapshotListResponse, *http.Response, error) { return r.ApiService.GetSnapshotsExecute(r) } /* - * GetSnapshots Method for GetSnapshots - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiGetSnapshotsRequest - */ -func (a *VolumesApiService) GetSnapshots(ctx _context.Context) ApiGetSnapshotsRequest { +GetSnapshots Method for GetSnapshots + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiGetSnapshotsRequest +*/ +func (a *VolumesApiService) GetSnapshots(ctx context.Context) ApiGetSnapshotsRequest { return ApiGetSnapshotsRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return CSISnapshotListResponse - */ -func (a *VolumesApiService) GetSnapshotsExecute(r ApiGetSnapshotsRequest) (CSISnapshotListResponse, *_nethttp.Response, error) { +// Execute executes the request +// @return CSISnapshotListResponse +func (a *VolumesApiService) GetSnapshotsExecute(r ApiGetSnapshotsRequest) (*CSISnapshotListResponse, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CSISnapshotListResponse + formFiles []formFile + localVarReturnValue *CSISnapshotListResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VolumesApiService.GetSnapshots") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/volumes/snapshot" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -987,7 +1009,7 @@ func (a *VolumesApiService) GetSnapshotsExecute(r ApiGetSnapshotsRequest) (CSISn } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -997,15 +1019,15 @@ func (a *VolumesApiService) GetSnapshotsExecute(r ApiGetSnapshotsRequest) (CSISn return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -1014,7 +1036,7 @@ func (a *VolumesApiService) GetSnapshotsExecute(r ApiGetSnapshotsRequest) (CSISn err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -1025,7 +1047,7 @@ func (a *VolumesApiService) GetSnapshotsExecute(r ApiGetSnapshotsRequest) (CSISn } type ApiGetVolumeRequest struct { - ctx _context.Context + ctx context.Context ApiService *VolumesApiService volumeId string region *string @@ -1039,54 +1061,64 @@ type ApiGetVolumeRequest struct { nextToken *string } +// Filters results based on the specified region. func (r ApiGetVolumeRequest) Region(region string) ApiGetVolumeRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetVolumeRequest) Namespace(namespace string) ApiGetVolumeRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetVolumeRequest) Index(index int32) ApiGetVolumeRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetVolumeRequest) Wait(wait string) ApiGetVolumeRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetVolumeRequest) Stale(stale string) ApiGetVolumeRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetVolumeRequest) Prefix(prefix string) ApiGetVolumeRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetVolumeRequest) XNomadToken(xNomadToken string) ApiGetVolumeRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetVolumeRequest) PerPage(perPage int32) ApiGetVolumeRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetVolumeRequest) NextToken(nextToken string) ApiGetVolumeRequest { r.nextToken = &nextToken return r } -func (r ApiGetVolumeRequest) Execute() (CSIVolume, *_nethttp.Response, error) { +func (r ApiGetVolumeRequest) Execute() (*CSIVolume, *http.Response, error) { return r.ApiService.GetVolumeExecute(r) } /* - * GetVolume Method for GetVolume - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param volumeId Volume unique identifier. - * @return ApiGetVolumeRequest - */ -func (a *VolumesApiService) GetVolume(ctx _context.Context, volumeId string) ApiGetVolumeRequest { +GetVolume Method for GetVolume + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param volumeId Volume unique identifier. + @return ApiGetVolumeRequest +*/ +func (a *VolumesApiService) GetVolume(ctx context.Context, volumeId string) ApiGetVolumeRequest { return ApiGetVolumeRequest{ ApiService: a, ctx: ctx, @@ -1094,31 +1126,27 @@ func (a *VolumesApiService) GetVolume(ctx _context.Context, volumeId string) Api } } -/* - * Execute executes the request - * @return CSIVolume - */ -func (a *VolumesApiService) GetVolumeExecute(r ApiGetVolumeRequest) (CSIVolume, *_nethttp.Response, error) { +// Execute executes the request +// @return CSIVolume +func (a *VolumesApiService) GetVolumeExecute(r ApiGetVolumeRequest) (*CSIVolume, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CSIVolume + formFiles []formFile + localVarReturnValue *CSIVolume ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VolumesApiService.GetVolume") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/volume/csi/{volumeId}" - localVarPath = strings.Replace(localVarPath, "{"+"volumeId"+"}", _neturl.PathEscape(parameterToString(r.volumeId, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"volumeId"+"}", url.PathEscape(parameterToString(r.volumeId, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -1178,7 +1206,7 @@ func (a *VolumesApiService) GetVolumeExecute(r ApiGetVolumeRequest) (CSIVolume, } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -1188,15 +1216,15 @@ func (a *VolumesApiService) GetVolumeExecute(r ApiGetVolumeRequest) (CSIVolume, return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -1205,7 +1233,7 @@ func (a *VolumesApiService) GetVolumeExecute(r ApiGetVolumeRequest) (CSIVolume, err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -1216,7 +1244,7 @@ func (a *VolumesApiService) GetVolumeExecute(r ApiGetVolumeRequest) (CSIVolume, } type ApiGetVolumesRequest struct { - ctx _context.Context + ctx context.Context ApiService *VolumesApiService region *string namespace *string @@ -1232,95 +1260,104 @@ type ApiGetVolumesRequest struct { type_ *string } +// Filters results based on the specified region. func (r ApiGetVolumesRequest) Region(region string) ApiGetVolumesRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiGetVolumesRequest) Namespace(namespace string) ApiGetVolumesRequest { r.namespace = &namespace return r } +// If set, wait until query exceeds given index. Must be provided with WaitParam. func (r ApiGetVolumesRequest) Index(index int32) ApiGetVolumesRequest { r.index = &index return r } +// Provided with IndexParam to wait for change. func (r ApiGetVolumesRequest) Wait(wait string) ApiGetVolumesRequest { r.wait = &wait return r } +// If present, results will include stale reads. func (r ApiGetVolumesRequest) Stale(stale string) ApiGetVolumesRequest { r.stale = &stale return r } +// Constrains results to jobs that start with the defined prefix func (r ApiGetVolumesRequest) Prefix(prefix string) ApiGetVolumesRequest { r.prefix = &prefix return r } +// A Nomad ACL token. func (r ApiGetVolumesRequest) XNomadToken(xNomadToken string) ApiGetVolumesRequest { r.xNomadToken = &xNomadToken return r } +// Maximum number of results to return. func (r ApiGetVolumesRequest) PerPage(perPage int32) ApiGetVolumesRequest { r.perPage = &perPage return r } +// Indicates where to start paging for queries that support pagination. func (r ApiGetVolumesRequest) NextToken(nextToken string) ApiGetVolumesRequest { r.nextToken = &nextToken return r } +// Filters volume lists by node ID. func (r ApiGetVolumesRequest) NodeId(nodeId string) ApiGetVolumesRequest { r.nodeId = &nodeId return r } +// Filters volume lists by plugin ID. func (r ApiGetVolumesRequest) PluginId(pluginId string) ApiGetVolumesRequest { r.pluginId = &pluginId return r } +// Filters volume lists to a specific type. func (r ApiGetVolumesRequest) Type_(type_ string) ApiGetVolumesRequest { r.type_ = &type_ return r } -func (r ApiGetVolumesRequest) Execute() ([]CSIVolumeListStub, *_nethttp.Response, error) { +func (r ApiGetVolumesRequest) Execute() ([]CSIVolumeListStub, *http.Response, error) { return r.ApiService.GetVolumesExecute(r) } /* - * GetVolumes Method for GetVolumes - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiGetVolumesRequest - */ -func (a *VolumesApiService) GetVolumes(ctx _context.Context) ApiGetVolumesRequest { +GetVolumes Method for GetVolumes + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiGetVolumesRequest +*/ +func (a *VolumesApiService) GetVolumes(ctx context.Context) ApiGetVolumesRequest { return ApiGetVolumesRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return []CSIVolumeListStub - */ -func (a *VolumesApiService) GetVolumesExecute(r ApiGetVolumesRequest) ([]CSIVolumeListStub, *_nethttp.Response, error) { +// Execute executes the request +// @return []CSIVolumeListStub +func (a *VolumesApiService) GetVolumesExecute(r ApiGetVolumesRequest) ([]CSIVolumeListStub, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodGet + localVarHTTPMethod = http.MethodGet localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile localVarReturnValue []CSIVolumeListStub ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VolumesApiService.GetVolumes") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/volumes" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.region != nil { localVarQueryParams.Add("region", parameterToString(*r.region, "")) @@ -1389,7 +1426,7 @@ func (a *VolumesApiService) GetVolumesExecute(r ApiGetVolumesRequest) ([]CSIVolu } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -1399,15 +1436,15 @@ func (a *VolumesApiService) GetVolumesExecute(r ApiGetVolumesRequest) ([]CSIVolu return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -1416,7 +1453,7 @@ func (a *VolumesApiService) GetVolumesExecute(r ApiGetVolumesRequest) ([]CSIVolu err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -1427,7 +1464,7 @@ func (a *VolumesApiService) GetVolumesExecute(r ApiGetVolumesRequest) ([]CSIVolu } type ApiPostSnapshotRequest struct { - ctx _context.Context + ctx context.Context ApiService *VolumesApiService cSISnapshotCreateRequest *CSISnapshotCreateRequest region *string @@ -1440,63 +1477,64 @@ func (r ApiPostSnapshotRequest) CSISnapshotCreateRequest(cSISnapshotCreateReques r.cSISnapshotCreateRequest = &cSISnapshotCreateRequest return r } +// Filters results based on the specified region. func (r ApiPostSnapshotRequest) Region(region string) ApiPostSnapshotRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiPostSnapshotRequest) Namespace(namespace string) ApiPostSnapshotRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiPostSnapshotRequest) XNomadToken(xNomadToken string) ApiPostSnapshotRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiPostSnapshotRequest) IdempotencyToken(idempotencyToken string) ApiPostSnapshotRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiPostSnapshotRequest) Execute() (CSISnapshotCreateResponse, *_nethttp.Response, error) { +func (r ApiPostSnapshotRequest) Execute() (*CSISnapshotCreateResponse, *http.Response, error) { return r.ApiService.PostSnapshotExecute(r) } /* - * PostSnapshot Method for PostSnapshot - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiPostSnapshotRequest - */ -func (a *VolumesApiService) PostSnapshot(ctx _context.Context) ApiPostSnapshotRequest { +PostSnapshot Method for PostSnapshot + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiPostSnapshotRequest +*/ +func (a *VolumesApiService) PostSnapshot(ctx context.Context) ApiPostSnapshotRequest { return ApiPostSnapshotRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - * @return CSISnapshotCreateResponse - */ -func (a *VolumesApiService) PostSnapshotExecute(r ApiPostSnapshotRequest) (CSISnapshotCreateResponse, *_nethttp.Response, error) { +// Execute executes the request +// @return CSISnapshotCreateResponse +func (a *VolumesApiService) PostSnapshotExecute(r ApiPostSnapshotRequest) (*CSISnapshotCreateResponse, *http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CSISnapshotCreateResponse + formFiles []formFile + localVarReturnValue *CSISnapshotCreateResponse ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VolumesApiService.PostSnapshot") if err != nil { - return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/volumes/snapshot" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.cSISnapshotCreateRequest == nil { return localVarReturnValue, nil, reportError("cSISnapshotCreateRequest is required and must be specified") } @@ -1546,7 +1584,7 @@ func (a *VolumesApiService) PostSnapshotExecute(r ApiPostSnapshotRequest) (CSISn } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return localVarReturnValue, nil, err } @@ -1556,15 +1594,15 @@ func (a *VolumesApiService) PostSnapshotExecute(r ApiPostSnapshotRequest) (CSISn return localVarReturnValue, localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarReturnValue, localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -1573,7 +1611,7 @@ func (a *VolumesApiService) PostSnapshotExecute(r ApiPostSnapshotRequest) (CSISn err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) if err != nil { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: err.Error(), } @@ -1584,7 +1622,7 @@ func (a *VolumesApiService) PostSnapshotExecute(r ApiPostSnapshotRequest) (CSISn } type ApiPostVolumeRequest struct { - ctx _context.Context + ctx context.Context ApiService *VolumesApiService cSIVolumeRegisterRequest *CSIVolumeRegisterRequest region *string @@ -1597,61 +1635,62 @@ func (r ApiPostVolumeRequest) CSIVolumeRegisterRequest(cSIVolumeRegisterRequest r.cSIVolumeRegisterRequest = &cSIVolumeRegisterRequest return r } +// Filters results based on the specified region. func (r ApiPostVolumeRequest) Region(region string) ApiPostVolumeRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiPostVolumeRequest) Namespace(namespace string) ApiPostVolumeRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiPostVolumeRequest) XNomadToken(xNomadToken string) ApiPostVolumeRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiPostVolumeRequest) IdempotencyToken(idempotencyToken string) ApiPostVolumeRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiPostVolumeRequest) Execute() (*_nethttp.Response, error) { +func (r ApiPostVolumeRequest) Execute() (*http.Response, error) { return r.ApiService.PostVolumeExecute(r) } /* - * PostVolume Method for PostVolume - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return ApiPostVolumeRequest - */ -func (a *VolumesApiService) PostVolume(ctx _context.Context) ApiPostVolumeRequest { +PostVolume Method for PostVolume + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiPostVolumeRequest +*/ +func (a *VolumesApiService) PostVolume(ctx context.Context) ApiPostVolumeRequest { return ApiPostVolumeRequest{ ApiService: a, ctx: ctx, } } -/* - * Execute executes the request - */ -func (a *VolumesApiService) PostVolumeExecute(r ApiPostVolumeRequest) (*_nethttp.Response, error) { +// Execute executes the request +func (a *VolumesApiService) PostVolumeExecute(r ApiPostVolumeRequest) (*http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VolumesApiService.PostVolume") if err != nil { - return nil, GenericOpenAPIError{error: err.Error()} + return nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/volumes" localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.cSIVolumeRegisterRequest == nil { return nil, reportError("cSIVolumeRegisterRequest is required and must be specified") } @@ -1701,7 +1740,7 @@ func (a *VolumesApiService) PostVolumeExecute(r ApiPostVolumeRequest) (*_nethttp } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return nil, err } @@ -1711,15 +1750,15 @@ func (a *VolumesApiService) PostVolumeExecute(r ApiPostVolumeRequest) (*_nethttp return localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } @@ -1730,7 +1769,7 @@ func (a *VolumesApiService) PostVolumeExecute(r ApiPostVolumeRequest) (*_nethttp } type ApiPostVolumeRegistrationRequest struct { - ctx _context.Context + ctx context.Context ApiService *VolumesApiService volumeId string cSIVolumeRegisterRequest *CSIVolumeRegisterRequest @@ -1744,34 +1783,39 @@ func (r ApiPostVolumeRegistrationRequest) CSIVolumeRegisterRequest(cSIVolumeRegi r.cSIVolumeRegisterRequest = &cSIVolumeRegisterRequest return r } +// Filters results based on the specified region. func (r ApiPostVolumeRegistrationRequest) Region(region string) ApiPostVolumeRegistrationRequest { r.region = ®ion return r } +// Filters results based on the specified namespace. func (r ApiPostVolumeRegistrationRequest) Namespace(namespace string) ApiPostVolumeRegistrationRequest { r.namespace = &namespace return r } +// A Nomad ACL token. func (r ApiPostVolumeRegistrationRequest) XNomadToken(xNomadToken string) ApiPostVolumeRegistrationRequest { r.xNomadToken = &xNomadToken return r } +// Can be used to ensure operations are only run once. func (r ApiPostVolumeRegistrationRequest) IdempotencyToken(idempotencyToken string) ApiPostVolumeRegistrationRequest { r.idempotencyToken = &idempotencyToken return r } -func (r ApiPostVolumeRegistrationRequest) Execute() (*_nethttp.Response, error) { +func (r ApiPostVolumeRegistrationRequest) Execute() (*http.Response, error) { return r.ApiService.PostVolumeRegistrationExecute(r) } /* - * PostVolumeRegistration Method for PostVolumeRegistration - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param volumeId Volume unique identifier. - * @return ApiPostVolumeRegistrationRequest - */ -func (a *VolumesApiService) PostVolumeRegistration(ctx _context.Context, volumeId string) ApiPostVolumeRegistrationRequest { +PostVolumeRegistration Method for PostVolumeRegistration + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @param volumeId Volume unique identifier. + @return ApiPostVolumeRegistrationRequest +*/ +func (a *VolumesApiService) PostVolumeRegistration(ctx context.Context, volumeId string) ApiPostVolumeRegistrationRequest { return ApiPostVolumeRegistrationRequest{ ApiService: a, ctx: ctx, @@ -1779,29 +1823,25 @@ func (a *VolumesApiService) PostVolumeRegistration(ctx _context.Context, volumeI } } -/* - * Execute executes the request - */ -func (a *VolumesApiService) PostVolumeRegistrationExecute(r ApiPostVolumeRegistrationRequest) (*_nethttp.Response, error) { +// Execute executes the request +func (a *VolumesApiService) PostVolumeRegistrationExecute(r ApiPostVolumeRegistrationRequest) (*http.Response, error) { var ( - localVarHTTPMethod = _nethttp.MethodPost + localVarHTTPMethod = http.MethodPost localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte + formFiles []formFile ) localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VolumesApiService.PostVolumeRegistration") if err != nil { - return nil, GenericOpenAPIError{error: err.Error()} + return nil, &GenericOpenAPIError{error: err.Error()} } localVarPath := localBasePath + "/volume/csi/{volumeId}" - localVarPath = strings.Replace(localVarPath, "{"+"volumeId"+"}", _neturl.PathEscape(parameterToString(r.volumeId, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"volumeId"+"}", url.PathEscape(parameterToString(r.volumeId, "")), -1) localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} if r.cSIVolumeRegisterRequest == nil { return nil, reportError("cSIVolumeRegisterRequest is required and must be specified") } @@ -1851,7 +1891,7 @@ func (a *VolumesApiService) PostVolumeRegistrationExecute(r ApiPostVolumeRegistr } } } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) if err != nil { return nil, err } @@ -1861,15 +1901,15 @@ func (a *VolumesApiService) PostVolumeRegistrationExecute(r ApiPostVolumeRegistr return localVarHTTPResponse, err } - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarBody, err := ioutil.ReadAll(localVarHTTPResponse.Body) localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody)) + localVarHTTPResponse.Body = ioutil.NopCloser(bytes.NewBuffer(localVarBody)) if err != nil { return localVarHTTPResponse, err } if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ + newErr := &GenericOpenAPIError{ body: localVarBody, error: localVarHTTPResponse.Status, } diff --git a/clients/go/v1/client.go b/clients/go/v1/client.go index 6fa3ac69..873e8fbd 100644 --- a/clients/go/v1/client.go +++ b/clients/go/v1/client.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -238,6 +238,12 @@ func (c *APIClient) GetConfig() *Configuration { return c.cfg } +type formFile struct { + fileBytes []byte + fileName string + formFileName string +} + // prepareRequest build the request func (c *APIClient) prepareRequest( ctx context.Context, @@ -246,9 +252,7 @@ func (c *APIClient) prepareRequest( headerParams map[string]string, queryParams url.Values, formParams url.Values, - formFileName string, - fileName string, - fileBytes []byte) (localVarRequest *http.Request, err error) { + formFiles []formFile) (localVarRequest *http.Request, err error) { var body *bytes.Buffer @@ -267,7 +271,7 @@ func (c *APIClient) prepareRequest( } // add form parameters and file if available. - if strings.HasPrefix(headerParams["Content-Type"], "multipart/form-data") && len(formParams) > 0 || (len(fileBytes) > 0 && fileName != "") { + if strings.HasPrefix(headerParams["Content-Type"], "multipart/form-data") && len(formParams) > 0 || (len(formFiles) > 0) { if body != nil { return nil, errors.New("Cannot specify postBody and multipart form at the same time.") } @@ -286,16 +290,17 @@ func (c *APIClient) prepareRequest( } } } - if len(fileBytes) > 0 && fileName != "" { - w.Boundary() - //_, fileNm := filepath.Split(fileName) - part, err := w.CreateFormFile(formFileName, filepath.Base(fileName)) - if err != nil { - return nil, err - } - _, err = part.Write(fileBytes) - if err != nil { - return nil, err + for _, formFile := range formFiles { + if len(formFile.fileBytes) > 0 && formFile.fileName != "" { + w.Boundary() + part, err := w.CreateFormFile(formFile.formFileName, filepath.Base(formFile.fileName)) + if err != nil { + return nil, err + } + _, err = part.Write(formFile.fileBytes) + if err != nil { + return nil, err + } } } @@ -358,7 +363,7 @@ func (c *APIClient) prepareRequest( if len(headerParams) > 0 { headers := http.Header{} for h, v := range headerParams { - headers.Set(h, v) + headers[h] = []string{v} } localVarRequest.Header = headers } @@ -415,6 +420,9 @@ func (c *APIClient) decode(v interface{}, b []byte, contentType string) (err err return } _, err = (*f).Write(b) + if err != nil { + return + } _, err = (*f).Seek(0, io.SeekStart) return } @@ -463,6 +471,13 @@ func reportError(format string, a ...interface{}) error { return fmt.Errorf(format, a...) } +// A wrapper for strict JSON decoding +func newStrictDecoder(data []byte) *json.Decoder { + dec := json.NewDecoder(bytes.NewBuffer(data)) + dec.DisallowUnknownFields() + return dec +} + // Set request body from an interface{} func setBody(body interface{}, contentType string) (bodyBuf *bytes.Buffer, err error) { if bodyBuf == nil { diff --git a/clients/go/v1/configuration.go b/clients/go/v1/configuration.go index 7e9c60bf..6e64c75b 100644 --- a/clients/go/v1/configuration.go +++ b/clients/go/v1/configuration.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/docs/ACLApi.md b/clients/go/v1/docs/ACLApi.md index 8ddf9775..e6b1c740 100644 --- a/clients/go/v1/docs/ACLApi.md +++ b/clients/go/v1/docs/ACLApi.md @@ -45,8 +45,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.ACLApi.DeleteACLPolicy(context.Background(), policyName).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.ACLApi.DeleteACLPolicy(context.Background(), policyName).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `ACLApi.DeleteACLPolicy``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -119,8 +119,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.ACLApi.DeleteACLToken(context.Background(), tokenAccessor).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.ACLApi.DeleteACLToken(context.Background(), tokenAccessor).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `ACLApi.DeleteACLToken``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -197,8 +197,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.ACLApi.GetACLPolicies(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.ACLApi.GetACLPolicies(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `ACLApi.GetACLPolicies``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -278,8 +278,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.ACLApi.GetACLPolicy(context.Background(), policyName).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.ACLApi.GetACLPolicy(context.Background(), policyName).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `ACLApi.GetACLPolicy``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -364,8 +364,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.ACLApi.GetACLToken(context.Background(), tokenAccessor).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.ACLApi.GetACLToken(context.Background(), tokenAccessor).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `ACLApi.GetACLToken``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -449,8 +449,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.ACLApi.GetACLTokenSelf(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.ACLApi.GetACLTokenSelf(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `ACLApi.GetACLTokenSelf``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -529,8 +529,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.ACLApi.GetACLTokens(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.ACLApi.GetACLTokens(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `ACLApi.GetACLTokens``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -604,8 +604,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.ACLApi.PostACLBootstrap(context.Background()).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.ACLApi.PostACLBootstrap(context.Background()).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `ACLApi.PostACLBootstrap``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -676,8 +676,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.ACLApi.PostACLPolicy(context.Background(), policyName).ACLPolicy(aCLPolicy).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.ACLApi.PostACLPolicy(context.Background(), policyName).ACLPolicy(aCLPolicy).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `ACLApi.PostACLPolicy``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -752,8 +752,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.ACLApi.PostACLToken(context.Background(), tokenAccessor).ACLToken(aCLToken).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.ACLApi.PostACLToken(context.Background(), tokenAccessor).ACLToken(aCLToken).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `ACLApi.PostACLToken``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -828,8 +828,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.ACLApi.PostACLTokenOnetime(context.Background()).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.ACLApi.PostACLTokenOnetime(context.Background()).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `ACLApi.PostACLTokenOnetime``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -899,8 +899,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.ACLApi.PostACLTokenOnetimeExchange(context.Background()).OneTimeTokenExchangeRequest(oneTimeTokenExchangeRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.ACLApi.PostACLTokenOnetimeExchange(context.Background()).OneTimeTokenExchangeRequest(oneTimeTokenExchangeRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `ACLApi.PostACLTokenOnetimeExchange``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) diff --git a/clients/go/v1/docs/ACLToken.md b/clients/go/v1/docs/ACLToken.md index b9e399aa..df74d798 100644 --- a/clients/go/v1/docs/ACLToken.md +++ b/clients/go/v1/docs/ACLToken.md @@ -6,7 +6,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **AccessorID** | Pointer to **string** | | [optional] **CreateIndex** | Pointer to **int32** | | [optional] -**CreateTime** | Pointer to **time.Time** | | [optional] +**CreateTime** | Pointer to **NullableTime** | | [optional] **Global** | Pointer to **bool** | | [optional] **ModifyIndex** | Pointer to **int32** | | [optional] **Name** | Pointer to **string** | | [optional] @@ -108,6 +108,16 @@ SetCreateTime sets CreateTime field to given value. HasCreateTime returns a boolean if a field has been set. +### SetCreateTimeNil + +`func (o *ACLToken) SetCreateTimeNil(b bool)` + + SetCreateTimeNil sets the value for CreateTime to be an explicit nil + +### UnsetCreateTime +`func (o *ACLToken) UnsetCreateTime()` + +UnsetCreateTime ensures that no value is present for CreateTime, not even an explicit nil ### GetGlobal `func (o *ACLToken) GetGlobal() bool` diff --git a/clients/go/v1/docs/ACLTokenListStub.md b/clients/go/v1/docs/ACLTokenListStub.md index 22e61419..1c2a06ec 100644 --- a/clients/go/v1/docs/ACLTokenListStub.md +++ b/clients/go/v1/docs/ACLTokenListStub.md @@ -6,7 +6,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **AccessorID** | Pointer to **string** | | [optional] **CreateIndex** | Pointer to **int32** | | [optional] -**CreateTime** | Pointer to **time.Time** | | [optional] +**CreateTime** | Pointer to **NullableTime** | | [optional] **Global** | Pointer to **bool** | | [optional] **ModifyIndex** | Pointer to **int32** | | [optional] **Name** | Pointer to **string** | | [optional] @@ -107,6 +107,16 @@ SetCreateTime sets CreateTime field to given value. HasCreateTime returns a boolean if a field has been set. +### SetCreateTimeNil + +`func (o *ACLTokenListStub) SetCreateTimeNil(b bool)` + + SetCreateTimeNil sets the value for CreateTime to be an explicit nil + +### UnsetCreateTime +`func (o *ACLTokenListStub) UnsetCreateTime()` + +UnsetCreateTime ensures that no value is present for CreateTime, not even an explicit nil ### GetGlobal `func (o *ACLTokenListStub) GetGlobal() bool` diff --git a/clients/go/v1/docs/AllocDeploymentStatus.md b/clients/go/v1/docs/AllocDeploymentStatus.md index 05d51c88..bea3d12e 100644 --- a/clients/go/v1/docs/AllocDeploymentStatus.md +++ b/clients/go/v1/docs/AllocDeploymentStatus.md @@ -7,7 +7,7 @@ Name | Type | Description | Notes **Canary** | Pointer to **bool** | | [optional] **Healthy** | Pointer to **bool** | | [optional] **ModifyIndex** | Pointer to **int32** | | [optional] -**Timestamp** | Pointer to **time.Time** | | [optional] +**Timestamp** | Pointer to **NullableTime** | | [optional] ## Methods @@ -128,6 +128,16 @@ SetTimestamp sets Timestamp field to given value. HasTimestamp returns a boolean if a field has been set. +### SetTimestampNil + +`func (o *AllocDeploymentStatus) SetTimestampNil(b bool)` + + SetTimestampNil sets the value for Timestamp to be an explicit nil + +### UnsetTimestamp +`func (o *AllocDeploymentStatus) UnsetTimestamp()` + +UnsetTimestamp ensures that no value is present for Timestamp, not even an explicit nil [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/go/v1/docs/AllocatedResources.md b/clients/go/v1/docs/AllocatedResources.md index 456e0a33..3647cb16 100644 --- a/clients/go/v1/docs/AllocatedResources.md +++ b/clients/go/v1/docs/AllocatedResources.md @@ -4,7 +4,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Shared** | Pointer to [**AllocatedSharedResources**](AllocatedSharedResources.md) | | [optional] +**Shared** | Pointer to [**NullableAllocatedSharedResources**](AllocatedSharedResources.md) | | [optional] **Tasks** | Pointer to [**map[string]AllocatedTaskResources**](AllocatedTaskResources.md) | | [optional] ## Methods @@ -51,6 +51,16 @@ SetShared sets Shared field to given value. HasShared returns a boolean if a field has been set. +### SetSharedNil + +`func (o *AllocatedResources) SetSharedNil(b bool)` + + SetSharedNil sets the value for Shared to be an explicit nil + +### UnsetShared +`func (o *AllocatedResources) UnsetShared()` + +UnsetShared ensures that no value is present for Shared, not even an explicit nil ### GetTasks `func (o *AllocatedResources) GetTasks() map[string]AllocatedTaskResources` diff --git a/clients/go/v1/docs/AllocatedTaskResources.md b/clients/go/v1/docs/AllocatedTaskResources.md index 460526cf..d2338bf4 100644 --- a/clients/go/v1/docs/AllocatedTaskResources.md +++ b/clients/go/v1/docs/AllocatedTaskResources.md @@ -4,9 +4,9 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Cpu** | Pointer to [**AllocatedCpuResources**](AllocatedCpuResources.md) | | [optional] +**Cpu** | Pointer to [**NullableAllocatedCpuResources**](AllocatedCpuResources.md) | | [optional] **Devices** | Pointer to [**[]AllocatedDeviceResource**](AllocatedDeviceResource.md) | | [optional] -**Memory** | Pointer to [**AllocatedMemoryResources**](AllocatedMemoryResources.md) | | [optional] +**Memory** | Pointer to [**NullableAllocatedMemoryResources**](AllocatedMemoryResources.md) | | [optional] **Networks** | Pointer to [**[]NetworkResource**](NetworkResource.md) | | [optional] ## Methods @@ -53,6 +53,16 @@ SetCpu sets Cpu field to given value. HasCpu returns a boolean if a field has been set. +### SetCpuNil + +`func (o *AllocatedTaskResources) SetCpuNil(b bool)` + + SetCpuNil sets the value for Cpu to be an explicit nil + +### UnsetCpu +`func (o *AllocatedTaskResources) UnsetCpu()` + +UnsetCpu ensures that no value is present for Cpu, not even an explicit nil ### GetDevices `func (o *AllocatedTaskResources) GetDevices() []AllocatedDeviceResource` @@ -103,6 +113,16 @@ SetMemory sets Memory field to given value. HasMemory returns a boolean if a field has been set. +### SetMemoryNil + +`func (o *AllocatedTaskResources) SetMemoryNil(b bool)` + + SetMemoryNil sets the value for Memory to be an explicit nil + +### UnsetMemory +`func (o *AllocatedTaskResources) UnsetMemory()` + +UnsetMemory ensures that no value is present for Memory, not even an explicit nil ### GetNetworks `func (o *AllocatedTaskResources) GetNetworks() []NetworkResource` diff --git a/clients/go/v1/docs/Allocation.md b/clients/go/v1/docs/Allocation.md index 57a1a4e7..2a373f31 100644 --- a/clients/go/v1/docs/Allocation.md +++ b/clients/go/v1/docs/Allocation.md @@ -5,22 +5,22 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **AllocModifyIndex** | Pointer to **int32** | | [optional] -**AllocatedResources** | Pointer to [**AllocatedResources**](AllocatedResources.md) | | [optional] +**AllocatedResources** | Pointer to [**NullableAllocatedResources**](AllocatedResources.md) | | [optional] **ClientDescription** | Pointer to **string** | | [optional] **ClientStatus** | Pointer to **string** | | [optional] **CreateIndex** | Pointer to **int32** | | [optional] **CreateTime** | Pointer to **int64** | | [optional] **DeploymentID** | Pointer to **string** | | [optional] -**DeploymentStatus** | Pointer to [**AllocDeploymentStatus**](AllocDeploymentStatus.md) | | [optional] +**DeploymentStatus** | Pointer to [**NullableAllocDeploymentStatus**](AllocDeploymentStatus.md) | | [optional] **DesiredDescription** | Pointer to **string** | | [optional] **DesiredStatus** | Pointer to **string** | | [optional] **DesiredTransition** | Pointer to [**DesiredTransition**](DesiredTransition.md) | | [optional] **EvalID** | Pointer to **string** | | [optional] **FollowupEvalID** | Pointer to **string** | | [optional] **ID** | Pointer to **string** | | [optional] -**Job** | Pointer to [**Job**](Job.md) | | [optional] +**Job** | Pointer to [**NullableJob**](Job.md) | | [optional] **JobID** | Pointer to **string** | | [optional] -**Metrics** | Pointer to [**AllocationMetric**](AllocationMetric.md) | | [optional] +**Metrics** | Pointer to [**NullableAllocationMetric**](AllocationMetric.md) | | [optional] **ModifyIndex** | Pointer to **int32** | | [optional] **ModifyTime** | Pointer to **int64** | | [optional] **Name** | Pointer to **string** | | [optional] @@ -31,8 +31,8 @@ Name | Type | Description | Notes **PreemptedAllocations** | Pointer to **[]string** | | [optional] **PreemptedByAllocation** | Pointer to **string** | | [optional] **PreviousAllocation** | Pointer to **string** | | [optional] -**RescheduleTracker** | Pointer to [**RescheduleTracker**](RescheduleTracker.md) | | [optional] -**Resources** | Pointer to [**Resources**](Resources.md) | | [optional] +**RescheduleTracker** | Pointer to [**NullableRescheduleTracker**](RescheduleTracker.md) | | [optional] +**Resources** | Pointer to [**NullableResources**](Resources.md) | | [optional] **Services** | Pointer to **map[string]string** | | [optional] **TaskGroup** | Pointer to **string** | | [optional] **TaskResources** | Pointer to [**map[string]Resources**](Resources.md) | | [optional] @@ -107,6 +107,16 @@ SetAllocatedResources sets AllocatedResources field to given value. HasAllocatedResources returns a boolean if a field has been set. +### SetAllocatedResourcesNil + +`func (o *Allocation) SetAllocatedResourcesNil(b bool)` + + SetAllocatedResourcesNil sets the value for AllocatedResources to be an explicit nil + +### UnsetAllocatedResources +`func (o *Allocation) UnsetAllocatedResources()` + +UnsetAllocatedResources ensures that no value is present for AllocatedResources, not even an explicit nil ### GetClientDescription `func (o *Allocation) GetClientDescription() string` @@ -257,6 +267,16 @@ SetDeploymentStatus sets DeploymentStatus field to given value. HasDeploymentStatus returns a boolean if a field has been set. +### SetDeploymentStatusNil + +`func (o *Allocation) SetDeploymentStatusNil(b bool)` + + SetDeploymentStatusNil sets the value for DeploymentStatus to be an explicit nil + +### UnsetDeploymentStatus +`func (o *Allocation) UnsetDeploymentStatus()` + +UnsetDeploymentStatus ensures that no value is present for DeploymentStatus, not even an explicit nil ### GetDesiredDescription `func (o *Allocation) GetDesiredDescription() string` @@ -432,6 +452,16 @@ SetJob sets Job field to given value. HasJob returns a boolean if a field has been set. +### SetJobNil + +`func (o *Allocation) SetJobNil(b bool)` + + SetJobNil sets the value for Job to be an explicit nil + +### UnsetJob +`func (o *Allocation) UnsetJob()` + +UnsetJob ensures that no value is present for Job, not even an explicit nil ### GetJobID `func (o *Allocation) GetJobID() string` @@ -482,6 +512,16 @@ SetMetrics sets Metrics field to given value. HasMetrics returns a boolean if a field has been set. +### SetMetricsNil + +`func (o *Allocation) SetMetricsNil(b bool)` + + SetMetricsNil sets the value for Metrics to be an explicit nil + +### UnsetMetrics +`func (o *Allocation) UnsetMetrics()` + +UnsetMetrics ensures that no value is present for Metrics, not even an explicit nil ### GetModifyIndex `func (o *Allocation) GetModifyIndex() int32` @@ -757,6 +797,16 @@ SetRescheduleTracker sets RescheduleTracker field to given value. HasRescheduleTracker returns a boolean if a field has been set. +### SetRescheduleTrackerNil + +`func (o *Allocation) SetRescheduleTrackerNil(b bool)` + + SetRescheduleTrackerNil sets the value for RescheduleTracker to be an explicit nil + +### UnsetRescheduleTracker +`func (o *Allocation) UnsetRescheduleTracker()` + +UnsetRescheduleTracker ensures that no value is present for RescheduleTracker, not even an explicit nil ### GetResources `func (o *Allocation) GetResources() Resources` @@ -782,6 +832,16 @@ SetResources sets Resources field to given value. HasResources returns a boolean if a field has been set. +### SetResourcesNil + +`func (o *Allocation) SetResourcesNil(b bool)` + + SetResourcesNil sets the value for Resources to be an explicit nil + +### UnsetResources +`func (o *Allocation) UnsetResources()` + +UnsetResources ensures that no value is present for Resources, not even an explicit nil ### GetServices `func (o *Allocation) GetServices() map[string]string` diff --git a/clients/go/v1/docs/AllocationListStub.md b/clients/go/v1/docs/AllocationListStub.md index 84fbc298..f1bc1d21 100644 --- a/clients/go/v1/docs/AllocationListStub.md +++ b/clients/go/v1/docs/AllocationListStub.md @@ -4,12 +4,12 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**AllocatedResources** | Pointer to [**AllocatedResources**](AllocatedResources.md) | | [optional] +**AllocatedResources** | Pointer to [**NullableAllocatedResources**](AllocatedResources.md) | | [optional] **ClientDescription** | Pointer to **string** | | [optional] **ClientStatus** | Pointer to **string** | | [optional] **CreateIndex** | Pointer to **int32** | | [optional] **CreateTime** | Pointer to **int64** | | [optional] -**DeploymentStatus** | Pointer to [**AllocDeploymentStatus**](AllocDeploymentStatus.md) | | [optional] +**DeploymentStatus** | Pointer to [**NullableAllocDeploymentStatus**](AllocDeploymentStatus.md) | | [optional] **DesiredDescription** | Pointer to **string** | | [optional] **DesiredStatus** | Pointer to **string** | | [optional] **EvalID** | Pointer to **string** | | [optional] @@ -26,7 +26,7 @@ Name | Type | Description | Notes **NodeName** | Pointer to **string** | | [optional] **PreemptedAllocations** | Pointer to **[]string** | | [optional] **PreemptedByAllocation** | Pointer to **string** | | [optional] -**RescheduleTracker** | Pointer to [**RescheduleTracker**](RescheduleTracker.md) | | [optional] +**RescheduleTracker** | Pointer to [**NullableRescheduleTracker**](RescheduleTracker.md) | | [optional] **TaskGroup** | Pointer to **string** | | [optional] **TaskStates** | Pointer to [**map[string]TaskState**](TaskState.md) | | [optional] @@ -74,6 +74,16 @@ SetAllocatedResources sets AllocatedResources field to given value. HasAllocatedResources returns a boolean if a field has been set. +### SetAllocatedResourcesNil + +`func (o *AllocationListStub) SetAllocatedResourcesNil(b bool)` + + SetAllocatedResourcesNil sets the value for AllocatedResources to be an explicit nil + +### UnsetAllocatedResources +`func (o *AllocationListStub) UnsetAllocatedResources()` + +UnsetAllocatedResources ensures that no value is present for AllocatedResources, not even an explicit nil ### GetClientDescription `func (o *AllocationListStub) GetClientDescription() string` @@ -199,6 +209,16 @@ SetDeploymentStatus sets DeploymentStatus field to given value. HasDeploymentStatus returns a boolean if a field has been set. +### SetDeploymentStatusNil + +`func (o *AllocationListStub) SetDeploymentStatusNil(b bool)` + + SetDeploymentStatusNil sets the value for DeploymentStatus to be an explicit nil + +### UnsetDeploymentStatus +`func (o *AllocationListStub) UnsetDeploymentStatus()` + +UnsetDeploymentStatus ensures that no value is present for DeploymentStatus, not even an explicit nil ### GetDesiredDescription `func (o *AllocationListStub) GetDesiredDescription() string` @@ -624,6 +644,16 @@ SetRescheduleTracker sets RescheduleTracker field to given value. HasRescheduleTracker returns a boolean if a field has been set. +### SetRescheduleTrackerNil + +`func (o *AllocationListStub) SetRescheduleTrackerNil(b bool)` + + SetRescheduleTrackerNil sets the value for RescheduleTracker to be an explicit nil + +### UnsetRescheduleTracker +`func (o *AllocationListStub) UnsetRescheduleTracker()` + +UnsetRescheduleTracker ensures that no value is present for RescheduleTracker, not even an explicit nil ### GetTaskGroup `func (o *AllocationListStub) GetTaskGroup() string` diff --git a/clients/go/v1/docs/AllocationsApi.md b/clients/go/v1/docs/AllocationsApi.md index 540a2981..c23dda55 100644 --- a/clients/go/v1/docs/AllocationsApi.md +++ b/clients/go/v1/docs/AllocationsApi.md @@ -42,8 +42,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.AllocationsApi.GetAllocation(context.Background(), allocID).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.AllocationsApi.GetAllocation(context.Background(), allocID).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `AllocationsApi.GetAllocation``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -128,8 +128,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.AllocationsApi.GetAllocationServices(context.Background(), allocID).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.AllocationsApi.GetAllocationServices(context.Background(), allocID).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `AllocationsApi.GetAllocationServices``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -215,8 +215,8 @@ func main() { taskStates := true // bool | Flag indicating whether to include task states in response. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.AllocationsApi.GetAllocations(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Resources(resources).TaskStates(taskStates).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.AllocationsApi.GetAllocations(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Resources(resources).TaskStates(taskStates).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `AllocationsApi.GetAllocations``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -299,8 +299,8 @@ func main() { noShutdownDelay := true // bool | Flag indicating whether to delay shutdown when requesting an allocation stop. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.AllocationsApi.PostAllocationStop(context.Background(), allocID).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).NoShutdownDelay(noShutdownDelay).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.AllocationsApi.PostAllocationStop(context.Background(), allocID).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).NoShutdownDelay(noShutdownDelay).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `AllocationsApi.PostAllocationStop``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) diff --git a/clients/go/v1/docs/CSIInfo.md b/clients/go/v1/docs/CSIInfo.md index c1bee795..7034170f 100644 --- a/clients/go/v1/docs/CSIInfo.md +++ b/clients/go/v1/docs/CSIInfo.md @@ -5,14 +5,14 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **AllocID** | Pointer to **string** | | [optional] -**ControllerInfo** | Pointer to [**CSIControllerInfo**](CSIControllerInfo.md) | | [optional] +**ControllerInfo** | Pointer to [**NullableCSIControllerInfo**](CSIControllerInfo.md) | | [optional] **HealthDescription** | Pointer to **string** | | [optional] **Healthy** | Pointer to **bool** | | [optional] -**NodeInfo** | Pointer to [**CSINodeInfo**](CSINodeInfo.md) | | [optional] +**NodeInfo** | Pointer to [**NullableCSINodeInfo**](CSINodeInfo.md) | | [optional] **PluginID** | Pointer to **string** | | [optional] **RequiresControllerPlugin** | Pointer to **bool** | | [optional] **RequiresTopologies** | Pointer to **bool** | | [optional] -**UpdateTime** | Pointer to **time.Time** | | [optional] +**UpdateTime** | Pointer to **NullableTime** | | [optional] ## Methods @@ -83,6 +83,16 @@ SetControllerInfo sets ControllerInfo field to given value. HasControllerInfo returns a boolean if a field has been set. +### SetControllerInfoNil + +`func (o *CSIInfo) SetControllerInfoNil(b bool)` + + SetControllerInfoNil sets the value for ControllerInfo to be an explicit nil + +### UnsetControllerInfo +`func (o *CSIInfo) UnsetControllerInfo()` + +UnsetControllerInfo ensures that no value is present for ControllerInfo, not even an explicit nil ### GetHealthDescription `func (o *CSIInfo) GetHealthDescription() string` @@ -158,6 +168,16 @@ SetNodeInfo sets NodeInfo field to given value. HasNodeInfo returns a boolean if a field has been set. +### SetNodeInfoNil + +`func (o *CSIInfo) SetNodeInfoNil(b bool)` + + SetNodeInfoNil sets the value for NodeInfo to be an explicit nil + +### UnsetNodeInfo +`func (o *CSIInfo) UnsetNodeInfo()` + +UnsetNodeInfo ensures that no value is present for NodeInfo, not even an explicit nil ### GetPluginID `func (o *CSIInfo) GetPluginID() string` @@ -258,6 +278,16 @@ SetUpdateTime sets UpdateTime field to given value. HasUpdateTime returns a boolean if a field has been set. +### SetUpdateTimeNil + +`func (o *CSIInfo) SetUpdateTimeNil(b bool)` + + SetUpdateTimeNil sets the value for UpdateTime to be an explicit nil + +### UnsetUpdateTime +`func (o *CSIInfo) UnsetUpdateTime()` + +UnsetUpdateTime ensures that no value is present for UpdateTime, not even an explicit nil [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/go/v1/docs/CSINodeInfo.md b/clients/go/v1/docs/CSINodeInfo.md index 9f438626..6b4c0afb 100644 --- a/clients/go/v1/docs/CSINodeInfo.md +++ b/clients/go/v1/docs/CSINodeInfo.md @@ -4,7 +4,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**AccessibleTopology** | Pointer to [**CSITopology**](CSITopology.md) | | [optional] +**AccessibleTopology** | Pointer to [**NullableCSITopology**](CSITopology.md) | | [optional] **ID** | Pointer to **string** | | [optional] **MaxVolumes** | Pointer to **int64** | | [optional] **RequiresNodeStageVolume** | Pointer to **bool** | | [optional] @@ -56,6 +56,16 @@ SetAccessibleTopology sets AccessibleTopology field to given value. HasAccessibleTopology returns a boolean if a field has been set. +### SetAccessibleTopologyNil + +`func (o *CSINodeInfo) SetAccessibleTopologyNil(b bool)` + + SetAccessibleTopologyNil sets the value for AccessibleTopology to be an explicit nil + +### UnsetAccessibleTopology +`func (o *CSINodeInfo) UnsetAccessibleTopology()` + +UnsetAccessibleTopology ensures that no value is present for AccessibleTopology, not even an explicit nil ### GetID `func (o *CSINodeInfo) GetID() string` diff --git a/clients/go/v1/docs/CSIVolume.md b/clients/go/v1/docs/CSIVolume.md index 42480150..11f55175 100644 --- a/clients/go/v1/docs/CSIVolume.md +++ b/clients/go/v1/docs/CSIVolume.md @@ -17,7 +17,7 @@ Name | Type | Description | Notes **ExternalID** | Pointer to **string** | | [optional] **ID** | Pointer to **string** | | [optional] **ModifyIndex** | Pointer to **int32** | | [optional] -**MountOptions** | Pointer to [**CSIMountOptions**](CSIMountOptions.md) | | [optional] +**MountOptions** | Pointer to [**NullableCSIMountOptions**](CSIMountOptions.md) | | [optional] **Name** | Pointer to **string** | | [optional] **Namespace** | Pointer to **string** | | [optional] **NodesExpected** | Pointer to **int32** | | [optional] @@ -30,8 +30,8 @@ Name | Type | Description | Notes **RequestedCapabilities** | Pointer to [**[]CSIVolumeCapability**](CSIVolumeCapability.md) | | [optional] **RequestedCapacityMax** | Pointer to **int64** | | [optional] **RequestedCapacityMin** | Pointer to **int64** | | [optional] -**RequestedTopologies** | Pointer to [**CSITopologyRequest**](CSITopologyRequest.md) | | [optional] -**ResourceExhausted** | Pointer to **time.Time** | | [optional] +**RequestedTopologies** | Pointer to [**NullableCSITopologyRequest**](CSITopologyRequest.md) | | [optional] +**ResourceExhausted** | Pointer to **NullableTime** | | [optional] **Schedulable** | Pointer to **bool** | | [optional] **Secrets** | Pointer to **map[string]string** | | [optional] **SnapshotID** | Pointer to **string** | | [optional] @@ -407,6 +407,16 @@ SetMountOptions sets MountOptions field to given value. HasMountOptions returns a boolean if a field has been set. +### SetMountOptionsNil + +`func (o *CSIVolume) SetMountOptionsNil(b bool)` + + SetMountOptionsNil sets the value for MountOptions to be an explicit nil + +### UnsetMountOptions +`func (o *CSIVolume) UnsetMountOptions()` + +UnsetMountOptions ensures that no value is present for MountOptions, not even an explicit nil ### GetName `func (o *CSIVolume) GetName() string` @@ -732,6 +742,16 @@ SetRequestedTopologies sets RequestedTopologies field to given value. HasRequestedTopologies returns a boolean if a field has been set. +### SetRequestedTopologiesNil + +`func (o *CSIVolume) SetRequestedTopologiesNil(b bool)` + + SetRequestedTopologiesNil sets the value for RequestedTopologies to be an explicit nil + +### UnsetRequestedTopologies +`func (o *CSIVolume) UnsetRequestedTopologies()` + +UnsetRequestedTopologies ensures that no value is present for RequestedTopologies, not even an explicit nil ### GetResourceExhausted `func (o *CSIVolume) GetResourceExhausted() time.Time` @@ -757,6 +777,16 @@ SetResourceExhausted sets ResourceExhausted field to given value. HasResourceExhausted returns a boolean if a field has been set. +### SetResourceExhaustedNil + +`func (o *CSIVolume) SetResourceExhaustedNil(b bool)` + + SetResourceExhaustedNil sets the value for ResourceExhausted to be an explicit nil + +### UnsetResourceExhausted +`func (o *CSIVolume) UnsetResourceExhausted()` + +UnsetResourceExhausted ensures that no value is present for ResourceExhausted, not even an explicit nil ### GetSchedulable `func (o *CSIVolume) GetSchedulable() bool` diff --git a/clients/go/v1/docs/CSIVolumeListStub.md b/clients/go/v1/docs/CSIVolumeListStub.md index 1b7abd0b..998418d0 100644 --- a/clients/go/v1/docs/CSIVolumeListStub.md +++ b/clients/go/v1/docs/CSIVolumeListStub.md @@ -19,7 +19,7 @@ Name | Type | Description | Notes **NodesHealthy** | Pointer to **int32** | | [optional] **PluginID** | Pointer to **string** | | [optional] **Provider** | Pointer to **string** | | [optional] -**ResourceExhausted** | Pointer to **time.Time** | | [optional] +**ResourceExhausted** | Pointer to **NullableTime** | | [optional] **Schedulable** | Pointer to **bool** | | [optional] **Topologies** | Pointer to [**[]CSITopology**](CSITopology.md) | | [optional] @@ -442,6 +442,16 @@ SetResourceExhausted sets ResourceExhausted field to given value. HasResourceExhausted returns a boolean if a field has been set. +### SetResourceExhaustedNil + +`func (o *CSIVolumeListStub) SetResourceExhaustedNil(b bool)` + + SetResourceExhaustedNil sets the value for ResourceExhausted to be an explicit nil + +### UnsetResourceExhausted +`func (o *CSIVolumeListStub) UnsetResourceExhausted()` + +UnsetResourceExhausted ensures that no value is present for ResourceExhausted, not even an explicit nil ### GetSchedulable `func (o *CSIVolumeListStub) GetSchedulable() bool` diff --git a/clients/go/v1/docs/ConsulConnect.md b/clients/go/v1/docs/ConsulConnect.md index 2c214f35..c928ce36 100644 --- a/clients/go/v1/docs/ConsulConnect.md +++ b/clients/go/v1/docs/ConsulConnect.md @@ -6,8 +6,8 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **Gateway** | Pointer to [**ConsulGateway**](ConsulGateway.md) | | [optional] **Native** | Pointer to **bool** | | [optional] -**SidecarService** | Pointer to [**ConsulSidecarService**](ConsulSidecarService.md) | | [optional] -**SidecarTask** | Pointer to [**SidecarTask**](SidecarTask.md) | | [optional] +**SidecarService** | Pointer to [**NullableConsulSidecarService**](ConsulSidecarService.md) | | [optional] +**SidecarTask** | Pointer to [**NullableSidecarTask**](SidecarTask.md) | | [optional] ## Methods @@ -103,6 +103,16 @@ SetSidecarService sets SidecarService field to given value. HasSidecarService returns a boolean if a field has been set. +### SetSidecarServiceNil + +`func (o *ConsulConnect) SetSidecarServiceNil(b bool)` + + SetSidecarServiceNil sets the value for SidecarService to be an explicit nil + +### UnsetSidecarService +`func (o *ConsulConnect) UnsetSidecarService()` + +UnsetSidecarService ensures that no value is present for SidecarService, not even an explicit nil ### GetSidecarTask `func (o *ConsulConnect) GetSidecarTask() SidecarTask` @@ -128,6 +138,16 @@ SetSidecarTask sets SidecarTask field to given value. HasSidecarTask returns a boolean if a field has been set. +### SetSidecarTaskNil + +`func (o *ConsulConnect) SetSidecarTaskNil(b bool)` + + SetSidecarTaskNil sets the value for SidecarTask to be an explicit nil + +### UnsetSidecarTask +`func (o *ConsulConnect) UnsetSidecarTask()` + +UnsetSidecarTask ensures that no value is present for SidecarTask, not even an explicit nil [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/go/v1/docs/ConsulGateway.md b/clients/go/v1/docs/ConsulGateway.md index 6b594a2b..4e41566f 100644 --- a/clients/go/v1/docs/ConsulGateway.md +++ b/clients/go/v1/docs/ConsulGateway.md @@ -4,10 +4,10 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Ingress** | Pointer to [**ConsulIngressConfigEntry**](ConsulIngressConfigEntry.md) | | [optional] +**Ingress** | Pointer to [**NullableConsulIngressConfigEntry**](ConsulIngressConfigEntry.md) | | [optional] **Mesh** | Pointer to **interface{}** | | [optional] -**Proxy** | Pointer to [**ConsulGatewayProxy**](ConsulGatewayProxy.md) | | [optional] -**Terminating** | Pointer to [**ConsulTerminatingConfigEntry**](ConsulTerminatingConfigEntry.md) | | [optional] +**Proxy** | Pointer to [**NullableConsulGatewayProxy**](ConsulGatewayProxy.md) | | [optional] +**Terminating** | Pointer to [**NullableConsulTerminatingConfigEntry**](ConsulTerminatingConfigEntry.md) | | [optional] ## Methods @@ -53,6 +53,16 @@ SetIngress sets Ingress field to given value. HasIngress returns a boolean if a field has been set. +### SetIngressNil + +`func (o *ConsulGateway) SetIngressNil(b bool)` + + SetIngressNil sets the value for Ingress to be an explicit nil + +### UnsetIngress +`func (o *ConsulGateway) UnsetIngress()` + +UnsetIngress ensures that no value is present for Ingress, not even an explicit nil ### GetMesh `func (o *ConsulGateway) GetMesh() interface{}` @@ -113,6 +123,16 @@ SetProxy sets Proxy field to given value. HasProxy returns a boolean if a field has been set. +### SetProxyNil + +`func (o *ConsulGateway) SetProxyNil(b bool)` + + SetProxyNil sets the value for Proxy to be an explicit nil + +### UnsetProxy +`func (o *ConsulGateway) UnsetProxy()` + +UnsetProxy ensures that no value is present for Proxy, not even an explicit nil ### GetTerminating `func (o *ConsulGateway) GetTerminating() ConsulTerminatingConfigEntry` @@ -138,6 +158,16 @@ SetTerminating sets Terminating field to given value. HasTerminating returns a boolean if a field has been set. +### SetTerminatingNil + +`func (o *ConsulGateway) SetTerminatingNil(b bool)` + + SetTerminatingNil sets the value for Terminating to be an explicit nil + +### UnsetTerminating +`func (o *ConsulGateway) UnsetTerminating()` + +UnsetTerminating ensures that no value is present for Terminating, not even an explicit nil [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/go/v1/docs/ConsulIngressConfigEntry.md b/clients/go/v1/docs/ConsulIngressConfigEntry.md index a87c252e..c598d15c 100644 --- a/clients/go/v1/docs/ConsulIngressConfigEntry.md +++ b/clients/go/v1/docs/ConsulIngressConfigEntry.md @@ -5,7 +5,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **Listeners** | Pointer to [**[]ConsulIngressListener**](ConsulIngressListener.md) | | [optional] -**TLS** | Pointer to [**ConsulGatewayTLSConfig**](ConsulGatewayTLSConfig.md) | | [optional] +**TLS** | Pointer to [**NullableConsulGatewayTLSConfig**](ConsulGatewayTLSConfig.md) | | [optional] ## Methods @@ -76,6 +76,16 @@ SetTLS sets TLS field to given value. HasTLS returns a boolean if a field has been set. +### SetTLSNil + +`func (o *ConsulIngressConfigEntry) SetTLSNil(b bool)` + + SetTLSNil sets the value for TLS to be an explicit nil + +### UnsetTLS +`func (o *ConsulIngressConfigEntry) UnsetTLS()` + +UnsetTLS ensures that no value is present for TLS, not even an explicit nil [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/go/v1/docs/ConsulProxy.md b/clients/go/v1/docs/ConsulProxy.md index 282aa1ad..57e5afbf 100644 --- a/clients/go/v1/docs/ConsulProxy.md +++ b/clients/go/v1/docs/ConsulProxy.md @@ -5,7 +5,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **Config** | Pointer to **map[string]interface{}** | | [optional] -**ExposeConfig** | Pointer to [**ConsulExposeConfig**](ConsulExposeConfig.md) | | [optional] +**ExposeConfig** | Pointer to [**NullableConsulExposeConfig**](ConsulExposeConfig.md) | | [optional] **LocalServiceAddress** | Pointer to **string** | | [optional] **LocalServicePort** | Pointer to **int32** | | [optional] **Upstreams** | Pointer to [**[]ConsulUpstream**](ConsulUpstream.md) | | [optional] @@ -79,6 +79,16 @@ SetExposeConfig sets ExposeConfig field to given value. HasExposeConfig returns a boolean if a field has been set. +### SetExposeConfigNil + +`func (o *ConsulProxy) SetExposeConfigNil(b bool)` + + SetExposeConfigNil sets the value for ExposeConfig to be an explicit nil + +### UnsetExposeConfig +`func (o *ConsulProxy) UnsetExposeConfig()` + +UnsetExposeConfig ensures that no value is present for ExposeConfig, not even an explicit nil ### GetLocalServiceAddress `func (o *ConsulProxy) GetLocalServiceAddress() string` diff --git a/clients/go/v1/docs/ConsulSidecarService.md b/clients/go/v1/docs/ConsulSidecarService.md index 5526d737..bfa078d2 100644 --- a/clients/go/v1/docs/ConsulSidecarService.md +++ b/clients/go/v1/docs/ConsulSidecarService.md @@ -6,7 +6,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **DisableDefaultTCPCheck** | Pointer to **bool** | | [optional] **Port** | Pointer to **string** | | [optional] -**Proxy** | Pointer to [**ConsulProxy**](ConsulProxy.md) | | [optional] +**Proxy** | Pointer to [**NullableConsulProxy**](ConsulProxy.md) | | [optional] **Tags** | Pointer to **[]string** | | [optional] ## Methods @@ -103,6 +103,16 @@ SetProxy sets Proxy field to given value. HasProxy returns a boolean if a field has been set. +### SetProxyNil + +`func (o *ConsulSidecarService) SetProxyNil(b bool)` + + SetProxyNil sets the value for Proxy to be an explicit nil + +### UnsetProxy +`func (o *ConsulSidecarService) UnsetProxy()` + +UnsetProxy ensures that no value is present for Proxy, not even an explicit nil ### GetTags `func (o *ConsulSidecarService) GetTags() []string` diff --git a/clients/go/v1/docs/ConsulUpstream.md b/clients/go/v1/docs/ConsulUpstream.md index 84cf5ace..564ce5e6 100644 --- a/clients/go/v1/docs/ConsulUpstream.md +++ b/clients/go/v1/docs/ConsulUpstream.md @@ -9,7 +9,7 @@ Name | Type | Description | Notes **DestinationNamespace** | Pointer to **string** | | [optional] **LocalBindAddress** | Pointer to **string** | | [optional] **LocalBindPort** | Pointer to **int32** | | [optional] -**MeshGateway** | Pointer to [**ConsulMeshGateway**](ConsulMeshGateway.md) | | [optional] +**MeshGateway** | Pointer to [**NullableConsulMeshGateway**](ConsulMeshGateway.md) | | [optional] ## Methods @@ -180,6 +180,16 @@ SetMeshGateway sets MeshGateway field to given value. HasMeshGateway returns a boolean if a field has been set. +### SetMeshGatewayNil + +`func (o *ConsulUpstream) SetMeshGatewayNil(b bool)` + + SetMeshGatewayNil sets the value for MeshGateway to be an explicit nil + +### UnsetMeshGateway +`func (o *ConsulUpstream) UnsetMeshGateway()` + +UnsetMeshGateway ensures that no value is present for MeshGateway, not even an explicit nil [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/go/v1/docs/DeploymentState.md b/clients/go/v1/docs/DeploymentState.md index 93dd3cbf..9290d4ef 100644 --- a/clients/go/v1/docs/DeploymentState.md +++ b/clients/go/v1/docs/DeploymentState.md @@ -12,7 +12,7 @@ Name | Type | Description | Notes **PlacedCanaries** | Pointer to **[]string** | | [optional] **ProgressDeadline** | Pointer to **int64** | | [optional] **Promoted** | Pointer to **bool** | | [optional] -**RequireProgressBy** | Pointer to **time.Time** | | [optional] +**RequireProgressBy** | Pointer to **NullableTime** | | [optional] **UnhealthyAllocs** | Pointer to **int32** | | [optional] ## Methods @@ -259,6 +259,16 @@ SetRequireProgressBy sets RequireProgressBy field to given value. HasRequireProgressBy returns a boolean if a field has been set. +### SetRequireProgressByNil + +`func (o *DeploymentState) SetRequireProgressByNil(b bool)` + + SetRequireProgressByNil sets the value for RequireProgressBy to be an explicit nil + +### UnsetRequireProgressBy +`func (o *DeploymentState) UnsetRequireProgressBy()` + +UnsetRequireProgressBy ensures that no value is present for RequireProgressBy, not even an explicit nil ### GetUnhealthyAllocs `func (o *DeploymentState) GetUnhealthyAllocs() int32` diff --git a/clients/go/v1/docs/DeploymentsApi.md b/clients/go/v1/docs/DeploymentsApi.md index 0c9f34d2..b50ca9d4 100644 --- a/clients/go/v1/docs/DeploymentsApi.md +++ b/clients/go/v1/docs/DeploymentsApi.md @@ -46,8 +46,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.DeploymentsApi.GetDeployment(context.Background(), deploymentID).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.DeploymentsApi.GetDeployment(context.Background(), deploymentID).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `DeploymentsApi.GetDeployment``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -132,8 +132,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.DeploymentsApi.GetDeploymentAllocations(context.Background(), deploymentID).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.DeploymentsApi.GetDeploymentAllocations(context.Background(), deploymentID).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `DeploymentsApi.GetDeploymentAllocations``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -217,8 +217,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.DeploymentsApi.GetDeployments(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.DeploymentsApi.GetDeployments(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `DeploymentsApi.GetDeployments``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -294,8 +294,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.DeploymentsApi.PostDeploymentAllocationHealth(context.Background(), deploymentID).DeploymentAllocHealthRequest(deploymentAllocHealthRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.DeploymentsApi.PostDeploymentAllocationHealth(context.Background(), deploymentID).DeploymentAllocHealthRequest(deploymentAllocHealthRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `DeploymentsApi.PostDeploymentAllocationHealth``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -371,8 +371,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.DeploymentsApi.PostDeploymentFail(context.Background(), deploymentID).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.DeploymentsApi.PostDeploymentFail(context.Background(), deploymentID).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `DeploymentsApi.PostDeploymentFail``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -448,8 +448,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.DeploymentsApi.PostDeploymentPause(context.Background(), deploymentID).DeploymentPauseRequest(deploymentPauseRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.DeploymentsApi.PostDeploymentPause(context.Background(), deploymentID).DeploymentPauseRequest(deploymentPauseRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `DeploymentsApi.PostDeploymentPause``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -526,8 +526,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.DeploymentsApi.PostDeploymentPromote(context.Background(), deploymentID).DeploymentPromoteRequest(deploymentPromoteRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.DeploymentsApi.PostDeploymentPromote(context.Background(), deploymentID).DeploymentPromoteRequest(deploymentPromoteRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `DeploymentsApi.PostDeploymentPromote``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -604,8 +604,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.DeploymentsApi.PostDeploymentUnblock(context.Background(), deploymentID).DeploymentUnblockRequest(deploymentUnblockRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.DeploymentsApi.PostDeploymentUnblock(context.Background(), deploymentID).DeploymentUnblockRequest(deploymentUnblockRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `DeploymentsApi.PostDeploymentUnblock``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) diff --git a/clients/go/v1/docs/DrainMetadata.md b/clients/go/v1/docs/DrainMetadata.md index 3d8ac78f..2e32724c 100644 --- a/clients/go/v1/docs/DrainMetadata.md +++ b/clients/go/v1/docs/DrainMetadata.md @@ -6,9 +6,9 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **AccessorID** | Pointer to **string** | | [optional] **Meta** | Pointer to **map[string]string** | | [optional] -**StartedAt** | Pointer to **time.Time** | | [optional] +**StartedAt** | Pointer to **NullableTime** | | [optional] **Status** | Pointer to **string** | | [optional] -**UpdatedAt** | Pointer to **time.Time** | | [optional] +**UpdatedAt** | Pointer to **NullableTime** | | [optional] ## Methods @@ -104,6 +104,16 @@ SetStartedAt sets StartedAt field to given value. HasStartedAt returns a boolean if a field has been set. +### SetStartedAtNil + +`func (o *DrainMetadata) SetStartedAtNil(b bool)` + + SetStartedAtNil sets the value for StartedAt to be an explicit nil + +### UnsetStartedAt +`func (o *DrainMetadata) UnsetStartedAt()` + +UnsetStartedAt ensures that no value is present for StartedAt, not even an explicit nil ### GetStatus `func (o *DrainMetadata) GetStatus() string` @@ -154,6 +164,16 @@ SetUpdatedAt sets UpdatedAt field to given value. HasUpdatedAt returns a boolean if a field has been set. +### SetUpdatedAtNil + +`func (o *DrainMetadata) SetUpdatedAtNil(b bool)` + + SetUpdatedAtNil sets the value for UpdatedAt to be an explicit nil + +### UnsetUpdatedAt +`func (o *DrainMetadata) UnsetUpdatedAt()` + +UnsetUpdatedAt ensures that no value is present for UpdatedAt, not even an explicit nil [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/go/v1/docs/DrainStrategy.md b/clients/go/v1/docs/DrainStrategy.md index 765e65d3..0a5e4ab2 100644 --- a/clients/go/v1/docs/DrainStrategy.md +++ b/clients/go/v1/docs/DrainStrategy.md @@ -5,9 +5,9 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **Deadline** | Pointer to **int64** | | [optional] -**ForceDeadline** | Pointer to **time.Time** | | [optional] +**ForceDeadline** | Pointer to **NullableTime** | | [optional] **IgnoreSystemJobs** | Pointer to **bool** | | [optional] -**StartedAt** | Pointer to **time.Time** | | [optional] +**StartedAt** | Pointer to **NullableTime** | | [optional] ## Methods @@ -78,6 +78,16 @@ SetForceDeadline sets ForceDeadline field to given value. HasForceDeadline returns a boolean if a field has been set. +### SetForceDeadlineNil + +`func (o *DrainStrategy) SetForceDeadlineNil(b bool)` + + SetForceDeadlineNil sets the value for ForceDeadline to be an explicit nil + +### UnsetForceDeadline +`func (o *DrainStrategy) UnsetForceDeadline()` + +UnsetForceDeadline ensures that no value is present for ForceDeadline, not even an explicit nil ### GetIgnoreSystemJobs `func (o *DrainStrategy) GetIgnoreSystemJobs() bool` @@ -128,6 +138,16 @@ SetStartedAt sets StartedAt field to given value. HasStartedAt returns a boolean if a field has been set. +### SetStartedAtNil + +`func (o *DrainStrategy) SetStartedAtNil(b bool)` + + SetStartedAtNil sets the value for StartedAt to be an explicit nil + +### UnsetStartedAt +`func (o *DrainStrategy) UnsetStartedAt()` + +UnsetStartedAt ensures that no value is present for StartedAt, not even an explicit nil [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/go/v1/docs/DriverInfo.md b/clients/go/v1/docs/DriverInfo.md index e26db6e3..e15592f9 100644 --- a/clients/go/v1/docs/DriverInfo.md +++ b/clients/go/v1/docs/DriverInfo.md @@ -8,7 +8,7 @@ Name | Type | Description | Notes **Detected** | Pointer to **bool** | | [optional] **HealthDescription** | Pointer to **string** | | [optional] **Healthy** | Pointer to **bool** | | [optional] -**UpdateTime** | Pointer to **time.Time** | | [optional] +**UpdateTime** | Pointer to **NullableTime** | | [optional] ## Methods @@ -154,6 +154,16 @@ SetUpdateTime sets UpdateTime field to given value. HasUpdateTime returns a boolean if a field has been set. +### SetUpdateTimeNil + +`func (o *DriverInfo) SetUpdateTimeNil(b bool)` + + SetUpdateTimeNil sets the value for UpdateTime to be an explicit nil + +### UnsetUpdateTime +`func (o *DriverInfo) UnsetUpdateTime()` + +UnsetUpdateTime ensures that no value is present for UpdateTime, not even an explicit nil [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/go/v1/docs/EnterpriseApi.md b/clients/go/v1/docs/EnterpriseApi.md index 920156e1..e6374049 100644 --- a/clients/go/v1/docs/EnterpriseApi.md +++ b/clients/go/v1/docs/EnterpriseApi.md @@ -38,8 +38,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.EnterpriseApi.CreateQuotaSpec(context.Background()).QuotaSpec(quotaSpec).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.EnterpriseApi.CreateQuotaSpec(context.Background()).QuotaSpec(quotaSpec).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `EnterpriseApi.CreateQuotaSpec``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -108,8 +108,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.EnterpriseApi.DeleteQuotaSpec(context.Background(), specName).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.EnterpriseApi.DeleteQuotaSpec(context.Background(), specName).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `EnterpriseApi.DeleteQuotaSpec``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -187,8 +187,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.EnterpriseApi.GetQuotaSpec(context.Background(), specName).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.EnterpriseApi.GetQuotaSpec(context.Background(), specName).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `EnterpriseApi.GetQuotaSpec``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -272,8 +272,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.EnterpriseApi.GetQuotas(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.EnterpriseApi.GetQuotas(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `EnterpriseApi.GetQuotas``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -349,8 +349,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.EnterpriseApi.PostQuotaSpec(context.Background(), specName).QuotaSpec(quotaSpec).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.EnterpriseApi.PostQuotaSpec(context.Background(), specName).QuotaSpec(quotaSpec).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `EnterpriseApi.PostQuotaSpec``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) diff --git a/clients/go/v1/docs/Evaluation.md b/clients/go/v1/docs/Evaluation.md index cb4d4577..643be220 100644 --- a/clients/go/v1/docs/Evaluation.md +++ b/clients/go/v1/docs/Evaluation.md @@ -32,7 +32,7 @@ Name | Type | Description | Notes **TriggeredBy** | Pointer to **string** | | [optional] **Type** | Pointer to **string** | | [optional] **Wait** | Pointer to **int64** | | [optional] -**WaitUntil** | Pointer to **time.Time** | | [optional] +**WaitUntil** | Pointer to **NullableTime** | | [optional] ## Methods @@ -778,6 +778,16 @@ SetWaitUntil sets WaitUntil field to given value. HasWaitUntil returns a boolean if a field has been set. +### SetWaitUntilNil + +`func (o *Evaluation) SetWaitUntilNil(b bool)` + + SetWaitUntilNil sets the value for WaitUntil to be an explicit nil + +### UnsetWaitUntil +`func (o *Evaluation) UnsetWaitUntil()` + +UnsetWaitUntil ensures that no value is present for WaitUntil, not even an explicit nil [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/go/v1/docs/EvaluationStub.md b/clients/go/v1/docs/EvaluationStub.md index e18d280b..93d37be3 100644 --- a/clients/go/v1/docs/EvaluationStub.md +++ b/clients/go/v1/docs/EvaluationStub.md @@ -21,7 +21,7 @@ Name | Type | Description | Notes **StatusDescription** | Pointer to **string** | | [optional] **TriggeredBy** | Pointer to **string** | | [optional] **Type** | Pointer to **string** | | [optional] -**WaitUntil** | Pointer to **time.Time** | | [optional] +**WaitUntil** | Pointer to **NullableTime** | | [optional] ## Methods @@ -492,6 +492,16 @@ SetWaitUntil sets WaitUntil field to given value. HasWaitUntil returns a boolean if a field has been set. +### SetWaitUntilNil + +`func (o *EvaluationStub) SetWaitUntilNil(b bool)` + + SetWaitUntilNil sets the value for WaitUntil to be an explicit nil + +### UnsetWaitUntil +`func (o *EvaluationStub) UnsetWaitUntil()` + +UnsetWaitUntil ensures that no value is present for WaitUntil, not even an explicit nil [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/go/v1/docs/EvaluationsApi.md b/clients/go/v1/docs/EvaluationsApi.md index 229b0296..700942db 100644 --- a/clients/go/v1/docs/EvaluationsApi.md +++ b/clients/go/v1/docs/EvaluationsApi.md @@ -41,8 +41,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.EvaluationsApi.GetEvaluation(context.Background(), evalID).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.EvaluationsApi.GetEvaluation(context.Background(), evalID).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `EvaluationsApi.GetEvaluation``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -127,8 +127,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.EvaluationsApi.GetEvaluationAllocations(context.Background(), evalID).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.EvaluationsApi.GetEvaluationAllocations(context.Background(), evalID).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `EvaluationsApi.GetEvaluationAllocations``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -212,8 +212,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.EvaluationsApi.GetEvaluations(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.EvaluationsApi.GetEvaluations(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `EvaluationsApi.GetEvaluations``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) diff --git a/clients/go/v1/docs/Job.md b/clients/go/v1/docs/Job.md index 8746e016..e3becc20 100644 --- a/clients/go/v1/docs/Job.md +++ b/clients/go/v1/docs/Job.md @@ -18,11 +18,11 @@ Name | Type | Description | Notes **Meta** | Pointer to **map[string]string** | | [optional] **Migrate** | Pointer to [**MigrateStrategy**](MigrateStrategy.md) | | [optional] **ModifyIndex** | Pointer to **int32** | | [optional] -**Multiregion** | Pointer to [**Multiregion**](Multiregion.md) | | [optional] +**Multiregion** | Pointer to [**NullableMultiregion**](Multiregion.md) | | [optional] **Name** | Pointer to **string** | | [optional] **Namespace** | Pointer to **string** | | [optional] **NomadTokenID** | Pointer to **string** | | [optional] -**ParameterizedJob** | Pointer to [**ParameterizedJobConfig**](ParameterizedJobConfig.md) | | [optional] +**ParameterizedJob** | Pointer to [**NullableParameterizedJobConfig**](ParameterizedJobConfig.md) | | [optional] **ParentID** | Pointer to **string** | | [optional] **Payload** | Pointer to **string** | | [optional] **Periodic** | Pointer to [**PeriodicConfig**](PeriodicConfig.md) | | [optional] @@ -436,6 +436,16 @@ SetMultiregion sets Multiregion field to given value. HasMultiregion returns a boolean if a field has been set. +### SetMultiregionNil + +`func (o *Job) SetMultiregionNil(b bool)` + + SetMultiregionNil sets the value for Multiregion to be an explicit nil + +### UnsetMultiregion +`func (o *Job) UnsetMultiregion()` + +UnsetMultiregion ensures that no value is present for Multiregion, not even an explicit nil ### GetName `func (o *Job) GetName() string` @@ -536,6 +546,16 @@ SetParameterizedJob sets ParameterizedJob field to given value. HasParameterizedJob returns a boolean if a field has been set. +### SetParameterizedJobNil + +`func (o *Job) SetParameterizedJobNil(b bool)` + + SetParameterizedJobNil sets the value for ParameterizedJob to be an explicit nil + +### UnsetParameterizedJob +`func (o *Job) UnsetParameterizedJob()` + +UnsetParameterizedJob ensures that no value is present for ParameterizedJob, not even an explicit nil ### GetParentID `func (o *Job) GetParentID() string` diff --git a/clients/go/v1/docs/JobEvaluateRequest.md b/clients/go/v1/docs/JobEvaluateRequest.md index 4ea0bba9..f0481134 100644 --- a/clients/go/v1/docs/JobEvaluateRequest.md +++ b/clients/go/v1/docs/JobEvaluateRequest.md @@ -4,7 +4,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**EvalOptions** | Pointer to [**EvalOptions**](EvalOptions.md) | | [optional] +**EvalOptions** | Pointer to [**NullableEvalOptions**](EvalOptions.md) | | [optional] **JobID** | Pointer to **string** | | [optional] **Namespace** | Pointer to **string** | | [optional] **Region** | Pointer to **string** | | [optional] @@ -54,6 +54,16 @@ SetEvalOptions sets EvalOptions field to given value. HasEvalOptions returns a boolean if a field has been set. +### SetEvalOptionsNil + +`func (o *JobEvaluateRequest) SetEvalOptionsNil(b bool)` + + SetEvalOptionsNil sets the value for EvalOptions to be an explicit nil + +### UnsetEvalOptions +`func (o *JobEvaluateRequest) UnsetEvalOptions()` + +UnsetEvalOptions ensures that no value is present for EvalOptions, not even an explicit nil ### GetJobID `func (o *JobEvaluateRequest) GetJobID() string` diff --git a/clients/go/v1/docs/JobListStub.md b/clients/go/v1/docs/JobListStub.md index b3174504..8c3cb579 100644 --- a/clients/go/v1/docs/JobListStub.md +++ b/clients/go/v1/docs/JobListStub.md @@ -8,7 +8,7 @@ Name | Type | Description | Notes **Datacenters** | Pointer to **[]string** | | [optional] **ID** | Pointer to **string** | | [optional] **JobModifyIndex** | Pointer to **int32** | | [optional] -**JobSummary** | Pointer to [**JobSummary**](JobSummary.md) | | [optional] +**JobSummary** | Pointer to [**NullableJobSummary**](JobSummary.md) | | [optional] **ModifyIndex** | Pointer to **int32** | | [optional] **Name** | Pointer to **string** | | [optional] **Namespace** | Pointer to **string** | | [optional] @@ -166,6 +166,16 @@ SetJobSummary sets JobSummary field to given value. HasJobSummary returns a boolean if a field has been set. +### SetJobSummaryNil + +`func (o *JobListStub) SetJobSummaryNil(b bool)` + + SetJobSummaryNil sets the value for JobSummary to be an explicit nil + +### UnsetJobSummary +`func (o *JobListStub) UnsetJobSummary()` + +UnsetJobSummary ensures that no value is present for JobSummary, not even an explicit nil ### GetModifyIndex `func (o *JobListStub) GetModifyIndex() int32` diff --git a/clients/go/v1/docs/JobPlanRequest.md b/clients/go/v1/docs/JobPlanRequest.md index 6a56ba2c..7fe8d8b3 100644 --- a/clients/go/v1/docs/JobPlanRequest.md +++ b/clients/go/v1/docs/JobPlanRequest.md @@ -5,7 +5,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **Diff** | Pointer to **bool** | | [optional] -**Job** | Pointer to [**Job**](Job.md) | | [optional] +**Job** | Pointer to [**NullableJob**](Job.md) | | [optional] **Namespace** | Pointer to **string** | | [optional] **PolicyOverride** | Pointer to **bool** | | [optional] **Region** | Pointer to **string** | | [optional] @@ -80,6 +80,16 @@ SetJob sets Job field to given value. HasJob returns a boolean if a field has been set. +### SetJobNil + +`func (o *JobPlanRequest) SetJobNil(b bool)` + + SetJobNil sets the value for Job to be an explicit nil + +### UnsetJob +`func (o *JobPlanRequest) UnsetJob()` + +UnsetJob ensures that no value is present for Job, not even an explicit nil ### GetNamespace `func (o *JobPlanRequest) GetNamespace() string` diff --git a/clients/go/v1/docs/JobPlanResponse.md b/clients/go/v1/docs/JobPlanResponse.md index b622bd42..469929c6 100644 --- a/clients/go/v1/docs/JobPlanResponse.md +++ b/clients/go/v1/docs/JobPlanResponse.md @@ -4,12 +4,12 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Annotations** | Pointer to [**PlanAnnotations**](PlanAnnotations.md) | | [optional] +**Annotations** | Pointer to [**NullablePlanAnnotations**](PlanAnnotations.md) | | [optional] **CreatedEvals** | Pointer to [**[]Evaluation**](Evaluation.md) | | [optional] -**Diff** | Pointer to [**JobDiff**](JobDiff.md) | | [optional] +**Diff** | Pointer to [**NullableJobDiff**](JobDiff.md) | | [optional] **FailedTGAllocs** | Pointer to [**map[string]AllocationMetric**](AllocationMetric.md) | | [optional] **JobModifyIndex** | Pointer to **int32** | | [optional] -**NextPeriodicLaunch** | Pointer to **time.Time** | | [optional] +**NextPeriodicLaunch** | Pointer to **NullableTime** | | [optional] **Warnings** | Pointer to **string** | | [optional] ## Methods @@ -56,6 +56,16 @@ SetAnnotations sets Annotations field to given value. HasAnnotations returns a boolean if a field has been set. +### SetAnnotationsNil + +`func (o *JobPlanResponse) SetAnnotationsNil(b bool)` + + SetAnnotationsNil sets the value for Annotations to be an explicit nil + +### UnsetAnnotations +`func (o *JobPlanResponse) UnsetAnnotations()` + +UnsetAnnotations ensures that no value is present for Annotations, not even an explicit nil ### GetCreatedEvals `func (o *JobPlanResponse) GetCreatedEvals() []Evaluation` @@ -106,6 +116,16 @@ SetDiff sets Diff field to given value. HasDiff returns a boolean if a field has been set. +### SetDiffNil + +`func (o *JobPlanResponse) SetDiffNil(b bool)` + + SetDiffNil sets the value for Diff to be an explicit nil + +### UnsetDiff +`func (o *JobPlanResponse) UnsetDiff()` + +UnsetDiff ensures that no value is present for Diff, not even an explicit nil ### GetFailedTGAllocs `func (o *JobPlanResponse) GetFailedTGAllocs() map[string]AllocationMetric` @@ -181,6 +201,16 @@ SetNextPeriodicLaunch sets NextPeriodicLaunch field to given value. HasNextPeriodicLaunch returns a boolean if a field has been set. +### SetNextPeriodicLaunchNil + +`func (o *JobPlanResponse) SetNextPeriodicLaunchNil(b bool)` + + SetNextPeriodicLaunchNil sets the value for NextPeriodicLaunch to be an explicit nil + +### UnsetNextPeriodicLaunch +`func (o *JobPlanResponse) UnsetNextPeriodicLaunch()` + +UnsetNextPeriodicLaunch ensures that no value is present for NextPeriodicLaunch, not even an explicit nil ### GetWarnings `func (o *JobPlanResponse) GetWarnings() string` diff --git a/clients/go/v1/docs/JobRegisterRequest.md b/clients/go/v1/docs/JobRegisterRequest.md index 2a7ed33b..2b9ca7df 100644 --- a/clients/go/v1/docs/JobRegisterRequest.md +++ b/clients/go/v1/docs/JobRegisterRequest.md @@ -6,7 +6,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **EnforceIndex** | Pointer to **bool** | | [optional] **EvalPriority** | Pointer to **int32** | | [optional] -**Job** | Pointer to [**Job**](Job.md) | | [optional] +**Job** | Pointer to [**NullableJob**](Job.md) | | [optional] **JobModifyIndex** | Pointer to **int32** | | [optional] **Namespace** | Pointer to **string** | | [optional] **PolicyOverride** | Pointer to **bool** | | [optional] @@ -108,6 +108,16 @@ SetJob sets Job field to given value. HasJob returns a boolean if a field has been set. +### SetJobNil + +`func (o *JobRegisterRequest) SetJobNil(b bool)` + + SetJobNil sets the value for Job to be an explicit nil + +### UnsetJob +`func (o *JobRegisterRequest) UnsetJob()` + +UnsetJob ensures that no value is present for Job, not even an explicit nil ### GetJobModifyIndex `func (o *JobRegisterRequest) GetJobModifyIndex() int32` diff --git a/clients/go/v1/docs/JobSummary.md b/clients/go/v1/docs/JobSummary.md index 6ce0e9e1..7aaaff16 100644 --- a/clients/go/v1/docs/JobSummary.md +++ b/clients/go/v1/docs/JobSummary.md @@ -4,7 +4,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Children** | Pointer to [**JobChildrenSummary**](JobChildrenSummary.md) | | [optional] +**Children** | Pointer to [**NullableJobChildrenSummary**](JobChildrenSummary.md) | | [optional] **CreateIndex** | Pointer to **int32** | | [optional] **JobID** | Pointer to **string** | | [optional] **ModifyIndex** | Pointer to **int32** | | [optional] @@ -55,6 +55,16 @@ SetChildren sets Children field to given value. HasChildren returns a boolean if a field has been set. +### SetChildrenNil + +`func (o *JobSummary) SetChildrenNil(b bool)` + + SetChildrenNil sets the value for Children to be an explicit nil + +### UnsetChildren +`func (o *JobSummary) UnsetChildren()` + +UnsetChildren ensures that no value is present for Children, not even an explicit nil ### GetCreateIndex `func (o *JobSummary) GetCreateIndex() int32` diff --git a/clients/go/v1/docs/JobValidateRequest.md b/clients/go/v1/docs/JobValidateRequest.md index e4f20460..f93b3116 100644 --- a/clients/go/v1/docs/JobValidateRequest.md +++ b/clients/go/v1/docs/JobValidateRequest.md @@ -4,7 +4,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Job** | Pointer to [**Job**](Job.md) | | [optional] +**Job** | Pointer to [**NullableJob**](Job.md) | | [optional] **Namespace** | Pointer to **string** | | [optional] **Region** | Pointer to **string** | | [optional] **SecretID** | Pointer to **string** | | [optional] @@ -53,6 +53,16 @@ SetJob sets Job field to given value. HasJob returns a boolean if a field has been set. +### SetJobNil + +`func (o *JobValidateRequest) SetJobNil(b bool)` + + SetJobNil sets the value for Job to be an explicit nil + +### UnsetJob +`func (o *JobValidateRequest) UnsetJob()` + +UnsetJob ensures that no value is present for Job, not even an explicit nil ### GetNamespace `func (o *JobValidateRequest) GetNamespace() string` diff --git a/clients/go/v1/docs/JobsApi.md b/clients/go/v1/docs/JobsApi.md index d425c928..432f32e2 100644 --- a/clients/go/v1/docs/JobsApi.md +++ b/clients/go/v1/docs/JobsApi.md @@ -56,8 +56,8 @@ func main() { global := true // bool | Boolean flag indicating whether the operation should apply to all instances of the job globally. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.JobsApi.DeleteJob(context.Background(), jobName).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Purge(purge).Global(global).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.JobsApi.DeleteJob(context.Background(), jobName).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Purge(purge).Global(global).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `JobsApi.DeleteJob``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -139,8 +139,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.JobsApi.GetJob(context.Background(), jobName).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.JobsApi.GetJob(context.Background(), jobName).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `JobsApi.GetJob``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -226,8 +226,8 @@ func main() { all := true // bool | Specifies whether the list of allocations should include allocations from a previously registered job with the same ID. This is possible if the job is deregistered and reregistered. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.JobsApi.GetJobAllocations(context.Background(), jobName).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).All(all).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.JobsApi.GetJobAllocations(context.Background(), jobName).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).All(all).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `JobsApi.GetJobAllocations``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -313,8 +313,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.JobsApi.GetJobDeployment(context.Background(), jobName).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.JobsApi.GetJobDeployment(context.Background(), jobName).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `JobsApi.GetJobDeployment``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -400,8 +400,8 @@ func main() { all := int32(56) // int32 | Flag indicating whether to constrain by job creation index or not. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.JobsApi.GetJobDeployments(context.Background(), jobName).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).All(all).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.JobsApi.GetJobDeployments(context.Background(), jobName).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).All(all).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `JobsApi.GetJobDeployments``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -487,8 +487,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.JobsApi.GetJobEvaluations(context.Background(), jobName).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.JobsApi.GetJobEvaluations(context.Background(), jobName).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `JobsApi.GetJobEvaluations``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -573,8 +573,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.JobsApi.GetJobScaleStatus(context.Background(), jobName).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.JobsApi.GetJobScaleStatus(context.Background(), jobName).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `JobsApi.GetJobScaleStatus``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -659,8 +659,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.JobsApi.GetJobSummary(context.Background(), jobName).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.JobsApi.GetJobSummary(context.Background(), jobName).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `JobsApi.GetJobSummary``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -746,8 +746,8 @@ func main() { diffs := true // bool | Boolean flag indicating whether to compute job diffs. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.JobsApi.GetJobVersions(context.Background(), jobName).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Diffs(diffs).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.JobsApi.GetJobVersions(context.Background(), jobName).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Diffs(diffs).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `JobsApi.GetJobVersions``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -832,8 +832,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.JobsApi.GetJobs(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.JobsApi.GetJobs(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `JobsApi.GetJobs``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -909,8 +909,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.JobsApi.PostJob(context.Background(), jobName).JobRegisterRequest(jobRegisterRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.JobsApi.PostJob(context.Background(), jobName).JobRegisterRequest(jobRegisterRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `JobsApi.PostJob``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -987,8 +987,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.JobsApi.PostJobDispatch(context.Background(), jobName).JobDispatchRequest(jobDispatchRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.JobsApi.PostJobDispatch(context.Background(), jobName).JobDispatchRequest(jobDispatchRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `JobsApi.PostJobDispatch``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -1065,8 +1065,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.JobsApi.PostJobEvaluate(context.Background(), jobName).JobEvaluateRequest(jobEvaluateRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.JobsApi.PostJobEvaluate(context.Background(), jobName).JobEvaluateRequest(jobEvaluateRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `JobsApi.PostJobEvaluate``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -1138,8 +1138,8 @@ func main() { jobsParseRequest := *openapiclient.NewJobsParseRequest() // JobsParseRequest | configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.JobsApi.PostJobParse(context.Background()).JobsParseRequest(jobsParseRequest).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.JobsApi.PostJobParse(context.Background()).JobsParseRequest(jobsParseRequest).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `JobsApi.PostJobParse``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -1206,8 +1206,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.JobsApi.PostJobPeriodicForce(context.Background(), jobName).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.JobsApi.PostJobPeriodicForce(context.Background(), jobName).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `JobsApi.PostJobPeriodicForce``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -1283,8 +1283,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.JobsApi.PostJobPlan(context.Background(), jobName).JobPlanRequest(jobPlanRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.JobsApi.PostJobPlan(context.Background(), jobName).JobPlanRequest(jobPlanRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `JobsApi.PostJobPlan``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -1361,8 +1361,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.JobsApi.PostJobRevert(context.Background(), jobName).JobRevertRequest(jobRevertRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.JobsApi.PostJobRevert(context.Background(), jobName).JobRevertRequest(jobRevertRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `JobsApi.PostJobRevert``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -1439,8 +1439,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.JobsApi.PostJobScalingRequest(context.Background(), jobName).ScalingRequest(scalingRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.JobsApi.PostJobScalingRequest(context.Background(), jobName).ScalingRequest(scalingRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `JobsApi.PostJobScalingRequest``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -1517,8 +1517,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.JobsApi.PostJobStability(context.Background(), jobName).JobStabilityRequest(jobStabilityRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.JobsApi.PostJobStability(context.Background(), jobName).JobStabilityRequest(jobStabilityRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `JobsApi.PostJobStability``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -1594,8 +1594,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.JobsApi.PostJobValidateRequest(context.Background()).JobValidateRequest(jobValidateRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.JobsApi.PostJobValidateRequest(context.Background()).JobValidateRequest(jobValidateRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `JobsApi.PostJobValidateRequest``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -1666,8 +1666,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.JobsApi.RegisterJob(context.Background()).JobRegisterRequest(jobRegisterRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.JobsApi.RegisterJob(context.Background()).JobRegisterRequest(jobRegisterRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `JobsApi.RegisterJob``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) diff --git a/clients/go/v1/docs/MetricsApi.md b/clients/go/v1/docs/MetricsApi.md index 7e7e9c25..2b4268b5 100644 --- a/clients/go/v1/docs/MetricsApi.md +++ b/clients/go/v1/docs/MetricsApi.md @@ -30,8 +30,8 @@ func main() { format := "format_example" // string | The format the user requested for the metrics summary (e.g. prometheus) (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.MetricsApi.GetMetricsSummary(context.Background()).Format(format).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.MetricsApi.GetMetricsSummary(context.Background()).Format(format).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `MetricsApi.GetMetricsSummary``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) diff --git a/clients/go/v1/docs/Namespace.md b/clients/go/v1/docs/Namespace.md index 0e2c0999..a4ed8583 100644 --- a/clients/go/v1/docs/Namespace.md +++ b/clients/go/v1/docs/Namespace.md @@ -4,7 +4,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Capabilities** | Pointer to [**NamespaceCapabilities**](NamespaceCapabilities.md) | | [optional] +**Capabilities** | Pointer to [**NullableNamespaceCapabilities**](NamespaceCapabilities.md) | | [optional] **CreateIndex** | Pointer to **int32** | | [optional] **Description** | Pointer to **string** | | [optional] **Meta** | Pointer to **map[string]string** | | [optional] @@ -56,6 +56,16 @@ SetCapabilities sets Capabilities field to given value. HasCapabilities returns a boolean if a field has been set. +### SetCapabilitiesNil + +`func (o *Namespace) SetCapabilitiesNil(b bool)` + + SetCapabilitiesNil sets the value for Capabilities to be an explicit nil + +### UnsetCapabilities +`func (o *Namespace) UnsetCapabilities()` + +UnsetCapabilities ensures that no value is present for Capabilities, not even an explicit nil ### GetCreateIndex `func (o *Namespace) GetCreateIndex() int32` diff --git a/clients/go/v1/docs/NamespacesApi.md b/clients/go/v1/docs/NamespacesApi.md index 89fe8e57..a90fd829 100644 --- a/clients/go/v1/docs/NamespacesApi.md +++ b/clients/go/v1/docs/NamespacesApi.md @@ -37,8 +37,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.NamespacesApi.CreateNamespace(context.Background()).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.NamespacesApi.CreateNamespace(context.Background()).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `NamespacesApi.CreateNamespace``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -106,8 +106,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.NamespacesApi.DeleteNamespace(context.Background(), namespaceName).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.NamespacesApi.DeleteNamespace(context.Background(), namespaceName).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `NamespacesApi.DeleteNamespace``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -185,8 +185,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.NamespacesApi.GetNamespace(context.Background(), namespaceName).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.NamespacesApi.GetNamespace(context.Background(), namespaceName).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `NamespacesApi.GetNamespace``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -270,8 +270,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.NamespacesApi.GetNamespaces(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.NamespacesApi.GetNamespaces(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `NamespacesApi.GetNamespaces``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -347,8 +347,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.NamespacesApi.PostNamespace(context.Background(), namespaceName).Namespace2(namespace2).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.NamespacesApi.PostNamespace(context.Background(), namespaceName).Namespace2(namespace2).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `NamespacesApi.PostNamespace``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) diff --git a/clients/go/v1/docs/NetworkResource.md b/clients/go/v1/docs/NetworkResource.md index e1731526..93a6040d 100644 --- a/clients/go/v1/docs/NetworkResource.md +++ b/clients/go/v1/docs/NetworkResource.md @@ -5,7 +5,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **CIDR** | Pointer to **string** | | [optional] -**DNS** | Pointer to [**DNSConfig**](DNSConfig.md) | | [optional] +**DNS** | Pointer to [**NullableDNSConfig**](DNSConfig.md) | | [optional] **Device** | Pointer to **string** | | [optional] **DynamicPorts** | Pointer to [**[]Port**](Port.md) | | [optional] **Hostname** | Pointer to **string** | | [optional] @@ -83,6 +83,16 @@ SetDNS sets DNS field to given value. HasDNS returns a boolean if a field has been set. +### SetDNSNil + +`func (o *NetworkResource) SetDNSNil(b bool)` + + SetDNSNil sets the value for DNS to be an explicit nil + +### UnsetDNS +`func (o *NetworkResource) UnsetDNS()` + +UnsetDNS ensures that no value is present for DNS, not even an explicit nil ### GetDevice `func (o *NetworkResource) GetDevice() string` diff --git a/clients/go/v1/docs/Node.md b/clients/go/v1/docs/Node.md index 77680f3d..fbfadc0a 100644 --- a/clients/go/v1/docs/Node.md +++ b/clients/go/v1/docs/Node.md @@ -11,23 +11,23 @@ Name | Type | Description | Notes **CreateIndex** | Pointer to **int32** | | [optional] **Datacenter** | Pointer to **string** | | [optional] **Drain** | Pointer to **bool** | | [optional] -**DrainStrategy** | Pointer to [**DrainStrategy**](DrainStrategy.md) | | [optional] +**DrainStrategy** | Pointer to [**NullableDrainStrategy**](DrainStrategy.md) | | [optional] **Drivers** | Pointer to [**map[string]DriverInfo**](DriverInfo.md) | | [optional] **Events** | Pointer to [**[]NodeEvent**](NodeEvent.md) | | [optional] **HTTPAddr** | Pointer to **string** | | [optional] **HostNetworks** | Pointer to [**map[string]HostNetworkInfo**](HostNetworkInfo.md) | | [optional] **HostVolumes** | Pointer to [**map[string]HostVolumeInfo**](HostVolumeInfo.md) | | [optional] **ID** | Pointer to **string** | | [optional] -**LastDrain** | Pointer to [**DrainMetadata**](DrainMetadata.md) | | [optional] +**LastDrain** | Pointer to [**NullableDrainMetadata**](DrainMetadata.md) | | [optional] **Links** | Pointer to **map[string]string** | | [optional] **Meta** | Pointer to **map[string]string** | | [optional] **ModifyIndex** | Pointer to **int32** | | [optional] **Name** | Pointer to **string** | | [optional] **NodeClass** | Pointer to **string** | | [optional] -**NodeResources** | Pointer to [**NodeResources**](NodeResources.md) | | [optional] -**Reserved** | Pointer to [**Resources**](Resources.md) | | [optional] -**ReservedResources** | Pointer to [**NodeReservedResources**](NodeReservedResources.md) | | [optional] -**Resources** | Pointer to [**Resources**](Resources.md) | | [optional] +**NodeResources** | Pointer to [**NullableNodeResources**](NodeResources.md) | | [optional] +**Reserved** | Pointer to [**NullableResources**](Resources.md) | | [optional] +**ReservedResources** | Pointer to [**NullableNodeReservedResources**](NodeReservedResources.md) | | [optional] +**Resources** | Pointer to [**NullableResources**](Resources.md) | | [optional] **SchedulingEligibility** | Pointer to **string** | | [optional] **Status** | Pointer to **string** | | [optional] **StatusDescription** | Pointer to **string** | | [optional] @@ -253,6 +253,16 @@ SetDrainStrategy sets DrainStrategy field to given value. HasDrainStrategy returns a boolean if a field has been set. +### SetDrainStrategyNil + +`func (o *Node) SetDrainStrategyNil(b bool)` + + SetDrainStrategyNil sets the value for DrainStrategy to be an explicit nil + +### UnsetDrainStrategy +`func (o *Node) UnsetDrainStrategy()` + +UnsetDrainStrategy ensures that no value is present for DrainStrategy, not even an explicit nil ### GetDrivers `func (o *Node) GetDrivers() map[string]DriverInfo` @@ -428,6 +438,16 @@ SetLastDrain sets LastDrain field to given value. HasLastDrain returns a boolean if a field has been set. +### SetLastDrainNil + +`func (o *Node) SetLastDrainNil(b bool)` + + SetLastDrainNil sets the value for LastDrain to be an explicit nil + +### UnsetLastDrain +`func (o *Node) UnsetLastDrain()` + +UnsetLastDrain ensures that no value is present for LastDrain, not even an explicit nil ### GetLinks `func (o *Node) GetLinks() map[string]string` @@ -578,6 +598,16 @@ SetNodeResources sets NodeResources field to given value. HasNodeResources returns a boolean if a field has been set. +### SetNodeResourcesNil + +`func (o *Node) SetNodeResourcesNil(b bool)` + + SetNodeResourcesNil sets the value for NodeResources to be an explicit nil + +### UnsetNodeResources +`func (o *Node) UnsetNodeResources()` + +UnsetNodeResources ensures that no value is present for NodeResources, not even an explicit nil ### GetReserved `func (o *Node) GetReserved() Resources` @@ -603,6 +633,16 @@ SetReserved sets Reserved field to given value. HasReserved returns a boolean if a field has been set. +### SetReservedNil + +`func (o *Node) SetReservedNil(b bool)` + + SetReservedNil sets the value for Reserved to be an explicit nil + +### UnsetReserved +`func (o *Node) UnsetReserved()` + +UnsetReserved ensures that no value is present for Reserved, not even an explicit nil ### GetReservedResources `func (o *Node) GetReservedResources() NodeReservedResources` @@ -628,6 +668,16 @@ SetReservedResources sets ReservedResources field to given value. HasReservedResources returns a boolean if a field has been set. +### SetReservedResourcesNil + +`func (o *Node) SetReservedResourcesNil(b bool)` + + SetReservedResourcesNil sets the value for ReservedResources to be an explicit nil + +### UnsetReservedResources +`func (o *Node) UnsetReservedResources()` + +UnsetReservedResources ensures that no value is present for ReservedResources, not even an explicit nil ### GetResources `func (o *Node) GetResources() Resources` @@ -653,6 +703,16 @@ SetResources sets Resources field to given value. HasResources returns a boolean if a field has been set. +### SetResourcesNil + +`func (o *Node) SetResourcesNil(b bool)` + + SetResourcesNil sets the value for Resources to be an explicit nil + +### UnsetResources +`func (o *Node) UnsetResources()` + +UnsetResources ensures that no value is present for Resources, not even an explicit nil ### GetSchedulingEligibility `func (o *Node) GetSchedulingEligibility() string` diff --git a/clients/go/v1/docs/NodeDevice.md b/clients/go/v1/docs/NodeDevice.md index e432a48c..09e579f8 100644 --- a/clients/go/v1/docs/NodeDevice.md +++ b/clients/go/v1/docs/NodeDevice.md @@ -7,7 +7,7 @@ Name | Type | Description | Notes **HealthDescription** | Pointer to **string** | | [optional] **Healthy** | Pointer to **bool** | | [optional] **ID** | Pointer to **string** | | [optional] -**Locality** | Pointer to [**NodeDeviceLocality**](NodeDeviceLocality.md) | | [optional] +**Locality** | Pointer to [**NullableNodeDeviceLocality**](NodeDeviceLocality.md) | | [optional] ## Methods @@ -128,6 +128,16 @@ SetLocality sets Locality field to given value. HasLocality returns a boolean if a field has been set. +### SetLocalityNil + +`func (o *NodeDevice) SetLocalityNil(b bool)` + + SetLocalityNil sets the value for Locality to be an explicit nil + +### UnsetLocality +`func (o *NodeDevice) UnsetLocality()` + +UnsetLocality ensures that no value is present for Locality, not even an explicit nil [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/go/v1/docs/NodeEvent.md b/clients/go/v1/docs/NodeEvent.md index 5ce2c5d7..cf049bf8 100644 --- a/clients/go/v1/docs/NodeEvent.md +++ b/clients/go/v1/docs/NodeEvent.md @@ -8,7 +8,7 @@ Name | Type | Description | Notes **Details** | Pointer to **map[string]string** | | [optional] **Message** | Pointer to **string** | | [optional] **Subsystem** | Pointer to **string** | | [optional] -**Timestamp** | Pointer to **time.Time** | | [optional] +**Timestamp** | Pointer to **NullableTime** | | [optional] ## Methods @@ -154,6 +154,16 @@ SetTimestamp sets Timestamp field to given value. HasTimestamp returns a boolean if a field has been set. +### SetTimestampNil + +`func (o *NodeEvent) SetTimestampNil(b bool)` + + SetTimestampNil sets the value for Timestamp to be an explicit nil + +### UnsetTimestamp +`func (o *NodeEvent) UnsetTimestamp()` + +UnsetTimestamp ensures that no value is present for Timestamp, not even an explicit nil [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/go/v1/docs/NodeListStub.md b/clients/go/v1/docs/NodeListStub.md index 776ba1cf..bd4cd4e0 100644 --- a/clients/go/v1/docs/NodeListStub.md +++ b/clients/go/v1/docs/NodeListStub.md @@ -11,12 +11,12 @@ Name | Type | Description | Notes **Drain** | Pointer to **bool** | | [optional] **Drivers** | Pointer to [**map[string]DriverInfo**](DriverInfo.md) | | [optional] **ID** | Pointer to **string** | | [optional] -**LastDrain** | Pointer to [**DrainMetadata**](DrainMetadata.md) | | [optional] +**LastDrain** | Pointer to [**NullableDrainMetadata**](DrainMetadata.md) | | [optional] **ModifyIndex** | Pointer to **int32** | | [optional] **Name** | Pointer to **string** | | [optional] **NodeClass** | Pointer to **string** | | [optional] -**NodeResources** | Pointer to [**NodeResources**](NodeResources.md) | | [optional] -**ReservedResources** | Pointer to [**NodeReservedResources**](NodeReservedResources.md) | | [optional] +**NodeResources** | Pointer to [**NullableNodeResources**](NodeResources.md) | | [optional] +**ReservedResources** | Pointer to [**NullableNodeReservedResources**](NodeReservedResources.md) | | [optional] **SchedulingEligibility** | Pointer to **string** | | [optional] **Status** | Pointer to **string** | | [optional] **StatusDescription** | Pointer to **string** | | [optional] @@ -241,6 +241,16 @@ SetLastDrain sets LastDrain field to given value. HasLastDrain returns a boolean if a field has been set. +### SetLastDrainNil + +`func (o *NodeListStub) SetLastDrainNil(b bool)` + + SetLastDrainNil sets the value for LastDrain to be an explicit nil + +### UnsetLastDrain +`func (o *NodeListStub) UnsetLastDrain()` + +UnsetLastDrain ensures that no value is present for LastDrain, not even an explicit nil ### GetModifyIndex `func (o *NodeListStub) GetModifyIndex() int32` @@ -341,6 +351,16 @@ SetNodeResources sets NodeResources field to given value. HasNodeResources returns a boolean if a field has been set. +### SetNodeResourcesNil + +`func (o *NodeListStub) SetNodeResourcesNil(b bool)` + + SetNodeResourcesNil sets the value for NodeResources to be an explicit nil + +### UnsetNodeResources +`func (o *NodeListStub) UnsetNodeResources()` + +UnsetNodeResources ensures that no value is present for NodeResources, not even an explicit nil ### GetReservedResources `func (o *NodeListStub) GetReservedResources() NodeReservedResources` @@ -366,6 +386,16 @@ SetReservedResources sets ReservedResources field to given value. HasReservedResources returns a boolean if a field has been set. +### SetReservedResourcesNil + +`func (o *NodeListStub) SetReservedResourcesNil(b bool)` + + SetReservedResourcesNil sets the value for ReservedResources to be an explicit nil + +### UnsetReservedResources +`func (o *NodeListStub) UnsetReservedResources()` + +UnsetReservedResources ensures that no value is present for ReservedResources, not even an explicit nil ### GetSchedulingEligibility `func (o *NodeListStub) GetSchedulingEligibility() string` diff --git a/clients/go/v1/docs/NodeReservedResources.md b/clients/go/v1/docs/NodeReservedResources.md index deb18bf1..4edb581f 100644 --- a/clients/go/v1/docs/NodeReservedResources.md +++ b/clients/go/v1/docs/NodeReservedResources.md @@ -4,10 +4,10 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Cpu** | Pointer to [**NodeReservedCpuResources**](NodeReservedCpuResources.md) | | [optional] -**Disk** | Pointer to [**NodeReservedDiskResources**](NodeReservedDiskResources.md) | | [optional] -**Memory** | Pointer to [**NodeReservedMemoryResources**](NodeReservedMemoryResources.md) | | [optional] -**Networks** | Pointer to [**NodeReservedNetworkResources**](NodeReservedNetworkResources.md) | | [optional] +**Cpu** | Pointer to [**NullableNodeReservedCpuResources**](NodeReservedCpuResources.md) | | [optional] +**Disk** | Pointer to [**NullableNodeReservedDiskResources**](NodeReservedDiskResources.md) | | [optional] +**Memory** | Pointer to [**NullableNodeReservedMemoryResources**](NodeReservedMemoryResources.md) | | [optional] +**Networks** | Pointer to [**NullableNodeReservedNetworkResources**](NodeReservedNetworkResources.md) | | [optional] ## Methods @@ -53,6 +53,16 @@ SetCpu sets Cpu field to given value. HasCpu returns a boolean if a field has been set. +### SetCpuNil + +`func (o *NodeReservedResources) SetCpuNil(b bool)` + + SetCpuNil sets the value for Cpu to be an explicit nil + +### UnsetCpu +`func (o *NodeReservedResources) UnsetCpu()` + +UnsetCpu ensures that no value is present for Cpu, not even an explicit nil ### GetDisk `func (o *NodeReservedResources) GetDisk() NodeReservedDiskResources` @@ -78,6 +88,16 @@ SetDisk sets Disk field to given value. HasDisk returns a boolean if a field has been set. +### SetDiskNil + +`func (o *NodeReservedResources) SetDiskNil(b bool)` + + SetDiskNil sets the value for Disk to be an explicit nil + +### UnsetDisk +`func (o *NodeReservedResources) UnsetDisk()` + +UnsetDisk ensures that no value is present for Disk, not even an explicit nil ### GetMemory `func (o *NodeReservedResources) GetMemory() NodeReservedMemoryResources` @@ -103,6 +123,16 @@ SetMemory sets Memory field to given value. HasMemory returns a boolean if a field has been set. +### SetMemoryNil + +`func (o *NodeReservedResources) SetMemoryNil(b bool)` + + SetMemoryNil sets the value for Memory to be an explicit nil + +### UnsetMemory +`func (o *NodeReservedResources) UnsetMemory()` + +UnsetMemory ensures that no value is present for Memory, not even an explicit nil ### GetNetworks `func (o *NodeReservedResources) GetNetworks() NodeReservedNetworkResources` @@ -128,6 +158,16 @@ SetNetworks sets Networks field to given value. HasNetworks returns a boolean if a field has been set. +### SetNetworksNil + +`func (o *NodeReservedResources) SetNetworksNil(b bool)` + + SetNetworksNil sets the value for Networks to be an explicit nil + +### UnsetNetworks +`func (o *NodeReservedResources) UnsetNetworks()` + +UnsetNetworks ensures that no value is present for Networks, not even an explicit nil [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/go/v1/docs/NodeResources.md b/clients/go/v1/docs/NodeResources.md index 9a8a19f6..97171773 100644 --- a/clients/go/v1/docs/NodeResources.md +++ b/clients/go/v1/docs/NodeResources.md @@ -4,11 +4,11 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Cpu** | Pointer to [**NodeCpuResources**](NodeCpuResources.md) | | [optional] +**Cpu** | Pointer to [**NullableNodeCpuResources**](NodeCpuResources.md) | | [optional] **Devices** | Pointer to [**[]NodeDeviceResource**](NodeDeviceResource.md) | | [optional] -**Disk** | Pointer to [**NodeDiskResources**](NodeDiskResources.md) | | [optional] +**Disk** | Pointer to [**NullableNodeDiskResources**](NodeDiskResources.md) | | [optional] **MaxDynamicPort** | Pointer to **int32** | | [optional] -**Memory** | Pointer to [**NodeMemoryResources**](NodeMemoryResources.md) | | [optional] +**Memory** | Pointer to [**NullableNodeMemoryResources**](NodeMemoryResources.md) | | [optional] **MinDynamicPort** | Pointer to **int32** | | [optional] **Networks** | Pointer to [**[]NetworkResource**](NetworkResource.md) | | [optional] @@ -56,6 +56,16 @@ SetCpu sets Cpu field to given value. HasCpu returns a boolean if a field has been set. +### SetCpuNil + +`func (o *NodeResources) SetCpuNil(b bool)` + + SetCpuNil sets the value for Cpu to be an explicit nil + +### UnsetCpu +`func (o *NodeResources) UnsetCpu()` + +UnsetCpu ensures that no value is present for Cpu, not even an explicit nil ### GetDevices `func (o *NodeResources) GetDevices() []NodeDeviceResource` @@ -106,6 +116,16 @@ SetDisk sets Disk field to given value. HasDisk returns a boolean if a field has been set. +### SetDiskNil + +`func (o *NodeResources) SetDiskNil(b bool)` + + SetDiskNil sets the value for Disk to be an explicit nil + +### UnsetDisk +`func (o *NodeResources) UnsetDisk()` + +UnsetDisk ensures that no value is present for Disk, not even an explicit nil ### GetMaxDynamicPort `func (o *NodeResources) GetMaxDynamicPort() int32` @@ -156,6 +176,16 @@ SetMemory sets Memory field to given value. HasMemory returns a boolean if a field has been set. +### SetMemoryNil + +`func (o *NodeResources) SetMemoryNil(b bool)` + + SetMemoryNil sets the value for Memory to be an explicit nil + +### UnsetMemory +`func (o *NodeResources) UnsetMemory()` + +UnsetMemory ensures that no value is present for Memory, not even an explicit nil ### GetMinDynamicPort `func (o *NodeResources) GetMinDynamicPort() int32` diff --git a/clients/go/v1/docs/NodeUpdateDrainRequest.md b/clients/go/v1/docs/NodeUpdateDrainRequest.md index 1c104a0b..fe3d5c1d 100644 --- a/clients/go/v1/docs/NodeUpdateDrainRequest.md +++ b/clients/go/v1/docs/NodeUpdateDrainRequest.md @@ -4,7 +4,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**DrainSpec** | Pointer to [**DrainSpec**](DrainSpec.md) | | [optional] +**DrainSpec** | Pointer to [**NullableDrainSpec**](DrainSpec.md) | | [optional] **MarkEligible** | Pointer to **bool** | | [optional] **Meta** | Pointer to **map[string]string** | | [optional] **NodeID** | Pointer to **string** | | [optional] @@ -53,6 +53,16 @@ SetDrainSpec sets DrainSpec field to given value. HasDrainSpec returns a boolean if a field has been set. +### SetDrainSpecNil + +`func (o *NodeUpdateDrainRequest) SetDrainSpecNil(b bool)` + + SetDrainSpecNil sets the value for DrainSpec to be an explicit nil + +### UnsetDrainSpec +`func (o *NodeUpdateDrainRequest) UnsetDrainSpec()` + +UnsetDrainSpec ensures that no value is present for DrainSpec, not even an explicit nil ### GetMarkEligible `func (o *NodeUpdateDrainRequest) GetMarkEligible() bool` diff --git a/clients/go/v1/docs/NodesApi.md b/clients/go/v1/docs/NodesApi.md index a87a08c6..cbedf2ae 100644 --- a/clients/go/v1/docs/NodesApi.md +++ b/clients/go/v1/docs/NodesApi.md @@ -44,8 +44,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.NodesApi.GetNode(context.Background(), nodeId).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.NodesApi.GetNode(context.Background(), nodeId).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `NodesApi.GetNode``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -130,8 +130,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.NodesApi.GetNodeAllocations(context.Background(), nodeId).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.NodesApi.GetNodeAllocations(context.Background(), nodeId).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `NodesApi.GetNodeAllocations``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -216,8 +216,8 @@ func main() { resources := true // bool | Whether or not to include the NodeResources and ReservedResources fields in the response. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.NodesApi.GetNodes(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Resources(resources).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.NodesApi.GetNodes(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Resources(resources).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `NodesApi.GetNodes``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -299,8 +299,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.NodesApi.UpdateNodeDrain(context.Background(), nodeId).NodeUpdateDrainRequest(nodeUpdateDrainRequest).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.NodesApi.UpdateNodeDrain(context.Background(), nodeId).NodeUpdateDrainRequest(nodeUpdateDrainRequest).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `NodesApi.UpdateNodeDrain``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -387,8 +387,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.NodesApi.UpdateNodeEligibility(context.Background(), nodeId).NodeUpdateEligibilityRequest(nodeUpdateEligibilityRequest).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.NodesApi.UpdateNodeEligibility(context.Background(), nodeId).NodeUpdateEligibilityRequest(nodeUpdateEligibilityRequest).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `NodesApi.UpdateNodeEligibility``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -474,8 +474,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.NodesApi.UpdateNodePurge(context.Background(), nodeId).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.NodesApi.UpdateNodePurge(context.Background(), nodeId).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `NodesApi.UpdateNodePurge``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) diff --git a/clients/go/v1/docs/OneTimeToken.md b/clients/go/v1/docs/OneTimeToken.md index b33d392d..4a47f353 100644 --- a/clients/go/v1/docs/OneTimeToken.md +++ b/clients/go/v1/docs/OneTimeToken.md @@ -6,7 +6,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **AccessorID** | Pointer to **string** | | [optional] **CreateIndex** | Pointer to **int32** | | [optional] -**ExpiresAt** | Pointer to **time.Time** | | [optional] +**ExpiresAt** | Pointer to **NullableTime** | | [optional] **ModifyIndex** | Pointer to **int32** | | [optional] **OneTimeSecretID** | Pointer to **string** | | [optional] @@ -104,6 +104,16 @@ SetExpiresAt sets ExpiresAt field to given value. HasExpiresAt returns a boolean if a field has been set. +### SetExpiresAtNil + +`func (o *OneTimeToken) SetExpiresAtNil(b bool)` + + SetExpiresAtNil sets the value for ExpiresAt to be an explicit nil + +### UnsetExpiresAt +`func (o *OneTimeToken) UnsetExpiresAt()` + +UnsetExpiresAt ensures that no value is present for ExpiresAt, not even an explicit nil ### GetModifyIndex `func (o *OneTimeToken) GetModifyIndex() int32` diff --git a/clients/go/v1/docs/OperatorApi.md b/clients/go/v1/docs/OperatorApi.md index e231989e..ad96844e 100644 --- a/clients/go/v1/docs/OperatorApi.md +++ b/clients/go/v1/docs/OperatorApi.md @@ -39,8 +39,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.OperatorApi.DeleteOperatorRaftPeer(context.Background()).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.OperatorApi.DeleteOperatorRaftPeer(context.Background()).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `OperatorApi.DeleteOperatorRaftPeer``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -112,8 +112,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.OperatorApi.GetOperatorAutopilotConfiguration(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.OperatorApi.GetOperatorAutopilotConfiguration(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `OperatorApi.GetOperatorAutopilotConfiguration``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -192,8 +192,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.OperatorApi.GetOperatorAutopilotHealth(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.OperatorApi.GetOperatorAutopilotHealth(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `OperatorApi.GetOperatorAutopilotHealth``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -272,8 +272,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.OperatorApi.GetOperatorRaftConfiguration(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.OperatorApi.GetOperatorRaftConfiguration(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `OperatorApi.GetOperatorRaftConfiguration``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -352,8 +352,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.OperatorApi.GetOperatorSchedulerConfiguration(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.OperatorApi.GetOperatorSchedulerConfiguration(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `OperatorApi.GetOperatorSchedulerConfiguration``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -428,8 +428,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.OperatorApi.PostOperatorSchedulerConfiguration(context.Background()).SchedulerConfiguration(schedulerConfiguration).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.OperatorApi.PostOperatorSchedulerConfiguration(context.Background()).SchedulerConfiguration(schedulerConfiguration).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `OperatorApi.PostOperatorSchedulerConfiguration``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -500,8 +500,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.OperatorApi.PutOperatorAutopilotConfiguration(context.Background()).AutopilotConfiguration(autopilotConfiguration).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.OperatorApi.PutOperatorAutopilotConfiguration(context.Background()).AutopilotConfiguration(autopilotConfiguration).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `OperatorApi.PutOperatorAutopilotConfiguration``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) diff --git a/clients/go/v1/docs/PluginsApi.md b/clients/go/v1/docs/PluginsApi.md index ee8704ca..e70a218b 100644 --- a/clients/go/v1/docs/PluginsApi.md +++ b/clients/go/v1/docs/PluginsApi.md @@ -40,8 +40,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.PluginsApi.GetPluginCSI(context.Background(), pluginID).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.PluginsApi.GetPluginCSI(context.Background(), pluginID).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `PluginsApi.GetPluginCSI``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -125,8 +125,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.PluginsApi.GetPlugins(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.PluginsApi.GetPlugins(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `PluginsApi.GetPlugins``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) diff --git a/clients/go/v1/docs/QuotaLimit.md b/clients/go/v1/docs/QuotaLimit.md index 1174c266..dea1b78f 100644 --- a/clients/go/v1/docs/QuotaLimit.md +++ b/clients/go/v1/docs/QuotaLimit.md @@ -6,7 +6,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **Hash** | Pointer to **string** | | [optional] **Region** | Pointer to **string** | | [optional] -**RegionLimit** | Pointer to [**Resources**](Resources.md) | | [optional] +**RegionLimit** | Pointer to [**NullableResources**](Resources.md) | | [optional] ## Methods @@ -102,6 +102,16 @@ SetRegionLimit sets RegionLimit field to given value. HasRegionLimit returns a boolean if a field has been set. +### SetRegionLimitNil + +`func (o *QuotaLimit) SetRegionLimitNil(b bool)` + + SetRegionLimitNil sets the value for RegionLimit to be an explicit nil + +### UnsetRegionLimit +`func (o *QuotaLimit) UnsetRegionLimit()` + +UnsetRegionLimit ensures that no value is present for RegionLimit, not even an explicit nil [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/go/v1/docs/RegionsApi.md b/clients/go/v1/docs/RegionsApi.md index 925529f3..87f62823 100644 --- a/clients/go/v1/docs/RegionsApi.md +++ b/clients/go/v1/docs/RegionsApi.md @@ -29,8 +29,8 @@ import ( func main() { configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.RegionsApi.GetRegions(context.Background()).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.RegionsApi.GetRegions(context.Background()).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `RegionsApi.GetRegions``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) diff --git a/clients/go/v1/docs/ScalingApi.md b/clients/go/v1/docs/ScalingApi.md index 7bf6da1f..7908f919 100644 --- a/clients/go/v1/docs/ScalingApi.md +++ b/clients/go/v1/docs/ScalingApi.md @@ -39,8 +39,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.ScalingApi.GetScalingPolicies(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.ScalingApi.GetScalingPolicies(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `ScalingApi.GetScalingPolicies``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -120,8 +120,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.ScalingApi.GetScalingPolicy(context.Background(), policyID).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.ScalingApi.GetScalingPolicy(context.Background(), policyID).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `ScalingApi.GetScalingPolicy``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) diff --git a/clients/go/v1/docs/SchedulerConfiguration.md b/clients/go/v1/docs/SchedulerConfiguration.md index cb9b532f..4e7be6f5 100644 --- a/clients/go/v1/docs/SchedulerConfiguration.md +++ b/clients/go/v1/docs/SchedulerConfiguration.md @@ -8,7 +8,7 @@ Name | Type | Description | Notes **MemoryOversubscriptionEnabled** | Pointer to **bool** | | [optional] **ModifyIndex** | Pointer to **int32** | | [optional] **PauseEvalBroker** | Pointer to **bool** | | [optional] -**PreemptionConfig** | Pointer to [**PreemptionConfig**](PreemptionConfig.md) | | [optional] +**PreemptionConfig** | Pointer to [**NullablePreemptionConfig**](PreemptionConfig.md) | | [optional] **RejectJobRegistration** | Pointer to **bool** | | [optional] **SchedulerAlgorithm** | Pointer to **string** | | [optional] @@ -156,6 +156,16 @@ SetPreemptionConfig sets PreemptionConfig field to given value. HasPreemptionConfig returns a boolean if a field has been set. +### SetPreemptionConfigNil + +`func (o *SchedulerConfiguration) SetPreemptionConfigNil(b bool)` + + SetPreemptionConfigNil sets the value for PreemptionConfig to be an explicit nil + +### UnsetPreemptionConfig +`func (o *SchedulerConfiguration) UnsetPreemptionConfig()` + +UnsetPreemptionConfig ensures that no value is present for PreemptionConfig, not even an explicit nil ### GetRejectJobRegistration `func (o *SchedulerConfiguration) GetRejectJobRegistration() bool` diff --git a/clients/go/v1/docs/SchedulerConfigurationResponse.md b/clients/go/v1/docs/SchedulerConfigurationResponse.md index d27f2cb0..bcf6be20 100644 --- a/clients/go/v1/docs/SchedulerConfigurationResponse.md +++ b/clients/go/v1/docs/SchedulerConfigurationResponse.md @@ -9,7 +9,7 @@ Name | Type | Description | Notes **LastIndex** | Pointer to **int32** | | [optional] **NextToken** | Pointer to **string** | | [optional] **RequestTime** | Pointer to **int64** | | [optional] -**SchedulerConfig** | Pointer to [**SchedulerConfiguration**](SchedulerConfiguration.md) | | [optional] +**SchedulerConfig** | Pointer to [**NullableSchedulerConfiguration**](SchedulerConfiguration.md) | | [optional] ## Methods @@ -180,6 +180,16 @@ SetSchedulerConfig sets SchedulerConfig field to given value. HasSchedulerConfig returns a boolean if a field has been set. +### SetSchedulerConfigNil + +`func (o *SchedulerConfigurationResponse) SetSchedulerConfigNil(b bool)` + + SetSchedulerConfigNil sets the value for SchedulerConfig to be an explicit nil + +### UnsetSchedulerConfig +`func (o *SchedulerConfigurationResponse) UnsetSchedulerConfig()` + +UnsetSchedulerConfig ensures that no value is present for SchedulerConfig, not even an explicit nil [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/go/v1/docs/SearchApi.md b/clients/go/v1/docs/SearchApi.md index 4fea39e9..c5c59738 100644 --- a/clients/go/v1/docs/SearchApi.md +++ b/clients/go/v1/docs/SearchApi.md @@ -40,8 +40,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.SearchApi.GetFuzzySearch(context.Background()).FuzzySearchRequest(fuzzySearchRequest).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.SearchApi.GetFuzzySearch(context.Background()).FuzzySearchRequest(fuzzySearchRequest).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `SearchApi.GetFuzzySearch``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -122,8 +122,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.SearchApi.GetSearch(context.Background()).SearchRequest(searchRequest).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.SearchApi.GetSearch(context.Background()).SearchRequest(searchRequest).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `SearchApi.GetSearch``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) diff --git a/clients/go/v1/docs/ServerHealth.md b/clients/go/v1/docs/ServerHealth.md index ac57cee6..fe9133bb 100644 --- a/clients/go/v1/docs/ServerHealth.md +++ b/clients/go/v1/docs/ServerHealth.md @@ -13,7 +13,7 @@ Name | Type | Description | Notes **Leader** | Pointer to **bool** | | [optional] **Name** | Pointer to **string** | | [optional] **SerfStatus** | Pointer to **string** | | [optional] -**StableSince** | Pointer to **time.Time** | | [optional] +**StableSince** | Pointer to **NullableTime** | | [optional] **Version** | Pointer to **string** | | [optional] **Voter** | Pointer to **bool** | | [optional] @@ -286,6 +286,16 @@ SetStableSince sets StableSince field to given value. HasStableSince returns a boolean if a field has been set. +### SetStableSinceNil + +`func (o *ServerHealth) SetStableSinceNil(b bool)` + + SetStableSinceNil sets the value for StableSince to be an explicit nil + +### UnsetStableSince +`func (o *ServerHealth) UnsetStableSince()` + +UnsetStableSince ensures that no value is present for StableSince, not even an explicit nil ### GetVersion `func (o *ServerHealth) GetVersion() string` diff --git a/clients/go/v1/docs/Service.md b/clients/go/v1/docs/Service.md index 98a2cd5f..b6496e0a 100644 --- a/clients/go/v1/docs/Service.md +++ b/clients/go/v1/docs/Service.md @@ -8,9 +8,9 @@ Name | Type | Description | Notes **AddressMode** | Pointer to **string** | | [optional] **CanaryMeta** | Pointer to **map[string]string** | | [optional] **CanaryTags** | Pointer to **[]string** | | [optional] -**CheckRestart** | Pointer to [**CheckRestart**](CheckRestart.md) | | [optional] +**CheckRestart** | Pointer to [**NullableCheckRestart**](CheckRestart.md) | | [optional] **Checks** | Pointer to [**[]ServiceCheck**](ServiceCheck.md) | | [optional] -**Connect** | Pointer to [**ConsulConnect**](ConsulConnect.md) | | [optional] +**Connect** | Pointer to [**NullableConsulConnect**](ConsulConnect.md) | | [optional] **EnableTagOverride** | Pointer to **bool** | | [optional] **Meta** | Pointer to **map[string]string** | | [optional] **Name** | Pointer to **string** | | [optional] @@ -165,6 +165,16 @@ SetCheckRestart sets CheckRestart field to given value. HasCheckRestart returns a boolean if a field has been set. +### SetCheckRestartNil + +`func (o *Service) SetCheckRestartNil(b bool)` + + SetCheckRestartNil sets the value for CheckRestart to be an explicit nil + +### UnsetCheckRestart +`func (o *Service) UnsetCheckRestart()` + +UnsetCheckRestart ensures that no value is present for CheckRestart, not even an explicit nil ### GetChecks `func (o *Service) GetChecks() []ServiceCheck` @@ -215,6 +225,16 @@ SetConnect sets Connect field to given value. HasConnect returns a boolean if a field has been set. +### SetConnectNil + +`func (o *Service) SetConnectNil(b bool)` + + SetConnectNil sets the value for Connect to be an explicit nil + +### UnsetConnect +`func (o *Service) UnsetConnect()` + +UnsetConnect ensures that no value is present for Connect, not even an explicit nil ### GetEnableTagOverride `func (o *Service) GetEnableTagOverride() bool` diff --git a/clients/go/v1/docs/ServiceCheck.md b/clients/go/v1/docs/ServiceCheck.md index ed35f0ec..5ba4b6b7 100644 --- a/clients/go/v1/docs/ServiceCheck.md +++ b/clients/go/v1/docs/ServiceCheck.md @@ -8,7 +8,7 @@ Name | Type | Description | Notes **Advertise** | Pointer to **string** | | [optional] **Args** | Pointer to **[]string** | | [optional] **Body** | Pointer to **string** | | [optional] -**CheckRestart** | Pointer to [**CheckRestart**](CheckRestart.md) | | [optional] +**CheckRestart** | Pointer to [**NullableCheckRestart**](CheckRestart.md) | | [optional] **Command** | Pointer to **string** | | [optional] **Expose** | Pointer to **bool** | | [optional] **FailuresBeforeCritical** | Pointer to **int32** | | [optional] @@ -173,6 +173,16 @@ SetCheckRestart sets CheckRestart field to given value. HasCheckRestart returns a boolean if a field has been set. +### SetCheckRestartNil + +`func (o *ServiceCheck) SetCheckRestartNil(b bool)` + + SetCheckRestartNil sets the value for CheckRestart to be an explicit nil + +### UnsetCheckRestart +`func (o *ServiceCheck) UnsetCheckRestart()` + +UnsetCheckRestart ensures that no value is present for CheckRestart, not even an explicit nil ### GetCommand `func (o *ServiceCheck) GetCommand() string` diff --git a/clients/go/v1/docs/SidecarTask.md b/clients/go/v1/docs/SidecarTask.md index 4821b7f6..b1cab5ba 100644 --- a/clients/go/v1/docs/SidecarTask.md +++ b/clients/go/v1/docs/SidecarTask.md @@ -12,7 +12,7 @@ Name | Type | Description | Notes **LogConfig** | Pointer to [**LogConfig**](LogConfig.md) | | [optional] **Meta** | Pointer to **map[string]string** | | [optional] **Name** | Pointer to **string** | | [optional] -**Resources** | Pointer to [**Resources**](Resources.md) | | [optional] +**Resources** | Pointer to [**NullableResources**](Resources.md) | | [optional] **ShutdownDelay** | Pointer to **int64** | | [optional] **User** | Pointer to **string** | | [optional] @@ -260,6 +260,16 @@ SetResources sets Resources field to given value. HasResources returns a boolean if a field has been set. +### SetResourcesNil + +`func (o *SidecarTask) SetResourcesNil(b bool)` + + SetResourcesNil sets the value for Resources to be an explicit nil + +### UnsetResources +`func (o *SidecarTask) UnsetResources()` + +UnsetResources ensures that no value is present for Resources, not even an explicit nil ### GetShutdownDelay `func (o *SidecarTask) GetShutdownDelay() int64` diff --git a/clients/go/v1/docs/StatusApi.md b/clients/go/v1/docs/StatusApi.md index 5724b651..4b1bf727 100644 --- a/clients/go/v1/docs/StatusApi.md +++ b/clients/go/v1/docs/StatusApi.md @@ -39,8 +39,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.StatusApi.GetStatusLeader(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.StatusApi.GetStatusLeader(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `StatusApi.GetStatusLeader``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -119,8 +119,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.StatusApi.GetStatusPeers(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.StatusApi.GetStatusPeers(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `StatusApi.GetStatusPeers``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) diff --git a/clients/go/v1/docs/SystemApi.md b/clients/go/v1/docs/SystemApi.md index bc0d1453..439a64c5 100644 --- a/clients/go/v1/docs/SystemApi.md +++ b/clients/go/v1/docs/SystemApi.md @@ -34,8 +34,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.SystemApi.PutSystemGC(context.Background()).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.SystemApi.PutSystemGC(context.Background()).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `SystemApi.PutSystemGC``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -102,8 +102,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.SystemApi.PutSystemReconcileSummaries(context.Background()).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.SystemApi.PutSystemReconcileSummaries(context.Background()).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `SystemApi.PutSystemReconcileSummaries``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) diff --git a/clients/go/v1/docs/Task.md b/clients/go/v1/docs/Task.md index 46f596eb..f33a4cf5 100644 --- a/clients/go/v1/docs/Task.md +++ b/clients/go/v1/docs/Task.md @@ -6,28 +6,28 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **Affinities** | Pointer to [**[]Affinity**](Affinity.md) | | [optional] **Artifacts** | Pointer to [**[]TaskArtifact**](TaskArtifact.md) | | [optional] -**CSIPluginConfig** | Pointer to [**TaskCSIPluginConfig**](TaskCSIPluginConfig.md) | | [optional] +**CSIPluginConfig** | Pointer to [**NullableTaskCSIPluginConfig**](TaskCSIPluginConfig.md) | | [optional] **Config** | Pointer to **map[string]interface{}** | | [optional] **Constraints** | Pointer to [**[]Constraint**](Constraint.md) | | [optional] -**DispatchPayload** | Pointer to [**DispatchPayloadConfig**](DispatchPayloadConfig.md) | | [optional] +**DispatchPayload** | Pointer to [**NullableDispatchPayloadConfig**](DispatchPayloadConfig.md) | | [optional] **Driver** | Pointer to **string** | | [optional] **Env** | Pointer to **map[string]string** | | [optional] **KillSignal** | Pointer to **string** | | [optional] **KillTimeout** | Pointer to **int64** | | [optional] **Kind** | Pointer to **string** | | [optional] **Leader** | Pointer to **bool** | | [optional] -**Lifecycle** | Pointer to [**TaskLifecycle**](TaskLifecycle.md) | | [optional] +**Lifecycle** | Pointer to [**NullableTaskLifecycle**](TaskLifecycle.md) | | [optional] **LogConfig** | Pointer to [**LogConfig**](LogConfig.md) | | [optional] **Meta** | Pointer to **map[string]string** | | [optional] **Name** | Pointer to **string** | | [optional] -**Resources** | Pointer to [**Resources**](Resources.md) | | [optional] +**Resources** | Pointer to [**NullableResources**](Resources.md) | | [optional] **RestartPolicy** | Pointer to [**RestartPolicy**](RestartPolicy.md) | | [optional] **ScalingPolicies** | Pointer to [**[]ScalingPolicy**](ScalingPolicy.md) | | [optional] **Services** | Pointer to [**[]Service**](Service.md) | | [optional] **ShutdownDelay** | Pointer to **int64** | | [optional] **Templates** | Pointer to [**[]Template**](Template.md) | | [optional] **User** | Pointer to **string** | | [optional] -**Vault** | Pointer to [**Vault**](Vault.md) | | [optional] +**Vault** | Pointer to [**NullableVault**](Vault.md) | | [optional] **VolumeMounts** | Pointer to [**[]VolumeMount**](VolumeMount.md) | | [optional] ## Methods @@ -124,6 +124,16 @@ SetCSIPluginConfig sets CSIPluginConfig field to given value. HasCSIPluginConfig returns a boolean if a field has been set. +### SetCSIPluginConfigNil + +`func (o *Task) SetCSIPluginConfigNil(b bool)` + + SetCSIPluginConfigNil sets the value for CSIPluginConfig to be an explicit nil + +### UnsetCSIPluginConfig +`func (o *Task) UnsetCSIPluginConfig()` + +UnsetCSIPluginConfig ensures that no value is present for CSIPluginConfig, not even an explicit nil ### GetConfig `func (o *Task) GetConfig() map[string]interface{}` @@ -199,6 +209,16 @@ SetDispatchPayload sets DispatchPayload field to given value. HasDispatchPayload returns a boolean if a field has been set. +### SetDispatchPayloadNil + +`func (o *Task) SetDispatchPayloadNil(b bool)` + + SetDispatchPayloadNil sets the value for DispatchPayload to be an explicit nil + +### UnsetDispatchPayload +`func (o *Task) UnsetDispatchPayload()` + +UnsetDispatchPayload ensures that no value is present for DispatchPayload, not even an explicit nil ### GetDriver `func (o *Task) GetDriver() string` @@ -374,6 +394,16 @@ SetLifecycle sets Lifecycle field to given value. HasLifecycle returns a boolean if a field has been set. +### SetLifecycleNil + +`func (o *Task) SetLifecycleNil(b bool)` + + SetLifecycleNil sets the value for Lifecycle to be an explicit nil + +### UnsetLifecycle +`func (o *Task) UnsetLifecycle()` + +UnsetLifecycle ensures that no value is present for Lifecycle, not even an explicit nil ### GetLogConfig `func (o *Task) GetLogConfig() LogConfig` @@ -474,6 +504,16 @@ SetResources sets Resources field to given value. HasResources returns a boolean if a field has been set. +### SetResourcesNil + +`func (o *Task) SetResourcesNil(b bool)` + + SetResourcesNil sets the value for Resources to be an explicit nil + +### UnsetResources +`func (o *Task) UnsetResources()` + +UnsetResources ensures that no value is present for Resources, not even an explicit nil ### GetRestartPolicy `func (o *Task) GetRestartPolicy() RestartPolicy` @@ -649,6 +689,16 @@ SetVault sets Vault field to given value. HasVault returns a boolean if a field has been set. +### SetVaultNil + +`func (o *Task) SetVaultNil(b bool)` + + SetVaultNil sets the value for Vault to be an explicit nil + +### UnsetVault +`func (o *Task) UnsetVault()` + +UnsetVault ensures that no value is present for Vault, not even an explicit nil ### GetVolumeMounts `func (o *Task) GetVolumeMounts() []VolumeMount` diff --git a/clients/go/v1/docs/TaskGroup.md b/clients/go/v1/docs/TaskGroup.md index b2b81a85..06d4c29e 100644 --- a/clients/go/v1/docs/TaskGroup.md +++ b/clients/go/v1/docs/TaskGroup.md @@ -6,7 +6,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **Affinities** | Pointer to [**[]Affinity**](Affinity.md) | | [optional] **Constraints** | Pointer to [**[]Constraint**](Constraint.md) | | [optional] -**Consul** | Pointer to [**Consul**](Consul.md) | | [optional] +**Consul** | Pointer to [**NullableConsul**](Consul.md) | | [optional] **Count** | Pointer to **int32** | | [optional] **EphemeralDisk** | Pointer to [**EphemeralDisk**](EphemeralDisk.md) | | [optional] **MaxClientDisconnect** | Pointer to **int64** | | [optional] @@ -16,7 +16,7 @@ Name | Type | Description | Notes **Networks** | Pointer to [**[]NetworkResource**](NetworkResource.md) | | [optional] **ReschedulePolicy** | Pointer to [**ReschedulePolicy**](ReschedulePolicy.md) | | [optional] **RestartPolicy** | Pointer to [**RestartPolicy**](RestartPolicy.md) | | [optional] -**Scaling** | Pointer to [**ScalingPolicy**](ScalingPolicy.md) | | [optional] +**Scaling** | Pointer to [**NullableScalingPolicy**](ScalingPolicy.md) | | [optional] **Services** | Pointer to [**[]Service**](Service.md) | | [optional] **ShutdownDelay** | Pointer to **int64** | | [optional] **Spreads** | Pointer to [**[]Spread**](Spread.md) | | [optional] @@ -119,6 +119,16 @@ SetConsul sets Consul field to given value. HasConsul returns a boolean if a field has been set. +### SetConsulNil + +`func (o *TaskGroup) SetConsulNil(b bool)` + + SetConsulNil sets the value for Consul to be an explicit nil + +### UnsetConsul +`func (o *TaskGroup) UnsetConsul()` + +UnsetConsul ensures that no value is present for Consul, not even an explicit nil ### GetCount `func (o *TaskGroup) GetCount() int32` @@ -369,6 +379,16 @@ SetScaling sets Scaling field to given value. HasScaling returns a boolean if a field has been set. +### SetScalingNil + +`func (o *TaskGroup) SetScalingNil(b bool)` + + SetScalingNil sets the value for Scaling to be an explicit nil + +### UnsetScaling +`func (o *TaskGroup) UnsetScaling()` + +UnsetScaling ensures that no value is present for Scaling, not even an explicit nil ### GetServices `func (o *TaskGroup) GetServices() []Service` diff --git a/clients/go/v1/docs/TaskState.md b/clients/go/v1/docs/TaskState.md index e96e2cf8..6e18f883 100644 --- a/clients/go/v1/docs/TaskState.md +++ b/clients/go/v1/docs/TaskState.md @@ -6,12 +6,12 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **Events** | Pointer to [**[]TaskEvent**](TaskEvent.md) | | [optional] **Failed** | Pointer to **bool** | | [optional] -**FinishedAt** | Pointer to **time.Time** | | [optional] -**LastRestart** | Pointer to **time.Time** | | [optional] +**FinishedAt** | Pointer to **NullableTime** | | [optional] +**LastRestart** | Pointer to **NullableTime** | | [optional] **Restarts** | Pointer to **int32** | | [optional] -**StartedAt** | Pointer to **time.Time** | | [optional] +**StartedAt** | Pointer to **NullableTime** | | [optional] **State** | Pointer to **string** | | [optional] -**TaskHandle** | Pointer to [**TaskHandle**](TaskHandle.md) | | [optional] +**TaskHandle** | Pointer to [**NullableTaskHandle**](TaskHandle.md) | | [optional] ## Methods @@ -107,6 +107,16 @@ SetFinishedAt sets FinishedAt field to given value. HasFinishedAt returns a boolean if a field has been set. +### SetFinishedAtNil + +`func (o *TaskState) SetFinishedAtNil(b bool)` + + SetFinishedAtNil sets the value for FinishedAt to be an explicit nil + +### UnsetFinishedAt +`func (o *TaskState) UnsetFinishedAt()` + +UnsetFinishedAt ensures that no value is present for FinishedAt, not even an explicit nil ### GetLastRestart `func (o *TaskState) GetLastRestart() time.Time` @@ -132,6 +142,16 @@ SetLastRestart sets LastRestart field to given value. HasLastRestart returns a boolean if a field has been set. +### SetLastRestartNil + +`func (o *TaskState) SetLastRestartNil(b bool)` + + SetLastRestartNil sets the value for LastRestart to be an explicit nil + +### UnsetLastRestart +`func (o *TaskState) UnsetLastRestart()` + +UnsetLastRestart ensures that no value is present for LastRestart, not even an explicit nil ### GetRestarts `func (o *TaskState) GetRestarts() int32` @@ -182,6 +202,16 @@ SetStartedAt sets StartedAt field to given value. HasStartedAt returns a boolean if a field has been set. +### SetStartedAtNil + +`func (o *TaskState) SetStartedAtNil(b bool)` + + SetStartedAtNil sets the value for StartedAt to be an explicit nil + +### UnsetStartedAt +`func (o *TaskState) UnsetStartedAt()` + +UnsetStartedAt ensures that no value is present for StartedAt, not even an explicit nil ### GetState `func (o *TaskState) GetState() string` @@ -232,6 +262,16 @@ SetTaskHandle sets TaskHandle field to given value. HasTaskHandle returns a boolean if a field has been set. +### SetTaskHandleNil + +`func (o *TaskState) SetTaskHandleNil(b bool)` + + SetTaskHandleNil sets the value for TaskHandle to be an explicit nil + +### UnsetTaskHandle +`func (o *TaskState) UnsetTaskHandle()` + +UnsetTaskHandle ensures that no value is present for TaskHandle, not even an explicit nil [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/go/v1/docs/VolumeRequest.md b/clients/go/v1/docs/VolumeRequest.md index 57ca9201..1a9659ef 100644 --- a/clients/go/v1/docs/VolumeRequest.md +++ b/clients/go/v1/docs/VolumeRequest.md @@ -6,7 +6,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **AccessMode** | Pointer to **string** | | [optional] **AttachmentMode** | Pointer to **string** | | [optional] -**MountOptions** | Pointer to [**CSIMountOptions**](CSIMountOptions.md) | | [optional] +**MountOptions** | Pointer to [**NullableCSIMountOptions**](CSIMountOptions.md) | | [optional] **Name** | Pointer to **string** | | [optional] **PerAlloc** | Pointer to **bool** | | [optional] **ReadOnly** | Pointer to **bool** | | [optional] @@ -107,6 +107,16 @@ SetMountOptions sets MountOptions field to given value. HasMountOptions returns a boolean if a field has been set. +### SetMountOptionsNil + +`func (o *VolumeRequest) SetMountOptionsNil(b bool)` + + SetMountOptionsNil sets the value for MountOptions to be an explicit nil + +### UnsetMountOptions +`func (o *VolumeRequest) UnsetMountOptions()` + +UnsetMountOptions ensures that no value is present for MountOptions, not even an explicit nil ### GetName `func (o *VolumeRequest) GetName() string` diff --git a/clients/go/v1/docs/VolumesApi.md b/clients/go/v1/docs/VolumesApi.md index 67948b95..94ae5379 100644 --- a/clients/go/v1/docs/VolumesApi.md +++ b/clients/go/v1/docs/VolumesApi.md @@ -46,8 +46,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.VolumesApi.CreateVolume(context.Background(), volumeId, action).CSIVolumeCreateRequest(cSIVolumeCreateRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.VolumesApi.CreateVolume(context.Background(), volumeId, action).CSIVolumeCreateRequest(cSIVolumeCreateRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `VolumesApi.CreateVolume``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -124,8 +124,8 @@ func main() { snapshotId := "snapshotId_example" // string | The ID of the snapshot to target. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.VolumesApi.DeleteSnapshot(context.Background()).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).PluginId(pluginId).SnapshotId(snapshotId).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.VolumesApi.DeleteSnapshot(context.Background()).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).PluginId(pluginId).SnapshotId(snapshotId).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `VolumesApi.DeleteSnapshot``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -196,8 +196,8 @@ func main() { force := "force_example" // string | Used to force the de-registration of a volume. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.VolumesApi.DeleteVolumeRegistration(context.Background(), volumeId).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Force(force).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.VolumesApi.DeleteVolumeRegistration(context.Background(), volumeId).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Force(force).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `VolumesApi.DeleteVolumeRegistration``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -273,8 +273,8 @@ func main() { node := "node_example" // string | Specifies node to target volume operation for. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.VolumesApi.DetachOrDeleteVolume(context.Background(), volumeId, action).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Node(node).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.VolumesApi.DetachOrDeleteVolume(context.Background(), volumeId, action).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Node(node).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `VolumesApi.DetachOrDeleteVolume``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -355,8 +355,8 @@ func main() { pluginId := "pluginId_example" // string | Filters volume lists by plugin ID. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.VolumesApi.GetExternalVolumes(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).PluginId(pluginId).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.VolumesApi.GetExternalVolumes(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).PluginId(pluginId).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `VolumesApi.GetExternalVolumes``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -437,8 +437,8 @@ func main() { pluginId := "pluginId_example" // string | Filters volume lists by plugin ID. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.VolumesApi.GetSnapshots(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).PluginId(pluginId).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.VolumesApi.GetSnapshots(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).PluginId(pluginId).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `VolumesApi.GetSnapshots``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -519,8 +519,8 @@ func main() { nextToken := "nextToken_example" // string | Indicates where to start paging for queries that support pagination. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.VolumesApi.GetVolume(context.Background(), volumeId).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.VolumesApi.GetVolume(context.Background(), volumeId).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `VolumesApi.GetVolume``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -607,8 +607,8 @@ func main() { type_ := "type__example" // string | Filters volume lists to a specific type. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.VolumesApi.GetVolumes(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).NodeId(nodeId).PluginId(pluginId).Type_(type_).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.VolumesApi.GetVolumes(context.Background()).Region(region).Namespace(namespace).Index(index).Wait(wait).Stale(stale).Prefix(prefix).XNomadToken(xNomadToken).PerPage(perPage).NextToken(nextToken).NodeId(nodeId).PluginId(pluginId).Type_(type_).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `VolumesApi.GetVolumes``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -686,8 +686,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.VolumesApi.PostSnapshot(context.Background()).CSISnapshotCreateRequest(cSISnapshotCreateRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.VolumesApi.PostSnapshot(context.Background()).CSISnapshotCreateRequest(cSISnapshotCreateRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `VolumesApi.PostSnapshot``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -758,8 +758,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.VolumesApi.PostVolume(context.Background()).CSIVolumeRegisterRequest(cSIVolumeRegisterRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.VolumesApi.PostVolume(context.Background()).CSIVolumeRegisterRequest(cSIVolumeRegisterRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `VolumesApi.PostVolume``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) @@ -829,8 +829,8 @@ func main() { idempotencyToken := "idempotencyToken_example" // string | Can be used to ensure operations are only run once. (optional) configuration := openapiclient.NewConfiguration() - api_client := openapiclient.NewAPIClient(configuration) - resp, r, err := api_client.VolumesApi.PostVolumeRegistration(context.Background(), volumeId).CSIVolumeRegisterRequest(cSIVolumeRegisterRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.VolumesApi.PostVolumeRegistration(context.Background(), volumeId).CSIVolumeRegisterRequest(cSIVolumeRegisterRequest).Region(region).Namespace(namespace).XNomadToken(xNomadToken).IdempotencyToken(idempotencyToken).Execute() if err != nil { fmt.Fprintf(os.Stderr, "Error when calling `VolumesApi.PostVolumeRegistration``: %v\n", err) fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) diff --git a/clients/go/v1/model_acl_policy.go b/clients/go/v1/model_acl_policy.go index 63bd0f19..f738681b 100644 --- a/clients/go/v1/model_acl_policy.go +++ b/clients/go/v1/model_acl_policy.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_acl_policy_list_stub.go b/clients/go/v1/model_acl_policy_list_stub.go index b78230e8..9a0437df 100644 --- a/clients/go/v1/model_acl_policy_list_stub.go +++ b/clients/go/v1/model_acl_policy_list_stub.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_acl_token.go b/clients/go/v1/model_acl_token.go index b31ecfdf..34451e33 100644 --- a/clients/go/v1/model_acl_token.go +++ b/clients/go/v1/model_acl_token.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -20,11 +20,11 @@ import ( type ACLToken struct { AccessorID *string `json:"AccessorID,omitempty"` CreateIndex *int32 `json:"CreateIndex,omitempty"` - CreateTime *time.Time `json:"CreateTime,omitempty"` + CreateTime NullableTime `json:"CreateTime,omitempty"` Global *bool `json:"Global,omitempty"` ModifyIndex *int32 `json:"ModifyIndex,omitempty"` Name *string `json:"Name,omitempty"` - Policies *[]string `json:"Policies,omitempty"` + Policies []string `json:"Policies,omitempty"` SecretID *string `json:"SecretID,omitempty"` Type *string `json:"Type,omitempty"` } @@ -110,36 +110,46 @@ func (o *ACLToken) SetCreateIndex(v int32) { o.CreateIndex = &v } -// GetCreateTime returns the CreateTime field value if set, zero value otherwise. +// GetCreateTime returns the CreateTime field value if set, zero value otherwise (both if not set or set to explicit null). func (o *ACLToken) GetCreateTime() time.Time { - if o == nil || o.CreateTime == nil { + if o == nil || o.CreateTime.Get() == nil { var ret time.Time return ret } - return *o.CreateTime + return *o.CreateTime.Get() } // GetCreateTimeOk returns a tuple with the CreateTime field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *ACLToken) GetCreateTimeOk() (*time.Time, bool) { - if o == nil || o.CreateTime == nil { + if o == nil { return nil, false } - return o.CreateTime, true + return o.CreateTime.Get(), o.CreateTime.IsSet() } // HasCreateTime returns a boolean if a field has been set. func (o *ACLToken) HasCreateTime() bool { - if o != nil && o.CreateTime != nil { + if o != nil && o.CreateTime.IsSet() { return true } return false } -// SetCreateTime gets a reference to the given time.Time and assigns it to the CreateTime field. +// SetCreateTime gets a reference to the given NullableTime and assigns it to the CreateTime field. func (o *ACLToken) SetCreateTime(v time.Time) { - o.CreateTime = &v + o.CreateTime.Set(&v) +} +// SetCreateTimeNil sets the value for CreateTime to be an explicit nil +func (o *ACLToken) SetCreateTimeNil() { + o.CreateTime.Set(nil) +} + +// UnsetCreateTime ensures that no value is present for CreateTime, not even an explicit nil +func (o *ACLToken) UnsetCreateTime() { + o.CreateTime.Unset() } // GetGlobal returns the Global field value if set, zero value otherwise. @@ -244,12 +254,12 @@ func (o *ACLToken) GetPolicies() []string { var ret []string return ret } - return *o.Policies + return o.Policies } // GetPoliciesOk returns a tuple with the Policies field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *ACLToken) GetPoliciesOk() (*[]string, bool) { +func (o *ACLToken) GetPoliciesOk() ([]string, bool) { if o == nil || o.Policies == nil { return nil, false } @@ -267,7 +277,7 @@ func (o *ACLToken) HasPolicies() bool { // SetPolicies gets a reference to the given []string and assigns it to the Policies field. func (o *ACLToken) SetPolicies(v []string) { - o.Policies = &v + o.Policies = v } // GetSecretID returns the SecretID field value if set, zero value otherwise. @@ -342,8 +352,8 @@ func (o ACLToken) MarshalJSON() ([]byte, error) { if o.CreateIndex != nil { toSerialize["CreateIndex"] = o.CreateIndex } - if o.CreateTime != nil { - toSerialize["CreateTime"] = o.CreateTime + if o.CreateTime.IsSet() { + toSerialize["CreateTime"] = o.CreateTime.Get() } if o.Global != nil { toSerialize["Global"] = o.Global diff --git a/clients/go/v1/model_acl_token_list_stub.go b/clients/go/v1/model_acl_token_list_stub.go index e4828266..28b46957 100644 --- a/clients/go/v1/model_acl_token_list_stub.go +++ b/clients/go/v1/model_acl_token_list_stub.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -20,11 +20,11 @@ import ( type ACLTokenListStub struct { AccessorID *string `json:"AccessorID,omitempty"` CreateIndex *int32 `json:"CreateIndex,omitempty"` - CreateTime *time.Time `json:"CreateTime,omitempty"` + CreateTime NullableTime `json:"CreateTime,omitempty"` Global *bool `json:"Global,omitempty"` ModifyIndex *int32 `json:"ModifyIndex,omitempty"` Name *string `json:"Name,omitempty"` - Policies *[]string `json:"Policies,omitempty"` + Policies []string `json:"Policies,omitempty"` Type *string `json:"Type,omitempty"` } @@ -109,36 +109,46 @@ func (o *ACLTokenListStub) SetCreateIndex(v int32) { o.CreateIndex = &v } -// GetCreateTime returns the CreateTime field value if set, zero value otherwise. +// GetCreateTime returns the CreateTime field value if set, zero value otherwise (both if not set or set to explicit null). func (o *ACLTokenListStub) GetCreateTime() time.Time { - if o == nil || o.CreateTime == nil { + if o == nil || o.CreateTime.Get() == nil { var ret time.Time return ret } - return *o.CreateTime + return *o.CreateTime.Get() } // GetCreateTimeOk returns a tuple with the CreateTime field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *ACLTokenListStub) GetCreateTimeOk() (*time.Time, bool) { - if o == nil || o.CreateTime == nil { + if o == nil { return nil, false } - return o.CreateTime, true + return o.CreateTime.Get(), o.CreateTime.IsSet() } // HasCreateTime returns a boolean if a field has been set. func (o *ACLTokenListStub) HasCreateTime() bool { - if o != nil && o.CreateTime != nil { + if o != nil && o.CreateTime.IsSet() { return true } return false } -// SetCreateTime gets a reference to the given time.Time and assigns it to the CreateTime field. +// SetCreateTime gets a reference to the given NullableTime and assigns it to the CreateTime field. func (o *ACLTokenListStub) SetCreateTime(v time.Time) { - o.CreateTime = &v + o.CreateTime.Set(&v) +} +// SetCreateTimeNil sets the value for CreateTime to be an explicit nil +func (o *ACLTokenListStub) SetCreateTimeNil() { + o.CreateTime.Set(nil) +} + +// UnsetCreateTime ensures that no value is present for CreateTime, not even an explicit nil +func (o *ACLTokenListStub) UnsetCreateTime() { + o.CreateTime.Unset() } // GetGlobal returns the Global field value if set, zero value otherwise. @@ -243,12 +253,12 @@ func (o *ACLTokenListStub) GetPolicies() []string { var ret []string return ret } - return *o.Policies + return o.Policies } // GetPoliciesOk returns a tuple with the Policies field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *ACLTokenListStub) GetPoliciesOk() (*[]string, bool) { +func (o *ACLTokenListStub) GetPoliciesOk() ([]string, bool) { if o == nil || o.Policies == nil { return nil, false } @@ -266,7 +276,7 @@ func (o *ACLTokenListStub) HasPolicies() bool { // SetPolicies gets a reference to the given []string and assigns it to the Policies field. func (o *ACLTokenListStub) SetPolicies(v []string) { - o.Policies = &v + o.Policies = v } // GetType returns the Type field value if set, zero value otherwise. @@ -309,8 +319,8 @@ func (o ACLTokenListStub) MarshalJSON() ([]byte, error) { if o.CreateIndex != nil { toSerialize["CreateIndex"] = o.CreateIndex } - if o.CreateTime != nil { - toSerialize["CreateTime"] = o.CreateTime + if o.CreateTime.IsSet() { + toSerialize["CreateTime"] = o.CreateTime.Get() } if o.Global != nil { toSerialize["Global"] = o.Global diff --git a/clients/go/v1/model_affinity.go b/clients/go/v1/model_affinity.go index 610cac78..e72d54ff 100644 --- a/clients/go/v1/model_affinity.go +++ b/clients/go/v1/model_affinity.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_alloc_deployment_status.go b/clients/go/v1/model_alloc_deployment_status.go index ab0c25d5..a13bbb09 100644 --- a/clients/go/v1/model_alloc_deployment_status.go +++ b/clients/go/v1/model_alloc_deployment_status.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -21,7 +21,7 @@ type AllocDeploymentStatus struct { Canary *bool `json:"Canary,omitempty"` Healthy *bool `json:"Healthy,omitempty"` ModifyIndex *int32 `json:"ModifyIndex,omitempty"` - Timestamp *time.Time `json:"Timestamp,omitempty"` + Timestamp NullableTime `json:"Timestamp,omitempty"` } // NewAllocDeploymentStatus instantiates a new AllocDeploymentStatus object @@ -137,36 +137,46 @@ func (o *AllocDeploymentStatus) SetModifyIndex(v int32) { o.ModifyIndex = &v } -// GetTimestamp returns the Timestamp field value if set, zero value otherwise. +// GetTimestamp returns the Timestamp field value if set, zero value otherwise (both if not set or set to explicit null). func (o *AllocDeploymentStatus) GetTimestamp() time.Time { - if o == nil || o.Timestamp == nil { + if o == nil || o.Timestamp.Get() == nil { var ret time.Time return ret } - return *o.Timestamp + return *o.Timestamp.Get() } // GetTimestampOk returns a tuple with the Timestamp field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *AllocDeploymentStatus) GetTimestampOk() (*time.Time, bool) { - if o == nil || o.Timestamp == nil { + if o == nil { return nil, false } - return o.Timestamp, true + return o.Timestamp.Get(), o.Timestamp.IsSet() } // HasTimestamp returns a boolean if a field has been set. func (o *AllocDeploymentStatus) HasTimestamp() bool { - if o != nil && o.Timestamp != nil { + if o != nil && o.Timestamp.IsSet() { return true } return false } -// SetTimestamp gets a reference to the given time.Time and assigns it to the Timestamp field. +// SetTimestamp gets a reference to the given NullableTime and assigns it to the Timestamp field. func (o *AllocDeploymentStatus) SetTimestamp(v time.Time) { - o.Timestamp = &v + o.Timestamp.Set(&v) +} +// SetTimestampNil sets the value for Timestamp to be an explicit nil +func (o *AllocDeploymentStatus) SetTimestampNil() { + o.Timestamp.Set(nil) +} + +// UnsetTimestamp ensures that no value is present for Timestamp, not even an explicit nil +func (o *AllocDeploymentStatus) UnsetTimestamp() { + o.Timestamp.Unset() } func (o AllocDeploymentStatus) MarshalJSON() ([]byte, error) { @@ -180,8 +190,8 @@ func (o AllocDeploymentStatus) MarshalJSON() ([]byte, error) { if o.ModifyIndex != nil { toSerialize["ModifyIndex"] = o.ModifyIndex } - if o.Timestamp != nil { - toSerialize["Timestamp"] = o.Timestamp + if o.Timestamp.IsSet() { + toSerialize["Timestamp"] = o.Timestamp.Get() } return json.Marshal(toSerialize) } diff --git a/clients/go/v1/model_alloc_stop_response.go b/clients/go/v1/model_alloc_stop_response.go index b5ea3a96..2f1bc29e 100644 --- a/clients/go/v1/model_alloc_stop_response.go +++ b/clients/go/v1/model_alloc_stop_response.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_allocated_cpu_resources.go b/clients/go/v1/model_allocated_cpu_resources.go index 4dc6c9ee..9fec4a01 100644 --- a/clients/go/v1/model_allocated_cpu_resources.go +++ b/clients/go/v1/model_allocated_cpu_resources.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_allocated_device_resource.go b/clients/go/v1/model_allocated_device_resource.go index e07d3652..e860b7d0 100644 --- a/clients/go/v1/model_allocated_device_resource.go +++ b/clients/go/v1/model_allocated_device_resource.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,7 +17,7 @@ import ( // AllocatedDeviceResource struct for AllocatedDeviceResource type AllocatedDeviceResource struct { - DeviceIDs *[]string `json:"DeviceIDs,omitempty"` + DeviceIDs []string `json:"DeviceIDs,omitempty"` Name *string `json:"Name,omitempty"` Type *string `json:"Type,omitempty"` Vendor *string `json:"Vendor,omitempty"` @@ -46,12 +46,12 @@ func (o *AllocatedDeviceResource) GetDeviceIDs() []string { var ret []string return ret } - return *o.DeviceIDs + return o.DeviceIDs } // GetDeviceIDsOk returns a tuple with the DeviceIDs field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *AllocatedDeviceResource) GetDeviceIDsOk() (*[]string, bool) { +func (o *AllocatedDeviceResource) GetDeviceIDsOk() ([]string, bool) { if o == nil || o.DeviceIDs == nil { return nil, false } @@ -69,7 +69,7 @@ func (o *AllocatedDeviceResource) HasDeviceIDs() bool { // SetDeviceIDs gets a reference to the given []string and assigns it to the DeviceIDs field. func (o *AllocatedDeviceResource) SetDeviceIDs(v []string) { - o.DeviceIDs = &v + o.DeviceIDs = v } // GetName returns the Name field value if set, zero value otherwise. diff --git a/clients/go/v1/model_allocated_memory_resources.go b/clients/go/v1/model_allocated_memory_resources.go index 5e3f4839..30ab8f09 100644 --- a/clients/go/v1/model_allocated_memory_resources.go +++ b/clients/go/v1/model_allocated_memory_resources.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_allocated_resources.go b/clients/go/v1/model_allocated_resources.go index 1c957aee..8308c38f 100644 --- a/clients/go/v1/model_allocated_resources.go +++ b/clients/go/v1/model_allocated_resources.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,7 +17,7 @@ import ( // AllocatedResources struct for AllocatedResources type AllocatedResources struct { - Shared *AllocatedSharedResources `json:"Shared,omitempty"` + Shared NullableAllocatedSharedResources `json:"Shared,omitempty"` Tasks *map[string]AllocatedTaskResources `json:"Tasks,omitempty"` } @@ -38,36 +38,46 @@ func NewAllocatedResourcesWithDefaults() *AllocatedResources { return &this } -// GetShared returns the Shared field value if set, zero value otherwise. +// GetShared returns the Shared field value if set, zero value otherwise (both if not set or set to explicit null). func (o *AllocatedResources) GetShared() AllocatedSharedResources { - if o == nil || o.Shared == nil { + if o == nil || o.Shared.Get() == nil { var ret AllocatedSharedResources return ret } - return *o.Shared + return *o.Shared.Get() } // GetSharedOk returns a tuple with the Shared field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *AllocatedResources) GetSharedOk() (*AllocatedSharedResources, bool) { - if o == nil || o.Shared == nil { + if o == nil { return nil, false } - return o.Shared, true + return o.Shared.Get(), o.Shared.IsSet() } // HasShared returns a boolean if a field has been set. func (o *AllocatedResources) HasShared() bool { - if o != nil && o.Shared != nil { + if o != nil && o.Shared.IsSet() { return true } return false } -// SetShared gets a reference to the given AllocatedSharedResources and assigns it to the Shared field. +// SetShared gets a reference to the given NullableAllocatedSharedResources and assigns it to the Shared field. func (o *AllocatedResources) SetShared(v AllocatedSharedResources) { - o.Shared = &v + o.Shared.Set(&v) +} +// SetSharedNil sets the value for Shared to be an explicit nil +func (o *AllocatedResources) SetSharedNil() { + o.Shared.Set(nil) +} + +// UnsetShared ensures that no value is present for Shared, not even an explicit nil +func (o *AllocatedResources) UnsetShared() { + o.Shared.Unset() } // GetTasks returns the Tasks field value if set, zero value otherwise. @@ -104,8 +114,8 @@ func (o *AllocatedResources) SetTasks(v map[string]AllocatedTaskResources) { func (o AllocatedResources) MarshalJSON() ([]byte, error) { toSerialize := map[string]interface{}{} - if o.Shared != nil { - toSerialize["Shared"] = o.Shared + if o.Shared.IsSet() { + toSerialize["Shared"] = o.Shared.Get() } if o.Tasks != nil { toSerialize["Tasks"] = o.Tasks diff --git a/clients/go/v1/model_allocated_shared_resources.go b/clients/go/v1/model_allocated_shared_resources.go index 33b7c83f..ba88b092 100644 --- a/clients/go/v1/model_allocated_shared_resources.go +++ b/clients/go/v1/model_allocated_shared_resources.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -18,8 +18,8 @@ import ( // AllocatedSharedResources struct for AllocatedSharedResources type AllocatedSharedResources struct { DiskMB *int64 `json:"DiskMB,omitempty"` - Networks *[]NetworkResource `json:"Networks,omitempty"` - Ports *[]PortMapping `json:"Ports,omitempty"` + Networks []NetworkResource `json:"Networks,omitempty"` + Ports []PortMapping `json:"Ports,omitempty"` } // NewAllocatedSharedResources instantiates a new AllocatedSharedResources object @@ -77,12 +77,12 @@ func (o *AllocatedSharedResources) GetNetworks() []NetworkResource { var ret []NetworkResource return ret } - return *o.Networks + return o.Networks } // GetNetworksOk returns a tuple with the Networks field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *AllocatedSharedResources) GetNetworksOk() (*[]NetworkResource, bool) { +func (o *AllocatedSharedResources) GetNetworksOk() ([]NetworkResource, bool) { if o == nil || o.Networks == nil { return nil, false } @@ -100,7 +100,7 @@ func (o *AllocatedSharedResources) HasNetworks() bool { // SetNetworks gets a reference to the given []NetworkResource and assigns it to the Networks field. func (o *AllocatedSharedResources) SetNetworks(v []NetworkResource) { - o.Networks = &v + o.Networks = v } // GetPorts returns the Ports field value if set, zero value otherwise. @@ -109,12 +109,12 @@ func (o *AllocatedSharedResources) GetPorts() []PortMapping { var ret []PortMapping return ret } - return *o.Ports + return o.Ports } // GetPortsOk returns a tuple with the Ports field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *AllocatedSharedResources) GetPortsOk() (*[]PortMapping, bool) { +func (o *AllocatedSharedResources) GetPortsOk() ([]PortMapping, bool) { if o == nil || o.Ports == nil { return nil, false } @@ -132,7 +132,7 @@ func (o *AllocatedSharedResources) HasPorts() bool { // SetPorts gets a reference to the given []PortMapping and assigns it to the Ports field. func (o *AllocatedSharedResources) SetPorts(v []PortMapping) { - o.Ports = &v + o.Ports = v } func (o AllocatedSharedResources) MarshalJSON() ([]byte, error) { diff --git a/clients/go/v1/model_allocated_task_resources.go b/clients/go/v1/model_allocated_task_resources.go index c4a774cd..26f40c34 100644 --- a/clients/go/v1/model_allocated_task_resources.go +++ b/clients/go/v1/model_allocated_task_resources.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,10 +17,10 @@ import ( // AllocatedTaskResources struct for AllocatedTaskResources type AllocatedTaskResources struct { - Cpu *AllocatedCpuResources `json:"Cpu,omitempty"` - Devices *[]AllocatedDeviceResource `json:"Devices,omitempty"` - Memory *AllocatedMemoryResources `json:"Memory,omitempty"` - Networks *[]NetworkResource `json:"Networks,omitempty"` + Cpu NullableAllocatedCpuResources `json:"Cpu,omitempty"` + Devices []AllocatedDeviceResource `json:"Devices,omitempty"` + Memory NullableAllocatedMemoryResources `json:"Memory,omitempty"` + Networks []NetworkResource `json:"Networks,omitempty"` } // NewAllocatedTaskResources instantiates a new AllocatedTaskResources object @@ -40,36 +40,46 @@ func NewAllocatedTaskResourcesWithDefaults() *AllocatedTaskResources { return &this } -// GetCpu returns the Cpu field value if set, zero value otherwise. +// GetCpu returns the Cpu field value if set, zero value otherwise (both if not set or set to explicit null). func (o *AllocatedTaskResources) GetCpu() AllocatedCpuResources { - if o == nil || o.Cpu == nil { + if o == nil || o.Cpu.Get() == nil { var ret AllocatedCpuResources return ret } - return *o.Cpu + return *o.Cpu.Get() } // GetCpuOk returns a tuple with the Cpu field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *AllocatedTaskResources) GetCpuOk() (*AllocatedCpuResources, bool) { - if o == nil || o.Cpu == nil { + if o == nil { return nil, false } - return o.Cpu, true + return o.Cpu.Get(), o.Cpu.IsSet() } // HasCpu returns a boolean if a field has been set. func (o *AllocatedTaskResources) HasCpu() bool { - if o != nil && o.Cpu != nil { + if o != nil && o.Cpu.IsSet() { return true } return false } -// SetCpu gets a reference to the given AllocatedCpuResources and assigns it to the Cpu field. +// SetCpu gets a reference to the given NullableAllocatedCpuResources and assigns it to the Cpu field. func (o *AllocatedTaskResources) SetCpu(v AllocatedCpuResources) { - o.Cpu = &v + o.Cpu.Set(&v) +} +// SetCpuNil sets the value for Cpu to be an explicit nil +func (o *AllocatedTaskResources) SetCpuNil() { + o.Cpu.Set(nil) +} + +// UnsetCpu ensures that no value is present for Cpu, not even an explicit nil +func (o *AllocatedTaskResources) UnsetCpu() { + o.Cpu.Unset() } // GetDevices returns the Devices field value if set, zero value otherwise. @@ -78,12 +88,12 @@ func (o *AllocatedTaskResources) GetDevices() []AllocatedDeviceResource { var ret []AllocatedDeviceResource return ret } - return *o.Devices + return o.Devices } // GetDevicesOk returns a tuple with the Devices field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *AllocatedTaskResources) GetDevicesOk() (*[]AllocatedDeviceResource, bool) { +func (o *AllocatedTaskResources) GetDevicesOk() ([]AllocatedDeviceResource, bool) { if o == nil || o.Devices == nil { return nil, false } @@ -101,39 +111,49 @@ func (o *AllocatedTaskResources) HasDevices() bool { // SetDevices gets a reference to the given []AllocatedDeviceResource and assigns it to the Devices field. func (o *AllocatedTaskResources) SetDevices(v []AllocatedDeviceResource) { - o.Devices = &v + o.Devices = v } -// GetMemory returns the Memory field value if set, zero value otherwise. +// GetMemory returns the Memory field value if set, zero value otherwise (both if not set or set to explicit null). func (o *AllocatedTaskResources) GetMemory() AllocatedMemoryResources { - if o == nil || o.Memory == nil { + if o == nil || o.Memory.Get() == nil { var ret AllocatedMemoryResources return ret } - return *o.Memory + return *o.Memory.Get() } // GetMemoryOk returns a tuple with the Memory field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *AllocatedTaskResources) GetMemoryOk() (*AllocatedMemoryResources, bool) { - if o == nil || o.Memory == nil { + if o == nil { return nil, false } - return o.Memory, true + return o.Memory.Get(), o.Memory.IsSet() } // HasMemory returns a boolean if a field has been set. func (o *AllocatedTaskResources) HasMemory() bool { - if o != nil && o.Memory != nil { + if o != nil && o.Memory.IsSet() { return true } return false } -// SetMemory gets a reference to the given AllocatedMemoryResources and assigns it to the Memory field. +// SetMemory gets a reference to the given NullableAllocatedMemoryResources and assigns it to the Memory field. func (o *AllocatedTaskResources) SetMemory(v AllocatedMemoryResources) { - o.Memory = &v + o.Memory.Set(&v) +} +// SetMemoryNil sets the value for Memory to be an explicit nil +func (o *AllocatedTaskResources) SetMemoryNil() { + o.Memory.Set(nil) +} + +// UnsetMemory ensures that no value is present for Memory, not even an explicit nil +func (o *AllocatedTaskResources) UnsetMemory() { + o.Memory.Unset() } // GetNetworks returns the Networks field value if set, zero value otherwise. @@ -142,12 +162,12 @@ func (o *AllocatedTaskResources) GetNetworks() []NetworkResource { var ret []NetworkResource return ret } - return *o.Networks + return o.Networks } // GetNetworksOk returns a tuple with the Networks field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *AllocatedTaskResources) GetNetworksOk() (*[]NetworkResource, bool) { +func (o *AllocatedTaskResources) GetNetworksOk() ([]NetworkResource, bool) { if o == nil || o.Networks == nil { return nil, false } @@ -165,19 +185,19 @@ func (o *AllocatedTaskResources) HasNetworks() bool { // SetNetworks gets a reference to the given []NetworkResource and assigns it to the Networks field. func (o *AllocatedTaskResources) SetNetworks(v []NetworkResource) { - o.Networks = &v + o.Networks = v } func (o AllocatedTaskResources) MarshalJSON() ([]byte, error) { toSerialize := map[string]interface{}{} - if o.Cpu != nil { - toSerialize["Cpu"] = o.Cpu + if o.Cpu.IsSet() { + toSerialize["Cpu"] = o.Cpu.Get() } if o.Devices != nil { toSerialize["Devices"] = o.Devices } - if o.Memory != nil { - toSerialize["Memory"] = o.Memory + if o.Memory.IsSet() { + toSerialize["Memory"] = o.Memory.Get() } if o.Networks != nil { toSerialize["Networks"] = o.Networks diff --git a/clients/go/v1/model_allocation.go b/clients/go/v1/model_allocation.go index fa57f830..d1a46a60 100644 --- a/clients/go/v1/model_allocation.go +++ b/clients/go/v1/model_allocation.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -18,22 +18,22 @@ import ( // Allocation struct for Allocation type Allocation struct { AllocModifyIndex *int32 `json:"AllocModifyIndex,omitempty"` - AllocatedResources *AllocatedResources `json:"AllocatedResources,omitempty"` + AllocatedResources NullableAllocatedResources `json:"AllocatedResources,omitempty"` ClientDescription *string `json:"ClientDescription,omitempty"` ClientStatus *string `json:"ClientStatus,omitempty"` CreateIndex *int32 `json:"CreateIndex,omitempty"` CreateTime *int64 `json:"CreateTime,omitempty"` DeploymentID *string `json:"DeploymentID,omitempty"` - DeploymentStatus *AllocDeploymentStatus `json:"DeploymentStatus,omitempty"` + DeploymentStatus NullableAllocDeploymentStatus `json:"DeploymentStatus,omitempty"` DesiredDescription *string `json:"DesiredDescription,omitempty"` DesiredStatus *string `json:"DesiredStatus,omitempty"` DesiredTransition *DesiredTransition `json:"DesiredTransition,omitempty"` EvalID *string `json:"EvalID,omitempty"` FollowupEvalID *string `json:"FollowupEvalID,omitempty"` ID *string `json:"ID,omitempty"` - Job *Job `json:"Job,omitempty"` + Job NullableJob `json:"Job,omitempty"` JobID *string `json:"JobID,omitempty"` - Metrics *AllocationMetric `json:"Metrics,omitempty"` + Metrics NullableAllocationMetric `json:"Metrics,omitempty"` ModifyIndex *int32 `json:"ModifyIndex,omitempty"` ModifyTime *int64 `json:"ModifyTime,omitempty"` Name *string `json:"Name,omitempty"` @@ -41,11 +41,11 @@ type Allocation struct { NextAllocation *string `json:"NextAllocation,omitempty"` NodeID *string `json:"NodeID,omitempty"` NodeName *string `json:"NodeName,omitempty"` - PreemptedAllocations *[]string `json:"PreemptedAllocations,omitempty"` + PreemptedAllocations []string `json:"PreemptedAllocations,omitempty"` PreemptedByAllocation *string `json:"PreemptedByAllocation,omitempty"` PreviousAllocation *string `json:"PreviousAllocation,omitempty"` - RescheduleTracker *RescheduleTracker `json:"RescheduleTracker,omitempty"` - Resources *Resources `json:"Resources,omitempty"` + RescheduleTracker NullableRescheduleTracker `json:"RescheduleTracker,omitempty"` + Resources NullableResources `json:"Resources,omitempty"` Services *map[string]string `json:"Services,omitempty"` TaskGroup *string `json:"TaskGroup,omitempty"` TaskResources *map[string]Resources `json:"TaskResources,omitempty"` @@ -101,36 +101,46 @@ func (o *Allocation) SetAllocModifyIndex(v int32) { o.AllocModifyIndex = &v } -// GetAllocatedResources returns the AllocatedResources field value if set, zero value otherwise. +// GetAllocatedResources returns the AllocatedResources field value if set, zero value otherwise (both if not set or set to explicit null). func (o *Allocation) GetAllocatedResources() AllocatedResources { - if o == nil || o.AllocatedResources == nil { + if o == nil || o.AllocatedResources.Get() == nil { var ret AllocatedResources return ret } - return *o.AllocatedResources + return *o.AllocatedResources.Get() } // GetAllocatedResourcesOk returns a tuple with the AllocatedResources field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *Allocation) GetAllocatedResourcesOk() (*AllocatedResources, bool) { - if o == nil || o.AllocatedResources == nil { + if o == nil { return nil, false } - return o.AllocatedResources, true + return o.AllocatedResources.Get(), o.AllocatedResources.IsSet() } // HasAllocatedResources returns a boolean if a field has been set. func (o *Allocation) HasAllocatedResources() bool { - if o != nil && o.AllocatedResources != nil { + if o != nil && o.AllocatedResources.IsSet() { return true } return false } -// SetAllocatedResources gets a reference to the given AllocatedResources and assigns it to the AllocatedResources field. +// SetAllocatedResources gets a reference to the given NullableAllocatedResources and assigns it to the AllocatedResources field. func (o *Allocation) SetAllocatedResources(v AllocatedResources) { - o.AllocatedResources = &v + o.AllocatedResources.Set(&v) +} +// SetAllocatedResourcesNil sets the value for AllocatedResources to be an explicit nil +func (o *Allocation) SetAllocatedResourcesNil() { + o.AllocatedResources.Set(nil) +} + +// UnsetAllocatedResources ensures that no value is present for AllocatedResources, not even an explicit nil +func (o *Allocation) UnsetAllocatedResources() { + o.AllocatedResources.Unset() } // GetClientDescription returns the ClientDescription field value if set, zero value otherwise. @@ -293,36 +303,46 @@ func (o *Allocation) SetDeploymentID(v string) { o.DeploymentID = &v } -// GetDeploymentStatus returns the DeploymentStatus field value if set, zero value otherwise. +// GetDeploymentStatus returns the DeploymentStatus field value if set, zero value otherwise (both if not set or set to explicit null). func (o *Allocation) GetDeploymentStatus() AllocDeploymentStatus { - if o == nil || o.DeploymentStatus == nil { + if o == nil || o.DeploymentStatus.Get() == nil { var ret AllocDeploymentStatus return ret } - return *o.DeploymentStatus + return *o.DeploymentStatus.Get() } // GetDeploymentStatusOk returns a tuple with the DeploymentStatus field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *Allocation) GetDeploymentStatusOk() (*AllocDeploymentStatus, bool) { - if o == nil || o.DeploymentStatus == nil { + if o == nil { return nil, false } - return o.DeploymentStatus, true + return o.DeploymentStatus.Get(), o.DeploymentStatus.IsSet() } // HasDeploymentStatus returns a boolean if a field has been set. func (o *Allocation) HasDeploymentStatus() bool { - if o != nil && o.DeploymentStatus != nil { + if o != nil && o.DeploymentStatus.IsSet() { return true } return false } -// SetDeploymentStatus gets a reference to the given AllocDeploymentStatus and assigns it to the DeploymentStatus field. +// SetDeploymentStatus gets a reference to the given NullableAllocDeploymentStatus and assigns it to the DeploymentStatus field. func (o *Allocation) SetDeploymentStatus(v AllocDeploymentStatus) { - o.DeploymentStatus = &v + o.DeploymentStatus.Set(&v) +} +// SetDeploymentStatusNil sets the value for DeploymentStatus to be an explicit nil +func (o *Allocation) SetDeploymentStatusNil() { + o.DeploymentStatus.Set(nil) +} + +// UnsetDeploymentStatus ensures that no value is present for DeploymentStatus, not even an explicit nil +func (o *Allocation) UnsetDeploymentStatus() { + o.DeploymentStatus.Unset() } // GetDesiredDescription returns the DesiredDescription field value if set, zero value otherwise. @@ -517,36 +537,46 @@ func (o *Allocation) SetID(v string) { o.ID = &v } -// GetJob returns the Job field value if set, zero value otherwise. +// GetJob returns the Job field value if set, zero value otherwise (both if not set or set to explicit null). func (o *Allocation) GetJob() Job { - if o == nil || o.Job == nil { + if o == nil || o.Job.Get() == nil { var ret Job return ret } - return *o.Job + return *o.Job.Get() } // GetJobOk returns a tuple with the Job field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *Allocation) GetJobOk() (*Job, bool) { - if o == nil || o.Job == nil { + if o == nil { return nil, false } - return o.Job, true + return o.Job.Get(), o.Job.IsSet() } // HasJob returns a boolean if a field has been set. func (o *Allocation) HasJob() bool { - if o != nil && o.Job != nil { + if o != nil && o.Job.IsSet() { return true } return false } -// SetJob gets a reference to the given Job and assigns it to the Job field. +// SetJob gets a reference to the given NullableJob and assigns it to the Job field. func (o *Allocation) SetJob(v Job) { - o.Job = &v + o.Job.Set(&v) +} +// SetJobNil sets the value for Job to be an explicit nil +func (o *Allocation) SetJobNil() { + o.Job.Set(nil) +} + +// UnsetJob ensures that no value is present for Job, not even an explicit nil +func (o *Allocation) UnsetJob() { + o.Job.Unset() } // GetJobID returns the JobID field value if set, zero value otherwise. @@ -581,36 +611,46 @@ func (o *Allocation) SetJobID(v string) { o.JobID = &v } -// GetMetrics returns the Metrics field value if set, zero value otherwise. +// GetMetrics returns the Metrics field value if set, zero value otherwise (both if not set or set to explicit null). func (o *Allocation) GetMetrics() AllocationMetric { - if o == nil || o.Metrics == nil { + if o == nil || o.Metrics.Get() == nil { var ret AllocationMetric return ret } - return *o.Metrics + return *o.Metrics.Get() } // GetMetricsOk returns a tuple with the Metrics field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *Allocation) GetMetricsOk() (*AllocationMetric, bool) { - if o == nil || o.Metrics == nil { + if o == nil { return nil, false } - return o.Metrics, true + return o.Metrics.Get(), o.Metrics.IsSet() } // HasMetrics returns a boolean if a field has been set. func (o *Allocation) HasMetrics() bool { - if o != nil && o.Metrics != nil { + if o != nil && o.Metrics.IsSet() { return true } return false } -// SetMetrics gets a reference to the given AllocationMetric and assigns it to the Metrics field. +// SetMetrics gets a reference to the given NullableAllocationMetric and assigns it to the Metrics field. func (o *Allocation) SetMetrics(v AllocationMetric) { - o.Metrics = &v + o.Metrics.Set(&v) +} +// SetMetricsNil sets the value for Metrics to be an explicit nil +func (o *Allocation) SetMetricsNil() { + o.Metrics.Set(nil) +} + +// UnsetMetrics ensures that no value is present for Metrics, not even an explicit nil +func (o *Allocation) UnsetMetrics() { + o.Metrics.Unset() } // GetModifyIndex returns the ModifyIndex field value if set, zero value otherwise. @@ -843,12 +883,12 @@ func (o *Allocation) GetPreemptedAllocations() []string { var ret []string return ret } - return *o.PreemptedAllocations + return o.PreemptedAllocations } // GetPreemptedAllocationsOk returns a tuple with the PreemptedAllocations field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *Allocation) GetPreemptedAllocationsOk() (*[]string, bool) { +func (o *Allocation) GetPreemptedAllocationsOk() ([]string, bool) { if o == nil || o.PreemptedAllocations == nil { return nil, false } @@ -866,7 +906,7 @@ func (o *Allocation) HasPreemptedAllocations() bool { // SetPreemptedAllocations gets a reference to the given []string and assigns it to the PreemptedAllocations field. func (o *Allocation) SetPreemptedAllocations(v []string) { - o.PreemptedAllocations = &v + o.PreemptedAllocations = v } // GetPreemptedByAllocation returns the PreemptedByAllocation field value if set, zero value otherwise. @@ -933,68 +973,88 @@ func (o *Allocation) SetPreviousAllocation(v string) { o.PreviousAllocation = &v } -// GetRescheduleTracker returns the RescheduleTracker field value if set, zero value otherwise. +// GetRescheduleTracker returns the RescheduleTracker field value if set, zero value otherwise (both if not set or set to explicit null). func (o *Allocation) GetRescheduleTracker() RescheduleTracker { - if o == nil || o.RescheduleTracker == nil { + if o == nil || o.RescheduleTracker.Get() == nil { var ret RescheduleTracker return ret } - return *o.RescheduleTracker + return *o.RescheduleTracker.Get() } // GetRescheduleTrackerOk returns a tuple with the RescheduleTracker field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *Allocation) GetRescheduleTrackerOk() (*RescheduleTracker, bool) { - if o == nil || o.RescheduleTracker == nil { + if o == nil { return nil, false } - return o.RescheduleTracker, true + return o.RescheduleTracker.Get(), o.RescheduleTracker.IsSet() } // HasRescheduleTracker returns a boolean if a field has been set. func (o *Allocation) HasRescheduleTracker() bool { - if o != nil && o.RescheduleTracker != nil { + if o != nil && o.RescheduleTracker.IsSet() { return true } return false } -// SetRescheduleTracker gets a reference to the given RescheduleTracker and assigns it to the RescheduleTracker field. +// SetRescheduleTracker gets a reference to the given NullableRescheduleTracker and assigns it to the RescheduleTracker field. func (o *Allocation) SetRescheduleTracker(v RescheduleTracker) { - o.RescheduleTracker = &v + o.RescheduleTracker.Set(&v) +} +// SetRescheduleTrackerNil sets the value for RescheduleTracker to be an explicit nil +func (o *Allocation) SetRescheduleTrackerNil() { + o.RescheduleTracker.Set(nil) } -// GetResources returns the Resources field value if set, zero value otherwise. +// UnsetRescheduleTracker ensures that no value is present for RescheduleTracker, not even an explicit nil +func (o *Allocation) UnsetRescheduleTracker() { + o.RescheduleTracker.Unset() +} + +// GetResources returns the Resources field value if set, zero value otherwise (both if not set or set to explicit null). func (o *Allocation) GetResources() Resources { - if o == nil || o.Resources == nil { + if o == nil || o.Resources.Get() == nil { var ret Resources return ret } - return *o.Resources + return *o.Resources.Get() } // GetResourcesOk returns a tuple with the Resources field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *Allocation) GetResourcesOk() (*Resources, bool) { - if o == nil || o.Resources == nil { + if o == nil { return nil, false } - return o.Resources, true + return o.Resources.Get(), o.Resources.IsSet() } // HasResources returns a boolean if a field has been set. func (o *Allocation) HasResources() bool { - if o != nil && o.Resources != nil { + if o != nil && o.Resources.IsSet() { return true } return false } -// SetResources gets a reference to the given Resources and assigns it to the Resources field. +// SetResources gets a reference to the given NullableResources and assigns it to the Resources field. func (o *Allocation) SetResources(v Resources) { - o.Resources = &v + o.Resources.Set(&v) +} +// SetResourcesNil sets the value for Resources to be an explicit nil +func (o *Allocation) SetResourcesNil() { + o.Resources.Set(nil) +} + +// UnsetResources ensures that no value is present for Resources, not even an explicit nil +func (o *Allocation) UnsetResources() { + o.Resources.Unset() } // GetServices returns the Services field value if set, zero value otherwise. @@ -1130,8 +1190,8 @@ func (o Allocation) MarshalJSON() ([]byte, error) { if o.AllocModifyIndex != nil { toSerialize["AllocModifyIndex"] = o.AllocModifyIndex } - if o.AllocatedResources != nil { - toSerialize["AllocatedResources"] = o.AllocatedResources + if o.AllocatedResources.IsSet() { + toSerialize["AllocatedResources"] = o.AllocatedResources.Get() } if o.ClientDescription != nil { toSerialize["ClientDescription"] = o.ClientDescription @@ -1148,8 +1208,8 @@ func (o Allocation) MarshalJSON() ([]byte, error) { if o.DeploymentID != nil { toSerialize["DeploymentID"] = o.DeploymentID } - if o.DeploymentStatus != nil { - toSerialize["DeploymentStatus"] = o.DeploymentStatus + if o.DeploymentStatus.IsSet() { + toSerialize["DeploymentStatus"] = o.DeploymentStatus.Get() } if o.DesiredDescription != nil { toSerialize["DesiredDescription"] = o.DesiredDescription @@ -1169,14 +1229,14 @@ func (o Allocation) MarshalJSON() ([]byte, error) { if o.ID != nil { toSerialize["ID"] = o.ID } - if o.Job != nil { - toSerialize["Job"] = o.Job + if o.Job.IsSet() { + toSerialize["Job"] = o.Job.Get() } if o.JobID != nil { toSerialize["JobID"] = o.JobID } - if o.Metrics != nil { - toSerialize["Metrics"] = o.Metrics + if o.Metrics.IsSet() { + toSerialize["Metrics"] = o.Metrics.Get() } if o.ModifyIndex != nil { toSerialize["ModifyIndex"] = o.ModifyIndex @@ -1208,11 +1268,11 @@ func (o Allocation) MarshalJSON() ([]byte, error) { if o.PreviousAllocation != nil { toSerialize["PreviousAllocation"] = o.PreviousAllocation } - if o.RescheduleTracker != nil { - toSerialize["RescheduleTracker"] = o.RescheduleTracker + if o.RescheduleTracker.IsSet() { + toSerialize["RescheduleTracker"] = o.RescheduleTracker.Get() } - if o.Resources != nil { - toSerialize["Resources"] = o.Resources + if o.Resources.IsSet() { + toSerialize["Resources"] = o.Resources.Get() } if o.Services != nil { toSerialize["Services"] = o.Services diff --git a/clients/go/v1/model_allocation_list_stub.go b/clients/go/v1/model_allocation_list_stub.go index 47871337..4750e534 100644 --- a/clients/go/v1/model_allocation_list_stub.go +++ b/clients/go/v1/model_allocation_list_stub.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,12 +17,12 @@ import ( // AllocationListStub struct for AllocationListStub type AllocationListStub struct { - AllocatedResources *AllocatedResources `json:"AllocatedResources,omitempty"` + AllocatedResources NullableAllocatedResources `json:"AllocatedResources,omitempty"` ClientDescription *string `json:"ClientDescription,omitempty"` ClientStatus *string `json:"ClientStatus,omitempty"` CreateIndex *int32 `json:"CreateIndex,omitempty"` CreateTime *int64 `json:"CreateTime,omitempty"` - DeploymentStatus *AllocDeploymentStatus `json:"DeploymentStatus,omitempty"` + DeploymentStatus NullableAllocDeploymentStatus `json:"DeploymentStatus,omitempty"` DesiredDescription *string `json:"DesiredDescription,omitempty"` DesiredStatus *string `json:"DesiredStatus,omitempty"` EvalID *string `json:"EvalID,omitempty"` @@ -37,9 +37,9 @@ type AllocationListStub struct { Namespace *string `json:"Namespace,omitempty"` NodeID *string `json:"NodeID,omitempty"` NodeName *string `json:"NodeName,omitempty"` - PreemptedAllocations *[]string `json:"PreemptedAllocations,omitempty"` + PreemptedAllocations []string `json:"PreemptedAllocations,omitempty"` PreemptedByAllocation *string `json:"PreemptedByAllocation,omitempty"` - RescheduleTracker *RescheduleTracker `json:"RescheduleTracker,omitempty"` + RescheduleTracker NullableRescheduleTracker `json:"RescheduleTracker,omitempty"` TaskGroup *string `json:"TaskGroup,omitempty"` TaskStates *map[string]TaskState `json:"TaskStates,omitempty"` } @@ -61,36 +61,46 @@ func NewAllocationListStubWithDefaults() *AllocationListStub { return &this } -// GetAllocatedResources returns the AllocatedResources field value if set, zero value otherwise. +// GetAllocatedResources returns the AllocatedResources field value if set, zero value otherwise (both if not set or set to explicit null). func (o *AllocationListStub) GetAllocatedResources() AllocatedResources { - if o == nil || o.AllocatedResources == nil { + if o == nil || o.AllocatedResources.Get() == nil { var ret AllocatedResources return ret } - return *o.AllocatedResources + return *o.AllocatedResources.Get() } // GetAllocatedResourcesOk returns a tuple with the AllocatedResources field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *AllocationListStub) GetAllocatedResourcesOk() (*AllocatedResources, bool) { - if o == nil || o.AllocatedResources == nil { + if o == nil { return nil, false } - return o.AllocatedResources, true + return o.AllocatedResources.Get(), o.AllocatedResources.IsSet() } // HasAllocatedResources returns a boolean if a field has been set. func (o *AllocationListStub) HasAllocatedResources() bool { - if o != nil && o.AllocatedResources != nil { + if o != nil && o.AllocatedResources.IsSet() { return true } return false } -// SetAllocatedResources gets a reference to the given AllocatedResources and assigns it to the AllocatedResources field. +// SetAllocatedResources gets a reference to the given NullableAllocatedResources and assigns it to the AllocatedResources field. func (o *AllocationListStub) SetAllocatedResources(v AllocatedResources) { - o.AllocatedResources = &v + o.AllocatedResources.Set(&v) +} +// SetAllocatedResourcesNil sets the value for AllocatedResources to be an explicit nil +func (o *AllocationListStub) SetAllocatedResourcesNil() { + o.AllocatedResources.Set(nil) +} + +// UnsetAllocatedResources ensures that no value is present for AllocatedResources, not even an explicit nil +func (o *AllocationListStub) UnsetAllocatedResources() { + o.AllocatedResources.Unset() } // GetClientDescription returns the ClientDescription field value if set, zero value otherwise. @@ -221,36 +231,46 @@ func (o *AllocationListStub) SetCreateTime(v int64) { o.CreateTime = &v } -// GetDeploymentStatus returns the DeploymentStatus field value if set, zero value otherwise. +// GetDeploymentStatus returns the DeploymentStatus field value if set, zero value otherwise (both if not set or set to explicit null). func (o *AllocationListStub) GetDeploymentStatus() AllocDeploymentStatus { - if o == nil || o.DeploymentStatus == nil { + if o == nil || o.DeploymentStatus.Get() == nil { var ret AllocDeploymentStatus return ret } - return *o.DeploymentStatus + return *o.DeploymentStatus.Get() } // GetDeploymentStatusOk returns a tuple with the DeploymentStatus field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *AllocationListStub) GetDeploymentStatusOk() (*AllocDeploymentStatus, bool) { - if o == nil || o.DeploymentStatus == nil { + if o == nil { return nil, false } - return o.DeploymentStatus, true + return o.DeploymentStatus.Get(), o.DeploymentStatus.IsSet() } // HasDeploymentStatus returns a boolean if a field has been set. func (o *AllocationListStub) HasDeploymentStatus() bool { - if o != nil && o.DeploymentStatus != nil { + if o != nil && o.DeploymentStatus.IsSet() { return true } return false } -// SetDeploymentStatus gets a reference to the given AllocDeploymentStatus and assigns it to the DeploymentStatus field. +// SetDeploymentStatus gets a reference to the given NullableAllocDeploymentStatus and assigns it to the DeploymentStatus field. func (o *AllocationListStub) SetDeploymentStatus(v AllocDeploymentStatus) { - o.DeploymentStatus = &v + o.DeploymentStatus.Set(&v) +} +// SetDeploymentStatusNil sets the value for DeploymentStatus to be an explicit nil +func (o *AllocationListStub) SetDeploymentStatusNil() { + o.DeploymentStatus.Set(nil) +} + +// UnsetDeploymentStatus ensures that no value is present for DeploymentStatus, not even an explicit nil +func (o *AllocationListStub) UnsetDeploymentStatus() { + o.DeploymentStatus.Unset() } // GetDesiredDescription returns the DesiredDescription field value if set, zero value otherwise. @@ -707,12 +727,12 @@ func (o *AllocationListStub) GetPreemptedAllocations() []string { var ret []string return ret } - return *o.PreemptedAllocations + return o.PreemptedAllocations } // GetPreemptedAllocationsOk returns a tuple with the PreemptedAllocations field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *AllocationListStub) GetPreemptedAllocationsOk() (*[]string, bool) { +func (o *AllocationListStub) GetPreemptedAllocationsOk() ([]string, bool) { if o == nil || o.PreemptedAllocations == nil { return nil, false } @@ -730,7 +750,7 @@ func (o *AllocationListStub) HasPreemptedAllocations() bool { // SetPreemptedAllocations gets a reference to the given []string and assigns it to the PreemptedAllocations field. func (o *AllocationListStub) SetPreemptedAllocations(v []string) { - o.PreemptedAllocations = &v + o.PreemptedAllocations = v } // GetPreemptedByAllocation returns the PreemptedByAllocation field value if set, zero value otherwise. @@ -765,36 +785,46 @@ func (o *AllocationListStub) SetPreemptedByAllocation(v string) { o.PreemptedByAllocation = &v } -// GetRescheduleTracker returns the RescheduleTracker field value if set, zero value otherwise. +// GetRescheduleTracker returns the RescheduleTracker field value if set, zero value otherwise (both if not set or set to explicit null). func (o *AllocationListStub) GetRescheduleTracker() RescheduleTracker { - if o == nil || o.RescheduleTracker == nil { + if o == nil || o.RescheduleTracker.Get() == nil { var ret RescheduleTracker return ret } - return *o.RescheduleTracker + return *o.RescheduleTracker.Get() } // GetRescheduleTrackerOk returns a tuple with the RescheduleTracker field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *AllocationListStub) GetRescheduleTrackerOk() (*RescheduleTracker, bool) { - if o == nil || o.RescheduleTracker == nil { + if o == nil { return nil, false } - return o.RescheduleTracker, true + return o.RescheduleTracker.Get(), o.RescheduleTracker.IsSet() } // HasRescheduleTracker returns a boolean if a field has been set. func (o *AllocationListStub) HasRescheduleTracker() bool { - if o != nil && o.RescheduleTracker != nil { + if o != nil && o.RescheduleTracker.IsSet() { return true } return false } -// SetRescheduleTracker gets a reference to the given RescheduleTracker and assigns it to the RescheduleTracker field. +// SetRescheduleTracker gets a reference to the given NullableRescheduleTracker and assigns it to the RescheduleTracker field. func (o *AllocationListStub) SetRescheduleTracker(v RescheduleTracker) { - o.RescheduleTracker = &v + o.RescheduleTracker.Set(&v) +} +// SetRescheduleTrackerNil sets the value for RescheduleTracker to be an explicit nil +func (o *AllocationListStub) SetRescheduleTrackerNil() { + o.RescheduleTracker.Set(nil) +} + +// UnsetRescheduleTracker ensures that no value is present for RescheduleTracker, not even an explicit nil +func (o *AllocationListStub) UnsetRescheduleTracker() { + o.RescheduleTracker.Unset() } // GetTaskGroup returns the TaskGroup field value if set, zero value otherwise. @@ -863,8 +893,8 @@ func (o *AllocationListStub) SetTaskStates(v map[string]TaskState) { func (o AllocationListStub) MarshalJSON() ([]byte, error) { toSerialize := map[string]interface{}{} - if o.AllocatedResources != nil { - toSerialize["AllocatedResources"] = o.AllocatedResources + if o.AllocatedResources.IsSet() { + toSerialize["AllocatedResources"] = o.AllocatedResources.Get() } if o.ClientDescription != nil { toSerialize["ClientDescription"] = o.ClientDescription @@ -878,8 +908,8 @@ func (o AllocationListStub) MarshalJSON() ([]byte, error) { if o.CreateTime != nil { toSerialize["CreateTime"] = o.CreateTime } - if o.DeploymentStatus != nil { - toSerialize["DeploymentStatus"] = o.DeploymentStatus + if o.DeploymentStatus.IsSet() { + toSerialize["DeploymentStatus"] = o.DeploymentStatus.Get() } if o.DesiredDescription != nil { toSerialize["DesiredDescription"] = o.DesiredDescription @@ -929,8 +959,8 @@ func (o AllocationListStub) MarshalJSON() ([]byte, error) { if o.PreemptedByAllocation != nil { toSerialize["PreemptedByAllocation"] = o.PreemptedByAllocation } - if o.RescheduleTracker != nil { - toSerialize["RescheduleTracker"] = o.RescheduleTracker + if o.RescheduleTracker.IsSet() { + toSerialize["RescheduleTracker"] = o.RescheduleTracker.Get() } if o.TaskGroup != nil { toSerialize["TaskGroup"] = o.TaskGroup diff --git a/clients/go/v1/model_allocation_metric.go b/clients/go/v1/model_allocation_metric.go index c8e05cb6..7485b7b2 100644 --- a/clients/go/v1/model_allocation_metric.go +++ b/clients/go/v1/model_allocation_metric.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -27,9 +27,9 @@ type AllocationMetric struct { NodesEvaluated *int32 `json:"NodesEvaluated,omitempty"` NodesExhausted *int32 `json:"NodesExhausted,omitempty"` NodesFiltered *int32 `json:"NodesFiltered,omitempty"` - QuotaExhausted *[]string `json:"QuotaExhausted,omitempty"` + QuotaExhausted []string `json:"QuotaExhausted,omitempty"` ResourcesExhausted *map[string]Resources `json:"ResourcesExhausted,omitempty"` - ScoreMetaData *[]NodeScoreMeta `json:"ScoreMetaData,omitempty"` + ScoreMetaData []NodeScoreMeta `json:"ScoreMetaData,omitempty"` Scores *map[string]float64 `json:"Scores,omitempty"` } @@ -376,12 +376,12 @@ func (o *AllocationMetric) GetQuotaExhausted() []string { var ret []string return ret } - return *o.QuotaExhausted + return o.QuotaExhausted } // GetQuotaExhaustedOk returns a tuple with the QuotaExhausted field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *AllocationMetric) GetQuotaExhaustedOk() (*[]string, bool) { +func (o *AllocationMetric) GetQuotaExhaustedOk() ([]string, bool) { if o == nil || o.QuotaExhausted == nil { return nil, false } @@ -399,7 +399,7 @@ func (o *AllocationMetric) HasQuotaExhausted() bool { // SetQuotaExhausted gets a reference to the given []string and assigns it to the QuotaExhausted field. func (o *AllocationMetric) SetQuotaExhausted(v []string) { - o.QuotaExhausted = &v + o.QuotaExhausted = v } // GetResourcesExhausted returns the ResourcesExhausted field value if set, zero value otherwise. @@ -440,12 +440,12 @@ func (o *AllocationMetric) GetScoreMetaData() []NodeScoreMeta { var ret []NodeScoreMeta return ret } - return *o.ScoreMetaData + return o.ScoreMetaData } // GetScoreMetaDataOk returns a tuple with the ScoreMetaData field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *AllocationMetric) GetScoreMetaDataOk() (*[]NodeScoreMeta, bool) { +func (o *AllocationMetric) GetScoreMetaDataOk() ([]NodeScoreMeta, bool) { if o == nil || o.ScoreMetaData == nil { return nil, false } @@ -463,7 +463,7 @@ func (o *AllocationMetric) HasScoreMetaData() bool { // SetScoreMetaData gets a reference to the given []NodeScoreMeta and assigns it to the ScoreMetaData field. func (o *AllocationMetric) SetScoreMetaData(v []NodeScoreMeta) { - o.ScoreMetaData = &v + o.ScoreMetaData = v } // GetScores returns the Scores field value if set, zero value otherwise. diff --git a/clients/go/v1/model_attribute.go b/clients/go/v1/model_attribute.go index 798bada1..8b6f4afd 100644 --- a/clients/go/v1/model_attribute.go +++ b/clients/go/v1/model_attribute.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_autopilot_configuration.go b/clients/go/v1/model_autopilot_configuration.go index 0714685d..2f33d5cd 100644 --- a/clients/go/v1/model_autopilot_configuration.go +++ b/clients/go/v1/model_autopilot_configuration.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_check_restart.go b/clients/go/v1/model_check_restart.go index cc85a35b..ba0ed156 100644 --- a/clients/go/v1/model_check_restart.go +++ b/clients/go/v1/model_check_restart.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_constraint.go b/clients/go/v1/model_constraint.go index 5bb27127..2142e965 100644 --- a/clients/go/v1/model_constraint.go +++ b/clients/go/v1/model_constraint.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_consul.go b/clients/go/v1/model_consul.go index 9d7156f8..aea03031 100644 --- a/clients/go/v1/model_consul.go +++ b/clients/go/v1/model_consul.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_consul_connect.go b/clients/go/v1/model_consul_connect.go index dcb2c225..4125b709 100644 --- a/clients/go/v1/model_consul_connect.go +++ b/clients/go/v1/model_consul_connect.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -19,8 +19,8 @@ import ( type ConsulConnect struct { Gateway *ConsulGateway `json:"Gateway,omitempty"` Native *bool `json:"Native,omitempty"` - SidecarService *ConsulSidecarService `json:"SidecarService,omitempty"` - SidecarTask *SidecarTask `json:"SidecarTask,omitempty"` + SidecarService NullableConsulSidecarService `json:"SidecarService,omitempty"` + SidecarTask NullableSidecarTask `json:"SidecarTask,omitempty"` } // NewConsulConnect instantiates a new ConsulConnect object @@ -104,68 +104,88 @@ func (o *ConsulConnect) SetNative(v bool) { o.Native = &v } -// GetSidecarService returns the SidecarService field value if set, zero value otherwise. +// GetSidecarService returns the SidecarService field value if set, zero value otherwise (both if not set or set to explicit null). func (o *ConsulConnect) GetSidecarService() ConsulSidecarService { - if o == nil || o.SidecarService == nil { + if o == nil || o.SidecarService.Get() == nil { var ret ConsulSidecarService return ret } - return *o.SidecarService + return *o.SidecarService.Get() } // GetSidecarServiceOk returns a tuple with the SidecarService field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *ConsulConnect) GetSidecarServiceOk() (*ConsulSidecarService, bool) { - if o == nil || o.SidecarService == nil { + if o == nil { return nil, false } - return o.SidecarService, true + return o.SidecarService.Get(), o.SidecarService.IsSet() } // HasSidecarService returns a boolean if a field has been set. func (o *ConsulConnect) HasSidecarService() bool { - if o != nil && o.SidecarService != nil { + if o != nil && o.SidecarService.IsSet() { return true } return false } -// SetSidecarService gets a reference to the given ConsulSidecarService and assigns it to the SidecarService field. +// SetSidecarService gets a reference to the given NullableConsulSidecarService and assigns it to the SidecarService field. func (o *ConsulConnect) SetSidecarService(v ConsulSidecarService) { - o.SidecarService = &v + o.SidecarService.Set(&v) +} +// SetSidecarServiceNil sets the value for SidecarService to be an explicit nil +func (o *ConsulConnect) SetSidecarServiceNil() { + o.SidecarService.Set(nil) +} + +// UnsetSidecarService ensures that no value is present for SidecarService, not even an explicit nil +func (o *ConsulConnect) UnsetSidecarService() { + o.SidecarService.Unset() } -// GetSidecarTask returns the SidecarTask field value if set, zero value otherwise. +// GetSidecarTask returns the SidecarTask field value if set, zero value otherwise (both if not set or set to explicit null). func (o *ConsulConnect) GetSidecarTask() SidecarTask { - if o == nil || o.SidecarTask == nil { + if o == nil || o.SidecarTask.Get() == nil { var ret SidecarTask return ret } - return *o.SidecarTask + return *o.SidecarTask.Get() } // GetSidecarTaskOk returns a tuple with the SidecarTask field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *ConsulConnect) GetSidecarTaskOk() (*SidecarTask, bool) { - if o == nil || o.SidecarTask == nil { + if o == nil { return nil, false } - return o.SidecarTask, true + return o.SidecarTask.Get(), o.SidecarTask.IsSet() } // HasSidecarTask returns a boolean if a field has been set. func (o *ConsulConnect) HasSidecarTask() bool { - if o != nil && o.SidecarTask != nil { + if o != nil && o.SidecarTask.IsSet() { return true } return false } -// SetSidecarTask gets a reference to the given SidecarTask and assigns it to the SidecarTask field. +// SetSidecarTask gets a reference to the given NullableSidecarTask and assigns it to the SidecarTask field. func (o *ConsulConnect) SetSidecarTask(v SidecarTask) { - o.SidecarTask = &v + o.SidecarTask.Set(&v) +} +// SetSidecarTaskNil sets the value for SidecarTask to be an explicit nil +func (o *ConsulConnect) SetSidecarTaskNil() { + o.SidecarTask.Set(nil) +} + +// UnsetSidecarTask ensures that no value is present for SidecarTask, not even an explicit nil +func (o *ConsulConnect) UnsetSidecarTask() { + o.SidecarTask.Unset() } func (o ConsulConnect) MarshalJSON() ([]byte, error) { @@ -176,11 +196,11 @@ func (o ConsulConnect) MarshalJSON() ([]byte, error) { if o.Native != nil { toSerialize["Native"] = o.Native } - if o.SidecarService != nil { - toSerialize["SidecarService"] = o.SidecarService + if o.SidecarService.IsSet() { + toSerialize["SidecarService"] = o.SidecarService.Get() } - if o.SidecarTask != nil { - toSerialize["SidecarTask"] = o.SidecarTask + if o.SidecarTask.IsSet() { + toSerialize["SidecarTask"] = o.SidecarTask.Get() } return json.Marshal(toSerialize) } diff --git a/clients/go/v1/model_consul_expose_config.go b/clients/go/v1/model_consul_expose_config.go index 45ad0ae7..640619ca 100644 --- a/clients/go/v1/model_consul_expose_config.go +++ b/clients/go/v1/model_consul_expose_config.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,7 +17,7 @@ import ( // ConsulExposeConfig struct for ConsulExposeConfig type ConsulExposeConfig struct { - Path *[]ConsulExposePath `json:"Path,omitempty"` + Path []ConsulExposePath `json:"Path,omitempty"` } // NewConsulExposeConfig instantiates a new ConsulExposeConfig object @@ -43,12 +43,12 @@ func (o *ConsulExposeConfig) GetPath() []ConsulExposePath { var ret []ConsulExposePath return ret } - return *o.Path + return o.Path } // GetPathOk returns a tuple with the Path field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *ConsulExposeConfig) GetPathOk() (*[]ConsulExposePath, bool) { +func (o *ConsulExposeConfig) GetPathOk() ([]ConsulExposePath, bool) { if o == nil || o.Path == nil { return nil, false } @@ -66,7 +66,7 @@ func (o *ConsulExposeConfig) HasPath() bool { // SetPath gets a reference to the given []ConsulExposePath and assigns it to the Path field. func (o *ConsulExposeConfig) SetPath(v []ConsulExposePath) { - o.Path = &v + o.Path = v } func (o ConsulExposeConfig) MarshalJSON() ([]byte, error) { diff --git a/clients/go/v1/model_consul_expose_path.go b/clients/go/v1/model_consul_expose_path.go index 2e3b695b..ce4a7dd1 100644 --- a/clients/go/v1/model_consul_expose_path.go +++ b/clients/go/v1/model_consul_expose_path.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_consul_gateway.go b/clients/go/v1/model_consul_gateway.go index 2d26b887..56c2c1b7 100644 --- a/clients/go/v1/model_consul_gateway.go +++ b/clients/go/v1/model_consul_gateway.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,10 +17,10 @@ import ( // ConsulGateway struct for ConsulGateway type ConsulGateway struct { - Ingress *ConsulIngressConfigEntry `json:"Ingress,omitempty"` + Ingress NullableConsulIngressConfigEntry `json:"Ingress,omitempty"` Mesh interface{} `json:"Mesh,omitempty"` - Proxy *ConsulGatewayProxy `json:"Proxy,omitempty"` - Terminating *ConsulTerminatingConfigEntry `json:"Terminating,omitempty"` + Proxy NullableConsulGatewayProxy `json:"Proxy,omitempty"` + Terminating NullableConsulTerminatingConfigEntry `json:"Terminating,omitempty"` } // NewConsulGateway instantiates a new ConsulGateway object @@ -40,36 +40,46 @@ func NewConsulGatewayWithDefaults() *ConsulGateway { return &this } -// GetIngress returns the Ingress field value if set, zero value otherwise. +// GetIngress returns the Ingress field value if set, zero value otherwise (both if not set or set to explicit null). func (o *ConsulGateway) GetIngress() ConsulIngressConfigEntry { - if o == nil || o.Ingress == nil { + if o == nil || o.Ingress.Get() == nil { var ret ConsulIngressConfigEntry return ret } - return *o.Ingress + return *o.Ingress.Get() } // GetIngressOk returns a tuple with the Ingress field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *ConsulGateway) GetIngressOk() (*ConsulIngressConfigEntry, bool) { - if o == nil || o.Ingress == nil { + if o == nil { return nil, false } - return o.Ingress, true + return o.Ingress.Get(), o.Ingress.IsSet() } // HasIngress returns a boolean if a field has been set. func (o *ConsulGateway) HasIngress() bool { - if o != nil && o.Ingress != nil { + if o != nil && o.Ingress.IsSet() { return true } return false } -// SetIngress gets a reference to the given ConsulIngressConfigEntry and assigns it to the Ingress field. +// SetIngress gets a reference to the given NullableConsulIngressConfigEntry and assigns it to the Ingress field. func (o *ConsulGateway) SetIngress(v ConsulIngressConfigEntry) { - o.Ingress = &v + o.Ingress.Set(&v) +} +// SetIngressNil sets the value for Ingress to be an explicit nil +func (o *ConsulGateway) SetIngressNil() { + o.Ingress.Set(nil) +} + +// UnsetIngress ensures that no value is present for Ingress, not even an explicit nil +func (o *ConsulGateway) UnsetIngress() { + o.Ingress.Unset() } // GetMesh returns the Mesh field value if set, zero value otherwise (both if not set or set to explicit null). @@ -105,83 +115,103 @@ func (o *ConsulGateway) SetMesh(v interface{}) { o.Mesh = v } -// GetProxy returns the Proxy field value if set, zero value otherwise. +// GetProxy returns the Proxy field value if set, zero value otherwise (both if not set or set to explicit null). func (o *ConsulGateway) GetProxy() ConsulGatewayProxy { - if o == nil || o.Proxy == nil { + if o == nil || o.Proxy.Get() == nil { var ret ConsulGatewayProxy return ret } - return *o.Proxy + return *o.Proxy.Get() } // GetProxyOk returns a tuple with the Proxy field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *ConsulGateway) GetProxyOk() (*ConsulGatewayProxy, bool) { - if o == nil || o.Proxy == nil { + if o == nil { return nil, false } - return o.Proxy, true + return o.Proxy.Get(), o.Proxy.IsSet() } // HasProxy returns a boolean if a field has been set. func (o *ConsulGateway) HasProxy() bool { - if o != nil && o.Proxy != nil { + if o != nil && o.Proxy.IsSet() { return true } return false } -// SetProxy gets a reference to the given ConsulGatewayProxy and assigns it to the Proxy field. +// SetProxy gets a reference to the given NullableConsulGatewayProxy and assigns it to the Proxy field. func (o *ConsulGateway) SetProxy(v ConsulGatewayProxy) { - o.Proxy = &v + o.Proxy.Set(&v) +} +// SetProxyNil sets the value for Proxy to be an explicit nil +func (o *ConsulGateway) SetProxyNil() { + o.Proxy.Set(nil) +} + +// UnsetProxy ensures that no value is present for Proxy, not even an explicit nil +func (o *ConsulGateway) UnsetProxy() { + o.Proxy.Unset() } -// GetTerminating returns the Terminating field value if set, zero value otherwise. +// GetTerminating returns the Terminating field value if set, zero value otherwise (both if not set or set to explicit null). func (o *ConsulGateway) GetTerminating() ConsulTerminatingConfigEntry { - if o == nil || o.Terminating == nil { + if o == nil || o.Terminating.Get() == nil { var ret ConsulTerminatingConfigEntry return ret } - return *o.Terminating + return *o.Terminating.Get() } // GetTerminatingOk returns a tuple with the Terminating field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *ConsulGateway) GetTerminatingOk() (*ConsulTerminatingConfigEntry, bool) { - if o == nil || o.Terminating == nil { + if o == nil { return nil, false } - return o.Terminating, true + return o.Terminating.Get(), o.Terminating.IsSet() } // HasTerminating returns a boolean if a field has been set. func (o *ConsulGateway) HasTerminating() bool { - if o != nil && o.Terminating != nil { + if o != nil && o.Terminating.IsSet() { return true } return false } -// SetTerminating gets a reference to the given ConsulTerminatingConfigEntry and assigns it to the Terminating field. +// SetTerminating gets a reference to the given NullableConsulTerminatingConfigEntry and assigns it to the Terminating field. func (o *ConsulGateway) SetTerminating(v ConsulTerminatingConfigEntry) { - o.Terminating = &v + o.Terminating.Set(&v) +} +// SetTerminatingNil sets the value for Terminating to be an explicit nil +func (o *ConsulGateway) SetTerminatingNil() { + o.Terminating.Set(nil) +} + +// UnsetTerminating ensures that no value is present for Terminating, not even an explicit nil +func (o *ConsulGateway) UnsetTerminating() { + o.Terminating.Unset() } func (o ConsulGateway) MarshalJSON() ([]byte, error) { toSerialize := map[string]interface{}{} - if o.Ingress != nil { - toSerialize["Ingress"] = o.Ingress + if o.Ingress.IsSet() { + toSerialize["Ingress"] = o.Ingress.Get() } if o.Mesh != nil { toSerialize["Mesh"] = o.Mesh } - if o.Proxy != nil { - toSerialize["Proxy"] = o.Proxy + if o.Proxy.IsSet() { + toSerialize["Proxy"] = o.Proxy.Get() } - if o.Terminating != nil { - toSerialize["Terminating"] = o.Terminating + if o.Terminating.IsSet() { + toSerialize["Terminating"] = o.Terminating.Get() } return json.Marshal(toSerialize) } diff --git a/clients/go/v1/model_consul_gateway_bind_address.go b/clients/go/v1/model_consul_gateway_bind_address.go index 75cd1f22..a7e899de 100644 --- a/clients/go/v1/model_consul_gateway_bind_address.go +++ b/clients/go/v1/model_consul_gateway_bind_address.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_consul_gateway_proxy.go b/clients/go/v1/model_consul_gateway_proxy.go index 6b52f45c..ae482d44 100644 --- a/clients/go/v1/model_consul_gateway_proxy.go +++ b/clients/go/v1/model_consul_gateway_proxy.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,7 +17,7 @@ import ( // ConsulGatewayProxy struct for ConsulGatewayProxy type ConsulGatewayProxy struct { - Config *map[string]interface{} `json:"Config,omitempty"` + Config map[string]interface{} `json:"Config,omitempty"` ConnectTimeout *int64 `json:"ConnectTimeout,omitempty"` EnvoyDNSDiscoveryType *string `json:"EnvoyDNSDiscoveryType,omitempty"` EnvoyGatewayBindAddresses *map[string]ConsulGatewayBindAddress `json:"EnvoyGatewayBindAddresses,omitempty"` @@ -48,12 +48,12 @@ func (o *ConsulGatewayProxy) GetConfig() map[string]interface{} { var ret map[string]interface{} return ret } - return *o.Config + return o.Config } // GetConfigOk returns a tuple with the Config field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *ConsulGatewayProxy) GetConfigOk() (*map[string]interface{}, bool) { +func (o *ConsulGatewayProxy) GetConfigOk() (map[string]interface{}, bool) { if o == nil || o.Config == nil { return nil, false } @@ -71,7 +71,7 @@ func (o *ConsulGatewayProxy) HasConfig() bool { // SetConfig gets a reference to the given map[string]interface{} and assigns it to the Config field. func (o *ConsulGatewayProxy) SetConfig(v map[string]interface{}) { - o.Config = &v + o.Config = v } // GetConnectTimeout returns the ConnectTimeout field value if set, zero value otherwise. diff --git a/clients/go/v1/model_consul_gateway_tls_config.go b/clients/go/v1/model_consul_gateway_tls_config.go index 31c8e25b..f4e541da 100644 --- a/clients/go/v1/model_consul_gateway_tls_config.go +++ b/clients/go/v1/model_consul_gateway_tls_config.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,7 +17,7 @@ import ( // ConsulGatewayTLSConfig struct for ConsulGatewayTLSConfig type ConsulGatewayTLSConfig struct { - CipherSuites *[]string `json:"CipherSuites,omitempty"` + CipherSuites []string `json:"CipherSuites,omitempty"` Enabled *bool `json:"Enabled,omitempty"` TLSMaxVersion *string `json:"TLSMaxVersion,omitempty"` TLSMinVersion *string `json:"TLSMinVersion,omitempty"` @@ -46,12 +46,12 @@ func (o *ConsulGatewayTLSConfig) GetCipherSuites() []string { var ret []string return ret } - return *o.CipherSuites + return o.CipherSuites } // GetCipherSuitesOk returns a tuple with the CipherSuites field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *ConsulGatewayTLSConfig) GetCipherSuitesOk() (*[]string, bool) { +func (o *ConsulGatewayTLSConfig) GetCipherSuitesOk() ([]string, bool) { if o == nil || o.CipherSuites == nil { return nil, false } @@ -69,7 +69,7 @@ func (o *ConsulGatewayTLSConfig) HasCipherSuites() bool { // SetCipherSuites gets a reference to the given []string and assigns it to the CipherSuites field. func (o *ConsulGatewayTLSConfig) SetCipherSuites(v []string) { - o.CipherSuites = &v + o.CipherSuites = v } // GetEnabled returns the Enabled field value if set, zero value otherwise. diff --git a/clients/go/v1/model_consul_ingress_config_entry.go b/clients/go/v1/model_consul_ingress_config_entry.go index e3349857..13923236 100644 --- a/clients/go/v1/model_consul_ingress_config_entry.go +++ b/clients/go/v1/model_consul_ingress_config_entry.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,8 +17,8 @@ import ( // ConsulIngressConfigEntry struct for ConsulIngressConfigEntry type ConsulIngressConfigEntry struct { - Listeners *[]ConsulIngressListener `json:"Listeners,omitempty"` - TLS *ConsulGatewayTLSConfig `json:"TLS,omitempty"` + Listeners []ConsulIngressListener `json:"Listeners,omitempty"` + TLS NullableConsulGatewayTLSConfig `json:"TLS,omitempty"` } // NewConsulIngressConfigEntry instantiates a new ConsulIngressConfigEntry object @@ -44,12 +44,12 @@ func (o *ConsulIngressConfigEntry) GetListeners() []ConsulIngressListener { var ret []ConsulIngressListener return ret } - return *o.Listeners + return o.Listeners } // GetListenersOk returns a tuple with the Listeners field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *ConsulIngressConfigEntry) GetListenersOk() (*[]ConsulIngressListener, bool) { +func (o *ConsulIngressConfigEntry) GetListenersOk() ([]ConsulIngressListener, bool) { if o == nil || o.Listeners == nil { return nil, false } @@ -67,39 +67,49 @@ func (o *ConsulIngressConfigEntry) HasListeners() bool { // SetListeners gets a reference to the given []ConsulIngressListener and assigns it to the Listeners field. func (o *ConsulIngressConfigEntry) SetListeners(v []ConsulIngressListener) { - o.Listeners = &v + o.Listeners = v } -// GetTLS returns the TLS field value if set, zero value otherwise. +// GetTLS returns the TLS field value if set, zero value otherwise (both if not set or set to explicit null). func (o *ConsulIngressConfigEntry) GetTLS() ConsulGatewayTLSConfig { - if o == nil || o.TLS == nil { + if o == nil || o.TLS.Get() == nil { var ret ConsulGatewayTLSConfig return ret } - return *o.TLS + return *o.TLS.Get() } // GetTLSOk returns a tuple with the TLS field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *ConsulIngressConfigEntry) GetTLSOk() (*ConsulGatewayTLSConfig, bool) { - if o == nil || o.TLS == nil { + if o == nil { return nil, false } - return o.TLS, true + return o.TLS.Get(), o.TLS.IsSet() } // HasTLS returns a boolean if a field has been set. func (o *ConsulIngressConfigEntry) HasTLS() bool { - if o != nil && o.TLS != nil { + if o != nil && o.TLS.IsSet() { return true } return false } -// SetTLS gets a reference to the given ConsulGatewayTLSConfig and assigns it to the TLS field. +// SetTLS gets a reference to the given NullableConsulGatewayTLSConfig and assigns it to the TLS field. func (o *ConsulIngressConfigEntry) SetTLS(v ConsulGatewayTLSConfig) { - o.TLS = &v + o.TLS.Set(&v) +} +// SetTLSNil sets the value for TLS to be an explicit nil +func (o *ConsulIngressConfigEntry) SetTLSNil() { + o.TLS.Set(nil) +} + +// UnsetTLS ensures that no value is present for TLS, not even an explicit nil +func (o *ConsulIngressConfigEntry) UnsetTLS() { + o.TLS.Unset() } func (o ConsulIngressConfigEntry) MarshalJSON() ([]byte, error) { @@ -107,8 +117,8 @@ func (o ConsulIngressConfigEntry) MarshalJSON() ([]byte, error) { if o.Listeners != nil { toSerialize["Listeners"] = o.Listeners } - if o.TLS != nil { - toSerialize["TLS"] = o.TLS + if o.TLS.IsSet() { + toSerialize["TLS"] = o.TLS.Get() } return json.Marshal(toSerialize) } diff --git a/clients/go/v1/model_consul_ingress_listener.go b/clients/go/v1/model_consul_ingress_listener.go index 364a0c42..a1a6adff 100644 --- a/clients/go/v1/model_consul_ingress_listener.go +++ b/clients/go/v1/model_consul_ingress_listener.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -19,7 +19,7 @@ import ( type ConsulIngressListener struct { Port *int32 `json:"Port,omitempty"` Protocol *string `json:"Protocol,omitempty"` - Services *[]ConsulIngressService `json:"Services,omitempty"` + Services []ConsulIngressService `json:"Services,omitempty"` } // NewConsulIngressListener instantiates a new ConsulIngressListener object @@ -109,12 +109,12 @@ func (o *ConsulIngressListener) GetServices() []ConsulIngressService { var ret []ConsulIngressService return ret } - return *o.Services + return o.Services } // GetServicesOk returns a tuple with the Services field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *ConsulIngressListener) GetServicesOk() (*[]ConsulIngressService, bool) { +func (o *ConsulIngressListener) GetServicesOk() ([]ConsulIngressService, bool) { if o == nil || o.Services == nil { return nil, false } @@ -132,7 +132,7 @@ func (o *ConsulIngressListener) HasServices() bool { // SetServices gets a reference to the given []ConsulIngressService and assigns it to the Services field. func (o *ConsulIngressListener) SetServices(v []ConsulIngressService) { - o.Services = &v + o.Services = v } func (o ConsulIngressListener) MarshalJSON() ([]byte, error) { diff --git a/clients/go/v1/model_consul_ingress_service.go b/clients/go/v1/model_consul_ingress_service.go index 6638aa57..8cf7689b 100644 --- a/clients/go/v1/model_consul_ingress_service.go +++ b/clients/go/v1/model_consul_ingress_service.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,7 +17,7 @@ import ( // ConsulIngressService struct for ConsulIngressService type ConsulIngressService struct { - Hosts *[]string `json:"Hosts,omitempty"` + Hosts []string `json:"Hosts,omitempty"` Name *string `json:"Name,omitempty"` } @@ -44,12 +44,12 @@ func (o *ConsulIngressService) GetHosts() []string { var ret []string return ret } - return *o.Hosts + return o.Hosts } // GetHostsOk returns a tuple with the Hosts field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *ConsulIngressService) GetHostsOk() (*[]string, bool) { +func (o *ConsulIngressService) GetHostsOk() ([]string, bool) { if o == nil || o.Hosts == nil { return nil, false } @@ -67,7 +67,7 @@ func (o *ConsulIngressService) HasHosts() bool { // SetHosts gets a reference to the given []string and assigns it to the Hosts field. func (o *ConsulIngressService) SetHosts(v []string) { - o.Hosts = &v + o.Hosts = v } // GetName returns the Name field value if set, zero value otherwise. diff --git a/clients/go/v1/model_consul_linked_service.go b/clients/go/v1/model_consul_linked_service.go index 144bcac7..59b8a6c3 100644 --- a/clients/go/v1/model_consul_linked_service.go +++ b/clients/go/v1/model_consul_linked_service.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_consul_mesh_gateway.go b/clients/go/v1/model_consul_mesh_gateway.go index 4c8bc15f..8d63b20e 100644 --- a/clients/go/v1/model_consul_mesh_gateway.go +++ b/clients/go/v1/model_consul_mesh_gateway.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_consul_proxy.go b/clients/go/v1/model_consul_proxy.go index 31742cf7..3c9c94da 100644 --- a/clients/go/v1/model_consul_proxy.go +++ b/clients/go/v1/model_consul_proxy.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,11 +17,11 @@ import ( // ConsulProxy struct for ConsulProxy type ConsulProxy struct { - Config *map[string]interface{} `json:"Config,omitempty"` - ExposeConfig *ConsulExposeConfig `json:"ExposeConfig,omitempty"` + Config map[string]interface{} `json:"Config,omitempty"` + ExposeConfig NullableConsulExposeConfig `json:"ExposeConfig,omitempty"` LocalServiceAddress *string `json:"LocalServiceAddress,omitempty"` LocalServicePort *int32 `json:"LocalServicePort,omitempty"` - Upstreams *[]ConsulUpstream `json:"Upstreams,omitempty"` + Upstreams []ConsulUpstream `json:"Upstreams,omitempty"` } // NewConsulProxy instantiates a new ConsulProxy object @@ -47,12 +47,12 @@ func (o *ConsulProxy) GetConfig() map[string]interface{} { var ret map[string]interface{} return ret } - return *o.Config + return o.Config } // GetConfigOk returns a tuple with the Config field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *ConsulProxy) GetConfigOk() (*map[string]interface{}, bool) { +func (o *ConsulProxy) GetConfigOk() (map[string]interface{}, bool) { if o == nil || o.Config == nil { return nil, false } @@ -70,39 +70,49 @@ func (o *ConsulProxy) HasConfig() bool { // SetConfig gets a reference to the given map[string]interface{} and assigns it to the Config field. func (o *ConsulProxy) SetConfig(v map[string]interface{}) { - o.Config = &v + o.Config = v } -// GetExposeConfig returns the ExposeConfig field value if set, zero value otherwise. +// GetExposeConfig returns the ExposeConfig field value if set, zero value otherwise (both if not set or set to explicit null). func (o *ConsulProxy) GetExposeConfig() ConsulExposeConfig { - if o == nil || o.ExposeConfig == nil { + if o == nil || o.ExposeConfig.Get() == nil { var ret ConsulExposeConfig return ret } - return *o.ExposeConfig + return *o.ExposeConfig.Get() } // GetExposeConfigOk returns a tuple with the ExposeConfig field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *ConsulProxy) GetExposeConfigOk() (*ConsulExposeConfig, bool) { - if o == nil || o.ExposeConfig == nil { + if o == nil { return nil, false } - return o.ExposeConfig, true + return o.ExposeConfig.Get(), o.ExposeConfig.IsSet() } // HasExposeConfig returns a boolean if a field has been set. func (o *ConsulProxy) HasExposeConfig() bool { - if o != nil && o.ExposeConfig != nil { + if o != nil && o.ExposeConfig.IsSet() { return true } return false } -// SetExposeConfig gets a reference to the given ConsulExposeConfig and assigns it to the ExposeConfig field. +// SetExposeConfig gets a reference to the given NullableConsulExposeConfig and assigns it to the ExposeConfig field. func (o *ConsulProxy) SetExposeConfig(v ConsulExposeConfig) { - o.ExposeConfig = &v + o.ExposeConfig.Set(&v) +} +// SetExposeConfigNil sets the value for ExposeConfig to be an explicit nil +func (o *ConsulProxy) SetExposeConfigNil() { + o.ExposeConfig.Set(nil) +} + +// UnsetExposeConfig ensures that no value is present for ExposeConfig, not even an explicit nil +func (o *ConsulProxy) UnsetExposeConfig() { + o.ExposeConfig.Unset() } // GetLocalServiceAddress returns the LocalServiceAddress field value if set, zero value otherwise. @@ -175,12 +185,12 @@ func (o *ConsulProxy) GetUpstreams() []ConsulUpstream { var ret []ConsulUpstream return ret } - return *o.Upstreams + return o.Upstreams } // GetUpstreamsOk returns a tuple with the Upstreams field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *ConsulProxy) GetUpstreamsOk() (*[]ConsulUpstream, bool) { +func (o *ConsulProxy) GetUpstreamsOk() ([]ConsulUpstream, bool) { if o == nil || o.Upstreams == nil { return nil, false } @@ -198,7 +208,7 @@ func (o *ConsulProxy) HasUpstreams() bool { // SetUpstreams gets a reference to the given []ConsulUpstream and assigns it to the Upstreams field. func (o *ConsulProxy) SetUpstreams(v []ConsulUpstream) { - o.Upstreams = &v + o.Upstreams = v } func (o ConsulProxy) MarshalJSON() ([]byte, error) { @@ -206,8 +216,8 @@ func (o ConsulProxy) MarshalJSON() ([]byte, error) { if o.Config != nil { toSerialize["Config"] = o.Config } - if o.ExposeConfig != nil { - toSerialize["ExposeConfig"] = o.ExposeConfig + if o.ExposeConfig.IsSet() { + toSerialize["ExposeConfig"] = o.ExposeConfig.Get() } if o.LocalServiceAddress != nil { toSerialize["LocalServiceAddress"] = o.LocalServiceAddress diff --git a/clients/go/v1/model_consul_sidecar_service.go b/clients/go/v1/model_consul_sidecar_service.go index aed46f56..cc5c2727 100644 --- a/clients/go/v1/model_consul_sidecar_service.go +++ b/clients/go/v1/model_consul_sidecar_service.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -19,8 +19,8 @@ import ( type ConsulSidecarService struct { DisableDefaultTCPCheck *bool `json:"DisableDefaultTCPCheck,omitempty"` Port *string `json:"Port,omitempty"` - Proxy *ConsulProxy `json:"Proxy,omitempty"` - Tags *[]string `json:"Tags,omitempty"` + Proxy NullableConsulProxy `json:"Proxy,omitempty"` + Tags []string `json:"Tags,omitempty"` } // NewConsulSidecarService instantiates a new ConsulSidecarService object @@ -104,36 +104,46 @@ func (o *ConsulSidecarService) SetPort(v string) { o.Port = &v } -// GetProxy returns the Proxy field value if set, zero value otherwise. +// GetProxy returns the Proxy field value if set, zero value otherwise (both if not set or set to explicit null). func (o *ConsulSidecarService) GetProxy() ConsulProxy { - if o == nil || o.Proxy == nil { + if o == nil || o.Proxy.Get() == nil { var ret ConsulProxy return ret } - return *o.Proxy + return *o.Proxy.Get() } // GetProxyOk returns a tuple with the Proxy field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *ConsulSidecarService) GetProxyOk() (*ConsulProxy, bool) { - if o == nil || o.Proxy == nil { + if o == nil { return nil, false } - return o.Proxy, true + return o.Proxy.Get(), o.Proxy.IsSet() } // HasProxy returns a boolean if a field has been set. func (o *ConsulSidecarService) HasProxy() bool { - if o != nil && o.Proxy != nil { + if o != nil && o.Proxy.IsSet() { return true } return false } -// SetProxy gets a reference to the given ConsulProxy and assigns it to the Proxy field. +// SetProxy gets a reference to the given NullableConsulProxy and assigns it to the Proxy field. func (o *ConsulSidecarService) SetProxy(v ConsulProxy) { - o.Proxy = &v + o.Proxy.Set(&v) +} +// SetProxyNil sets the value for Proxy to be an explicit nil +func (o *ConsulSidecarService) SetProxyNil() { + o.Proxy.Set(nil) +} + +// UnsetProxy ensures that no value is present for Proxy, not even an explicit nil +func (o *ConsulSidecarService) UnsetProxy() { + o.Proxy.Unset() } // GetTags returns the Tags field value if set, zero value otherwise. @@ -142,12 +152,12 @@ func (o *ConsulSidecarService) GetTags() []string { var ret []string return ret } - return *o.Tags + return o.Tags } // GetTagsOk returns a tuple with the Tags field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *ConsulSidecarService) GetTagsOk() (*[]string, bool) { +func (o *ConsulSidecarService) GetTagsOk() ([]string, bool) { if o == nil || o.Tags == nil { return nil, false } @@ -165,7 +175,7 @@ func (o *ConsulSidecarService) HasTags() bool { // SetTags gets a reference to the given []string and assigns it to the Tags field. func (o *ConsulSidecarService) SetTags(v []string) { - o.Tags = &v + o.Tags = v } func (o ConsulSidecarService) MarshalJSON() ([]byte, error) { @@ -176,8 +186,8 @@ func (o ConsulSidecarService) MarshalJSON() ([]byte, error) { if o.Port != nil { toSerialize["Port"] = o.Port } - if o.Proxy != nil { - toSerialize["Proxy"] = o.Proxy + if o.Proxy.IsSet() { + toSerialize["Proxy"] = o.Proxy.Get() } if o.Tags != nil { toSerialize["Tags"] = o.Tags diff --git a/clients/go/v1/model_consul_terminating_config_entry.go b/clients/go/v1/model_consul_terminating_config_entry.go index c804afd3..a6e5ea99 100644 --- a/clients/go/v1/model_consul_terminating_config_entry.go +++ b/clients/go/v1/model_consul_terminating_config_entry.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,7 +17,7 @@ import ( // ConsulTerminatingConfigEntry struct for ConsulTerminatingConfigEntry type ConsulTerminatingConfigEntry struct { - Services *[]ConsulLinkedService `json:"Services,omitempty"` + Services []ConsulLinkedService `json:"Services,omitempty"` } // NewConsulTerminatingConfigEntry instantiates a new ConsulTerminatingConfigEntry object @@ -43,12 +43,12 @@ func (o *ConsulTerminatingConfigEntry) GetServices() []ConsulLinkedService { var ret []ConsulLinkedService return ret } - return *o.Services + return o.Services } // GetServicesOk returns a tuple with the Services field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *ConsulTerminatingConfigEntry) GetServicesOk() (*[]ConsulLinkedService, bool) { +func (o *ConsulTerminatingConfigEntry) GetServicesOk() ([]ConsulLinkedService, bool) { if o == nil || o.Services == nil { return nil, false } @@ -66,7 +66,7 @@ func (o *ConsulTerminatingConfigEntry) HasServices() bool { // SetServices gets a reference to the given []ConsulLinkedService and assigns it to the Services field. func (o *ConsulTerminatingConfigEntry) SetServices(v []ConsulLinkedService) { - o.Services = &v + o.Services = v } func (o ConsulTerminatingConfigEntry) MarshalJSON() ([]byte, error) { diff --git a/clients/go/v1/model_consul_upstream.go b/clients/go/v1/model_consul_upstream.go index 344e3224..ac7ec43d 100644 --- a/clients/go/v1/model_consul_upstream.go +++ b/clients/go/v1/model_consul_upstream.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -22,7 +22,7 @@ type ConsulUpstream struct { DestinationNamespace *string `json:"DestinationNamespace,omitempty"` LocalBindAddress *string `json:"LocalBindAddress,omitempty"` LocalBindPort *int32 `json:"LocalBindPort,omitempty"` - MeshGateway *ConsulMeshGateway `json:"MeshGateway,omitempty"` + MeshGateway NullableConsulMeshGateway `json:"MeshGateway,omitempty"` } // NewConsulUpstream instantiates a new ConsulUpstream object @@ -202,36 +202,46 @@ func (o *ConsulUpstream) SetLocalBindPort(v int32) { o.LocalBindPort = &v } -// GetMeshGateway returns the MeshGateway field value if set, zero value otherwise. +// GetMeshGateway returns the MeshGateway field value if set, zero value otherwise (both if not set or set to explicit null). func (o *ConsulUpstream) GetMeshGateway() ConsulMeshGateway { - if o == nil || o.MeshGateway == nil { + if o == nil || o.MeshGateway.Get() == nil { var ret ConsulMeshGateway return ret } - return *o.MeshGateway + return *o.MeshGateway.Get() } // GetMeshGatewayOk returns a tuple with the MeshGateway field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *ConsulUpstream) GetMeshGatewayOk() (*ConsulMeshGateway, bool) { - if o == nil || o.MeshGateway == nil { + if o == nil { return nil, false } - return o.MeshGateway, true + return o.MeshGateway.Get(), o.MeshGateway.IsSet() } // HasMeshGateway returns a boolean if a field has been set. func (o *ConsulUpstream) HasMeshGateway() bool { - if o != nil && o.MeshGateway != nil { + if o != nil && o.MeshGateway.IsSet() { return true } return false } -// SetMeshGateway gets a reference to the given ConsulMeshGateway and assigns it to the MeshGateway field. +// SetMeshGateway gets a reference to the given NullableConsulMeshGateway and assigns it to the MeshGateway field. func (o *ConsulUpstream) SetMeshGateway(v ConsulMeshGateway) { - o.MeshGateway = &v + o.MeshGateway.Set(&v) +} +// SetMeshGatewayNil sets the value for MeshGateway to be an explicit nil +func (o *ConsulUpstream) SetMeshGatewayNil() { + o.MeshGateway.Set(nil) +} + +// UnsetMeshGateway ensures that no value is present for MeshGateway, not even an explicit nil +func (o *ConsulUpstream) UnsetMeshGateway() { + o.MeshGateway.Unset() } func (o ConsulUpstream) MarshalJSON() ([]byte, error) { @@ -251,8 +261,8 @@ func (o ConsulUpstream) MarshalJSON() ([]byte, error) { if o.LocalBindPort != nil { toSerialize["LocalBindPort"] = o.LocalBindPort } - if o.MeshGateway != nil { - toSerialize["MeshGateway"] = o.MeshGateway + if o.MeshGateway.IsSet() { + toSerialize["MeshGateway"] = o.MeshGateway.Get() } return json.Marshal(toSerialize) } diff --git a/clients/go/v1/model_csi_controller_info.go b/clients/go/v1/model_csi_controller_info.go index a44dc9b0..6dd3238c 100644 --- a/clients/go/v1/model_csi_controller_info.go +++ b/clients/go/v1/model_csi_controller_info.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_csi_info.go b/clients/go/v1/model_csi_info.go index 6847c9f9..76a4d93b 100644 --- a/clients/go/v1/model_csi_info.go +++ b/clients/go/v1/model_csi_info.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -19,14 +19,14 @@ import ( // CSIInfo struct for CSIInfo type CSIInfo struct { AllocID *string `json:"AllocID,omitempty"` - ControllerInfo *CSIControllerInfo `json:"ControllerInfo,omitempty"` + ControllerInfo NullableCSIControllerInfo `json:"ControllerInfo,omitempty"` HealthDescription *string `json:"HealthDescription,omitempty"` Healthy *bool `json:"Healthy,omitempty"` - NodeInfo *CSINodeInfo `json:"NodeInfo,omitempty"` + NodeInfo NullableCSINodeInfo `json:"NodeInfo,omitempty"` PluginID *string `json:"PluginID,omitempty"` RequiresControllerPlugin *bool `json:"RequiresControllerPlugin,omitempty"` RequiresTopologies *bool `json:"RequiresTopologies,omitempty"` - UpdateTime *time.Time `json:"UpdateTime,omitempty"` + UpdateTime NullableTime `json:"UpdateTime,omitempty"` } // NewCSIInfo instantiates a new CSIInfo object @@ -78,36 +78,46 @@ func (o *CSIInfo) SetAllocID(v string) { o.AllocID = &v } -// GetControllerInfo returns the ControllerInfo field value if set, zero value otherwise. +// GetControllerInfo returns the ControllerInfo field value if set, zero value otherwise (both if not set or set to explicit null). func (o *CSIInfo) GetControllerInfo() CSIControllerInfo { - if o == nil || o.ControllerInfo == nil { + if o == nil || o.ControllerInfo.Get() == nil { var ret CSIControllerInfo return ret } - return *o.ControllerInfo + return *o.ControllerInfo.Get() } // GetControllerInfoOk returns a tuple with the ControllerInfo field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *CSIInfo) GetControllerInfoOk() (*CSIControllerInfo, bool) { - if o == nil || o.ControllerInfo == nil { + if o == nil { return nil, false } - return o.ControllerInfo, true + return o.ControllerInfo.Get(), o.ControllerInfo.IsSet() } // HasControllerInfo returns a boolean if a field has been set. func (o *CSIInfo) HasControllerInfo() bool { - if o != nil && o.ControllerInfo != nil { + if o != nil && o.ControllerInfo.IsSet() { return true } return false } -// SetControllerInfo gets a reference to the given CSIControllerInfo and assigns it to the ControllerInfo field. +// SetControllerInfo gets a reference to the given NullableCSIControllerInfo and assigns it to the ControllerInfo field. func (o *CSIInfo) SetControllerInfo(v CSIControllerInfo) { - o.ControllerInfo = &v + o.ControllerInfo.Set(&v) +} +// SetControllerInfoNil sets the value for ControllerInfo to be an explicit nil +func (o *CSIInfo) SetControllerInfoNil() { + o.ControllerInfo.Set(nil) +} + +// UnsetControllerInfo ensures that no value is present for ControllerInfo, not even an explicit nil +func (o *CSIInfo) UnsetControllerInfo() { + o.ControllerInfo.Unset() } // GetHealthDescription returns the HealthDescription field value if set, zero value otherwise. @@ -174,36 +184,46 @@ func (o *CSIInfo) SetHealthy(v bool) { o.Healthy = &v } -// GetNodeInfo returns the NodeInfo field value if set, zero value otherwise. +// GetNodeInfo returns the NodeInfo field value if set, zero value otherwise (both if not set or set to explicit null). func (o *CSIInfo) GetNodeInfo() CSINodeInfo { - if o == nil || o.NodeInfo == nil { + if o == nil || o.NodeInfo.Get() == nil { var ret CSINodeInfo return ret } - return *o.NodeInfo + return *o.NodeInfo.Get() } // GetNodeInfoOk returns a tuple with the NodeInfo field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *CSIInfo) GetNodeInfoOk() (*CSINodeInfo, bool) { - if o == nil || o.NodeInfo == nil { + if o == nil { return nil, false } - return o.NodeInfo, true + return o.NodeInfo.Get(), o.NodeInfo.IsSet() } // HasNodeInfo returns a boolean if a field has been set. func (o *CSIInfo) HasNodeInfo() bool { - if o != nil && o.NodeInfo != nil { + if o != nil && o.NodeInfo.IsSet() { return true } return false } -// SetNodeInfo gets a reference to the given CSINodeInfo and assigns it to the NodeInfo field. +// SetNodeInfo gets a reference to the given NullableCSINodeInfo and assigns it to the NodeInfo field. func (o *CSIInfo) SetNodeInfo(v CSINodeInfo) { - o.NodeInfo = &v + o.NodeInfo.Set(&v) +} +// SetNodeInfoNil sets the value for NodeInfo to be an explicit nil +func (o *CSIInfo) SetNodeInfoNil() { + o.NodeInfo.Set(nil) +} + +// UnsetNodeInfo ensures that no value is present for NodeInfo, not even an explicit nil +func (o *CSIInfo) UnsetNodeInfo() { + o.NodeInfo.Unset() } // GetPluginID returns the PluginID field value if set, zero value otherwise. @@ -302,36 +322,46 @@ func (o *CSIInfo) SetRequiresTopologies(v bool) { o.RequiresTopologies = &v } -// GetUpdateTime returns the UpdateTime field value if set, zero value otherwise. +// GetUpdateTime returns the UpdateTime field value if set, zero value otherwise (both if not set or set to explicit null). func (o *CSIInfo) GetUpdateTime() time.Time { - if o == nil || o.UpdateTime == nil { + if o == nil || o.UpdateTime.Get() == nil { var ret time.Time return ret } - return *o.UpdateTime + return *o.UpdateTime.Get() } // GetUpdateTimeOk returns a tuple with the UpdateTime field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *CSIInfo) GetUpdateTimeOk() (*time.Time, bool) { - if o == nil || o.UpdateTime == nil { + if o == nil { return nil, false } - return o.UpdateTime, true + return o.UpdateTime.Get(), o.UpdateTime.IsSet() } // HasUpdateTime returns a boolean if a field has been set. func (o *CSIInfo) HasUpdateTime() bool { - if o != nil && o.UpdateTime != nil { + if o != nil && o.UpdateTime.IsSet() { return true } return false } -// SetUpdateTime gets a reference to the given time.Time and assigns it to the UpdateTime field. +// SetUpdateTime gets a reference to the given NullableTime and assigns it to the UpdateTime field. func (o *CSIInfo) SetUpdateTime(v time.Time) { - o.UpdateTime = &v + o.UpdateTime.Set(&v) +} +// SetUpdateTimeNil sets the value for UpdateTime to be an explicit nil +func (o *CSIInfo) SetUpdateTimeNil() { + o.UpdateTime.Set(nil) +} + +// UnsetUpdateTime ensures that no value is present for UpdateTime, not even an explicit nil +func (o *CSIInfo) UnsetUpdateTime() { + o.UpdateTime.Unset() } func (o CSIInfo) MarshalJSON() ([]byte, error) { @@ -339,8 +369,8 @@ func (o CSIInfo) MarshalJSON() ([]byte, error) { if o.AllocID != nil { toSerialize["AllocID"] = o.AllocID } - if o.ControllerInfo != nil { - toSerialize["ControllerInfo"] = o.ControllerInfo + if o.ControllerInfo.IsSet() { + toSerialize["ControllerInfo"] = o.ControllerInfo.Get() } if o.HealthDescription != nil { toSerialize["HealthDescription"] = o.HealthDescription @@ -348,8 +378,8 @@ func (o CSIInfo) MarshalJSON() ([]byte, error) { if o.Healthy != nil { toSerialize["Healthy"] = o.Healthy } - if o.NodeInfo != nil { - toSerialize["NodeInfo"] = o.NodeInfo + if o.NodeInfo.IsSet() { + toSerialize["NodeInfo"] = o.NodeInfo.Get() } if o.PluginID != nil { toSerialize["PluginID"] = o.PluginID @@ -360,8 +390,8 @@ func (o CSIInfo) MarshalJSON() ([]byte, error) { if o.RequiresTopologies != nil { toSerialize["RequiresTopologies"] = o.RequiresTopologies } - if o.UpdateTime != nil { - toSerialize["UpdateTime"] = o.UpdateTime + if o.UpdateTime.IsSet() { + toSerialize["UpdateTime"] = o.UpdateTime.Get() } return json.Marshal(toSerialize) } diff --git a/clients/go/v1/model_csi_mount_options.go b/clients/go/v1/model_csi_mount_options.go index cae6aa7d..603dd465 100644 --- a/clients/go/v1/model_csi_mount_options.go +++ b/clients/go/v1/model_csi_mount_options.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -18,7 +18,7 @@ import ( // CSIMountOptions struct for CSIMountOptions type CSIMountOptions struct { FSType *string `json:"FSType,omitempty"` - MountFlags *[]string `json:"MountFlags,omitempty"` + MountFlags []string `json:"MountFlags,omitempty"` } // NewCSIMountOptions instantiates a new CSIMountOptions object @@ -76,12 +76,12 @@ func (o *CSIMountOptions) GetMountFlags() []string { var ret []string return ret } - return *o.MountFlags + return o.MountFlags } // GetMountFlagsOk returns a tuple with the MountFlags field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *CSIMountOptions) GetMountFlagsOk() (*[]string, bool) { +func (o *CSIMountOptions) GetMountFlagsOk() ([]string, bool) { if o == nil || o.MountFlags == nil { return nil, false } @@ -99,7 +99,7 @@ func (o *CSIMountOptions) HasMountFlags() bool { // SetMountFlags gets a reference to the given []string and assigns it to the MountFlags field. func (o *CSIMountOptions) SetMountFlags(v []string) { - o.MountFlags = &v + o.MountFlags = v } func (o CSIMountOptions) MarshalJSON() ([]byte, error) { diff --git a/clients/go/v1/model_csi_node_info.go b/clients/go/v1/model_csi_node_info.go index 37ae31d9..7097113e 100644 --- a/clients/go/v1/model_csi_node_info.go +++ b/clients/go/v1/model_csi_node_info.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,7 +17,7 @@ import ( // CSINodeInfo struct for CSINodeInfo type CSINodeInfo struct { - AccessibleTopology *CSITopology `json:"AccessibleTopology,omitempty"` + AccessibleTopology NullableCSITopology `json:"AccessibleTopology,omitempty"` ID *string `json:"ID,omitempty"` MaxVolumes *int64 `json:"MaxVolumes,omitempty"` RequiresNodeStageVolume *bool `json:"RequiresNodeStageVolume,omitempty"` @@ -43,36 +43,46 @@ func NewCSINodeInfoWithDefaults() *CSINodeInfo { return &this } -// GetAccessibleTopology returns the AccessibleTopology field value if set, zero value otherwise. +// GetAccessibleTopology returns the AccessibleTopology field value if set, zero value otherwise (both if not set or set to explicit null). func (o *CSINodeInfo) GetAccessibleTopology() CSITopology { - if o == nil || o.AccessibleTopology == nil { + if o == nil || o.AccessibleTopology.Get() == nil { var ret CSITopology return ret } - return *o.AccessibleTopology + return *o.AccessibleTopology.Get() } // GetAccessibleTopologyOk returns a tuple with the AccessibleTopology field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *CSINodeInfo) GetAccessibleTopologyOk() (*CSITopology, bool) { - if o == nil || o.AccessibleTopology == nil { + if o == nil { return nil, false } - return o.AccessibleTopology, true + return o.AccessibleTopology.Get(), o.AccessibleTopology.IsSet() } // HasAccessibleTopology returns a boolean if a field has been set. func (o *CSINodeInfo) HasAccessibleTopology() bool { - if o != nil && o.AccessibleTopology != nil { + if o != nil && o.AccessibleTopology.IsSet() { return true } return false } -// SetAccessibleTopology gets a reference to the given CSITopology and assigns it to the AccessibleTopology field. +// SetAccessibleTopology gets a reference to the given NullableCSITopology and assigns it to the AccessibleTopology field. func (o *CSINodeInfo) SetAccessibleTopology(v CSITopology) { - o.AccessibleTopology = &v + o.AccessibleTopology.Set(&v) +} +// SetAccessibleTopologyNil sets the value for AccessibleTopology to be an explicit nil +func (o *CSINodeInfo) SetAccessibleTopologyNil() { + o.AccessibleTopology.Set(nil) +} + +// UnsetAccessibleTopology ensures that no value is present for AccessibleTopology, not even an explicit nil +func (o *CSINodeInfo) UnsetAccessibleTopology() { + o.AccessibleTopology.Unset() } // GetID returns the ID field value if set, zero value otherwise. @@ -269,8 +279,8 @@ func (o *CSINodeInfo) SetSupportsStats(v bool) { func (o CSINodeInfo) MarshalJSON() ([]byte, error) { toSerialize := map[string]interface{}{} - if o.AccessibleTopology != nil { - toSerialize["AccessibleTopology"] = o.AccessibleTopology + if o.AccessibleTopology.IsSet() { + toSerialize["AccessibleTopology"] = o.AccessibleTopology.Get() } if o.ID != nil { toSerialize["ID"] = o.ID diff --git a/clients/go/v1/model_csi_plugin.go b/clients/go/v1/model_csi_plugin.go index 2561a544..d976678a 100644 --- a/clients/go/v1/model_csi_plugin.go +++ b/clients/go/v1/model_csi_plugin.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,7 +17,7 @@ import ( // CSIPlugin struct for CSIPlugin type CSIPlugin struct { - Allocations *[]AllocationListStub `json:"Allocations,omitempty"` + Allocations []AllocationListStub `json:"Allocations,omitempty"` ControllerRequired *bool `json:"ControllerRequired,omitempty"` Controllers *map[string]CSIInfo `json:"Controllers,omitempty"` ControllersExpected *int32 `json:"ControllersExpected,omitempty"` @@ -55,12 +55,12 @@ func (o *CSIPlugin) GetAllocations() []AllocationListStub { var ret []AllocationListStub return ret } - return *o.Allocations + return o.Allocations } // GetAllocationsOk returns a tuple with the Allocations field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *CSIPlugin) GetAllocationsOk() (*[]AllocationListStub, bool) { +func (o *CSIPlugin) GetAllocationsOk() ([]AllocationListStub, bool) { if o == nil || o.Allocations == nil { return nil, false } @@ -78,7 +78,7 @@ func (o *CSIPlugin) HasAllocations() bool { // SetAllocations gets a reference to the given []AllocationListStub and assigns it to the Allocations field. func (o *CSIPlugin) SetAllocations(v []AllocationListStub) { - o.Allocations = &v + o.Allocations = v } // GetControllerRequired returns the ControllerRequired field value if set, zero value otherwise. diff --git a/clients/go/v1/model_csi_plugin_list_stub.go b/clients/go/v1/model_csi_plugin_list_stub.go index 92a47ae6..2c34f252 100644 --- a/clients/go/v1/model_csi_plugin_list_stub.go +++ b/clients/go/v1/model_csi_plugin_list_stub.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_csi_snapshot.go b/clients/go/v1/model_csi_snapshot.go index 3323a7e9..18900b35 100644 --- a/clients/go/v1/model_csi_snapshot.go +++ b/clients/go/v1/model_csi_snapshot.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_csi_snapshot_create_request.go b/clients/go/v1/model_csi_snapshot_create_request.go index f043d6ad..191eecc0 100644 --- a/clients/go/v1/model_csi_snapshot_create_request.go +++ b/clients/go/v1/model_csi_snapshot_create_request.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -20,7 +20,7 @@ type CSISnapshotCreateRequest struct { Namespace *string `json:"Namespace,omitempty"` Region *string `json:"Region,omitempty"` SecretID *string `json:"SecretID,omitempty"` - Snapshots *[]CSISnapshot `json:"Snapshots,omitempty"` + Snapshots []CSISnapshot `json:"Snapshots,omitempty"` } // NewCSISnapshotCreateRequest instantiates a new CSISnapshotCreateRequest object @@ -142,12 +142,12 @@ func (o *CSISnapshotCreateRequest) GetSnapshots() []CSISnapshot { var ret []CSISnapshot return ret } - return *o.Snapshots + return o.Snapshots } // GetSnapshotsOk returns a tuple with the Snapshots field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *CSISnapshotCreateRequest) GetSnapshotsOk() (*[]CSISnapshot, bool) { +func (o *CSISnapshotCreateRequest) GetSnapshotsOk() ([]CSISnapshot, bool) { if o == nil || o.Snapshots == nil { return nil, false } @@ -165,7 +165,7 @@ func (o *CSISnapshotCreateRequest) HasSnapshots() bool { // SetSnapshots gets a reference to the given []CSISnapshot and assigns it to the Snapshots field. func (o *CSISnapshotCreateRequest) SetSnapshots(v []CSISnapshot) { - o.Snapshots = &v + o.Snapshots = v } func (o CSISnapshotCreateRequest) MarshalJSON() ([]byte, error) { diff --git a/clients/go/v1/model_csi_snapshot_create_response.go b/clients/go/v1/model_csi_snapshot_create_response.go index 07181b52..4d5bfb97 100644 --- a/clients/go/v1/model_csi_snapshot_create_response.go +++ b/clients/go/v1/model_csi_snapshot_create_response.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -22,7 +22,7 @@ type CSISnapshotCreateResponse struct { LastIndex *int32 `json:"LastIndex,omitempty"` NextToken *string `json:"NextToken,omitempty"` RequestTime *int64 `json:"RequestTime,omitempty"` - Snapshots *[]CSISnapshot `json:"Snapshots,omitempty"` + Snapshots []CSISnapshot `json:"Snapshots,omitempty"` } // NewCSISnapshotCreateResponse instantiates a new CSISnapshotCreateResponse object @@ -208,12 +208,12 @@ func (o *CSISnapshotCreateResponse) GetSnapshots() []CSISnapshot { var ret []CSISnapshot return ret } - return *o.Snapshots + return o.Snapshots } // GetSnapshotsOk returns a tuple with the Snapshots field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *CSISnapshotCreateResponse) GetSnapshotsOk() (*[]CSISnapshot, bool) { +func (o *CSISnapshotCreateResponse) GetSnapshotsOk() ([]CSISnapshot, bool) { if o == nil || o.Snapshots == nil { return nil, false } @@ -231,7 +231,7 @@ func (o *CSISnapshotCreateResponse) HasSnapshots() bool { // SetSnapshots gets a reference to the given []CSISnapshot and assigns it to the Snapshots field. func (o *CSISnapshotCreateResponse) SetSnapshots(v []CSISnapshot) { - o.Snapshots = &v + o.Snapshots = v } func (o CSISnapshotCreateResponse) MarshalJSON() ([]byte, error) { diff --git a/clients/go/v1/model_csi_snapshot_list_response.go b/clients/go/v1/model_csi_snapshot_list_response.go index 40db53f0..0b4e5576 100644 --- a/clients/go/v1/model_csi_snapshot_list_response.go +++ b/clients/go/v1/model_csi_snapshot_list_response.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -22,7 +22,7 @@ type CSISnapshotListResponse struct { LastIndex *int32 `json:"LastIndex,omitempty"` NextToken *string `json:"NextToken,omitempty"` RequestTime *int64 `json:"RequestTime,omitempty"` - Snapshots *[]CSISnapshot `json:"Snapshots,omitempty"` + Snapshots []CSISnapshot `json:"Snapshots,omitempty"` } // NewCSISnapshotListResponse instantiates a new CSISnapshotListResponse object @@ -208,12 +208,12 @@ func (o *CSISnapshotListResponse) GetSnapshots() []CSISnapshot { var ret []CSISnapshot return ret } - return *o.Snapshots + return o.Snapshots } // GetSnapshotsOk returns a tuple with the Snapshots field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *CSISnapshotListResponse) GetSnapshotsOk() (*[]CSISnapshot, bool) { +func (o *CSISnapshotListResponse) GetSnapshotsOk() ([]CSISnapshot, bool) { if o == nil || o.Snapshots == nil { return nil, false } @@ -231,7 +231,7 @@ func (o *CSISnapshotListResponse) HasSnapshots() bool { // SetSnapshots gets a reference to the given []CSISnapshot and assigns it to the Snapshots field. func (o *CSISnapshotListResponse) SetSnapshots(v []CSISnapshot) { - o.Snapshots = &v + o.Snapshots = v } func (o CSISnapshotListResponse) MarshalJSON() ([]byte, error) { diff --git a/clients/go/v1/model_csi_topology.go b/clients/go/v1/model_csi_topology.go index 4f9c594c..4d486671 100644 --- a/clients/go/v1/model_csi_topology.go +++ b/clients/go/v1/model_csi_topology.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_csi_topology_request.go b/clients/go/v1/model_csi_topology_request.go index 22ad58e8..1ff5712b 100644 --- a/clients/go/v1/model_csi_topology_request.go +++ b/clients/go/v1/model_csi_topology_request.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,8 +17,8 @@ import ( // CSITopologyRequest struct for CSITopologyRequest type CSITopologyRequest struct { - Preferred *[]CSITopology `json:"Preferred,omitempty"` - Required *[]CSITopology `json:"Required,omitempty"` + Preferred []CSITopology `json:"Preferred,omitempty"` + Required []CSITopology `json:"Required,omitempty"` } // NewCSITopologyRequest instantiates a new CSITopologyRequest object @@ -44,12 +44,12 @@ func (o *CSITopologyRequest) GetPreferred() []CSITopology { var ret []CSITopology return ret } - return *o.Preferred + return o.Preferred } // GetPreferredOk returns a tuple with the Preferred field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *CSITopologyRequest) GetPreferredOk() (*[]CSITopology, bool) { +func (o *CSITopologyRequest) GetPreferredOk() ([]CSITopology, bool) { if o == nil || o.Preferred == nil { return nil, false } @@ -67,7 +67,7 @@ func (o *CSITopologyRequest) HasPreferred() bool { // SetPreferred gets a reference to the given []CSITopology and assigns it to the Preferred field. func (o *CSITopologyRequest) SetPreferred(v []CSITopology) { - o.Preferred = &v + o.Preferred = v } // GetRequired returns the Required field value if set, zero value otherwise. @@ -76,12 +76,12 @@ func (o *CSITopologyRequest) GetRequired() []CSITopology { var ret []CSITopology return ret } - return *o.Required + return o.Required } // GetRequiredOk returns a tuple with the Required field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *CSITopologyRequest) GetRequiredOk() (*[]CSITopology, bool) { +func (o *CSITopologyRequest) GetRequiredOk() ([]CSITopology, bool) { if o == nil || o.Required == nil { return nil, false } @@ -99,7 +99,7 @@ func (o *CSITopologyRequest) HasRequired() bool { // SetRequired gets a reference to the given []CSITopology and assigns it to the Required field. func (o *CSITopologyRequest) SetRequired(v []CSITopology) { - o.Required = &v + o.Required = v } func (o CSITopologyRequest) MarshalJSON() ([]byte, error) { diff --git a/clients/go/v1/model_csi_volume.go b/clients/go/v1/model_csi_volume.go index f369adf6..6226e73d 100644 --- a/clients/go/v1/model_csi_volume.go +++ b/clients/go/v1/model_csi_volume.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -19,7 +19,7 @@ import ( // CSIVolume struct for CSIVolume type CSIVolume struct { AccessMode *string `json:"AccessMode,omitempty"` - Allocations *[]AllocationListStub `json:"Allocations,omitempty"` + Allocations []AllocationListStub `json:"Allocations,omitempty"` AttachmentMode *string `json:"AttachmentMode,omitempty"` Capacity *int64 `json:"Capacity,omitempty"` CloneID *string `json:"CloneID,omitempty"` @@ -31,7 +31,7 @@ type CSIVolume struct { ExternalID *string `json:"ExternalID,omitempty"` ID *string `json:"ID,omitempty"` ModifyIndex *int32 `json:"ModifyIndex,omitempty"` - MountOptions *CSIMountOptions `json:"MountOptions,omitempty"` + MountOptions NullableCSIMountOptions `json:"MountOptions,omitempty"` Name *string `json:"Name,omitempty"` Namespace *string `json:"Namespace,omitempty"` NodesExpected *int32 `json:"NodesExpected,omitempty"` @@ -41,15 +41,15 @@ type CSIVolume struct { Provider *string `json:"Provider,omitempty"` ProviderVersion *string `json:"ProviderVersion,omitempty"` ReadAllocs *map[string]Allocation `json:"ReadAllocs,omitempty"` - RequestedCapabilities *[]CSIVolumeCapability `json:"RequestedCapabilities,omitempty"` + RequestedCapabilities []CSIVolumeCapability `json:"RequestedCapabilities,omitempty"` RequestedCapacityMax *int64 `json:"RequestedCapacityMax,omitempty"` RequestedCapacityMin *int64 `json:"RequestedCapacityMin,omitempty"` - RequestedTopologies *CSITopologyRequest `json:"RequestedTopologies,omitempty"` - ResourceExhausted *time.Time `json:"ResourceExhausted,omitempty"` + RequestedTopologies NullableCSITopologyRequest `json:"RequestedTopologies,omitempty"` + ResourceExhausted NullableTime `json:"ResourceExhausted,omitempty"` Schedulable *bool `json:"Schedulable,omitempty"` Secrets *map[string]string `json:"Secrets,omitempty"` SnapshotID *string `json:"SnapshotID,omitempty"` - Topologies *[]CSITopology `json:"Topologies,omitempty"` + Topologies []CSITopology `json:"Topologies,omitempty"` WriteAllocs *map[string]Allocation `json:"WriteAllocs,omitempty"` } @@ -108,12 +108,12 @@ func (o *CSIVolume) GetAllocations() []AllocationListStub { var ret []AllocationListStub return ret } - return *o.Allocations + return o.Allocations } // GetAllocationsOk returns a tuple with the Allocations field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *CSIVolume) GetAllocationsOk() (*[]AllocationListStub, bool) { +func (o *CSIVolume) GetAllocationsOk() ([]AllocationListStub, bool) { if o == nil || o.Allocations == nil { return nil, false } @@ -131,7 +131,7 @@ func (o *CSIVolume) HasAllocations() bool { // SetAllocations gets a reference to the given []AllocationListStub and assigns it to the Allocations field. func (o *CSIVolume) SetAllocations(v []AllocationListStub) { - o.Allocations = &v + o.Allocations = v } // GetAttachmentMode returns the AttachmentMode field value if set, zero value otherwise. @@ -486,36 +486,46 @@ func (o *CSIVolume) SetModifyIndex(v int32) { o.ModifyIndex = &v } -// GetMountOptions returns the MountOptions field value if set, zero value otherwise. +// GetMountOptions returns the MountOptions field value if set, zero value otherwise (both if not set or set to explicit null). func (o *CSIVolume) GetMountOptions() CSIMountOptions { - if o == nil || o.MountOptions == nil { + if o == nil || o.MountOptions.Get() == nil { var ret CSIMountOptions return ret } - return *o.MountOptions + return *o.MountOptions.Get() } // GetMountOptionsOk returns a tuple with the MountOptions field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *CSIVolume) GetMountOptionsOk() (*CSIMountOptions, bool) { - if o == nil || o.MountOptions == nil { + if o == nil { return nil, false } - return o.MountOptions, true + return o.MountOptions.Get(), o.MountOptions.IsSet() } // HasMountOptions returns a boolean if a field has been set. func (o *CSIVolume) HasMountOptions() bool { - if o != nil && o.MountOptions != nil { + if o != nil && o.MountOptions.IsSet() { return true } return false } -// SetMountOptions gets a reference to the given CSIMountOptions and assigns it to the MountOptions field. +// SetMountOptions gets a reference to the given NullableCSIMountOptions and assigns it to the MountOptions field. func (o *CSIVolume) SetMountOptions(v CSIMountOptions) { - o.MountOptions = &v + o.MountOptions.Set(&v) +} +// SetMountOptionsNil sets the value for MountOptions to be an explicit nil +func (o *CSIVolume) SetMountOptionsNil() { + o.MountOptions.Set(nil) +} + +// UnsetMountOptions ensures that no value is present for MountOptions, not even an explicit nil +func (o *CSIVolume) UnsetMountOptions() { + o.MountOptions.Unset() } // GetName returns the Name field value if set, zero value otherwise. @@ -812,12 +822,12 @@ func (o *CSIVolume) GetRequestedCapabilities() []CSIVolumeCapability { var ret []CSIVolumeCapability return ret } - return *o.RequestedCapabilities + return o.RequestedCapabilities } // GetRequestedCapabilitiesOk returns a tuple with the RequestedCapabilities field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *CSIVolume) GetRequestedCapabilitiesOk() (*[]CSIVolumeCapability, bool) { +func (o *CSIVolume) GetRequestedCapabilitiesOk() ([]CSIVolumeCapability, bool) { if o == nil || o.RequestedCapabilities == nil { return nil, false } @@ -835,7 +845,7 @@ func (o *CSIVolume) HasRequestedCapabilities() bool { // SetRequestedCapabilities gets a reference to the given []CSIVolumeCapability and assigns it to the RequestedCapabilities field. func (o *CSIVolume) SetRequestedCapabilities(v []CSIVolumeCapability) { - o.RequestedCapabilities = &v + o.RequestedCapabilities = v } // GetRequestedCapacityMax returns the RequestedCapacityMax field value if set, zero value otherwise. @@ -902,68 +912,88 @@ func (o *CSIVolume) SetRequestedCapacityMin(v int64) { o.RequestedCapacityMin = &v } -// GetRequestedTopologies returns the RequestedTopologies field value if set, zero value otherwise. +// GetRequestedTopologies returns the RequestedTopologies field value if set, zero value otherwise (both if not set or set to explicit null). func (o *CSIVolume) GetRequestedTopologies() CSITopologyRequest { - if o == nil || o.RequestedTopologies == nil { + if o == nil || o.RequestedTopologies.Get() == nil { var ret CSITopologyRequest return ret } - return *o.RequestedTopologies + return *o.RequestedTopologies.Get() } // GetRequestedTopologiesOk returns a tuple with the RequestedTopologies field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *CSIVolume) GetRequestedTopologiesOk() (*CSITopologyRequest, bool) { - if o == nil || o.RequestedTopologies == nil { + if o == nil { return nil, false } - return o.RequestedTopologies, true + return o.RequestedTopologies.Get(), o.RequestedTopologies.IsSet() } // HasRequestedTopologies returns a boolean if a field has been set. func (o *CSIVolume) HasRequestedTopologies() bool { - if o != nil && o.RequestedTopologies != nil { + if o != nil && o.RequestedTopologies.IsSet() { return true } return false } -// SetRequestedTopologies gets a reference to the given CSITopologyRequest and assigns it to the RequestedTopologies field. +// SetRequestedTopologies gets a reference to the given NullableCSITopologyRequest and assigns it to the RequestedTopologies field. func (o *CSIVolume) SetRequestedTopologies(v CSITopologyRequest) { - o.RequestedTopologies = &v + o.RequestedTopologies.Set(&v) +} +// SetRequestedTopologiesNil sets the value for RequestedTopologies to be an explicit nil +func (o *CSIVolume) SetRequestedTopologiesNil() { + o.RequestedTopologies.Set(nil) } -// GetResourceExhausted returns the ResourceExhausted field value if set, zero value otherwise. +// UnsetRequestedTopologies ensures that no value is present for RequestedTopologies, not even an explicit nil +func (o *CSIVolume) UnsetRequestedTopologies() { + o.RequestedTopologies.Unset() +} + +// GetResourceExhausted returns the ResourceExhausted field value if set, zero value otherwise (both if not set or set to explicit null). func (o *CSIVolume) GetResourceExhausted() time.Time { - if o == nil || o.ResourceExhausted == nil { + if o == nil || o.ResourceExhausted.Get() == nil { var ret time.Time return ret } - return *o.ResourceExhausted + return *o.ResourceExhausted.Get() } // GetResourceExhaustedOk returns a tuple with the ResourceExhausted field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *CSIVolume) GetResourceExhaustedOk() (*time.Time, bool) { - if o == nil || o.ResourceExhausted == nil { + if o == nil { return nil, false } - return o.ResourceExhausted, true + return o.ResourceExhausted.Get(), o.ResourceExhausted.IsSet() } // HasResourceExhausted returns a boolean if a field has been set. func (o *CSIVolume) HasResourceExhausted() bool { - if o != nil && o.ResourceExhausted != nil { + if o != nil && o.ResourceExhausted.IsSet() { return true } return false } -// SetResourceExhausted gets a reference to the given time.Time and assigns it to the ResourceExhausted field. +// SetResourceExhausted gets a reference to the given NullableTime and assigns it to the ResourceExhausted field. func (o *CSIVolume) SetResourceExhausted(v time.Time) { - o.ResourceExhausted = &v + o.ResourceExhausted.Set(&v) +} +// SetResourceExhaustedNil sets the value for ResourceExhausted to be an explicit nil +func (o *CSIVolume) SetResourceExhaustedNil() { + o.ResourceExhausted.Set(nil) +} + +// UnsetResourceExhausted ensures that no value is present for ResourceExhausted, not even an explicit nil +func (o *CSIVolume) UnsetResourceExhausted() { + o.ResourceExhausted.Unset() } // GetSchedulable returns the Schedulable field value if set, zero value otherwise. @@ -1068,12 +1098,12 @@ func (o *CSIVolume) GetTopologies() []CSITopology { var ret []CSITopology return ret } - return *o.Topologies + return o.Topologies } // GetTopologiesOk returns a tuple with the Topologies field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *CSIVolume) GetTopologiesOk() (*[]CSITopology, bool) { +func (o *CSIVolume) GetTopologiesOk() ([]CSITopology, bool) { if o == nil || o.Topologies == nil { return nil, false } @@ -1091,7 +1121,7 @@ func (o *CSIVolume) HasTopologies() bool { // SetTopologies gets a reference to the given []CSITopology and assigns it to the Topologies field. func (o *CSIVolume) SetTopologies(v []CSITopology) { - o.Topologies = &v + o.Topologies = v } // GetWriteAllocs returns the WriteAllocs field value if set, zero value otherwise. @@ -1167,8 +1197,8 @@ func (o CSIVolume) MarshalJSON() ([]byte, error) { if o.ModifyIndex != nil { toSerialize["ModifyIndex"] = o.ModifyIndex } - if o.MountOptions != nil { - toSerialize["MountOptions"] = o.MountOptions + if o.MountOptions.IsSet() { + toSerialize["MountOptions"] = o.MountOptions.Get() } if o.Name != nil { toSerialize["Name"] = o.Name @@ -1206,11 +1236,11 @@ func (o CSIVolume) MarshalJSON() ([]byte, error) { if o.RequestedCapacityMin != nil { toSerialize["RequestedCapacityMin"] = o.RequestedCapacityMin } - if o.RequestedTopologies != nil { - toSerialize["RequestedTopologies"] = o.RequestedTopologies + if o.RequestedTopologies.IsSet() { + toSerialize["RequestedTopologies"] = o.RequestedTopologies.Get() } - if o.ResourceExhausted != nil { - toSerialize["ResourceExhausted"] = o.ResourceExhausted + if o.ResourceExhausted.IsSet() { + toSerialize["ResourceExhausted"] = o.ResourceExhausted.Get() } if o.Schedulable != nil { toSerialize["Schedulable"] = o.Schedulable diff --git a/clients/go/v1/model_csi_volume_capability.go b/clients/go/v1/model_csi_volume_capability.go index 0c42497c..36fcdddb 100644 --- a/clients/go/v1/model_csi_volume_capability.go +++ b/clients/go/v1/model_csi_volume_capability.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_csi_volume_create_request.go b/clients/go/v1/model_csi_volume_create_request.go index a1214c9d..06f0071e 100644 --- a/clients/go/v1/model_csi_volume_create_request.go +++ b/clients/go/v1/model_csi_volume_create_request.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -20,7 +20,7 @@ type CSIVolumeCreateRequest struct { Namespace *string `json:"Namespace,omitempty"` Region *string `json:"Region,omitempty"` SecretID *string `json:"SecretID,omitempty"` - Volumes *[]CSIVolume `json:"Volumes,omitempty"` + Volumes []CSIVolume `json:"Volumes,omitempty"` } // NewCSIVolumeCreateRequest instantiates a new CSIVolumeCreateRequest object @@ -142,12 +142,12 @@ func (o *CSIVolumeCreateRequest) GetVolumes() []CSIVolume { var ret []CSIVolume return ret } - return *o.Volumes + return o.Volumes } // GetVolumesOk returns a tuple with the Volumes field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *CSIVolumeCreateRequest) GetVolumesOk() (*[]CSIVolume, bool) { +func (o *CSIVolumeCreateRequest) GetVolumesOk() ([]CSIVolume, bool) { if o == nil || o.Volumes == nil { return nil, false } @@ -165,7 +165,7 @@ func (o *CSIVolumeCreateRequest) HasVolumes() bool { // SetVolumes gets a reference to the given []CSIVolume and assigns it to the Volumes field. func (o *CSIVolumeCreateRequest) SetVolumes(v []CSIVolume) { - o.Volumes = &v + o.Volumes = v } func (o CSIVolumeCreateRequest) MarshalJSON() ([]byte, error) { diff --git a/clients/go/v1/model_csi_volume_external_stub.go b/clients/go/v1/model_csi_volume_external_stub.go index deba709d..92493beb 100644 --- a/clients/go/v1/model_csi_volume_external_stub.go +++ b/clients/go/v1/model_csi_volume_external_stub.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -21,7 +21,7 @@ type CSIVolumeExternalStub struct { CloneID *string `json:"CloneID,omitempty"` ExternalID *string `json:"ExternalID,omitempty"` IsAbnormal *bool `json:"IsAbnormal,omitempty"` - PublishedExternalNodeIDs *[]string `json:"PublishedExternalNodeIDs,omitempty"` + PublishedExternalNodeIDs []string `json:"PublishedExternalNodeIDs,omitempty"` SnapshotID *string `json:"SnapshotID,omitempty"` Status *string `json:"Status,omitempty"` VolumeContext *map[string]string `json:"VolumeContext,omitempty"` @@ -178,12 +178,12 @@ func (o *CSIVolumeExternalStub) GetPublishedExternalNodeIDs() []string { var ret []string return ret } - return *o.PublishedExternalNodeIDs + return o.PublishedExternalNodeIDs } // GetPublishedExternalNodeIDsOk returns a tuple with the PublishedExternalNodeIDs field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *CSIVolumeExternalStub) GetPublishedExternalNodeIDsOk() (*[]string, bool) { +func (o *CSIVolumeExternalStub) GetPublishedExternalNodeIDsOk() ([]string, bool) { if o == nil || o.PublishedExternalNodeIDs == nil { return nil, false } @@ -201,7 +201,7 @@ func (o *CSIVolumeExternalStub) HasPublishedExternalNodeIDs() bool { // SetPublishedExternalNodeIDs gets a reference to the given []string and assigns it to the PublishedExternalNodeIDs field. func (o *CSIVolumeExternalStub) SetPublishedExternalNodeIDs(v []string) { - o.PublishedExternalNodeIDs = &v + o.PublishedExternalNodeIDs = v } // GetSnapshotID returns the SnapshotID field value if set, zero value otherwise. diff --git a/clients/go/v1/model_csi_volume_list_external_response.go b/clients/go/v1/model_csi_volume_list_external_response.go index 7bb13df3..8c9c0d96 100644 --- a/clients/go/v1/model_csi_volume_list_external_response.go +++ b/clients/go/v1/model_csi_volume_list_external_response.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -18,7 +18,7 @@ import ( // CSIVolumeListExternalResponse struct for CSIVolumeListExternalResponse type CSIVolumeListExternalResponse struct { NextToken *string `json:"NextToken,omitempty"` - Volumes *[]CSIVolumeExternalStub `json:"Volumes,omitempty"` + Volumes []CSIVolumeExternalStub `json:"Volumes,omitempty"` } // NewCSIVolumeListExternalResponse instantiates a new CSIVolumeListExternalResponse object @@ -76,12 +76,12 @@ func (o *CSIVolumeListExternalResponse) GetVolumes() []CSIVolumeExternalStub { var ret []CSIVolumeExternalStub return ret } - return *o.Volumes + return o.Volumes } // GetVolumesOk returns a tuple with the Volumes field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *CSIVolumeListExternalResponse) GetVolumesOk() (*[]CSIVolumeExternalStub, bool) { +func (o *CSIVolumeListExternalResponse) GetVolumesOk() ([]CSIVolumeExternalStub, bool) { if o == nil || o.Volumes == nil { return nil, false } @@ -99,7 +99,7 @@ func (o *CSIVolumeListExternalResponse) HasVolumes() bool { // SetVolumes gets a reference to the given []CSIVolumeExternalStub and assigns it to the Volumes field. func (o *CSIVolumeListExternalResponse) SetVolumes(v []CSIVolumeExternalStub) { - o.Volumes = &v + o.Volumes = v } func (o CSIVolumeListExternalResponse) MarshalJSON() ([]byte, error) { diff --git a/clients/go/v1/model_csi_volume_list_stub.go b/clients/go/v1/model_csi_volume_list_stub.go index 86d2fad8..a910db31 100644 --- a/clients/go/v1/model_csi_volume_list_stub.go +++ b/clients/go/v1/model_csi_volume_list_stub.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -33,9 +33,9 @@ type CSIVolumeListStub struct { NodesHealthy *int32 `json:"NodesHealthy,omitempty"` PluginID *string `json:"PluginID,omitempty"` Provider *string `json:"Provider,omitempty"` - ResourceExhausted *time.Time `json:"ResourceExhausted,omitempty"` + ResourceExhausted NullableTime `json:"ResourceExhausted,omitempty"` Schedulable *bool `json:"Schedulable,omitempty"` - Topologies *[]CSITopology `json:"Topologies,omitempty"` + Topologies []CSITopology `json:"Topologies,omitempty"` } // NewCSIVolumeListStub instantiates a new CSIVolumeListStub object @@ -535,36 +535,46 @@ func (o *CSIVolumeListStub) SetProvider(v string) { o.Provider = &v } -// GetResourceExhausted returns the ResourceExhausted field value if set, zero value otherwise. +// GetResourceExhausted returns the ResourceExhausted field value if set, zero value otherwise (both if not set or set to explicit null). func (o *CSIVolumeListStub) GetResourceExhausted() time.Time { - if o == nil || o.ResourceExhausted == nil { + if o == nil || o.ResourceExhausted.Get() == nil { var ret time.Time return ret } - return *o.ResourceExhausted + return *o.ResourceExhausted.Get() } // GetResourceExhaustedOk returns a tuple with the ResourceExhausted field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *CSIVolumeListStub) GetResourceExhaustedOk() (*time.Time, bool) { - if o == nil || o.ResourceExhausted == nil { + if o == nil { return nil, false } - return o.ResourceExhausted, true + return o.ResourceExhausted.Get(), o.ResourceExhausted.IsSet() } // HasResourceExhausted returns a boolean if a field has been set. func (o *CSIVolumeListStub) HasResourceExhausted() bool { - if o != nil && o.ResourceExhausted != nil { + if o != nil && o.ResourceExhausted.IsSet() { return true } return false } -// SetResourceExhausted gets a reference to the given time.Time and assigns it to the ResourceExhausted field. +// SetResourceExhausted gets a reference to the given NullableTime and assigns it to the ResourceExhausted field. func (o *CSIVolumeListStub) SetResourceExhausted(v time.Time) { - o.ResourceExhausted = &v + o.ResourceExhausted.Set(&v) +} +// SetResourceExhaustedNil sets the value for ResourceExhausted to be an explicit nil +func (o *CSIVolumeListStub) SetResourceExhaustedNil() { + o.ResourceExhausted.Set(nil) +} + +// UnsetResourceExhausted ensures that no value is present for ResourceExhausted, not even an explicit nil +func (o *CSIVolumeListStub) UnsetResourceExhausted() { + o.ResourceExhausted.Unset() } // GetSchedulable returns the Schedulable field value if set, zero value otherwise. @@ -605,12 +615,12 @@ func (o *CSIVolumeListStub) GetTopologies() []CSITopology { var ret []CSITopology return ret } - return *o.Topologies + return o.Topologies } // GetTopologiesOk returns a tuple with the Topologies field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *CSIVolumeListStub) GetTopologiesOk() (*[]CSITopology, bool) { +func (o *CSIVolumeListStub) GetTopologiesOk() ([]CSITopology, bool) { if o == nil || o.Topologies == nil { return nil, false } @@ -628,7 +638,7 @@ func (o *CSIVolumeListStub) HasTopologies() bool { // SetTopologies gets a reference to the given []CSITopology and assigns it to the Topologies field. func (o *CSIVolumeListStub) SetTopologies(v []CSITopology) { - o.Topologies = &v + o.Topologies = v } func (o CSIVolumeListStub) MarshalJSON() ([]byte, error) { @@ -678,8 +688,8 @@ func (o CSIVolumeListStub) MarshalJSON() ([]byte, error) { if o.Provider != nil { toSerialize["Provider"] = o.Provider } - if o.ResourceExhausted != nil { - toSerialize["ResourceExhausted"] = o.ResourceExhausted + if o.ResourceExhausted.IsSet() { + toSerialize["ResourceExhausted"] = o.ResourceExhausted.Get() } if o.Schedulable != nil { toSerialize["Schedulable"] = o.Schedulable diff --git a/clients/go/v1/model_csi_volume_register_request.go b/clients/go/v1/model_csi_volume_register_request.go index da411775..c4ce91e7 100644 --- a/clients/go/v1/model_csi_volume_register_request.go +++ b/clients/go/v1/model_csi_volume_register_request.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -20,7 +20,7 @@ type CSIVolumeRegisterRequest struct { Namespace *string `json:"Namespace,omitempty"` Region *string `json:"Region,omitempty"` SecretID *string `json:"SecretID,omitempty"` - Volumes *[]CSIVolume `json:"Volumes,omitempty"` + Volumes []CSIVolume `json:"Volumes,omitempty"` } // NewCSIVolumeRegisterRequest instantiates a new CSIVolumeRegisterRequest object @@ -142,12 +142,12 @@ func (o *CSIVolumeRegisterRequest) GetVolumes() []CSIVolume { var ret []CSIVolume return ret } - return *o.Volumes + return o.Volumes } // GetVolumesOk returns a tuple with the Volumes field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *CSIVolumeRegisterRequest) GetVolumesOk() (*[]CSIVolume, bool) { +func (o *CSIVolumeRegisterRequest) GetVolumesOk() ([]CSIVolume, bool) { if o == nil || o.Volumes == nil { return nil, false } @@ -165,7 +165,7 @@ func (o *CSIVolumeRegisterRequest) HasVolumes() bool { // SetVolumes gets a reference to the given []CSIVolume and assigns it to the Volumes field. func (o *CSIVolumeRegisterRequest) SetVolumes(v []CSIVolume) { - o.Volumes = &v + o.Volumes = v } func (o CSIVolumeRegisterRequest) MarshalJSON() ([]byte, error) { diff --git a/clients/go/v1/model_deployment.go b/clients/go/v1/model_deployment.go index cbcd91a6..bcf5da46 100644 --- a/clients/go/v1/model_deployment.go +++ b/clients/go/v1/model_deployment.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_deployment_alloc_health_request.go b/clients/go/v1/model_deployment_alloc_health_request.go index 3552ca59..1699abc4 100644 --- a/clients/go/v1/model_deployment_alloc_health_request.go +++ b/clients/go/v1/model_deployment_alloc_health_request.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -18,11 +18,11 @@ import ( // DeploymentAllocHealthRequest struct for DeploymentAllocHealthRequest type DeploymentAllocHealthRequest struct { DeploymentID *string `json:"DeploymentID,omitempty"` - HealthyAllocationIDs *[]string `json:"HealthyAllocationIDs,omitempty"` + HealthyAllocationIDs []string `json:"HealthyAllocationIDs,omitempty"` Namespace *string `json:"Namespace,omitempty"` Region *string `json:"Region,omitempty"` SecretID *string `json:"SecretID,omitempty"` - UnhealthyAllocationIDs *[]string `json:"UnhealthyAllocationIDs,omitempty"` + UnhealthyAllocationIDs []string `json:"UnhealthyAllocationIDs,omitempty"` } // NewDeploymentAllocHealthRequest instantiates a new DeploymentAllocHealthRequest object @@ -80,12 +80,12 @@ func (o *DeploymentAllocHealthRequest) GetHealthyAllocationIDs() []string { var ret []string return ret } - return *o.HealthyAllocationIDs + return o.HealthyAllocationIDs } // GetHealthyAllocationIDsOk returns a tuple with the HealthyAllocationIDs field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *DeploymentAllocHealthRequest) GetHealthyAllocationIDsOk() (*[]string, bool) { +func (o *DeploymentAllocHealthRequest) GetHealthyAllocationIDsOk() ([]string, bool) { if o == nil || o.HealthyAllocationIDs == nil { return nil, false } @@ -103,7 +103,7 @@ func (o *DeploymentAllocHealthRequest) HasHealthyAllocationIDs() bool { // SetHealthyAllocationIDs gets a reference to the given []string and assigns it to the HealthyAllocationIDs field. func (o *DeploymentAllocHealthRequest) SetHealthyAllocationIDs(v []string) { - o.HealthyAllocationIDs = &v + o.HealthyAllocationIDs = v } // GetNamespace returns the Namespace field value if set, zero value otherwise. @@ -208,12 +208,12 @@ func (o *DeploymentAllocHealthRequest) GetUnhealthyAllocationIDs() []string { var ret []string return ret } - return *o.UnhealthyAllocationIDs + return o.UnhealthyAllocationIDs } // GetUnhealthyAllocationIDsOk returns a tuple with the UnhealthyAllocationIDs field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *DeploymentAllocHealthRequest) GetUnhealthyAllocationIDsOk() (*[]string, bool) { +func (o *DeploymentAllocHealthRequest) GetUnhealthyAllocationIDsOk() ([]string, bool) { if o == nil || o.UnhealthyAllocationIDs == nil { return nil, false } @@ -231,7 +231,7 @@ func (o *DeploymentAllocHealthRequest) HasUnhealthyAllocationIDs() bool { // SetUnhealthyAllocationIDs gets a reference to the given []string and assigns it to the UnhealthyAllocationIDs field. func (o *DeploymentAllocHealthRequest) SetUnhealthyAllocationIDs(v []string) { - o.UnhealthyAllocationIDs = &v + o.UnhealthyAllocationIDs = v } func (o DeploymentAllocHealthRequest) MarshalJSON() ([]byte, error) { diff --git a/clients/go/v1/model_deployment_pause_request.go b/clients/go/v1/model_deployment_pause_request.go index b505d576..08313f2c 100644 --- a/clients/go/v1/model_deployment_pause_request.go +++ b/clients/go/v1/model_deployment_pause_request.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_deployment_promote_request.go b/clients/go/v1/model_deployment_promote_request.go index 729ef9be..c8c283d4 100644 --- a/clients/go/v1/model_deployment_promote_request.go +++ b/clients/go/v1/model_deployment_promote_request.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -19,7 +19,7 @@ import ( type DeploymentPromoteRequest struct { All *bool `json:"All,omitempty"` DeploymentID *string `json:"DeploymentID,omitempty"` - Groups *[]string `json:"Groups,omitempty"` + Groups []string `json:"Groups,omitempty"` Namespace *string `json:"Namespace,omitempty"` Region *string `json:"Region,omitempty"` SecretID *string `json:"SecretID,omitempty"` @@ -112,12 +112,12 @@ func (o *DeploymentPromoteRequest) GetGroups() []string { var ret []string return ret } - return *o.Groups + return o.Groups } // GetGroupsOk returns a tuple with the Groups field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *DeploymentPromoteRequest) GetGroupsOk() (*[]string, bool) { +func (o *DeploymentPromoteRequest) GetGroupsOk() ([]string, bool) { if o == nil || o.Groups == nil { return nil, false } @@ -135,7 +135,7 @@ func (o *DeploymentPromoteRequest) HasGroups() bool { // SetGroups gets a reference to the given []string and assigns it to the Groups field. func (o *DeploymentPromoteRequest) SetGroups(v []string) { - o.Groups = &v + o.Groups = v } // GetNamespace returns the Namespace field value if set, zero value otherwise. diff --git a/clients/go/v1/model_deployment_state.go b/clients/go/v1/model_deployment_state.go index 785b59d6..534857eb 100644 --- a/clients/go/v1/model_deployment_state.go +++ b/clients/go/v1/model_deployment_state.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -23,10 +23,10 @@ type DeploymentState struct { DesiredTotal *int32 `json:"DesiredTotal,omitempty"` HealthyAllocs *int32 `json:"HealthyAllocs,omitempty"` PlacedAllocs *int32 `json:"PlacedAllocs,omitempty"` - PlacedCanaries *[]string `json:"PlacedCanaries,omitempty"` + PlacedCanaries []string `json:"PlacedCanaries,omitempty"` ProgressDeadline *int64 `json:"ProgressDeadline,omitempty"` Promoted *bool `json:"Promoted,omitempty"` - RequireProgressBy *time.Time `json:"RequireProgressBy,omitempty"` + RequireProgressBy NullableTime `json:"RequireProgressBy,omitempty"` UnhealthyAllocs *int32 `json:"UnhealthyAllocs,omitempty"` } @@ -213,12 +213,12 @@ func (o *DeploymentState) GetPlacedCanaries() []string { var ret []string return ret } - return *o.PlacedCanaries + return o.PlacedCanaries } // GetPlacedCanariesOk returns a tuple with the PlacedCanaries field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *DeploymentState) GetPlacedCanariesOk() (*[]string, bool) { +func (o *DeploymentState) GetPlacedCanariesOk() ([]string, bool) { if o == nil || o.PlacedCanaries == nil { return nil, false } @@ -236,7 +236,7 @@ func (o *DeploymentState) HasPlacedCanaries() bool { // SetPlacedCanaries gets a reference to the given []string and assigns it to the PlacedCanaries field. func (o *DeploymentState) SetPlacedCanaries(v []string) { - o.PlacedCanaries = &v + o.PlacedCanaries = v } // GetProgressDeadline returns the ProgressDeadline field value if set, zero value otherwise. @@ -303,36 +303,46 @@ func (o *DeploymentState) SetPromoted(v bool) { o.Promoted = &v } -// GetRequireProgressBy returns the RequireProgressBy field value if set, zero value otherwise. +// GetRequireProgressBy returns the RequireProgressBy field value if set, zero value otherwise (both if not set or set to explicit null). func (o *DeploymentState) GetRequireProgressBy() time.Time { - if o == nil || o.RequireProgressBy == nil { + if o == nil || o.RequireProgressBy.Get() == nil { var ret time.Time return ret } - return *o.RequireProgressBy + return *o.RequireProgressBy.Get() } // GetRequireProgressByOk returns a tuple with the RequireProgressBy field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *DeploymentState) GetRequireProgressByOk() (*time.Time, bool) { - if o == nil || o.RequireProgressBy == nil { + if o == nil { return nil, false } - return o.RequireProgressBy, true + return o.RequireProgressBy.Get(), o.RequireProgressBy.IsSet() } // HasRequireProgressBy returns a boolean if a field has been set. func (o *DeploymentState) HasRequireProgressBy() bool { - if o != nil && o.RequireProgressBy != nil { + if o != nil && o.RequireProgressBy.IsSet() { return true } return false } -// SetRequireProgressBy gets a reference to the given time.Time and assigns it to the RequireProgressBy field. +// SetRequireProgressBy gets a reference to the given NullableTime and assigns it to the RequireProgressBy field. func (o *DeploymentState) SetRequireProgressBy(v time.Time) { - o.RequireProgressBy = &v + o.RequireProgressBy.Set(&v) +} +// SetRequireProgressByNil sets the value for RequireProgressBy to be an explicit nil +func (o *DeploymentState) SetRequireProgressByNil() { + o.RequireProgressBy.Set(nil) +} + +// UnsetRequireProgressBy ensures that no value is present for RequireProgressBy, not even an explicit nil +func (o *DeploymentState) UnsetRequireProgressBy() { + o.RequireProgressBy.Unset() } // GetUnhealthyAllocs returns the UnhealthyAllocs field value if set, zero value otherwise. @@ -393,8 +403,8 @@ func (o DeploymentState) MarshalJSON() ([]byte, error) { if o.Promoted != nil { toSerialize["Promoted"] = o.Promoted } - if o.RequireProgressBy != nil { - toSerialize["RequireProgressBy"] = o.RequireProgressBy + if o.RequireProgressBy.IsSet() { + toSerialize["RequireProgressBy"] = o.RequireProgressBy.Get() } if o.UnhealthyAllocs != nil { toSerialize["UnhealthyAllocs"] = o.UnhealthyAllocs diff --git a/clients/go/v1/model_deployment_unblock_request.go b/clients/go/v1/model_deployment_unblock_request.go index 962353d0..7afb807a 100644 --- a/clients/go/v1/model_deployment_unblock_request.go +++ b/clients/go/v1/model_deployment_unblock_request.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_deployment_update_response.go b/clients/go/v1/model_deployment_update_response.go index bcd0a9fe..c339f673 100644 --- a/clients/go/v1/model_deployment_update_response.go +++ b/clients/go/v1/model_deployment_update_response.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_desired_transition.go b/clients/go/v1/model_desired_transition.go index e1b1b30a..a51c12e1 100644 --- a/clients/go/v1/model_desired_transition.go +++ b/clients/go/v1/model_desired_transition.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_desired_updates.go b/clients/go/v1/model_desired_updates.go index f57e4a42..c5443c6b 100644 --- a/clients/go/v1/model_desired_updates.go +++ b/clients/go/v1/model_desired_updates.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_dispatch_payload_config.go b/clients/go/v1/model_dispatch_payload_config.go index 75f523b8..a016ba03 100644 --- a/clients/go/v1/model_dispatch_payload_config.go +++ b/clients/go/v1/model_dispatch_payload_config.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_dns_config.go b/clients/go/v1/model_dns_config.go index 092e7d3f..c9b6e211 100644 --- a/clients/go/v1/model_dns_config.go +++ b/clients/go/v1/model_dns_config.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,9 +17,9 @@ import ( // DNSConfig struct for DNSConfig type DNSConfig struct { - Options *[]string `json:"Options,omitempty"` - Searches *[]string `json:"Searches,omitempty"` - Servers *[]string `json:"Servers,omitempty"` + Options []string `json:"Options,omitempty"` + Searches []string `json:"Searches,omitempty"` + Servers []string `json:"Servers,omitempty"` } // NewDNSConfig instantiates a new DNSConfig object @@ -45,12 +45,12 @@ func (o *DNSConfig) GetOptions() []string { var ret []string return ret } - return *o.Options + return o.Options } // GetOptionsOk returns a tuple with the Options field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *DNSConfig) GetOptionsOk() (*[]string, bool) { +func (o *DNSConfig) GetOptionsOk() ([]string, bool) { if o == nil || o.Options == nil { return nil, false } @@ -68,7 +68,7 @@ func (o *DNSConfig) HasOptions() bool { // SetOptions gets a reference to the given []string and assigns it to the Options field. func (o *DNSConfig) SetOptions(v []string) { - o.Options = &v + o.Options = v } // GetSearches returns the Searches field value if set, zero value otherwise. @@ -77,12 +77,12 @@ func (o *DNSConfig) GetSearches() []string { var ret []string return ret } - return *o.Searches + return o.Searches } // GetSearchesOk returns a tuple with the Searches field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *DNSConfig) GetSearchesOk() (*[]string, bool) { +func (o *DNSConfig) GetSearchesOk() ([]string, bool) { if o == nil || o.Searches == nil { return nil, false } @@ -100,7 +100,7 @@ func (o *DNSConfig) HasSearches() bool { // SetSearches gets a reference to the given []string and assigns it to the Searches field. func (o *DNSConfig) SetSearches(v []string) { - o.Searches = &v + o.Searches = v } // GetServers returns the Servers field value if set, zero value otherwise. @@ -109,12 +109,12 @@ func (o *DNSConfig) GetServers() []string { var ret []string return ret } - return *o.Servers + return o.Servers } // GetServersOk returns a tuple with the Servers field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *DNSConfig) GetServersOk() (*[]string, bool) { +func (o *DNSConfig) GetServersOk() ([]string, bool) { if o == nil || o.Servers == nil { return nil, false } @@ -132,7 +132,7 @@ func (o *DNSConfig) HasServers() bool { // SetServers gets a reference to the given []string and assigns it to the Servers field. func (o *DNSConfig) SetServers(v []string) { - o.Servers = &v + o.Servers = v } func (o DNSConfig) MarshalJSON() ([]byte, error) { diff --git a/clients/go/v1/model_drain_metadata.go b/clients/go/v1/model_drain_metadata.go index 028a6844..fe6978a9 100644 --- a/clients/go/v1/model_drain_metadata.go +++ b/clients/go/v1/model_drain_metadata.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -20,9 +20,9 @@ import ( type DrainMetadata struct { AccessorID *string `json:"AccessorID,omitempty"` Meta *map[string]string `json:"Meta,omitempty"` - StartedAt *time.Time `json:"StartedAt,omitempty"` + StartedAt NullableTime `json:"StartedAt,omitempty"` Status *string `json:"Status,omitempty"` - UpdatedAt *time.Time `json:"UpdatedAt,omitempty"` + UpdatedAt NullableTime `json:"UpdatedAt,omitempty"` } // NewDrainMetadata instantiates a new DrainMetadata object @@ -106,36 +106,46 @@ func (o *DrainMetadata) SetMeta(v map[string]string) { o.Meta = &v } -// GetStartedAt returns the StartedAt field value if set, zero value otherwise. +// GetStartedAt returns the StartedAt field value if set, zero value otherwise (both if not set or set to explicit null). func (o *DrainMetadata) GetStartedAt() time.Time { - if o == nil || o.StartedAt == nil { + if o == nil || o.StartedAt.Get() == nil { var ret time.Time return ret } - return *o.StartedAt + return *o.StartedAt.Get() } // GetStartedAtOk returns a tuple with the StartedAt field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *DrainMetadata) GetStartedAtOk() (*time.Time, bool) { - if o == nil || o.StartedAt == nil { + if o == nil { return nil, false } - return o.StartedAt, true + return o.StartedAt.Get(), o.StartedAt.IsSet() } // HasStartedAt returns a boolean if a field has been set. func (o *DrainMetadata) HasStartedAt() bool { - if o != nil && o.StartedAt != nil { + if o != nil && o.StartedAt.IsSet() { return true } return false } -// SetStartedAt gets a reference to the given time.Time and assigns it to the StartedAt field. +// SetStartedAt gets a reference to the given NullableTime and assigns it to the StartedAt field. func (o *DrainMetadata) SetStartedAt(v time.Time) { - o.StartedAt = &v + o.StartedAt.Set(&v) +} +// SetStartedAtNil sets the value for StartedAt to be an explicit nil +func (o *DrainMetadata) SetStartedAtNil() { + o.StartedAt.Set(nil) +} + +// UnsetStartedAt ensures that no value is present for StartedAt, not even an explicit nil +func (o *DrainMetadata) UnsetStartedAt() { + o.StartedAt.Unset() } // GetStatus returns the Status field value if set, zero value otherwise. @@ -170,36 +180,46 @@ func (o *DrainMetadata) SetStatus(v string) { o.Status = &v } -// GetUpdatedAt returns the UpdatedAt field value if set, zero value otherwise. +// GetUpdatedAt returns the UpdatedAt field value if set, zero value otherwise (both if not set or set to explicit null). func (o *DrainMetadata) GetUpdatedAt() time.Time { - if o == nil || o.UpdatedAt == nil { + if o == nil || o.UpdatedAt.Get() == nil { var ret time.Time return ret } - return *o.UpdatedAt + return *o.UpdatedAt.Get() } // GetUpdatedAtOk returns a tuple with the UpdatedAt field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *DrainMetadata) GetUpdatedAtOk() (*time.Time, bool) { - if o == nil || o.UpdatedAt == nil { + if o == nil { return nil, false } - return o.UpdatedAt, true + return o.UpdatedAt.Get(), o.UpdatedAt.IsSet() } // HasUpdatedAt returns a boolean if a field has been set. func (o *DrainMetadata) HasUpdatedAt() bool { - if o != nil && o.UpdatedAt != nil { + if o != nil && o.UpdatedAt.IsSet() { return true } return false } -// SetUpdatedAt gets a reference to the given time.Time and assigns it to the UpdatedAt field. +// SetUpdatedAt gets a reference to the given NullableTime and assigns it to the UpdatedAt field. func (o *DrainMetadata) SetUpdatedAt(v time.Time) { - o.UpdatedAt = &v + o.UpdatedAt.Set(&v) +} +// SetUpdatedAtNil sets the value for UpdatedAt to be an explicit nil +func (o *DrainMetadata) SetUpdatedAtNil() { + o.UpdatedAt.Set(nil) +} + +// UnsetUpdatedAt ensures that no value is present for UpdatedAt, not even an explicit nil +func (o *DrainMetadata) UnsetUpdatedAt() { + o.UpdatedAt.Unset() } func (o DrainMetadata) MarshalJSON() ([]byte, error) { @@ -210,14 +230,14 @@ func (o DrainMetadata) MarshalJSON() ([]byte, error) { if o.Meta != nil { toSerialize["Meta"] = o.Meta } - if o.StartedAt != nil { - toSerialize["StartedAt"] = o.StartedAt + if o.StartedAt.IsSet() { + toSerialize["StartedAt"] = o.StartedAt.Get() } if o.Status != nil { toSerialize["Status"] = o.Status } - if o.UpdatedAt != nil { - toSerialize["UpdatedAt"] = o.UpdatedAt + if o.UpdatedAt.IsSet() { + toSerialize["UpdatedAt"] = o.UpdatedAt.Get() } return json.Marshal(toSerialize) } diff --git a/clients/go/v1/model_drain_spec.go b/clients/go/v1/model_drain_spec.go index 6e97ef7c..771f5a53 100644 --- a/clients/go/v1/model_drain_spec.go +++ b/clients/go/v1/model_drain_spec.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_drain_strategy.go b/clients/go/v1/model_drain_strategy.go index 1d7e93d4..128a8c0b 100644 --- a/clients/go/v1/model_drain_strategy.go +++ b/clients/go/v1/model_drain_strategy.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -19,9 +19,9 @@ import ( // DrainStrategy struct for DrainStrategy type DrainStrategy struct { Deadline *int64 `json:"Deadline,omitempty"` - ForceDeadline *time.Time `json:"ForceDeadline,omitempty"` + ForceDeadline NullableTime `json:"ForceDeadline,omitempty"` IgnoreSystemJobs *bool `json:"IgnoreSystemJobs,omitempty"` - StartedAt *time.Time `json:"StartedAt,omitempty"` + StartedAt NullableTime `json:"StartedAt,omitempty"` } // NewDrainStrategy instantiates a new DrainStrategy object @@ -73,36 +73,46 @@ func (o *DrainStrategy) SetDeadline(v int64) { o.Deadline = &v } -// GetForceDeadline returns the ForceDeadline field value if set, zero value otherwise. +// GetForceDeadline returns the ForceDeadline field value if set, zero value otherwise (both if not set or set to explicit null). func (o *DrainStrategy) GetForceDeadline() time.Time { - if o == nil || o.ForceDeadline == nil { + if o == nil || o.ForceDeadline.Get() == nil { var ret time.Time return ret } - return *o.ForceDeadline + return *o.ForceDeadline.Get() } // GetForceDeadlineOk returns a tuple with the ForceDeadline field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *DrainStrategy) GetForceDeadlineOk() (*time.Time, bool) { - if o == nil || o.ForceDeadline == nil { + if o == nil { return nil, false } - return o.ForceDeadline, true + return o.ForceDeadline.Get(), o.ForceDeadline.IsSet() } // HasForceDeadline returns a boolean if a field has been set. func (o *DrainStrategy) HasForceDeadline() bool { - if o != nil && o.ForceDeadline != nil { + if o != nil && o.ForceDeadline.IsSet() { return true } return false } -// SetForceDeadline gets a reference to the given time.Time and assigns it to the ForceDeadline field. +// SetForceDeadline gets a reference to the given NullableTime and assigns it to the ForceDeadline field. func (o *DrainStrategy) SetForceDeadline(v time.Time) { - o.ForceDeadline = &v + o.ForceDeadline.Set(&v) +} +// SetForceDeadlineNil sets the value for ForceDeadline to be an explicit nil +func (o *DrainStrategy) SetForceDeadlineNil() { + o.ForceDeadline.Set(nil) +} + +// UnsetForceDeadline ensures that no value is present for ForceDeadline, not even an explicit nil +func (o *DrainStrategy) UnsetForceDeadline() { + o.ForceDeadline.Unset() } // GetIgnoreSystemJobs returns the IgnoreSystemJobs field value if set, zero value otherwise. @@ -137,36 +147,46 @@ func (o *DrainStrategy) SetIgnoreSystemJobs(v bool) { o.IgnoreSystemJobs = &v } -// GetStartedAt returns the StartedAt field value if set, zero value otherwise. +// GetStartedAt returns the StartedAt field value if set, zero value otherwise (both if not set or set to explicit null). func (o *DrainStrategy) GetStartedAt() time.Time { - if o == nil || o.StartedAt == nil { + if o == nil || o.StartedAt.Get() == nil { var ret time.Time return ret } - return *o.StartedAt + return *o.StartedAt.Get() } // GetStartedAtOk returns a tuple with the StartedAt field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *DrainStrategy) GetStartedAtOk() (*time.Time, bool) { - if o == nil || o.StartedAt == nil { + if o == nil { return nil, false } - return o.StartedAt, true + return o.StartedAt.Get(), o.StartedAt.IsSet() } // HasStartedAt returns a boolean if a field has been set. func (o *DrainStrategy) HasStartedAt() bool { - if o != nil && o.StartedAt != nil { + if o != nil && o.StartedAt.IsSet() { return true } return false } -// SetStartedAt gets a reference to the given time.Time and assigns it to the StartedAt field. +// SetStartedAt gets a reference to the given NullableTime and assigns it to the StartedAt field. func (o *DrainStrategy) SetStartedAt(v time.Time) { - o.StartedAt = &v + o.StartedAt.Set(&v) +} +// SetStartedAtNil sets the value for StartedAt to be an explicit nil +func (o *DrainStrategy) SetStartedAtNil() { + o.StartedAt.Set(nil) +} + +// UnsetStartedAt ensures that no value is present for StartedAt, not even an explicit nil +func (o *DrainStrategy) UnsetStartedAt() { + o.StartedAt.Unset() } func (o DrainStrategy) MarshalJSON() ([]byte, error) { @@ -174,14 +194,14 @@ func (o DrainStrategy) MarshalJSON() ([]byte, error) { if o.Deadline != nil { toSerialize["Deadline"] = o.Deadline } - if o.ForceDeadline != nil { - toSerialize["ForceDeadline"] = o.ForceDeadline + if o.ForceDeadline.IsSet() { + toSerialize["ForceDeadline"] = o.ForceDeadline.Get() } if o.IgnoreSystemJobs != nil { toSerialize["IgnoreSystemJobs"] = o.IgnoreSystemJobs } - if o.StartedAt != nil { - toSerialize["StartedAt"] = o.StartedAt + if o.StartedAt.IsSet() { + toSerialize["StartedAt"] = o.StartedAt.Get() } return json.Marshal(toSerialize) } diff --git a/clients/go/v1/model_driver_info.go b/clients/go/v1/model_driver_info.go index 6ef3b365..382e5709 100644 --- a/clients/go/v1/model_driver_info.go +++ b/clients/go/v1/model_driver_info.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -22,7 +22,7 @@ type DriverInfo struct { Detected *bool `json:"Detected,omitempty"` HealthDescription *string `json:"HealthDescription,omitempty"` Healthy *bool `json:"Healthy,omitempty"` - UpdateTime *time.Time `json:"UpdateTime,omitempty"` + UpdateTime NullableTime `json:"UpdateTime,omitempty"` } // NewDriverInfo instantiates a new DriverInfo object @@ -170,36 +170,46 @@ func (o *DriverInfo) SetHealthy(v bool) { o.Healthy = &v } -// GetUpdateTime returns the UpdateTime field value if set, zero value otherwise. +// GetUpdateTime returns the UpdateTime field value if set, zero value otherwise (both if not set or set to explicit null). func (o *DriverInfo) GetUpdateTime() time.Time { - if o == nil || o.UpdateTime == nil { + if o == nil || o.UpdateTime.Get() == nil { var ret time.Time return ret } - return *o.UpdateTime + return *o.UpdateTime.Get() } // GetUpdateTimeOk returns a tuple with the UpdateTime field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *DriverInfo) GetUpdateTimeOk() (*time.Time, bool) { - if o == nil || o.UpdateTime == nil { + if o == nil { return nil, false } - return o.UpdateTime, true + return o.UpdateTime.Get(), o.UpdateTime.IsSet() } // HasUpdateTime returns a boolean if a field has been set. func (o *DriverInfo) HasUpdateTime() bool { - if o != nil && o.UpdateTime != nil { + if o != nil && o.UpdateTime.IsSet() { return true } return false } -// SetUpdateTime gets a reference to the given time.Time and assigns it to the UpdateTime field. +// SetUpdateTime gets a reference to the given NullableTime and assigns it to the UpdateTime field. func (o *DriverInfo) SetUpdateTime(v time.Time) { - o.UpdateTime = &v + o.UpdateTime.Set(&v) +} +// SetUpdateTimeNil sets the value for UpdateTime to be an explicit nil +func (o *DriverInfo) SetUpdateTimeNil() { + o.UpdateTime.Set(nil) +} + +// UnsetUpdateTime ensures that no value is present for UpdateTime, not even an explicit nil +func (o *DriverInfo) UnsetUpdateTime() { + o.UpdateTime.Unset() } func (o DriverInfo) MarshalJSON() ([]byte, error) { @@ -216,8 +226,8 @@ func (o DriverInfo) MarshalJSON() ([]byte, error) { if o.Healthy != nil { toSerialize["Healthy"] = o.Healthy } - if o.UpdateTime != nil { - toSerialize["UpdateTime"] = o.UpdateTime + if o.UpdateTime.IsSet() { + toSerialize["UpdateTime"] = o.UpdateTime.Get() } return json.Marshal(toSerialize) } diff --git a/clients/go/v1/model_ephemeral_disk.go b/clients/go/v1/model_ephemeral_disk.go index cabcaf49..9df10846 100644 --- a/clients/go/v1/model_ephemeral_disk.go +++ b/clients/go/v1/model_ephemeral_disk.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_eval_options.go b/clients/go/v1/model_eval_options.go index b7522302..90e237ed 100644 --- a/clients/go/v1/model_eval_options.go +++ b/clients/go/v1/model_eval_options.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_evaluation.go b/clients/go/v1/model_evaluation.go index 24c1b197..503b3124 100644 --- a/clients/go/v1/model_evaluation.go +++ b/clients/go/v1/model_evaluation.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -39,14 +39,14 @@ type Evaluation struct { Priority *int32 `json:"Priority,omitempty"` QueuedAllocations *map[string]int32 `json:"QueuedAllocations,omitempty"` QuotaLimitReached *string `json:"QuotaLimitReached,omitempty"` - RelatedEvals *[]EvaluationStub `json:"RelatedEvals,omitempty"` + RelatedEvals []EvaluationStub `json:"RelatedEvals,omitempty"` SnapshotIndex *int32 `json:"SnapshotIndex,omitempty"` Status *string `json:"Status,omitempty"` StatusDescription *string `json:"StatusDescription,omitempty"` TriggeredBy *string `json:"TriggeredBy,omitempty"` Type *string `json:"Type,omitempty"` Wait *int64 `json:"Wait,omitempty"` - WaitUntil *time.Time `json:"WaitUntil,omitempty"` + WaitUntil NullableTime `json:"WaitUntil,omitempty"` } // NewEvaluation instantiates a new Evaluation object @@ -744,12 +744,12 @@ func (o *Evaluation) GetRelatedEvals() []EvaluationStub { var ret []EvaluationStub return ret } - return *o.RelatedEvals + return o.RelatedEvals } // GetRelatedEvalsOk returns a tuple with the RelatedEvals field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *Evaluation) GetRelatedEvalsOk() (*[]EvaluationStub, bool) { +func (o *Evaluation) GetRelatedEvalsOk() ([]EvaluationStub, bool) { if o == nil || o.RelatedEvals == nil { return nil, false } @@ -767,7 +767,7 @@ func (o *Evaluation) HasRelatedEvals() bool { // SetRelatedEvals gets a reference to the given []EvaluationStub and assigns it to the RelatedEvals field. func (o *Evaluation) SetRelatedEvals(v []EvaluationStub) { - o.RelatedEvals = &v + o.RelatedEvals = v } // GetSnapshotIndex returns the SnapshotIndex field value if set, zero value otherwise. @@ -962,36 +962,46 @@ func (o *Evaluation) SetWait(v int64) { o.Wait = &v } -// GetWaitUntil returns the WaitUntil field value if set, zero value otherwise. +// GetWaitUntil returns the WaitUntil field value if set, zero value otherwise (both if not set or set to explicit null). func (o *Evaluation) GetWaitUntil() time.Time { - if o == nil || o.WaitUntil == nil { + if o == nil || o.WaitUntil.Get() == nil { var ret time.Time return ret } - return *o.WaitUntil + return *o.WaitUntil.Get() } // GetWaitUntilOk returns a tuple with the WaitUntil field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *Evaluation) GetWaitUntilOk() (*time.Time, bool) { - if o == nil || o.WaitUntil == nil { + if o == nil { return nil, false } - return o.WaitUntil, true + return o.WaitUntil.Get(), o.WaitUntil.IsSet() } // HasWaitUntil returns a boolean if a field has been set. func (o *Evaluation) HasWaitUntil() bool { - if o != nil && o.WaitUntil != nil { + if o != nil && o.WaitUntil.IsSet() { return true } return false } -// SetWaitUntil gets a reference to the given time.Time and assigns it to the WaitUntil field. +// SetWaitUntil gets a reference to the given NullableTime and assigns it to the WaitUntil field. func (o *Evaluation) SetWaitUntil(v time.Time) { - o.WaitUntil = &v + o.WaitUntil.Set(&v) +} +// SetWaitUntilNil sets the value for WaitUntil to be an explicit nil +func (o *Evaluation) SetWaitUntilNil() { + o.WaitUntil.Set(nil) +} + +// UnsetWaitUntil ensures that no value is present for WaitUntil, not even an explicit nil +func (o *Evaluation) UnsetWaitUntil() { + o.WaitUntil.Unset() } func (o Evaluation) MarshalJSON() ([]byte, error) { @@ -1080,8 +1090,8 @@ func (o Evaluation) MarshalJSON() ([]byte, error) { if o.Wait != nil { toSerialize["Wait"] = o.Wait } - if o.WaitUntil != nil { - toSerialize["WaitUntil"] = o.WaitUntil + if o.WaitUntil.IsSet() { + toSerialize["WaitUntil"] = o.WaitUntil.Get() } return json.Marshal(toSerialize) } diff --git a/clients/go/v1/model_evaluation_stub.go b/clients/go/v1/model_evaluation_stub.go index cb8b0519..7bd1f224 100644 --- a/clients/go/v1/model_evaluation_stub.go +++ b/clients/go/v1/model_evaluation_stub.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -35,7 +35,7 @@ type EvaluationStub struct { StatusDescription *string `json:"StatusDescription,omitempty"` TriggeredBy *string `json:"TriggeredBy,omitempty"` Type *string `json:"Type,omitempty"` - WaitUntil *time.Time `json:"WaitUntil,omitempty"` + WaitUntil NullableTime `json:"WaitUntil,omitempty"` } // NewEvaluationStub instantiates a new EvaluationStub object @@ -599,36 +599,46 @@ func (o *EvaluationStub) SetType(v string) { o.Type = &v } -// GetWaitUntil returns the WaitUntil field value if set, zero value otherwise. +// GetWaitUntil returns the WaitUntil field value if set, zero value otherwise (both if not set or set to explicit null). func (o *EvaluationStub) GetWaitUntil() time.Time { - if o == nil || o.WaitUntil == nil { + if o == nil || o.WaitUntil.Get() == nil { var ret time.Time return ret } - return *o.WaitUntil + return *o.WaitUntil.Get() } // GetWaitUntilOk returns a tuple with the WaitUntil field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *EvaluationStub) GetWaitUntilOk() (*time.Time, bool) { - if o == nil || o.WaitUntil == nil { + if o == nil { return nil, false } - return o.WaitUntil, true + return o.WaitUntil.Get(), o.WaitUntil.IsSet() } // HasWaitUntil returns a boolean if a field has been set. func (o *EvaluationStub) HasWaitUntil() bool { - if o != nil && o.WaitUntil != nil { + if o != nil && o.WaitUntil.IsSet() { return true } return false } -// SetWaitUntil gets a reference to the given time.Time and assigns it to the WaitUntil field. +// SetWaitUntil gets a reference to the given NullableTime and assigns it to the WaitUntil field. func (o *EvaluationStub) SetWaitUntil(v time.Time) { - o.WaitUntil = &v + o.WaitUntil.Set(&v) +} +// SetWaitUntilNil sets the value for WaitUntil to be an explicit nil +func (o *EvaluationStub) SetWaitUntilNil() { + o.WaitUntil.Set(nil) +} + +// UnsetWaitUntil ensures that no value is present for WaitUntil, not even an explicit nil +func (o *EvaluationStub) UnsetWaitUntil() { + o.WaitUntil.Unset() } func (o EvaluationStub) MarshalJSON() ([]byte, error) { @@ -684,8 +694,8 @@ func (o EvaluationStub) MarshalJSON() ([]byte, error) { if o.Type != nil { toSerialize["Type"] = o.Type } - if o.WaitUntil != nil { - toSerialize["WaitUntil"] = o.WaitUntil + if o.WaitUntil.IsSet() { + toSerialize["WaitUntil"] = o.WaitUntil.Get() } return json.Marshal(toSerialize) } diff --git a/clients/go/v1/model_field_diff.go b/clients/go/v1/model_field_diff.go index 3c998dd4..1aad3b19 100644 --- a/clients/go/v1/model_field_diff.go +++ b/clients/go/v1/model_field_diff.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,7 +17,7 @@ import ( // FieldDiff struct for FieldDiff type FieldDiff struct { - Annotations *[]string `json:"Annotations,omitempty"` + Annotations []string `json:"Annotations,omitempty"` Name *string `json:"Name,omitempty"` New *string `json:"New,omitempty"` Old *string `json:"Old,omitempty"` @@ -47,12 +47,12 @@ func (o *FieldDiff) GetAnnotations() []string { var ret []string return ret } - return *o.Annotations + return o.Annotations } // GetAnnotationsOk returns a tuple with the Annotations field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *FieldDiff) GetAnnotationsOk() (*[]string, bool) { +func (o *FieldDiff) GetAnnotationsOk() ([]string, bool) { if o == nil || o.Annotations == nil { return nil, false } @@ -70,7 +70,7 @@ func (o *FieldDiff) HasAnnotations() bool { // SetAnnotations gets a reference to the given []string and assigns it to the Annotations field. func (o *FieldDiff) SetAnnotations(v []string) { - o.Annotations = &v + o.Annotations = v } // GetName returns the Name field value if set, zero value otherwise. diff --git a/clients/go/v1/model_fuzzy_match.go b/clients/go/v1/model_fuzzy_match.go index 7257d3c2..93fa73b7 100644 --- a/clients/go/v1/model_fuzzy_match.go +++ b/clients/go/v1/model_fuzzy_match.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -18,7 +18,7 @@ import ( // FuzzyMatch struct for FuzzyMatch type FuzzyMatch struct { ID *string `json:"ID,omitempty"` - Scope *[]string `json:"Scope,omitempty"` + Scope []string `json:"Scope,omitempty"` } // NewFuzzyMatch instantiates a new FuzzyMatch object @@ -76,12 +76,12 @@ func (o *FuzzyMatch) GetScope() []string { var ret []string return ret } - return *o.Scope + return o.Scope } // GetScopeOk returns a tuple with the Scope field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *FuzzyMatch) GetScopeOk() (*[]string, bool) { +func (o *FuzzyMatch) GetScopeOk() ([]string, bool) { if o == nil || o.Scope == nil { return nil, false } @@ -99,7 +99,7 @@ func (o *FuzzyMatch) HasScope() bool { // SetScope gets a reference to the given []string and assigns it to the Scope field. func (o *FuzzyMatch) SetScope(v []string) { - o.Scope = &v + o.Scope = v } func (o FuzzyMatch) MarshalJSON() ([]byte, error) { diff --git a/clients/go/v1/model_fuzzy_search_request.go b/clients/go/v1/model_fuzzy_search_request.go index 549e5d70..ff3301c0 100644 --- a/clients/go/v1/model_fuzzy_search_request.go +++ b/clients/go/v1/model_fuzzy_search_request.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_fuzzy_search_response.go b/clients/go/v1/model_fuzzy_search_response.go index 432073f1..e74b29b2 100644 --- a/clients/go/v1/model_fuzzy_search_response.go +++ b/clients/go/v1/model_fuzzy_search_response.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_gauge_value.go b/clients/go/v1/model_gauge_value.go index 754f4483..44f04ff1 100644 --- a/clients/go/v1/model_gauge_value.go +++ b/clients/go/v1/model_gauge_value.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_host_network_info.go b/clients/go/v1/model_host_network_info.go index 3621300a..eadbf7be 100644 --- a/clients/go/v1/model_host_network_info.go +++ b/clients/go/v1/model_host_network_info.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_host_volume_info.go b/clients/go/v1/model_host_volume_info.go index f332e543..01b4beeb 100644 --- a/clients/go/v1/model_host_volume_info.go +++ b/clients/go/v1/model_host_volume_info.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_job.go b/clients/go/v1/model_job.go index 16d2f40c..84d45a57 100644 --- a/clients/go/v1/model_job.go +++ b/clients/go/v1/model_job.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,13 +17,13 @@ import ( // Job struct for Job type Job struct { - Affinities *[]Affinity `json:"Affinities,omitempty"` + Affinities []Affinity `json:"Affinities,omitempty"` AllAtOnce *bool `json:"AllAtOnce,omitempty"` - Constraints *[]Constraint `json:"Constraints,omitempty"` + Constraints []Constraint `json:"Constraints,omitempty"` ConsulNamespace *string `json:"ConsulNamespace,omitempty"` ConsulToken *string `json:"ConsulToken,omitempty"` CreateIndex *int32 `json:"CreateIndex,omitempty"` - Datacenters *[]string `json:"Datacenters,omitempty"` + Datacenters []string `json:"Datacenters,omitempty"` DispatchIdempotencyToken *string `json:"DispatchIdempotencyToken,omitempty"` Dispatched *bool `json:"Dispatched,omitempty"` ID *string `json:"ID,omitempty"` @@ -31,24 +31,24 @@ type Job struct { Meta *map[string]string `json:"Meta,omitempty"` Migrate *MigrateStrategy `json:"Migrate,omitempty"` ModifyIndex *int32 `json:"ModifyIndex,omitempty"` - Multiregion *Multiregion `json:"Multiregion,omitempty"` + Multiregion NullableMultiregion `json:"Multiregion,omitempty"` Name *string `json:"Name,omitempty"` Namespace *string `json:"Namespace,omitempty"` NomadTokenID *string `json:"NomadTokenID,omitempty"` - ParameterizedJob *ParameterizedJobConfig `json:"ParameterizedJob,omitempty"` + ParameterizedJob NullableParameterizedJobConfig `json:"ParameterizedJob,omitempty"` ParentID *string `json:"ParentID,omitempty"` Payload *string `json:"Payload,omitempty"` Periodic *PeriodicConfig `json:"Periodic,omitempty"` Priority *int32 `json:"Priority,omitempty"` Region *string `json:"Region,omitempty"` Reschedule *ReschedulePolicy `json:"Reschedule,omitempty"` - Spreads *[]Spread `json:"Spreads,omitempty"` + Spreads []Spread `json:"Spreads,omitempty"` Stable *bool `json:"Stable,omitempty"` Status *string `json:"Status,omitempty"` StatusDescription *string `json:"StatusDescription,omitempty"` Stop *bool `json:"Stop,omitempty"` SubmitTime *int64 `json:"SubmitTime,omitempty"` - TaskGroups *[]TaskGroup `json:"TaskGroups,omitempty"` + TaskGroups []TaskGroup `json:"TaskGroups,omitempty"` Type *string `json:"Type,omitempty"` Update *UpdateStrategy `json:"Update,omitempty"` VaultNamespace *string `json:"VaultNamespace,omitempty"` @@ -79,12 +79,12 @@ func (o *Job) GetAffinities() []Affinity { var ret []Affinity return ret } - return *o.Affinities + return o.Affinities } // GetAffinitiesOk returns a tuple with the Affinities field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *Job) GetAffinitiesOk() (*[]Affinity, bool) { +func (o *Job) GetAffinitiesOk() ([]Affinity, bool) { if o == nil || o.Affinities == nil { return nil, false } @@ -102,7 +102,7 @@ func (o *Job) HasAffinities() bool { // SetAffinities gets a reference to the given []Affinity and assigns it to the Affinities field. func (o *Job) SetAffinities(v []Affinity) { - o.Affinities = &v + o.Affinities = v } // GetAllAtOnce returns the AllAtOnce field value if set, zero value otherwise. @@ -143,12 +143,12 @@ func (o *Job) GetConstraints() []Constraint { var ret []Constraint return ret } - return *o.Constraints + return o.Constraints } // GetConstraintsOk returns a tuple with the Constraints field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *Job) GetConstraintsOk() (*[]Constraint, bool) { +func (o *Job) GetConstraintsOk() ([]Constraint, bool) { if o == nil || o.Constraints == nil { return nil, false } @@ -166,7 +166,7 @@ func (o *Job) HasConstraints() bool { // SetConstraints gets a reference to the given []Constraint and assigns it to the Constraints field. func (o *Job) SetConstraints(v []Constraint) { - o.Constraints = &v + o.Constraints = v } // GetConsulNamespace returns the ConsulNamespace field value if set, zero value otherwise. @@ -271,12 +271,12 @@ func (o *Job) GetDatacenters() []string { var ret []string return ret } - return *o.Datacenters + return o.Datacenters } // GetDatacentersOk returns a tuple with the Datacenters field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *Job) GetDatacentersOk() (*[]string, bool) { +func (o *Job) GetDatacentersOk() ([]string, bool) { if o == nil || o.Datacenters == nil { return nil, false } @@ -294,7 +294,7 @@ func (o *Job) HasDatacenters() bool { // SetDatacenters gets a reference to the given []string and assigns it to the Datacenters field. func (o *Job) SetDatacenters(v []string) { - o.Datacenters = &v + o.Datacenters = v } // GetDispatchIdempotencyToken returns the DispatchIdempotencyToken field value if set, zero value otherwise. @@ -521,36 +521,46 @@ func (o *Job) SetModifyIndex(v int32) { o.ModifyIndex = &v } -// GetMultiregion returns the Multiregion field value if set, zero value otherwise. +// GetMultiregion returns the Multiregion field value if set, zero value otherwise (both if not set or set to explicit null). func (o *Job) GetMultiregion() Multiregion { - if o == nil || o.Multiregion == nil { + if o == nil || o.Multiregion.Get() == nil { var ret Multiregion return ret } - return *o.Multiregion + return *o.Multiregion.Get() } // GetMultiregionOk returns a tuple with the Multiregion field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *Job) GetMultiregionOk() (*Multiregion, bool) { - if o == nil || o.Multiregion == nil { + if o == nil { return nil, false } - return o.Multiregion, true + return o.Multiregion.Get(), o.Multiregion.IsSet() } // HasMultiregion returns a boolean if a field has been set. func (o *Job) HasMultiregion() bool { - if o != nil && o.Multiregion != nil { + if o != nil && o.Multiregion.IsSet() { return true } return false } -// SetMultiregion gets a reference to the given Multiregion and assigns it to the Multiregion field. +// SetMultiregion gets a reference to the given NullableMultiregion and assigns it to the Multiregion field. func (o *Job) SetMultiregion(v Multiregion) { - o.Multiregion = &v + o.Multiregion.Set(&v) +} +// SetMultiregionNil sets the value for Multiregion to be an explicit nil +func (o *Job) SetMultiregionNil() { + o.Multiregion.Set(nil) +} + +// UnsetMultiregion ensures that no value is present for Multiregion, not even an explicit nil +func (o *Job) UnsetMultiregion() { + o.Multiregion.Unset() } // GetName returns the Name field value if set, zero value otherwise. @@ -649,36 +659,46 @@ func (o *Job) SetNomadTokenID(v string) { o.NomadTokenID = &v } -// GetParameterizedJob returns the ParameterizedJob field value if set, zero value otherwise. +// GetParameterizedJob returns the ParameterizedJob field value if set, zero value otherwise (both if not set or set to explicit null). func (o *Job) GetParameterizedJob() ParameterizedJobConfig { - if o == nil || o.ParameterizedJob == nil { + if o == nil || o.ParameterizedJob.Get() == nil { var ret ParameterizedJobConfig return ret } - return *o.ParameterizedJob + return *o.ParameterizedJob.Get() } // GetParameterizedJobOk returns a tuple with the ParameterizedJob field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *Job) GetParameterizedJobOk() (*ParameterizedJobConfig, bool) { - if o == nil || o.ParameterizedJob == nil { + if o == nil { return nil, false } - return o.ParameterizedJob, true + return o.ParameterizedJob.Get(), o.ParameterizedJob.IsSet() } // HasParameterizedJob returns a boolean if a field has been set. func (o *Job) HasParameterizedJob() bool { - if o != nil && o.ParameterizedJob != nil { + if o != nil && o.ParameterizedJob.IsSet() { return true } return false } -// SetParameterizedJob gets a reference to the given ParameterizedJobConfig and assigns it to the ParameterizedJob field. +// SetParameterizedJob gets a reference to the given NullableParameterizedJobConfig and assigns it to the ParameterizedJob field. func (o *Job) SetParameterizedJob(v ParameterizedJobConfig) { - o.ParameterizedJob = &v + o.ParameterizedJob.Set(&v) +} +// SetParameterizedJobNil sets the value for ParameterizedJob to be an explicit nil +func (o *Job) SetParameterizedJobNil() { + o.ParameterizedJob.Set(nil) +} + +// UnsetParameterizedJob ensures that no value is present for ParameterizedJob, not even an explicit nil +func (o *Job) UnsetParameterizedJob() { + o.ParameterizedJob.Unset() } // GetParentID returns the ParentID field value if set, zero value otherwise. @@ -879,12 +899,12 @@ func (o *Job) GetSpreads() []Spread { var ret []Spread return ret } - return *o.Spreads + return o.Spreads } // GetSpreadsOk returns a tuple with the Spreads field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *Job) GetSpreadsOk() (*[]Spread, bool) { +func (o *Job) GetSpreadsOk() ([]Spread, bool) { if o == nil || o.Spreads == nil { return nil, false } @@ -902,7 +922,7 @@ func (o *Job) HasSpreads() bool { // SetSpreads gets a reference to the given []Spread and assigns it to the Spreads field. func (o *Job) SetSpreads(v []Spread) { - o.Spreads = &v + o.Spreads = v } // GetStable returns the Stable field value if set, zero value otherwise. @@ -1071,12 +1091,12 @@ func (o *Job) GetTaskGroups() []TaskGroup { var ret []TaskGroup return ret } - return *o.TaskGroups + return o.TaskGroups } // GetTaskGroupsOk returns a tuple with the TaskGroups field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *Job) GetTaskGroupsOk() (*[]TaskGroup, bool) { +func (o *Job) GetTaskGroupsOk() ([]TaskGroup, bool) { if o == nil || o.TaskGroups == nil { return nil, false } @@ -1094,7 +1114,7 @@ func (o *Job) HasTaskGroups() bool { // SetTaskGroups gets a reference to the given []TaskGroup and assigns it to the TaskGroups field. func (o *Job) SetTaskGroups(v []TaskGroup) { - o.TaskGroups = &v + o.TaskGroups = v } // GetType returns the Type field value if set, zero value otherwise. @@ -1301,8 +1321,8 @@ func (o Job) MarshalJSON() ([]byte, error) { if o.ModifyIndex != nil { toSerialize["ModifyIndex"] = o.ModifyIndex } - if o.Multiregion != nil { - toSerialize["Multiregion"] = o.Multiregion + if o.Multiregion.IsSet() { + toSerialize["Multiregion"] = o.Multiregion.Get() } if o.Name != nil { toSerialize["Name"] = o.Name @@ -1313,8 +1333,8 @@ func (o Job) MarshalJSON() ([]byte, error) { if o.NomadTokenID != nil { toSerialize["NomadTokenID"] = o.NomadTokenID } - if o.ParameterizedJob != nil { - toSerialize["ParameterizedJob"] = o.ParameterizedJob + if o.ParameterizedJob.IsSet() { + toSerialize["ParameterizedJob"] = o.ParameterizedJob.Get() } if o.ParentID != nil { toSerialize["ParentID"] = o.ParentID diff --git a/clients/go/v1/model_job_children_summary.go b/clients/go/v1/model_job_children_summary.go index 837a7b80..7f3c229b 100644 --- a/clients/go/v1/model_job_children_summary.go +++ b/clients/go/v1/model_job_children_summary.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_job_deregister_response.go b/clients/go/v1/model_job_deregister_response.go index 0d3cb08a..527c704d 100644 --- a/clients/go/v1/model_job_deregister_response.go +++ b/clients/go/v1/model_job_deregister_response.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_job_diff.go b/clients/go/v1/model_job_diff.go index e290f8bd..d586eb1d 100644 --- a/clients/go/v1/model_job_diff.go +++ b/clients/go/v1/model_job_diff.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,10 +17,10 @@ import ( // JobDiff struct for JobDiff type JobDiff struct { - Fields *[]FieldDiff `json:"Fields,omitempty"` + Fields []FieldDiff `json:"Fields,omitempty"` ID *string `json:"ID,omitempty"` - Objects *[]ObjectDiff `json:"Objects,omitempty"` - TaskGroups *[]TaskGroupDiff `json:"TaskGroups,omitempty"` + Objects []ObjectDiff `json:"Objects,omitempty"` + TaskGroups []TaskGroupDiff `json:"TaskGroups,omitempty"` Type *string `json:"Type,omitempty"` } @@ -47,12 +47,12 @@ func (o *JobDiff) GetFields() []FieldDiff { var ret []FieldDiff return ret } - return *o.Fields + return o.Fields } // GetFieldsOk returns a tuple with the Fields field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *JobDiff) GetFieldsOk() (*[]FieldDiff, bool) { +func (o *JobDiff) GetFieldsOk() ([]FieldDiff, bool) { if o == nil || o.Fields == nil { return nil, false } @@ -70,7 +70,7 @@ func (o *JobDiff) HasFields() bool { // SetFields gets a reference to the given []FieldDiff and assigns it to the Fields field. func (o *JobDiff) SetFields(v []FieldDiff) { - o.Fields = &v + o.Fields = v } // GetID returns the ID field value if set, zero value otherwise. @@ -111,12 +111,12 @@ func (o *JobDiff) GetObjects() []ObjectDiff { var ret []ObjectDiff return ret } - return *o.Objects + return o.Objects } // GetObjectsOk returns a tuple with the Objects field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *JobDiff) GetObjectsOk() (*[]ObjectDiff, bool) { +func (o *JobDiff) GetObjectsOk() ([]ObjectDiff, bool) { if o == nil || o.Objects == nil { return nil, false } @@ -134,7 +134,7 @@ func (o *JobDiff) HasObjects() bool { // SetObjects gets a reference to the given []ObjectDiff and assigns it to the Objects field. func (o *JobDiff) SetObjects(v []ObjectDiff) { - o.Objects = &v + o.Objects = v } // GetTaskGroups returns the TaskGroups field value if set, zero value otherwise. @@ -143,12 +143,12 @@ func (o *JobDiff) GetTaskGroups() []TaskGroupDiff { var ret []TaskGroupDiff return ret } - return *o.TaskGroups + return o.TaskGroups } // GetTaskGroupsOk returns a tuple with the TaskGroups field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *JobDiff) GetTaskGroupsOk() (*[]TaskGroupDiff, bool) { +func (o *JobDiff) GetTaskGroupsOk() ([]TaskGroupDiff, bool) { if o == nil || o.TaskGroups == nil { return nil, false } @@ -166,7 +166,7 @@ func (o *JobDiff) HasTaskGroups() bool { // SetTaskGroups gets a reference to the given []TaskGroupDiff and assigns it to the TaskGroups field. func (o *JobDiff) SetTaskGroups(v []TaskGroupDiff) { - o.TaskGroups = &v + o.TaskGroups = v } // GetType returns the Type field value if set, zero value otherwise. diff --git a/clients/go/v1/model_job_dispatch_request.go b/clients/go/v1/model_job_dispatch_request.go index be8efb5e..ec6f2e9f 100644 --- a/clients/go/v1/model_job_dispatch_request.go +++ b/clients/go/v1/model_job_dispatch_request.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_job_dispatch_response.go b/clients/go/v1/model_job_dispatch_response.go index 36015422..471c16da 100644 --- a/clients/go/v1/model_job_dispatch_response.go +++ b/clients/go/v1/model_job_dispatch_response.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_job_evaluate_request.go b/clients/go/v1/model_job_evaluate_request.go index 1f8d9424..cbbc0c73 100644 --- a/clients/go/v1/model_job_evaluate_request.go +++ b/clients/go/v1/model_job_evaluate_request.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,7 +17,7 @@ import ( // JobEvaluateRequest struct for JobEvaluateRequest type JobEvaluateRequest struct { - EvalOptions *EvalOptions `json:"EvalOptions,omitempty"` + EvalOptions NullableEvalOptions `json:"EvalOptions,omitempty"` JobID *string `json:"JobID,omitempty"` Namespace *string `json:"Namespace,omitempty"` Region *string `json:"Region,omitempty"` @@ -41,36 +41,46 @@ func NewJobEvaluateRequestWithDefaults() *JobEvaluateRequest { return &this } -// GetEvalOptions returns the EvalOptions field value if set, zero value otherwise. +// GetEvalOptions returns the EvalOptions field value if set, zero value otherwise (both if not set or set to explicit null). func (o *JobEvaluateRequest) GetEvalOptions() EvalOptions { - if o == nil || o.EvalOptions == nil { + if o == nil || o.EvalOptions.Get() == nil { var ret EvalOptions return ret } - return *o.EvalOptions + return *o.EvalOptions.Get() } // GetEvalOptionsOk returns a tuple with the EvalOptions field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *JobEvaluateRequest) GetEvalOptionsOk() (*EvalOptions, bool) { - if o == nil || o.EvalOptions == nil { + if o == nil { return nil, false } - return o.EvalOptions, true + return o.EvalOptions.Get(), o.EvalOptions.IsSet() } // HasEvalOptions returns a boolean if a field has been set. func (o *JobEvaluateRequest) HasEvalOptions() bool { - if o != nil && o.EvalOptions != nil { + if o != nil && o.EvalOptions.IsSet() { return true } return false } -// SetEvalOptions gets a reference to the given EvalOptions and assigns it to the EvalOptions field. +// SetEvalOptions gets a reference to the given NullableEvalOptions and assigns it to the EvalOptions field. func (o *JobEvaluateRequest) SetEvalOptions(v EvalOptions) { - o.EvalOptions = &v + o.EvalOptions.Set(&v) +} +// SetEvalOptionsNil sets the value for EvalOptions to be an explicit nil +func (o *JobEvaluateRequest) SetEvalOptionsNil() { + o.EvalOptions.Set(nil) +} + +// UnsetEvalOptions ensures that no value is present for EvalOptions, not even an explicit nil +func (o *JobEvaluateRequest) UnsetEvalOptions() { + o.EvalOptions.Unset() } // GetJobID returns the JobID field value if set, zero value otherwise. @@ -203,8 +213,8 @@ func (o *JobEvaluateRequest) SetSecretID(v string) { func (o JobEvaluateRequest) MarshalJSON() ([]byte, error) { toSerialize := map[string]interface{}{} - if o.EvalOptions != nil { - toSerialize["EvalOptions"] = o.EvalOptions + if o.EvalOptions.IsSet() { + toSerialize["EvalOptions"] = o.EvalOptions.Get() } if o.JobID != nil { toSerialize["JobID"] = o.JobID diff --git a/clients/go/v1/model_job_list_stub.go b/clients/go/v1/model_job_list_stub.go index b513c7e9..89df32f0 100644 --- a/clients/go/v1/model_job_list_stub.go +++ b/clients/go/v1/model_job_list_stub.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -18,10 +18,10 @@ import ( // JobListStub struct for JobListStub type JobListStub struct { CreateIndex *int32 `json:"CreateIndex,omitempty"` - Datacenters *[]string `json:"Datacenters,omitempty"` + Datacenters []string `json:"Datacenters,omitempty"` ID *string `json:"ID,omitempty"` JobModifyIndex *int32 `json:"JobModifyIndex,omitempty"` - JobSummary *JobSummary `json:"JobSummary,omitempty"` + JobSummary NullableJobSummary `json:"JobSummary,omitempty"` ModifyIndex *int32 `json:"ModifyIndex,omitempty"` Name *string `json:"Name,omitempty"` Namespace *string `json:"Namespace,omitempty"` @@ -91,12 +91,12 @@ func (o *JobListStub) GetDatacenters() []string { var ret []string return ret } - return *o.Datacenters + return o.Datacenters } // GetDatacentersOk returns a tuple with the Datacenters field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *JobListStub) GetDatacentersOk() (*[]string, bool) { +func (o *JobListStub) GetDatacentersOk() ([]string, bool) { if o == nil || o.Datacenters == nil { return nil, false } @@ -114,7 +114,7 @@ func (o *JobListStub) HasDatacenters() bool { // SetDatacenters gets a reference to the given []string and assigns it to the Datacenters field. func (o *JobListStub) SetDatacenters(v []string) { - o.Datacenters = &v + o.Datacenters = v } // GetID returns the ID field value if set, zero value otherwise. @@ -181,36 +181,46 @@ func (o *JobListStub) SetJobModifyIndex(v int32) { o.JobModifyIndex = &v } -// GetJobSummary returns the JobSummary field value if set, zero value otherwise. +// GetJobSummary returns the JobSummary field value if set, zero value otherwise (both if not set or set to explicit null). func (o *JobListStub) GetJobSummary() JobSummary { - if o == nil || o.JobSummary == nil { + if o == nil || o.JobSummary.Get() == nil { var ret JobSummary return ret } - return *o.JobSummary + return *o.JobSummary.Get() } // GetJobSummaryOk returns a tuple with the JobSummary field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *JobListStub) GetJobSummaryOk() (*JobSummary, bool) { - if o == nil || o.JobSummary == nil { + if o == nil { return nil, false } - return o.JobSummary, true + return o.JobSummary.Get(), o.JobSummary.IsSet() } // HasJobSummary returns a boolean if a field has been set. func (o *JobListStub) HasJobSummary() bool { - if o != nil && o.JobSummary != nil { + if o != nil && o.JobSummary.IsSet() { return true } return false } -// SetJobSummary gets a reference to the given JobSummary and assigns it to the JobSummary field. +// SetJobSummary gets a reference to the given NullableJobSummary and assigns it to the JobSummary field. func (o *JobListStub) SetJobSummary(v JobSummary) { - o.JobSummary = &v + o.JobSummary.Set(&v) +} +// SetJobSummaryNil sets the value for JobSummary to be an explicit nil +func (o *JobListStub) SetJobSummaryNil() { + o.JobSummary.Set(nil) +} + +// UnsetJobSummary ensures that no value is present for JobSummary, not even an explicit nil +func (o *JobListStub) UnsetJobSummary() { + o.JobSummary.Unset() } // GetModifyIndex returns the ModifyIndex field value if set, zero value otherwise. @@ -611,8 +621,8 @@ func (o JobListStub) MarshalJSON() ([]byte, error) { if o.JobModifyIndex != nil { toSerialize["JobModifyIndex"] = o.JobModifyIndex } - if o.JobSummary != nil { - toSerialize["JobSummary"] = o.JobSummary + if o.JobSummary.IsSet() { + toSerialize["JobSummary"] = o.JobSummary.Get() } if o.ModifyIndex != nil { toSerialize["ModifyIndex"] = o.ModifyIndex diff --git a/clients/go/v1/model_job_plan_request.go b/clients/go/v1/model_job_plan_request.go index f8a89e83..49889f9a 100644 --- a/clients/go/v1/model_job_plan_request.go +++ b/clients/go/v1/model_job_plan_request.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -18,7 +18,7 @@ import ( // JobPlanRequest struct for JobPlanRequest type JobPlanRequest struct { Diff *bool `json:"Diff,omitempty"` - Job *Job `json:"Job,omitempty"` + Job NullableJob `json:"Job,omitempty"` Namespace *string `json:"Namespace,omitempty"` PolicyOverride *bool `json:"PolicyOverride,omitempty"` Region *string `json:"Region,omitempty"` @@ -74,36 +74,46 @@ func (o *JobPlanRequest) SetDiff(v bool) { o.Diff = &v } -// GetJob returns the Job field value if set, zero value otherwise. +// GetJob returns the Job field value if set, zero value otherwise (both if not set or set to explicit null). func (o *JobPlanRequest) GetJob() Job { - if o == nil || o.Job == nil { + if o == nil || o.Job.Get() == nil { var ret Job return ret } - return *o.Job + return *o.Job.Get() } // GetJobOk returns a tuple with the Job field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *JobPlanRequest) GetJobOk() (*Job, bool) { - if o == nil || o.Job == nil { + if o == nil { return nil, false } - return o.Job, true + return o.Job.Get(), o.Job.IsSet() } // HasJob returns a boolean if a field has been set. func (o *JobPlanRequest) HasJob() bool { - if o != nil && o.Job != nil { + if o != nil && o.Job.IsSet() { return true } return false } -// SetJob gets a reference to the given Job and assigns it to the Job field. +// SetJob gets a reference to the given NullableJob and assigns it to the Job field. func (o *JobPlanRequest) SetJob(v Job) { - o.Job = &v + o.Job.Set(&v) +} +// SetJobNil sets the value for Job to be an explicit nil +func (o *JobPlanRequest) SetJobNil() { + o.Job.Set(nil) +} + +// UnsetJob ensures that no value is present for Job, not even an explicit nil +func (o *JobPlanRequest) UnsetJob() { + o.Job.Unset() } // GetNamespace returns the Namespace field value if set, zero value otherwise. @@ -239,8 +249,8 @@ func (o JobPlanRequest) MarshalJSON() ([]byte, error) { if o.Diff != nil { toSerialize["Diff"] = o.Diff } - if o.Job != nil { - toSerialize["Job"] = o.Job + if o.Job.IsSet() { + toSerialize["Job"] = o.Job.Get() } if o.Namespace != nil { toSerialize["Namespace"] = o.Namespace diff --git a/clients/go/v1/model_job_plan_response.go b/clients/go/v1/model_job_plan_response.go index 7a372d72..260e068d 100644 --- a/clients/go/v1/model_job_plan_response.go +++ b/clients/go/v1/model_job_plan_response.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -18,12 +18,12 @@ import ( // JobPlanResponse struct for JobPlanResponse type JobPlanResponse struct { - Annotations *PlanAnnotations `json:"Annotations,omitempty"` - CreatedEvals *[]Evaluation `json:"CreatedEvals,omitempty"` - Diff *JobDiff `json:"Diff,omitempty"` + Annotations NullablePlanAnnotations `json:"Annotations,omitempty"` + CreatedEvals []Evaluation `json:"CreatedEvals,omitempty"` + Diff NullableJobDiff `json:"Diff,omitempty"` FailedTGAllocs *map[string]AllocationMetric `json:"FailedTGAllocs,omitempty"` JobModifyIndex *int32 `json:"JobModifyIndex,omitempty"` - NextPeriodicLaunch *time.Time `json:"NextPeriodicLaunch,omitempty"` + NextPeriodicLaunch NullableTime `json:"NextPeriodicLaunch,omitempty"` Warnings *string `json:"Warnings,omitempty"` } @@ -44,36 +44,46 @@ func NewJobPlanResponseWithDefaults() *JobPlanResponse { return &this } -// GetAnnotations returns the Annotations field value if set, zero value otherwise. +// GetAnnotations returns the Annotations field value if set, zero value otherwise (both if not set or set to explicit null). func (o *JobPlanResponse) GetAnnotations() PlanAnnotations { - if o == nil || o.Annotations == nil { + if o == nil || o.Annotations.Get() == nil { var ret PlanAnnotations return ret } - return *o.Annotations + return *o.Annotations.Get() } // GetAnnotationsOk returns a tuple with the Annotations field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *JobPlanResponse) GetAnnotationsOk() (*PlanAnnotations, bool) { - if o == nil || o.Annotations == nil { + if o == nil { return nil, false } - return o.Annotations, true + return o.Annotations.Get(), o.Annotations.IsSet() } // HasAnnotations returns a boolean if a field has been set. func (o *JobPlanResponse) HasAnnotations() bool { - if o != nil && o.Annotations != nil { + if o != nil && o.Annotations.IsSet() { return true } return false } -// SetAnnotations gets a reference to the given PlanAnnotations and assigns it to the Annotations field. +// SetAnnotations gets a reference to the given NullablePlanAnnotations and assigns it to the Annotations field. func (o *JobPlanResponse) SetAnnotations(v PlanAnnotations) { - o.Annotations = &v + o.Annotations.Set(&v) +} +// SetAnnotationsNil sets the value for Annotations to be an explicit nil +func (o *JobPlanResponse) SetAnnotationsNil() { + o.Annotations.Set(nil) +} + +// UnsetAnnotations ensures that no value is present for Annotations, not even an explicit nil +func (o *JobPlanResponse) UnsetAnnotations() { + o.Annotations.Unset() } // GetCreatedEvals returns the CreatedEvals field value if set, zero value otherwise. @@ -82,12 +92,12 @@ func (o *JobPlanResponse) GetCreatedEvals() []Evaluation { var ret []Evaluation return ret } - return *o.CreatedEvals + return o.CreatedEvals } // GetCreatedEvalsOk returns a tuple with the CreatedEvals field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *JobPlanResponse) GetCreatedEvalsOk() (*[]Evaluation, bool) { +func (o *JobPlanResponse) GetCreatedEvalsOk() ([]Evaluation, bool) { if o == nil || o.CreatedEvals == nil { return nil, false } @@ -105,39 +115,49 @@ func (o *JobPlanResponse) HasCreatedEvals() bool { // SetCreatedEvals gets a reference to the given []Evaluation and assigns it to the CreatedEvals field. func (o *JobPlanResponse) SetCreatedEvals(v []Evaluation) { - o.CreatedEvals = &v + o.CreatedEvals = v } -// GetDiff returns the Diff field value if set, zero value otherwise. +// GetDiff returns the Diff field value if set, zero value otherwise (both if not set or set to explicit null). func (o *JobPlanResponse) GetDiff() JobDiff { - if o == nil || o.Diff == nil { + if o == nil || o.Diff.Get() == nil { var ret JobDiff return ret } - return *o.Diff + return *o.Diff.Get() } // GetDiffOk returns a tuple with the Diff field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *JobPlanResponse) GetDiffOk() (*JobDiff, bool) { - if o == nil || o.Diff == nil { + if o == nil { return nil, false } - return o.Diff, true + return o.Diff.Get(), o.Diff.IsSet() } // HasDiff returns a boolean if a field has been set. func (o *JobPlanResponse) HasDiff() bool { - if o != nil && o.Diff != nil { + if o != nil && o.Diff.IsSet() { return true } return false } -// SetDiff gets a reference to the given JobDiff and assigns it to the Diff field. +// SetDiff gets a reference to the given NullableJobDiff and assigns it to the Diff field. func (o *JobPlanResponse) SetDiff(v JobDiff) { - o.Diff = &v + o.Diff.Set(&v) +} +// SetDiffNil sets the value for Diff to be an explicit nil +func (o *JobPlanResponse) SetDiffNil() { + o.Diff.Set(nil) +} + +// UnsetDiff ensures that no value is present for Diff, not even an explicit nil +func (o *JobPlanResponse) UnsetDiff() { + o.Diff.Unset() } // GetFailedTGAllocs returns the FailedTGAllocs field value if set, zero value otherwise. @@ -204,36 +224,46 @@ func (o *JobPlanResponse) SetJobModifyIndex(v int32) { o.JobModifyIndex = &v } -// GetNextPeriodicLaunch returns the NextPeriodicLaunch field value if set, zero value otherwise. +// GetNextPeriodicLaunch returns the NextPeriodicLaunch field value if set, zero value otherwise (both if not set or set to explicit null). func (o *JobPlanResponse) GetNextPeriodicLaunch() time.Time { - if o == nil || o.NextPeriodicLaunch == nil { + if o == nil || o.NextPeriodicLaunch.Get() == nil { var ret time.Time return ret } - return *o.NextPeriodicLaunch + return *o.NextPeriodicLaunch.Get() } // GetNextPeriodicLaunchOk returns a tuple with the NextPeriodicLaunch field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *JobPlanResponse) GetNextPeriodicLaunchOk() (*time.Time, bool) { - if o == nil || o.NextPeriodicLaunch == nil { + if o == nil { return nil, false } - return o.NextPeriodicLaunch, true + return o.NextPeriodicLaunch.Get(), o.NextPeriodicLaunch.IsSet() } // HasNextPeriodicLaunch returns a boolean if a field has been set. func (o *JobPlanResponse) HasNextPeriodicLaunch() bool { - if o != nil && o.NextPeriodicLaunch != nil { + if o != nil && o.NextPeriodicLaunch.IsSet() { return true } return false } -// SetNextPeriodicLaunch gets a reference to the given time.Time and assigns it to the NextPeriodicLaunch field. +// SetNextPeriodicLaunch gets a reference to the given NullableTime and assigns it to the NextPeriodicLaunch field. func (o *JobPlanResponse) SetNextPeriodicLaunch(v time.Time) { - o.NextPeriodicLaunch = &v + o.NextPeriodicLaunch.Set(&v) +} +// SetNextPeriodicLaunchNil sets the value for NextPeriodicLaunch to be an explicit nil +func (o *JobPlanResponse) SetNextPeriodicLaunchNil() { + o.NextPeriodicLaunch.Set(nil) +} + +// UnsetNextPeriodicLaunch ensures that no value is present for NextPeriodicLaunch, not even an explicit nil +func (o *JobPlanResponse) UnsetNextPeriodicLaunch() { + o.NextPeriodicLaunch.Unset() } // GetWarnings returns the Warnings field value if set, zero value otherwise. @@ -270,14 +300,14 @@ func (o *JobPlanResponse) SetWarnings(v string) { func (o JobPlanResponse) MarshalJSON() ([]byte, error) { toSerialize := map[string]interface{}{} - if o.Annotations != nil { - toSerialize["Annotations"] = o.Annotations + if o.Annotations.IsSet() { + toSerialize["Annotations"] = o.Annotations.Get() } if o.CreatedEvals != nil { toSerialize["CreatedEvals"] = o.CreatedEvals } - if o.Diff != nil { - toSerialize["Diff"] = o.Diff + if o.Diff.IsSet() { + toSerialize["Diff"] = o.Diff.Get() } if o.FailedTGAllocs != nil { toSerialize["FailedTGAllocs"] = o.FailedTGAllocs @@ -285,8 +315,8 @@ func (o JobPlanResponse) MarshalJSON() ([]byte, error) { if o.JobModifyIndex != nil { toSerialize["JobModifyIndex"] = o.JobModifyIndex } - if o.NextPeriodicLaunch != nil { - toSerialize["NextPeriodicLaunch"] = o.NextPeriodicLaunch + if o.NextPeriodicLaunch.IsSet() { + toSerialize["NextPeriodicLaunch"] = o.NextPeriodicLaunch.Get() } if o.Warnings != nil { toSerialize["Warnings"] = o.Warnings diff --git a/clients/go/v1/model_job_register_request.go b/clients/go/v1/model_job_register_request.go index 795859e3..25cf146e 100644 --- a/clients/go/v1/model_job_register_request.go +++ b/clients/go/v1/model_job_register_request.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -19,7 +19,7 @@ import ( type JobRegisterRequest struct { EnforceIndex *bool `json:"EnforceIndex,omitempty"` EvalPriority *int32 `json:"EvalPriority,omitempty"` - Job *Job `json:"Job,omitempty"` + Job NullableJob `json:"Job,omitempty"` JobModifyIndex *int32 `json:"JobModifyIndex,omitempty"` Namespace *string `json:"Namespace,omitempty"` PolicyOverride *bool `json:"PolicyOverride,omitempty"` @@ -109,36 +109,46 @@ func (o *JobRegisterRequest) SetEvalPriority(v int32) { o.EvalPriority = &v } -// GetJob returns the Job field value if set, zero value otherwise. +// GetJob returns the Job field value if set, zero value otherwise (both if not set or set to explicit null). func (o *JobRegisterRequest) GetJob() Job { - if o == nil || o.Job == nil { + if o == nil || o.Job.Get() == nil { var ret Job return ret } - return *o.Job + return *o.Job.Get() } // GetJobOk returns a tuple with the Job field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *JobRegisterRequest) GetJobOk() (*Job, bool) { - if o == nil || o.Job == nil { + if o == nil { return nil, false } - return o.Job, true + return o.Job.Get(), o.Job.IsSet() } // HasJob returns a boolean if a field has been set. func (o *JobRegisterRequest) HasJob() bool { - if o != nil && o.Job != nil { + if o != nil && o.Job.IsSet() { return true } return false } -// SetJob gets a reference to the given Job and assigns it to the Job field. +// SetJob gets a reference to the given NullableJob and assigns it to the Job field. func (o *JobRegisterRequest) SetJob(v Job) { - o.Job = &v + o.Job.Set(&v) +} +// SetJobNil sets the value for Job to be an explicit nil +func (o *JobRegisterRequest) SetJobNil() { + o.Job.Set(nil) +} + +// UnsetJob ensures that no value is present for Job, not even an explicit nil +func (o *JobRegisterRequest) UnsetJob() { + o.Job.Unset() } // GetJobModifyIndex returns the JobModifyIndex field value if set, zero value otherwise. @@ -341,8 +351,8 @@ func (o JobRegisterRequest) MarshalJSON() ([]byte, error) { if o.EvalPriority != nil { toSerialize["EvalPriority"] = o.EvalPriority } - if o.Job != nil { - toSerialize["Job"] = o.Job + if o.Job.IsSet() { + toSerialize["Job"] = o.Job.Get() } if o.JobModifyIndex != nil { toSerialize["JobModifyIndex"] = o.JobModifyIndex diff --git a/clients/go/v1/model_job_register_response.go b/clients/go/v1/model_job_register_response.go index ee1c079d..41d16853 100644 --- a/clients/go/v1/model_job_register_response.go +++ b/clients/go/v1/model_job_register_response.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_job_revert_request.go b/clients/go/v1/model_job_revert_request.go index 0cc5921a..20fae70c 100644 --- a/clients/go/v1/model_job_revert_request.go +++ b/clients/go/v1/model_job_revert_request.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_job_scale_status_response.go b/clients/go/v1/model_job_scale_status_response.go index 160315fe..08aaef4f 100644 --- a/clients/go/v1/model_job_scale_status_response.go +++ b/clients/go/v1/model_job_scale_status_response.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_job_stability_request.go b/clients/go/v1/model_job_stability_request.go index 661684d5..93527a1b 100644 --- a/clients/go/v1/model_job_stability_request.go +++ b/clients/go/v1/model_job_stability_request.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_job_stability_response.go b/clients/go/v1/model_job_stability_response.go index 3471a6c9..32b9e609 100644 --- a/clients/go/v1/model_job_stability_response.go +++ b/clients/go/v1/model_job_stability_response.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_job_summary.go b/clients/go/v1/model_job_summary.go index c2359d2a..38799c95 100644 --- a/clients/go/v1/model_job_summary.go +++ b/clients/go/v1/model_job_summary.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,7 +17,7 @@ import ( // JobSummary struct for JobSummary type JobSummary struct { - Children *JobChildrenSummary `json:"Children,omitempty"` + Children NullableJobChildrenSummary `json:"Children,omitempty"` CreateIndex *int32 `json:"CreateIndex,omitempty"` JobID *string `json:"JobID,omitempty"` ModifyIndex *int32 `json:"ModifyIndex,omitempty"` @@ -42,36 +42,46 @@ func NewJobSummaryWithDefaults() *JobSummary { return &this } -// GetChildren returns the Children field value if set, zero value otherwise. +// GetChildren returns the Children field value if set, zero value otherwise (both if not set or set to explicit null). func (o *JobSummary) GetChildren() JobChildrenSummary { - if o == nil || o.Children == nil { + if o == nil || o.Children.Get() == nil { var ret JobChildrenSummary return ret } - return *o.Children + return *o.Children.Get() } // GetChildrenOk returns a tuple with the Children field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *JobSummary) GetChildrenOk() (*JobChildrenSummary, bool) { - if o == nil || o.Children == nil { + if o == nil { return nil, false } - return o.Children, true + return o.Children.Get(), o.Children.IsSet() } // HasChildren returns a boolean if a field has been set. func (o *JobSummary) HasChildren() bool { - if o != nil && o.Children != nil { + if o != nil && o.Children.IsSet() { return true } return false } -// SetChildren gets a reference to the given JobChildrenSummary and assigns it to the Children field. +// SetChildren gets a reference to the given NullableJobChildrenSummary and assigns it to the Children field. func (o *JobSummary) SetChildren(v JobChildrenSummary) { - o.Children = &v + o.Children.Set(&v) +} +// SetChildrenNil sets the value for Children to be an explicit nil +func (o *JobSummary) SetChildrenNil() { + o.Children.Set(nil) +} + +// UnsetChildren ensures that no value is present for Children, not even an explicit nil +func (o *JobSummary) UnsetChildren() { + o.Children.Unset() } // GetCreateIndex returns the CreateIndex field value if set, zero value otherwise. @@ -236,8 +246,8 @@ func (o *JobSummary) SetSummary(v map[string]TaskGroupSummary) { func (o JobSummary) MarshalJSON() ([]byte, error) { toSerialize := map[string]interface{}{} - if o.Children != nil { - toSerialize["Children"] = o.Children + if o.Children.IsSet() { + toSerialize["Children"] = o.Children.Get() } if o.CreateIndex != nil { toSerialize["CreateIndex"] = o.CreateIndex diff --git a/clients/go/v1/model_job_validate_request.go b/clients/go/v1/model_job_validate_request.go index 68272972..9a872e81 100644 --- a/clients/go/v1/model_job_validate_request.go +++ b/clients/go/v1/model_job_validate_request.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,7 +17,7 @@ import ( // JobValidateRequest struct for JobValidateRequest type JobValidateRequest struct { - Job *Job `json:"Job,omitempty"` + Job NullableJob `json:"Job,omitempty"` Namespace *string `json:"Namespace,omitempty"` Region *string `json:"Region,omitempty"` SecretID *string `json:"SecretID,omitempty"` @@ -40,36 +40,46 @@ func NewJobValidateRequestWithDefaults() *JobValidateRequest { return &this } -// GetJob returns the Job field value if set, zero value otherwise. +// GetJob returns the Job field value if set, zero value otherwise (both if not set or set to explicit null). func (o *JobValidateRequest) GetJob() Job { - if o == nil || o.Job == nil { + if o == nil || o.Job.Get() == nil { var ret Job return ret } - return *o.Job + return *o.Job.Get() } // GetJobOk returns a tuple with the Job field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *JobValidateRequest) GetJobOk() (*Job, bool) { - if o == nil || o.Job == nil { + if o == nil { return nil, false } - return o.Job, true + return o.Job.Get(), o.Job.IsSet() } // HasJob returns a boolean if a field has been set. func (o *JobValidateRequest) HasJob() bool { - if o != nil && o.Job != nil { + if o != nil && o.Job.IsSet() { return true } return false } -// SetJob gets a reference to the given Job and assigns it to the Job field. +// SetJob gets a reference to the given NullableJob and assigns it to the Job field. func (o *JobValidateRequest) SetJob(v Job) { - o.Job = &v + o.Job.Set(&v) +} +// SetJobNil sets the value for Job to be an explicit nil +func (o *JobValidateRequest) SetJobNil() { + o.Job.Set(nil) +} + +// UnsetJob ensures that no value is present for Job, not even an explicit nil +func (o *JobValidateRequest) UnsetJob() { + o.Job.Unset() } // GetNamespace returns the Namespace field value if set, zero value otherwise. @@ -170,8 +180,8 @@ func (o *JobValidateRequest) SetSecretID(v string) { func (o JobValidateRequest) MarshalJSON() ([]byte, error) { toSerialize := map[string]interface{}{} - if o.Job != nil { - toSerialize["Job"] = o.Job + if o.Job.IsSet() { + toSerialize["Job"] = o.Job.Get() } if o.Namespace != nil { toSerialize["Namespace"] = o.Namespace diff --git a/clients/go/v1/model_job_validate_response.go b/clients/go/v1/model_job_validate_response.go index 2fe330b0..1ac76d9e 100644 --- a/clients/go/v1/model_job_validate_response.go +++ b/clients/go/v1/model_job_validate_response.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -19,7 +19,7 @@ import ( type JobValidateResponse struct { DriverConfigValidated *bool `json:"DriverConfigValidated,omitempty"` Error *string `json:"Error,omitempty"` - ValidationErrors *[]string `json:"ValidationErrors,omitempty"` + ValidationErrors []string `json:"ValidationErrors,omitempty"` Warnings *string `json:"Warnings,omitempty"` } @@ -110,12 +110,12 @@ func (o *JobValidateResponse) GetValidationErrors() []string { var ret []string return ret } - return *o.ValidationErrors + return o.ValidationErrors } // GetValidationErrorsOk returns a tuple with the ValidationErrors field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *JobValidateResponse) GetValidationErrorsOk() (*[]string, bool) { +func (o *JobValidateResponse) GetValidationErrorsOk() ([]string, bool) { if o == nil || o.ValidationErrors == nil { return nil, false } @@ -133,7 +133,7 @@ func (o *JobValidateResponse) HasValidationErrors() bool { // SetValidationErrors gets a reference to the given []string and assigns it to the ValidationErrors field. func (o *JobValidateResponse) SetValidationErrors(v []string) { - o.ValidationErrors = &v + o.ValidationErrors = v } // GetWarnings returns the Warnings field value if set, zero value otherwise. diff --git a/clients/go/v1/model_job_versions_response.go b/clients/go/v1/model_job_versions_response.go index f3d2fb98..b8591e0b 100644 --- a/clients/go/v1/model_job_versions_response.go +++ b/clients/go/v1/model_job_versions_response.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,13 +17,13 @@ import ( // JobVersionsResponse struct for JobVersionsResponse type JobVersionsResponse struct { - Diffs *[]JobDiff `json:"Diffs,omitempty"` + Diffs []JobDiff `json:"Diffs,omitempty"` KnownLeader *bool `json:"KnownLeader,omitempty"` LastContact *int64 `json:"LastContact,omitempty"` LastIndex *int32 `json:"LastIndex,omitempty"` NextToken *string `json:"NextToken,omitempty"` RequestTime *int64 `json:"RequestTime,omitempty"` - Versions *[]Job `json:"Versions,omitempty"` + Versions []Job `json:"Versions,omitempty"` } // NewJobVersionsResponse instantiates a new JobVersionsResponse object @@ -49,12 +49,12 @@ func (o *JobVersionsResponse) GetDiffs() []JobDiff { var ret []JobDiff return ret } - return *o.Diffs + return o.Diffs } // GetDiffsOk returns a tuple with the Diffs field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *JobVersionsResponse) GetDiffsOk() (*[]JobDiff, bool) { +func (o *JobVersionsResponse) GetDiffsOk() ([]JobDiff, bool) { if o == nil || o.Diffs == nil { return nil, false } @@ -72,7 +72,7 @@ func (o *JobVersionsResponse) HasDiffs() bool { // SetDiffs gets a reference to the given []JobDiff and assigns it to the Diffs field. func (o *JobVersionsResponse) SetDiffs(v []JobDiff) { - o.Diffs = &v + o.Diffs = v } // GetKnownLeader returns the KnownLeader field value if set, zero value otherwise. @@ -241,12 +241,12 @@ func (o *JobVersionsResponse) GetVersions() []Job { var ret []Job return ret } - return *o.Versions + return o.Versions } // GetVersionsOk returns a tuple with the Versions field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *JobVersionsResponse) GetVersionsOk() (*[]Job, bool) { +func (o *JobVersionsResponse) GetVersionsOk() ([]Job, bool) { if o == nil || o.Versions == nil { return nil, false } @@ -264,7 +264,7 @@ func (o *JobVersionsResponse) HasVersions() bool { // SetVersions gets a reference to the given []Job and assigns it to the Versions field. func (o *JobVersionsResponse) SetVersions(v []Job) { - o.Versions = &v + o.Versions = v } func (o JobVersionsResponse) MarshalJSON() ([]byte, error) { diff --git a/clients/go/v1/model_jobs_parse_request.go b/clients/go/v1/model_jobs_parse_request.go index e38637bf..4b305f57 100644 --- a/clients/go/v1/model_jobs_parse_request.go +++ b/clients/go/v1/model_jobs_parse_request.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_log_config.go b/clients/go/v1/model_log_config.go index 66dc3868..222ceab4 100644 --- a/clients/go/v1/model_log_config.go +++ b/clients/go/v1/model_log_config.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_metrics_summary.go b/clients/go/v1/model_metrics_summary.go index dea99a38..26536bdf 100644 --- a/clients/go/v1/model_metrics_summary.go +++ b/clients/go/v1/model_metrics_summary.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,10 +17,10 @@ import ( // MetricsSummary struct for MetricsSummary type MetricsSummary struct { - Counters *[]SampledValue `json:"Counters,omitempty"` - Gauges *[]GaugeValue `json:"Gauges,omitempty"` - Points *[]PointValue `json:"Points,omitempty"` - Samples *[]SampledValue `json:"Samples,omitempty"` + Counters []SampledValue `json:"Counters,omitempty"` + Gauges []GaugeValue `json:"Gauges,omitempty"` + Points []PointValue `json:"Points,omitempty"` + Samples []SampledValue `json:"Samples,omitempty"` Timestamp *string `json:"Timestamp,omitempty"` } @@ -47,12 +47,12 @@ func (o *MetricsSummary) GetCounters() []SampledValue { var ret []SampledValue return ret } - return *o.Counters + return o.Counters } // GetCountersOk returns a tuple with the Counters field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *MetricsSummary) GetCountersOk() (*[]SampledValue, bool) { +func (o *MetricsSummary) GetCountersOk() ([]SampledValue, bool) { if o == nil || o.Counters == nil { return nil, false } @@ -70,7 +70,7 @@ func (o *MetricsSummary) HasCounters() bool { // SetCounters gets a reference to the given []SampledValue and assigns it to the Counters field. func (o *MetricsSummary) SetCounters(v []SampledValue) { - o.Counters = &v + o.Counters = v } // GetGauges returns the Gauges field value if set, zero value otherwise. @@ -79,12 +79,12 @@ func (o *MetricsSummary) GetGauges() []GaugeValue { var ret []GaugeValue return ret } - return *o.Gauges + return o.Gauges } // GetGaugesOk returns a tuple with the Gauges field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *MetricsSummary) GetGaugesOk() (*[]GaugeValue, bool) { +func (o *MetricsSummary) GetGaugesOk() ([]GaugeValue, bool) { if o == nil || o.Gauges == nil { return nil, false } @@ -102,7 +102,7 @@ func (o *MetricsSummary) HasGauges() bool { // SetGauges gets a reference to the given []GaugeValue and assigns it to the Gauges field. func (o *MetricsSummary) SetGauges(v []GaugeValue) { - o.Gauges = &v + o.Gauges = v } // GetPoints returns the Points field value if set, zero value otherwise. @@ -111,12 +111,12 @@ func (o *MetricsSummary) GetPoints() []PointValue { var ret []PointValue return ret } - return *o.Points + return o.Points } // GetPointsOk returns a tuple with the Points field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *MetricsSummary) GetPointsOk() (*[]PointValue, bool) { +func (o *MetricsSummary) GetPointsOk() ([]PointValue, bool) { if o == nil || o.Points == nil { return nil, false } @@ -134,7 +134,7 @@ func (o *MetricsSummary) HasPoints() bool { // SetPoints gets a reference to the given []PointValue and assigns it to the Points field. func (o *MetricsSummary) SetPoints(v []PointValue) { - o.Points = &v + o.Points = v } // GetSamples returns the Samples field value if set, zero value otherwise. @@ -143,12 +143,12 @@ func (o *MetricsSummary) GetSamples() []SampledValue { var ret []SampledValue return ret } - return *o.Samples + return o.Samples } // GetSamplesOk returns a tuple with the Samples field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *MetricsSummary) GetSamplesOk() (*[]SampledValue, bool) { +func (o *MetricsSummary) GetSamplesOk() ([]SampledValue, bool) { if o == nil || o.Samples == nil { return nil, false } @@ -166,7 +166,7 @@ func (o *MetricsSummary) HasSamples() bool { // SetSamples gets a reference to the given []SampledValue and assigns it to the Samples field. func (o *MetricsSummary) SetSamples(v []SampledValue) { - o.Samples = &v + o.Samples = v } // GetTimestamp returns the Timestamp field value if set, zero value otherwise. diff --git a/clients/go/v1/model_migrate_strategy.go b/clients/go/v1/model_migrate_strategy.go index 8cc2272d..2ddc5bf2 100644 --- a/clients/go/v1/model_migrate_strategy.go +++ b/clients/go/v1/model_migrate_strategy.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_multiregion.go b/clients/go/v1/model_multiregion.go index edf9a2fe..1d1b5972 100644 --- a/clients/go/v1/model_multiregion.go +++ b/clients/go/v1/model_multiregion.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,7 +17,7 @@ import ( // Multiregion struct for Multiregion type Multiregion struct { - Regions *[]MultiregionRegion `json:"Regions,omitempty"` + Regions []MultiregionRegion `json:"Regions,omitempty"` Strategy *MultiregionStrategy `json:"Strategy,omitempty"` } @@ -44,12 +44,12 @@ func (o *Multiregion) GetRegions() []MultiregionRegion { var ret []MultiregionRegion return ret } - return *o.Regions + return o.Regions } // GetRegionsOk returns a tuple with the Regions field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *Multiregion) GetRegionsOk() (*[]MultiregionRegion, bool) { +func (o *Multiregion) GetRegionsOk() ([]MultiregionRegion, bool) { if o == nil || o.Regions == nil { return nil, false } @@ -67,7 +67,7 @@ func (o *Multiregion) HasRegions() bool { // SetRegions gets a reference to the given []MultiregionRegion and assigns it to the Regions field. func (o *Multiregion) SetRegions(v []MultiregionRegion) { - o.Regions = &v + o.Regions = v } // GetStrategy returns the Strategy field value if set, zero value otherwise. diff --git a/clients/go/v1/model_multiregion_region.go b/clients/go/v1/model_multiregion_region.go index 76608016..231c5fe4 100644 --- a/clients/go/v1/model_multiregion_region.go +++ b/clients/go/v1/model_multiregion_region.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -18,7 +18,7 @@ import ( // MultiregionRegion struct for MultiregionRegion type MultiregionRegion struct { Count *int32 `json:"Count,omitempty"` - Datacenters *[]string `json:"Datacenters,omitempty"` + Datacenters []string `json:"Datacenters,omitempty"` Meta *map[string]string `json:"Meta,omitempty"` Name *string `json:"Name,omitempty"` } @@ -78,12 +78,12 @@ func (o *MultiregionRegion) GetDatacenters() []string { var ret []string return ret } - return *o.Datacenters + return o.Datacenters } // GetDatacentersOk returns a tuple with the Datacenters field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *MultiregionRegion) GetDatacentersOk() (*[]string, bool) { +func (o *MultiregionRegion) GetDatacentersOk() ([]string, bool) { if o == nil || o.Datacenters == nil { return nil, false } @@ -101,7 +101,7 @@ func (o *MultiregionRegion) HasDatacenters() bool { // SetDatacenters gets a reference to the given []string and assigns it to the Datacenters field. func (o *MultiregionRegion) SetDatacenters(v []string) { - o.Datacenters = &v + o.Datacenters = v } // GetMeta returns the Meta field value if set, zero value otherwise. diff --git a/clients/go/v1/model_multiregion_strategy.go b/clients/go/v1/model_multiregion_strategy.go index e77c552c..f6b499ee 100644 --- a/clients/go/v1/model_multiregion_strategy.go +++ b/clients/go/v1/model_multiregion_strategy.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_namespace.go b/clients/go/v1/model_namespace.go index d15a9c14..1dd7b485 100644 --- a/clients/go/v1/model_namespace.go +++ b/clients/go/v1/model_namespace.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,7 +17,7 @@ import ( // Namespace struct for Namespace type Namespace struct { - Capabilities *NamespaceCapabilities `json:"Capabilities,omitempty"` + Capabilities NullableNamespaceCapabilities `json:"Capabilities,omitempty"` CreateIndex *int32 `json:"CreateIndex,omitempty"` Description *string `json:"Description,omitempty"` Meta *map[string]string `json:"Meta,omitempty"` @@ -43,36 +43,46 @@ func NewNamespaceWithDefaults() *Namespace { return &this } -// GetCapabilities returns the Capabilities field value if set, zero value otherwise. +// GetCapabilities returns the Capabilities field value if set, zero value otherwise (both if not set or set to explicit null). func (o *Namespace) GetCapabilities() NamespaceCapabilities { - if o == nil || o.Capabilities == nil { + if o == nil || o.Capabilities.Get() == nil { var ret NamespaceCapabilities return ret } - return *o.Capabilities + return *o.Capabilities.Get() } // GetCapabilitiesOk returns a tuple with the Capabilities field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *Namespace) GetCapabilitiesOk() (*NamespaceCapabilities, bool) { - if o == nil || o.Capabilities == nil { + if o == nil { return nil, false } - return o.Capabilities, true + return o.Capabilities.Get(), o.Capabilities.IsSet() } // HasCapabilities returns a boolean if a field has been set. func (o *Namespace) HasCapabilities() bool { - if o != nil && o.Capabilities != nil { + if o != nil && o.Capabilities.IsSet() { return true } return false } -// SetCapabilities gets a reference to the given NamespaceCapabilities and assigns it to the Capabilities field. +// SetCapabilities gets a reference to the given NullableNamespaceCapabilities and assigns it to the Capabilities field. func (o *Namespace) SetCapabilities(v NamespaceCapabilities) { - o.Capabilities = &v + o.Capabilities.Set(&v) +} +// SetCapabilitiesNil sets the value for Capabilities to be an explicit nil +func (o *Namespace) SetCapabilitiesNil() { + o.Capabilities.Set(nil) +} + +// UnsetCapabilities ensures that no value is present for Capabilities, not even an explicit nil +func (o *Namespace) UnsetCapabilities() { + o.Capabilities.Unset() } // GetCreateIndex returns the CreateIndex field value if set, zero value otherwise. @@ -269,8 +279,8 @@ func (o *Namespace) SetQuota(v string) { func (o Namespace) MarshalJSON() ([]byte, error) { toSerialize := map[string]interface{}{} - if o.Capabilities != nil { - toSerialize["Capabilities"] = o.Capabilities + if o.Capabilities.IsSet() { + toSerialize["Capabilities"] = o.Capabilities.Get() } if o.CreateIndex != nil { toSerialize["CreateIndex"] = o.CreateIndex diff --git a/clients/go/v1/model_namespace_capabilities.go b/clients/go/v1/model_namespace_capabilities.go index baea414e..1b447264 100644 --- a/clients/go/v1/model_namespace_capabilities.go +++ b/clients/go/v1/model_namespace_capabilities.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,8 +17,8 @@ import ( // NamespaceCapabilities struct for NamespaceCapabilities type NamespaceCapabilities struct { - DisabledTaskDrivers *[]string `json:"DisabledTaskDrivers,omitempty"` - EnabledTaskDrivers *[]string `json:"EnabledTaskDrivers,omitempty"` + DisabledTaskDrivers []string `json:"DisabledTaskDrivers,omitempty"` + EnabledTaskDrivers []string `json:"EnabledTaskDrivers,omitempty"` } // NewNamespaceCapabilities instantiates a new NamespaceCapabilities object @@ -44,12 +44,12 @@ func (o *NamespaceCapabilities) GetDisabledTaskDrivers() []string { var ret []string return ret } - return *o.DisabledTaskDrivers + return o.DisabledTaskDrivers } // GetDisabledTaskDriversOk returns a tuple with the DisabledTaskDrivers field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *NamespaceCapabilities) GetDisabledTaskDriversOk() (*[]string, bool) { +func (o *NamespaceCapabilities) GetDisabledTaskDriversOk() ([]string, bool) { if o == nil || o.DisabledTaskDrivers == nil { return nil, false } @@ -67,7 +67,7 @@ func (o *NamespaceCapabilities) HasDisabledTaskDrivers() bool { // SetDisabledTaskDrivers gets a reference to the given []string and assigns it to the DisabledTaskDrivers field. func (o *NamespaceCapabilities) SetDisabledTaskDrivers(v []string) { - o.DisabledTaskDrivers = &v + o.DisabledTaskDrivers = v } // GetEnabledTaskDrivers returns the EnabledTaskDrivers field value if set, zero value otherwise. @@ -76,12 +76,12 @@ func (o *NamespaceCapabilities) GetEnabledTaskDrivers() []string { var ret []string return ret } - return *o.EnabledTaskDrivers + return o.EnabledTaskDrivers } // GetEnabledTaskDriversOk returns a tuple with the EnabledTaskDrivers field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *NamespaceCapabilities) GetEnabledTaskDriversOk() (*[]string, bool) { +func (o *NamespaceCapabilities) GetEnabledTaskDriversOk() ([]string, bool) { if o == nil || o.EnabledTaskDrivers == nil { return nil, false } @@ -99,7 +99,7 @@ func (o *NamespaceCapabilities) HasEnabledTaskDrivers() bool { // SetEnabledTaskDrivers gets a reference to the given []string and assigns it to the EnabledTaskDrivers field. func (o *NamespaceCapabilities) SetEnabledTaskDrivers(v []string) { - o.EnabledTaskDrivers = &v + o.EnabledTaskDrivers = v } func (o NamespaceCapabilities) MarshalJSON() ([]byte, error) { diff --git a/clients/go/v1/model_network_resource.go b/clients/go/v1/model_network_resource.go index c29f544d..ad812f22 100644 --- a/clients/go/v1/model_network_resource.go +++ b/clients/go/v1/model_network_resource.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -18,14 +18,14 @@ import ( // NetworkResource struct for NetworkResource type NetworkResource struct { CIDR *string `json:"CIDR,omitempty"` - DNS *DNSConfig `json:"DNS,omitempty"` + DNS NullableDNSConfig `json:"DNS,omitempty"` Device *string `json:"Device,omitempty"` - DynamicPorts *[]Port `json:"DynamicPorts,omitempty"` + DynamicPorts []Port `json:"DynamicPorts,omitempty"` Hostname *string `json:"Hostname,omitempty"` IP *string `json:"IP,omitempty"` MBits *int32 `json:"MBits,omitempty"` Mode *string `json:"Mode,omitempty"` - ReservedPorts *[]Port `json:"ReservedPorts,omitempty"` + ReservedPorts []Port `json:"ReservedPorts,omitempty"` } // NewNetworkResource instantiates a new NetworkResource object @@ -77,36 +77,46 @@ func (o *NetworkResource) SetCIDR(v string) { o.CIDR = &v } -// GetDNS returns the DNS field value if set, zero value otherwise. +// GetDNS returns the DNS field value if set, zero value otherwise (both if not set or set to explicit null). func (o *NetworkResource) GetDNS() DNSConfig { - if o == nil || o.DNS == nil { + if o == nil || o.DNS.Get() == nil { var ret DNSConfig return ret } - return *o.DNS + return *o.DNS.Get() } // GetDNSOk returns a tuple with the DNS field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *NetworkResource) GetDNSOk() (*DNSConfig, bool) { - if o == nil || o.DNS == nil { + if o == nil { return nil, false } - return o.DNS, true + return o.DNS.Get(), o.DNS.IsSet() } // HasDNS returns a boolean if a field has been set. func (o *NetworkResource) HasDNS() bool { - if o != nil && o.DNS != nil { + if o != nil && o.DNS.IsSet() { return true } return false } -// SetDNS gets a reference to the given DNSConfig and assigns it to the DNS field. +// SetDNS gets a reference to the given NullableDNSConfig and assigns it to the DNS field. func (o *NetworkResource) SetDNS(v DNSConfig) { - o.DNS = &v + o.DNS.Set(&v) +} +// SetDNSNil sets the value for DNS to be an explicit nil +func (o *NetworkResource) SetDNSNil() { + o.DNS.Set(nil) +} + +// UnsetDNS ensures that no value is present for DNS, not even an explicit nil +func (o *NetworkResource) UnsetDNS() { + o.DNS.Unset() } // GetDevice returns the Device field value if set, zero value otherwise. @@ -147,12 +157,12 @@ func (o *NetworkResource) GetDynamicPorts() []Port { var ret []Port return ret } - return *o.DynamicPorts + return o.DynamicPorts } // GetDynamicPortsOk returns a tuple with the DynamicPorts field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *NetworkResource) GetDynamicPortsOk() (*[]Port, bool) { +func (o *NetworkResource) GetDynamicPortsOk() ([]Port, bool) { if o == nil || o.DynamicPorts == nil { return nil, false } @@ -170,7 +180,7 @@ func (o *NetworkResource) HasDynamicPorts() bool { // SetDynamicPorts gets a reference to the given []Port and assigns it to the DynamicPorts field. func (o *NetworkResource) SetDynamicPorts(v []Port) { - o.DynamicPorts = &v + o.DynamicPorts = v } // GetHostname returns the Hostname field value if set, zero value otherwise. @@ -307,12 +317,12 @@ func (o *NetworkResource) GetReservedPorts() []Port { var ret []Port return ret } - return *o.ReservedPorts + return o.ReservedPorts } // GetReservedPortsOk returns a tuple with the ReservedPorts field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *NetworkResource) GetReservedPortsOk() (*[]Port, bool) { +func (o *NetworkResource) GetReservedPortsOk() ([]Port, bool) { if o == nil || o.ReservedPorts == nil { return nil, false } @@ -330,7 +340,7 @@ func (o *NetworkResource) HasReservedPorts() bool { // SetReservedPorts gets a reference to the given []Port and assigns it to the ReservedPorts field. func (o *NetworkResource) SetReservedPorts(v []Port) { - o.ReservedPorts = &v + o.ReservedPorts = v } func (o NetworkResource) MarshalJSON() ([]byte, error) { @@ -338,8 +348,8 @@ func (o NetworkResource) MarshalJSON() ([]byte, error) { if o.CIDR != nil { toSerialize["CIDR"] = o.CIDR } - if o.DNS != nil { - toSerialize["DNS"] = o.DNS + if o.DNS.IsSet() { + toSerialize["DNS"] = o.DNS.Get() } if o.Device != nil { toSerialize["Device"] = o.Device diff --git a/clients/go/v1/model_node.go b/clients/go/v1/model_node.go index 3a5774c6..36a2b7db 100644 --- a/clients/go/v1/model_node.go +++ b/clients/go/v1/model_node.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -24,23 +24,23 @@ type Node struct { CreateIndex *int32 `json:"CreateIndex,omitempty"` Datacenter *string `json:"Datacenter,omitempty"` Drain *bool `json:"Drain,omitempty"` - DrainStrategy *DrainStrategy `json:"DrainStrategy,omitempty"` + DrainStrategy NullableDrainStrategy `json:"DrainStrategy,omitempty"` Drivers *map[string]DriverInfo `json:"Drivers,omitempty"` - Events *[]NodeEvent `json:"Events,omitempty"` + Events []NodeEvent `json:"Events,omitempty"` HTTPAddr *string `json:"HTTPAddr,omitempty"` HostNetworks *map[string]HostNetworkInfo `json:"HostNetworks,omitempty"` HostVolumes *map[string]HostVolumeInfo `json:"HostVolumes,omitempty"` ID *string `json:"ID,omitempty"` - LastDrain *DrainMetadata `json:"LastDrain,omitempty"` + LastDrain NullableDrainMetadata `json:"LastDrain,omitempty"` Links *map[string]string `json:"Links,omitempty"` Meta *map[string]string `json:"Meta,omitempty"` ModifyIndex *int32 `json:"ModifyIndex,omitempty"` Name *string `json:"Name,omitempty"` NodeClass *string `json:"NodeClass,omitempty"` - NodeResources *NodeResources `json:"NodeResources,omitempty"` - Reserved *Resources `json:"Reserved,omitempty"` - ReservedResources *NodeReservedResources `json:"ReservedResources,omitempty"` - Resources *Resources `json:"Resources,omitempty"` + NodeResources NullableNodeResources `json:"NodeResources,omitempty"` + Reserved NullableResources `json:"Reserved,omitempty"` + ReservedResources NullableNodeReservedResources `json:"ReservedResources,omitempty"` + Resources NullableResources `json:"Resources,omitempty"` SchedulingEligibility *string `json:"SchedulingEligibility,omitempty"` Status *string `json:"Status,omitempty"` StatusDescription *string `json:"StatusDescription,omitempty"` @@ -289,36 +289,46 @@ func (o *Node) SetDrain(v bool) { o.Drain = &v } -// GetDrainStrategy returns the DrainStrategy field value if set, zero value otherwise. +// GetDrainStrategy returns the DrainStrategy field value if set, zero value otherwise (both if not set or set to explicit null). func (o *Node) GetDrainStrategy() DrainStrategy { - if o == nil || o.DrainStrategy == nil { + if o == nil || o.DrainStrategy.Get() == nil { var ret DrainStrategy return ret } - return *o.DrainStrategy + return *o.DrainStrategy.Get() } // GetDrainStrategyOk returns a tuple with the DrainStrategy field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *Node) GetDrainStrategyOk() (*DrainStrategy, bool) { - if o == nil || o.DrainStrategy == nil { + if o == nil { return nil, false } - return o.DrainStrategy, true + return o.DrainStrategy.Get(), o.DrainStrategy.IsSet() } // HasDrainStrategy returns a boolean if a field has been set. func (o *Node) HasDrainStrategy() bool { - if o != nil && o.DrainStrategy != nil { + if o != nil && o.DrainStrategy.IsSet() { return true } return false } -// SetDrainStrategy gets a reference to the given DrainStrategy and assigns it to the DrainStrategy field. +// SetDrainStrategy gets a reference to the given NullableDrainStrategy and assigns it to the DrainStrategy field. func (o *Node) SetDrainStrategy(v DrainStrategy) { - o.DrainStrategy = &v + o.DrainStrategy.Set(&v) +} +// SetDrainStrategyNil sets the value for DrainStrategy to be an explicit nil +func (o *Node) SetDrainStrategyNil() { + o.DrainStrategy.Set(nil) +} + +// UnsetDrainStrategy ensures that no value is present for DrainStrategy, not even an explicit nil +func (o *Node) UnsetDrainStrategy() { + o.DrainStrategy.Unset() } // GetDrivers returns the Drivers field value if set, zero value otherwise. @@ -359,12 +369,12 @@ func (o *Node) GetEvents() []NodeEvent { var ret []NodeEvent return ret } - return *o.Events + return o.Events } // GetEventsOk returns a tuple with the Events field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *Node) GetEventsOk() (*[]NodeEvent, bool) { +func (o *Node) GetEventsOk() ([]NodeEvent, bool) { if o == nil || o.Events == nil { return nil, false } @@ -382,7 +392,7 @@ func (o *Node) HasEvents() bool { // SetEvents gets a reference to the given []NodeEvent and assigns it to the Events field. func (o *Node) SetEvents(v []NodeEvent) { - o.Events = &v + o.Events = v } // GetHTTPAddr returns the HTTPAddr field value if set, zero value otherwise. @@ -513,36 +523,46 @@ func (o *Node) SetID(v string) { o.ID = &v } -// GetLastDrain returns the LastDrain field value if set, zero value otherwise. +// GetLastDrain returns the LastDrain field value if set, zero value otherwise (both if not set or set to explicit null). func (o *Node) GetLastDrain() DrainMetadata { - if o == nil || o.LastDrain == nil { + if o == nil || o.LastDrain.Get() == nil { var ret DrainMetadata return ret } - return *o.LastDrain + return *o.LastDrain.Get() } // GetLastDrainOk returns a tuple with the LastDrain field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *Node) GetLastDrainOk() (*DrainMetadata, bool) { - if o == nil || o.LastDrain == nil { + if o == nil { return nil, false } - return o.LastDrain, true + return o.LastDrain.Get(), o.LastDrain.IsSet() } // HasLastDrain returns a boolean if a field has been set. func (o *Node) HasLastDrain() bool { - if o != nil && o.LastDrain != nil { + if o != nil && o.LastDrain.IsSet() { return true } return false } -// SetLastDrain gets a reference to the given DrainMetadata and assigns it to the LastDrain field. +// SetLastDrain gets a reference to the given NullableDrainMetadata and assigns it to the LastDrain field. func (o *Node) SetLastDrain(v DrainMetadata) { - o.LastDrain = &v + o.LastDrain.Set(&v) +} +// SetLastDrainNil sets the value for LastDrain to be an explicit nil +func (o *Node) SetLastDrainNil() { + o.LastDrain.Set(nil) +} + +// UnsetLastDrain ensures that no value is present for LastDrain, not even an explicit nil +func (o *Node) UnsetLastDrain() { + o.LastDrain.Unset() } // GetLinks returns the Links field value if set, zero value otherwise. @@ -705,132 +725,172 @@ func (o *Node) SetNodeClass(v string) { o.NodeClass = &v } -// GetNodeResources returns the NodeResources field value if set, zero value otherwise. +// GetNodeResources returns the NodeResources field value if set, zero value otherwise (both if not set or set to explicit null). func (o *Node) GetNodeResources() NodeResources { - if o == nil || o.NodeResources == nil { + if o == nil || o.NodeResources.Get() == nil { var ret NodeResources return ret } - return *o.NodeResources + return *o.NodeResources.Get() } // GetNodeResourcesOk returns a tuple with the NodeResources field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *Node) GetNodeResourcesOk() (*NodeResources, bool) { - if o == nil || o.NodeResources == nil { + if o == nil { return nil, false } - return o.NodeResources, true + return o.NodeResources.Get(), o.NodeResources.IsSet() } // HasNodeResources returns a boolean if a field has been set. func (o *Node) HasNodeResources() bool { - if o != nil && o.NodeResources != nil { + if o != nil && o.NodeResources.IsSet() { return true } return false } -// SetNodeResources gets a reference to the given NodeResources and assigns it to the NodeResources field. +// SetNodeResources gets a reference to the given NullableNodeResources and assigns it to the NodeResources field. func (o *Node) SetNodeResources(v NodeResources) { - o.NodeResources = &v + o.NodeResources.Set(&v) +} +// SetNodeResourcesNil sets the value for NodeResources to be an explicit nil +func (o *Node) SetNodeResourcesNil() { + o.NodeResources.Set(nil) +} + +// UnsetNodeResources ensures that no value is present for NodeResources, not even an explicit nil +func (o *Node) UnsetNodeResources() { + o.NodeResources.Unset() } -// GetReserved returns the Reserved field value if set, zero value otherwise. +// GetReserved returns the Reserved field value if set, zero value otherwise (both if not set or set to explicit null). func (o *Node) GetReserved() Resources { - if o == nil || o.Reserved == nil { + if o == nil || o.Reserved.Get() == nil { var ret Resources return ret } - return *o.Reserved + return *o.Reserved.Get() } // GetReservedOk returns a tuple with the Reserved field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *Node) GetReservedOk() (*Resources, bool) { - if o == nil || o.Reserved == nil { + if o == nil { return nil, false } - return o.Reserved, true + return o.Reserved.Get(), o.Reserved.IsSet() } // HasReserved returns a boolean if a field has been set. func (o *Node) HasReserved() bool { - if o != nil && o.Reserved != nil { + if o != nil && o.Reserved.IsSet() { return true } return false } -// SetReserved gets a reference to the given Resources and assigns it to the Reserved field. +// SetReserved gets a reference to the given NullableResources and assigns it to the Reserved field. func (o *Node) SetReserved(v Resources) { - o.Reserved = &v + o.Reserved.Set(&v) +} +// SetReservedNil sets the value for Reserved to be an explicit nil +func (o *Node) SetReservedNil() { + o.Reserved.Set(nil) } -// GetReservedResources returns the ReservedResources field value if set, zero value otherwise. +// UnsetReserved ensures that no value is present for Reserved, not even an explicit nil +func (o *Node) UnsetReserved() { + o.Reserved.Unset() +} + +// GetReservedResources returns the ReservedResources field value if set, zero value otherwise (both if not set or set to explicit null). func (o *Node) GetReservedResources() NodeReservedResources { - if o == nil || o.ReservedResources == nil { + if o == nil || o.ReservedResources.Get() == nil { var ret NodeReservedResources return ret } - return *o.ReservedResources + return *o.ReservedResources.Get() } // GetReservedResourcesOk returns a tuple with the ReservedResources field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *Node) GetReservedResourcesOk() (*NodeReservedResources, bool) { - if o == nil || o.ReservedResources == nil { + if o == nil { return nil, false } - return o.ReservedResources, true + return o.ReservedResources.Get(), o.ReservedResources.IsSet() } // HasReservedResources returns a boolean if a field has been set. func (o *Node) HasReservedResources() bool { - if o != nil && o.ReservedResources != nil { + if o != nil && o.ReservedResources.IsSet() { return true } return false } -// SetReservedResources gets a reference to the given NodeReservedResources and assigns it to the ReservedResources field. +// SetReservedResources gets a reference to the given NullableNodeReservedResources and assigns it to the ReservedResources field. func (o *Node) SetReservedResources(v NodeReservedResources) { - o.ReservedResources = &v + o.ReservedResources.Set(&v) +} +// SetReservedResourcesNil sets the value for ReservedResources to be an explicit nil +func (o *Node) SetReservedResourcesNil() { + o.ReservedResources.Set(nil) } -// GetResources returns the Resources field value if set, zero value otherwise. +// UnsetReservedResources ensures that no value is present for ReservedResources, not even an explicit nil +func (o *Node) UnsetReservedResources() { + o.ReservedResources.Unset() +} + +// GetResources returns the Resources field value if set, zero value otherwise (both if not set or set to explicit null). func (o *Node) GetResources() Resources { - if o == nil || o.Resources == nil { + if o == nil || o.Resources.Get() == nil { var ret Resources return ret } - return *o.Resources + return *o.Resources.Get() } // GetResourcesOk returns a tuple with the Resources field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *Node) GetResourcesOk() (*Resources, bool) { - if o == nil || o.Resources == nil { + if o == nil { return nil, false } - return o.Resources, true + return o.Resources.Get(), o.Resources.IsSet() } // HasResources returns a boolean if a field has been set. func (o *Node) HasResources() bool { - if o != nil && o.Resources != nil { + if o != nil && o.Resources.IsSet() { return true } return false } -// SetResources gets a reference to the given Resources and assigns it to the Resources field. +// SetResources gets a reference to the given NullableResources and assigns it to the Resources field. func (o *Node) SetResources(v Resources) { - o.Resources = &v + o.Resources.Set(&v) +} +// SetResourcesNil sets the value for Resources to be an explicit nil +func (o *Node) SetResourcesNil() { + o.Resources.Set(nil) +} + +// UnsetResources ensures that no value is present for Resources, not even an explicit nil +func (o *Node) UnsetResources() { + o.Resources.Unset() } // GetSchedulingEligibility returns the SchedulingEligibility field value if set, zero value otherwise. @@ -1016,8 +1076,8 @@ func (o Node) MarshalJSON() ([]byte, error) { if o.Drain != nil { toSerialize["Drain"] = o.Drain } - if o.DrainStrategy != nil { - toSerialize["DrainStrategy"] = o.DrainStrategy + if o.DrainStrategy.IsSet() { + toSerialize["DrainStrategy"] = o.DrainStrategy.Get() } if o.Drivers != nil { toSerialize["Drivers"] = o.Drivers @@ -1037,8 +1097,8 @@ func (o Node) MarshalJSON() ([]byte, error) { if o.ID != nil { toSerialize["ID"] = o.ID } - if o.LastDrain != nil { - toSerialize["LastDrain"] = o.LastDrain + if o.LastDrain.IsSet() { + toSerialize["LastDrain"] = o.LastDrain.Get() } if o.Links != nil { toSerialize["Links"] = o.Links @@ -1055,17 +1115,17 @@ func (o Node) MarshalJSON() ([]byte, error) { if o.NodeClass != nil { toSerialize["NodeClass"] = o.NodeClass } - if o.NodeResources != nil { - toSerialize["NodeResources"] = o.NodeResources + if o.NodeResources.IsSet() { + toSerialize["NodeResources"] = o.NodeResources.Get() } - if o.Reserved != nil { - toSerialize["Reserved"] = o.Reserved + if o.Reserved.IsSet() { + toSerialize["Reserved"] = o.Reserved.Get() } - if o.ReservedResources != nil { - toSerialize["ReservedResources"] = o.ReservedResources + if o.ReservedResources.IsSet() { + toSerialize["ReservedResources"] = o.ReservedResources.Get() } - if o.Resources != nil { - toSerialize["Resources"] = o.Resources + if o.Resources.IsSet() { + toSerialize["Resources"] = o.Resources.Get() } if o.SchedulingEligibility != nil { toSerialize["SchedulingEligibility"] = o.SchedulingEligibility diff --git a/clients/go/v1/model_node_cpu_resources.go b/clients/go/v1/model_node_cpu_resources.go index ab172992..76145cf7 100644 --- a/clients/go/v1/model_node_cpu_resources.go +++ b/clients/go/v1/model_node_cpu_resources.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -18,7 +18,7 @@ import ( // NodeCpuResources struct for NodeCpuResources type NodeCpuResources struct { CpuShares *int64 `json:"CpuShares,omitempty"` - ReservableCpuCores *[]int32 `json:"ReservableCpuCores,omitempty"` + ReservableCpuCores []int32 `json:"ReservableCpuCores,omitempty"` TotalCpuCores *int32 `json:"TotalCpuCores,omitempty"` } @@ -77,12 +77,12 @@ func (o *NodeCpuResources) GetReservableCpuCores() []int32 { var ret []int32 return ret } - return *o.ReservableCpuCores + return o.ReservableCpuCores } // GetReservableCpuCoresOk returns a tuple with the ReservableCpuCores field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *NodeCpuResources) GetReservableCpuCoresOk() (*[]int32, bool) { +func (o *NodeCpuResources) GetReservableCpuCoresOk() ([]int32, bool) { if o == nil || o.ReservableCpuCores == nil { return nil, false } @@ -100,7 +100,7 @@ func (o *NodeCpuResources) HasReservableCpuCores() bool { // SetReservableCpuCores gets a reference to the given []int32 and assigns it to the ReservableCpuCores field. func (o *NodeCpuResources) SetReservableCpuCores(v []int32) { - o.ReservableCpuCores = &v + o.ReservableCpuCores = v } // GetTotalCpuCores returns the TotalCpuCores field value if set, zero value otherwise. diff --git a/clients/go/v1/model_node_device.go b/clients/go/v1/model_node_device.go index 6ae419e5..dacf1a4f 100644 --- a/clients/go/v1/model_node_device.go +++ b/clients/go/v1/model_node_device.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -20,7 +20,7 @@ type NodeDevice struct { HealthDescription *string `json:"HealthDescription,omitempty"` Healthy *bool `json:"Healthy,omitempty"` ID *string `json:"ID,omitempty"` - Locality *NodeDeviceLocality `json:"Locality,omitempty"` + Locality NullableNodeDeviceLocality `json:"Locality,omitempty"` } // NewNodeDevice instantiates a new NodeDevice object @@ -136,36 +136,46 @@ func (o *NodeDevice) SetID(v string) { o.ID = &v } -// GetLocality returns the Locality field value if set, zero value otherwise. +// GetLocality returns the Locality field value if set, zero value otherwise (both if not set or set to explicit null). func (o *NodeDevice) GetLocality() NodeDeviceLocality { - if o == nil || o.Locality == nil { + if o == nil || o.Locality.Get() == nil { var ret NodeDeviceLocality return ret } - return *o.Locality + return *o.Locality.Get() } // GetLocalityOk returns a tuple with the Locality field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *NodeDevice) GetLocalityOk() (*NodeDeviceLocality, bool) { - if o == nil || o.Locality == nil { + if o == nil { return nil, false } - return o.Locality, true + return o.Locality.Get(), o.Locality.IsSet() } // HasLocality returns a boolean if a field has been set. func (o *NodeDevice) HasLocality() bool { - if o != nil && o.Locality != nil { + if o != nil && o.Locality.IsSet() { return true } return false } -// SetLocality gets a reference to the given NodeDeviceLocality and assigns it to the Locality field. +// SetLocality gets a reference to the given NullableNodeDeviceLocality and assigns it to the Locality field. func (o *NodeDevice) SetLocality(v NodeDeviceLocality) { - o.Locality = &v + o.Locality.Set(&v) +} +// SetLocalityNil sets the value for Locality to be an explicit nil +func (o *NodeDevice) SetLocalityNil() { + o.Locality.Set(nil) +} + +// UnsetLocality ensures that no value is present for Locality, not even an explicit nil +func (o *NodeDevice) UnsetLocality() { + o.Locality.Unset() } func (o NodeDevice) MarshalJSON() ([]byte, error) { @@ -179,8 +189,8 @@ func (o NodeDevice) MarshalJSON() ([]byte, error) { if o.ID != nil { toSerialize["ID"] = o.ID } - if o.Locality != nil { - toSerialize["Locality"] = o.Locality + if o.Locality.IsSet() { + toSerialize["Locality"] = o.Locality.Get() } return json.Marshal(toSerialize) } diff --git a/clients/go/v1/model_node_device_locality.go b/clients/go/v1/model_node_device_locality.go index 6a1121b2..ec1605b5 100644 --- a/clients/go/v1/model_node_device_locality.go +++ b/clients/go/v1/model_node_device_locality.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_node_device_resource.go b/clients/go/v1/model_node_device_resource.go index 3b987627..5f04b82f 100644 --- a/clients/go/v1/model_node_device_resource.go +++ b/clients/go/v1/model_node_device_resource.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -18,7 +18,7 @@ import ( // NodeDeviceResource struct for NodeDeviceResource type NodeDeviceResource struct { Attributes *map[string]Attribute `json:"Attributes,omitempty"` - Instances *[]NodeDevice `json:"Instances,omitempty"` + Instances []NodeDevice `json:"Instances,omitempty"` Name *string `json:"Name,omitempty"` Type *string `json:"Type,omitempty"` Vendor *string `json:"Vendor,omitempty"` @@ -79,12 +79,12 @@ func (o *NodeDeviceResource) GetInstances() []NodeDevice { var ret []NodeDevice return ret } - return *o.Instances + return o.Instances } // GetInstancesOk returns a tuple with the Instances field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *NodeDeviceResource) GetInstancesOk() (*[]NodeDevice, bool) { +func (o *NodeDeviceResource) GetInstancesOk() ([]NodeDevice, bool) { if o == nil || o.Instances == nil { return nil, false } @@ -102,7 +102,7 @@ func (o *NodeDeviceResource) HasInstances() bool { // SetInstances gets a reference to the given []NodeDevice and assigns it to the Instances field. func (o *NodeDeviceResource) SetInstances(v []NodeDevice) { - o.Instances = &v + o.Instances = v } // GetName returns the Name field value if set, zero value otherwise. diff --git a/clients/go/v1/model_node_disk_resources.go b/clients/go/v1/model_node_disk_resources.go index 1b2a160a..d549304c 100644 --- a/clients/go/v1/model_node_disk_resources.go +++ b/clients/go/v1/model_node_disk_resources.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_node_drain_update_response.go b/clients/go/v1/model_node_drain_update_response.go index 25d29268..630eff88 100644 --- a/clients/go/v1/model_node_drain_update_response.go +++ b/clients/go/v1/model_node_drain_update_response.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -18,7 +18,7 @@ import ( // NodeDrainUpdateResponse struct for NodeDrainUpdateResponse type NodeDrainUpdateResponse struct { EvalCreateIndex *int32 `json:"EvalCreateIndex,omitempty"` - EvalIDs *[]string `json:"EvalIDs,omitempty"` + EvalIDs []string `json:"EvalIDs,omitempty"` LastIndex *int32 `json:"LastIndex,omitempty"` NodeModifyIndex *int32 `json:"NodeModifyIndex,omitempty"` RequestTime *int64 `json:"RequestTime,omitempty"` @@ -79,12 +79,12 @@ func (o *NodeDrainUpdateResponse) GetEvalIDs() []string { var ret []string return ret } - return *o.EvalIDs + return o.EvalIDs } // GetEvalIDsOk returns a tuple with the EvalIDs field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *NodeDrainUpdateResponse) GetEvalIDsOk() (*[]string, bool) { +func (o *NodeDrainUpdateResponse) GetEvalIDsOk() ([]string, bool) { if o == nil || o.EvalIDs == nil { return nil, false } @@ -102,7 +102,7 @@ func (o *NodeDrainUpdateResponse) HasEvalIDs() bool { // SetEvalIDs gets a reference to the given []string and assigns it to the EvalIDs field. func (o *NodeDrainUpdateResponse) SetEvalIDs(v []string) { - o.EvalIDs = &v + o.EvalIDs = v } // GetLastIndex returns the LastIndex field value if set, zero value otherwise. diff --git a/clients/go/v1/model_node_eligibility_update_response.go b/clients/go/v1/model_node_eligibility_update_response.go index e03af47e..7b642e86 100644 --- a/clients/go/v1/model_node_eligibility_update_response.go +++ b/clients/go/v1/model_node_eligibility_update_response.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -18,7 +18,7 @@ import ( // NodeEligibilityUpdateResponse struct for NodeEligibilityUpdateResponse type NodeEligibilityUpdateResponse struct { EvalCreateIndex *int32 `json:"EvalCreateIndex,omitempty"` - EvalIDs *[]string `json:"EvalIDs,omitempty"` + EvalIDs []string `json:"EvalIDs,omitempty"` LastIndex *int32 `json:"LastIndex,omitempty"` NodeModifyIndex *int32 `json:"NodeModifyIndex,omitempty"` RequestTime *int64 `json:"RequestTime,omitempty"` @@ -79,12 +79,12 @@ func (o *NodeEligibilityUpdateResponse) GetEvalIDs() []string { var ret []string return ret } - return *o.EvalIDs + return o.EvalIDs } // GetEvalIDsOk returns a tuple with the EvalIDs field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *NodeEligibilityUpdateResponse) GetEvalIDsOk() (*[]string, bool) { +func (o *NodeEligibilityUpdateResponse) GetEvalIDsOk() ([]string, bool) { if o == nil || o.EvalIDs == nil { return nil, false } @@ -102,7 +102,7 @@ func (o *NodeEligibilityUpdateResponse) HasEvalIDs() bool { // SetEvalIDs gets a reference to the given []string and assigns it to the EvalIDs field. func (o *NodeEligibilityUpdateResponse) SetEvalIDs(v []string) { - o.EvalIDs = &v + o.EvalIDs = v } // GetLastIndex returns the LastIndex field value if set, zero value otherwise. diff --git a/clients/go/v1/model_node_event.go b/clients/go/v1/model_node_event.go index a1227f3c..2e071eaf 100644 --- a/clients/go/v1/model_node_event.go +++ b/clients/go/v1/model_node_event.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -22,7 +22,7 @@ type NodeEvent struct { Details *map[string]string `json:"Details,omitempty"` Message *string `json:"Message,omitempty"` Subsystem *string `json:"Subsystem,omitempty"` - Timestamp *time.Time `json:"Timestamp,omitempty"` + Timestamp NullableTime `json:"Timestamp,omitempty"` } // NewNodeEvent instantiates a new NodeEvent object @@ -170,36 +170,46 @@ func (o *NodeEvent) SetSubsystem(v string) { o.Subsystem = &v } -// GetTimestamp returns the Timestamp field value if set, zero value otherwise. +// GetTimestamp returns the Timestamp field value if set, zero value otherwise (both if not set or set to explicit null). func (o *NodeEvent) GetTimestamp() time.Time { - if o == nil || o.Timestamp == nil { + if o == nil || o.Timestamp.Get() == nil { var ret time.Time return ret } - return *o.Timestamp + return *o.Timestamp.Get() } // GetTimestampOk returns a tuple with the Timestamp field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *NodeEvent) GetTimestampOk() (*time.Time, bool) { - if o == nil || o.Timestamp == nil { + if o == nil { return nil, false } - return o.Timestamp, true + return o.Timestamp.Get(), o.Timestamp.IsSet() } // HasTimestamp returns a boolean if a field has been set. func (o *NodeEvent) HasTimestamp() bool { - if o != nil && o.Timestamp != nil { + if o != nil && o.Timestamp.IsSet() { return true } return false } -// SetTimestamp gets a reference to the given time.Time and assigns it to the Timestamp field. +// SetTimestamp gets a reference to the given NullableTime and assigns it to the Timestamp field. func (o *NodeEvent) SetTimestamp(v time.Time) { - o.Timestamp = &v + o.Timestamp.Set(&v) +} +// SetTimestampNil sets the value for Timestamp to be an explicit nil +func (o *NodeEvent) SetTimestampNil() { + o.Timestamp.Set(nil) +} + +// UnsetTimestamp ensures that no value is present for Timestamp, not even an explicit nil +func (o *NodeEvent) UnsetTimestamp() { + o.Timestamp.Unset() } func (o NodeEvent) MarshalJSON() ([]byte, error) { @@ -216,8 +226,8 @@ func (o NodeEvent) MarshalJSON() ([]byte, error) { if o.Subsystem != nil { toSerialize["Subsystem"] = o.Subsystem } - if o.Timestamp != nil { - toSerialize["Timestamp"] = o.Timestamp + if o.Timestamp.IsSet() { + toSerialize["Timestamp"] = o.Timestamp.Get() } return json.Marshal(toSerialize) } diff --git a/clients/go/v1/model_node_list_stub.go b/clients/go/v1/model_node_list_stub.go index 32bad0ed..60bf5334 100644 --- a/clients/go/v1/model_node_list_stub.go +++ b/clients/go/v1/model_node_list_stub.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -24,12 +24,12 @@ type NodeListStub struct { Drain *bool `json:"Drain,omitempty"` Drivers *map[string]DriverInfo `json:"Drivers,omitempty"` ID *string `json:"ID,omitempty"` - LastDrain *DrainMetadata `json:"LastDrain,omitempty"` + LastDrain NullableDrainMetadata `json:"LastDrain,omitempty"` ModifyIndex *int32 `json:"ModifyIndex,omitempty"` Name *string `json:"Name,omitempty"` NodeClass *string `json:"NodeClass,omitempty"` - NodeResources *NodeResources `json:"NodeResources,omitempty"` - ReservedResources *NodeReservedResources `json:"ReservedResources,omitempty"` + NodeResources NullableNodeResources `json:"NodeResources,omitempty"` + ReservedResources NullableNodeReservedResources `json:"ReservedResources,omitempty"` SchedulingEligibility *string `json:"SchedulingEligibility,omitempty"` Status *string `json:"Status,omitempty"` StatusDescription *string `json:"StatusDescription,omitempty"` @@ -277,36 +277,46 @@ func (o *NodeListStub) SetID(v string) { o.ID = &v } -// GetLastDrain returns the LastDrain field value if set, zero value otherwise. +// GetLastDrain returns the LastDrain field value if set, zero value otherwise (both if not set or set to explicit null). func (o *NodeListStub) GetLastDrain() DrainMetadata { - if o == nil || o.LastDrain == nil { + if o == nil || o.LastDrain.Get() == nil { var ret DrainMetadata return ret } - return *o.LastDrain + return *o.LastDrain.Get() } // GetLastDrainOk returns a tuple with the LastDrain field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *NodeListStub) GetLastDrainOk() (*DrainMetadata, bool) { - if o == nil || o.LastDrain == nil { + if o == nil { return nil, false } - return o.LastDrain, true + return o.LastDrain.Get(), o.LastDrain.IsSet() } // HasLastDrain returns a boolean if a field has been set. func (o *NodeListStub) HasLastDrain() bool { - if o != nil && o.LastDrain != nil { + if o != nil && o.LastDrain.IsSet() { return true } return false } -// SetLastDrain gets a reference to the given DrainMetadata and assigns it to the LastDrain field. +// SetLastDrain gets a reference to the given NullableDrainMetadata and assigns it to the LastDrain field. func (o *NodeListStub) SetLastDrain(v DrainMetadata) { - o.LastDrain = &v + o.LastDrain.Set(&v) +} +// SetLastDrainNil sets the value for LastDrain to be an explicit nil +func (o *NodeListStub) SetLastDrainNil() { + o.LastDrain.Set(nil) +} + +// UnsetLastDrain ensures that no value is present for LastDrain, not even an explicit nil +func (o *NodeListStub) UnsetLastDrain() { + o.LastDrain.Unset() } // GetModifyIndex returns the ModifyIndex field value if set, zero value otherwise. @@ -405,68 +415,88 @@ func (o *NodeListStub) SetNodeClass(v string) { o.NodeClass = &v } -// GetNodeResources returns the NodeResources field value if set, zero value otherwise. +// GetNodeResources returns the NodeResources field value if set, zero value otherwise (both if not set or set to explicit null). func (o *NodeListStub) GetNodeResources() NodeResources { - if o == nil || o.NodeResources == nil { + if o == nil || o.NodeResources.Get() == nil { var ret NodeResources return ret } - return *o.NodeResources + return *o.NodeResources.Get() } // GetNodeResourcesOk returns a tuple with the NodeResources field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *NodeListStub) GetNodeResourcesOk() (*NodeResources, bool) { - if o == nil || o.NodeResources == nil { + if o == nil { return nil, false } - return o.NodeResources, true + return o.NodeResources.Get(), o.NodeResources.IsSet() } // HasNodeResources returns a boolean if a field has been set. func (o *NodeListStub) HasNodeResources() bool { - if o != nil && o.NodeResources != nil { + if o != nil && o.NodeResources.IsSet() { return true } return false } -// SetNodeResources gets a reference to the given NodeResources and assigns it to the NodeResources field. +// SetNodeResources gets a reference to the given NullableNodeResources and assigns it to the NodeResources field. func (o *NodeListStub) SetNodeResources(v NodeResources) { - o.NodeResources = &v + o.NodeResources.Set(&v) +} +// SetNodeResourcesNil sets the value for NodeResources to be an explicit nil +func (o *NodeListStub) SetNodeResourcesNil() { + o.NodeResources.Set(nil) } -// GetReservedResources returns the ReservedResources field value if set, zero value otherwise. +// UnsetNodeResources ensures that no value is present for NodeResources, not even an explicit nil +func (o *NodeListStub) UnsetNodeResources() { + o.NodeResources.Unset() +} + +// GetReservedResources returns the ReservedResources field value if set, zero value otherwise (both if not set or set to explicit null). func (o *NodeListStub) GetReservedResources() NodeReservedResources { - if o == nil || o.ReservedResources == nil { + if o == nil || o.ReservedResources.Get() == nil { var ret NodeReservedResources return ret } - return *o.ReservedResources + return *o.ReservedResources.Get() } // GetReservedResourcesOk returns a tuple with the ReservedResources field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *NodeListStub) GetReservedResourcesOk() (*NodeReservedResources, bool) { - if o == nil || o.ReservedResources == nil { + if o == nil { return nil, false } - return o.ReservedResources, true + return o.ReservedResources.Get(), o.ReservedResources.IsSet() } // HasReservedResources returns a boolean if a field has been set. func (o *NodeListStub) HasReservedResources() bool { - if o != nil && o.ReservedResources != nil { + if o != nil && o.ReservedResources.IsSet() { return true } return false } -// SetReservedResources gets a reference to the given NodeReservedResources and assigns it to the ReservedResources field. +// SetReservedResources gets a reference to the given NullableNodeReservedResources and assigns it to the ReservedResources field. func (o *NodeListStub) SetReservedResources(v NodeReservedResources) { - o.ReservedResources = &v + o.ReservedResources.Set(&v) +} +// SetReservedResourcesNil sets the value for ReservedResources to be an explicit nil +func (o *NodeListStub) SetReservedResourcesNil() { + o.ReservedResources.Set(nil) +} + +// UnsetReservedResources ensures that no value is present for ReservedResources, not even an explicit nil +func (o *NodeListStub) UnsetReservedResources() { + o.ReservedResources.Unset() } // GetSchedulingEligibility returns the SchedulingEligibility field value if set, zero value otherwise. @@ -620,8 +650,8 @@ func (o NodeListStub) MarshalJSON() ([]byte, error) { if o.ID != nil { toSerialize["ID"] = o.ID } - if o.LastDrain != nil { - toSerialize["LastDrain"] = o.LastDrain + if o.LastDrain.IsSet() { + toSerialize["LastDrain"] = o.LastDrain.Get() } if o.ModifyIndex != nil { toSerialize["ModifyIndex"] = o.ModifyIndex @@ -632,11 +662,11 @@ func (o NodeListStub) MarshalJSON() ([]byte, error) { if o.NodeClass != nil { toSerialize["NodeClass"] = o.NodeClass } - if o.NodeResources != nil { - toSerialize["NodeResources"] = o.NodeResources + if o.NodeResources.IsSet() { + toSerialize["NodeResources"] = o.NodeResources.Get() } - if o.ReservedResources != nil { - toSerialize["ReservedResources"] = o.ReservedResources + if o.ReservedResources.IsSet() { + toSerialize["ReservedResources"] = o.ReservedResources.Get() } if o.SchedulingEligibility != nil { toSerialize["SchedulingEligibility"] = o.SchedulingEligibility diff --git a/clients/go/v1/model_node_memory_resources.go b/clients/go/v1/model_node_memory_resources.go index a8226d6c..0e17fbb9 100644 --- a/clients/go/v1/model_node_memory_resources.go +++ b/clients/go/v1/model_node_memory_resources.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_node_purge_response.go b/clients/go/v1/model_node_purge_response.go index 9ef5dcce..847e77d5 100644 --- a/clients/go/v1/model_node_purge_response.go +++ b/clients/go/v1/model_node_purge_response.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -18,7 +18,7 @@ import ( // NodePurgeResponse struct for NodePurgeResponse type NodePurgeResponse struct { EvalCreateIndex *int32 `json:"EvalCreateIndex,omitempty"` - EvalIDs *[]string `json:"EvalIDs,omitempty"` + EvalIDs []string `json:"EvalIDs,omitempty"` NodeModifyIndex *int32 `json:"NodeModifyIndex,omitempty"` } @@ -77,12 +77,12 @@ func (o *NodePurgeResponse) GetEvalIDs() []string { var ret []string return ret } - return *o.EvalIDs + return o.EvalIDs } // GetEvalIDsOk returns a tuple with the EvalIDs field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *NodePurgeResponse) GetEvalIDsOk() (*[]string, bool) { +func (o *NodePurgeResponse) GetEvalIDsOk() ([]string, bool) { if o == nil || o.EvalIDs == nil { return nil, false } @@ -100,7 +100,7 @@ func (o *NodePurgeResponse) HasEvalIDs() bool { // SetEvalIDs gets a reference to the given []string and assigns it to the EvalIDs field. func (o *NodePurgeResponse) SetEvalIDs(v []string) { - o.EvalIDs = &v + o.EvalIDs = v } // GetNodeModifyIndex returns the NodeModifyIndex field value if set, zero value otherwise. diff --git a/clients/go/v1/model_node_reserved_cpu_resources.go b/clients/go/v1/model_node_reserved_cpu_resources.go index f984c344..16f5fe9f 100644 --- a/clients/go/v1/model_node_reserved_cpu_resources.go +++ b/clients/go/v1/model_node_reserved_cpu_resources.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_node_reserved_disk_resources.go b/clients/go/v1/model_node_reserved_disk_resources.go index 0eb4a377..83e425f4 100644 --- a/clients/go/v1/model_node_reserved_disk_resources.go +++ b/clients/go/v1/model_node_reserved_disk_resources.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_node_reserved_memory_resources.go b/clients/go/v1/model_node_reserved_memory_resources.go index 1198f87b..6d58d958 100644 --- a/clients/go/v1/model_node_reserved_memory_resources.go +++ b/clients/go/v1/model_node_reserved_memory_resources.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_node_reserved_network_resources.go b/clients/go/v1/model_node_reserved_network_resources.go index 7b4e3ed1..d5b04648 100644 --- a/clients/go/v1/model_node_reserved_network_resources.go +++ b/clients/go/v1/model_node_reserved_network_resources.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_node_reserved_resources.go b/clients/go/v1/model_node_reserved_resources.go index 29d1f590..fcecc2c0 100644 --- a/clients/go/v1/model_node_reserved_resources.go +++ b/clients/go/v1/model_node_reserved_resources.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,10 +17,10 @@ import ( // NodeReservedResources struct for NodeReservedResources type NodeReservedResources struct { - Cpu *NodeReservedCpuResources `json:"Cpu,omitempty"` - Disk *NodeReservedDiskResources `json:"Disk,omitempty"` - Memory *NodeReservedMemoryResources `json:"Memory,omitempty"` - Networks *NodeReservedNetworkResources `json:"Networks,omitempty"` + Cpu NullableNodeReservedCpuResources `json:"Cpu,omitempty"` + Disk NullableNodeReservedDiskResources `json:"Disk,omitempty"` + Memory NullableNodeReservedMemoryResources `json:"Memory,omitempty"` + Networks NullableNodeReservedNetworkResources `json:"Networks,omitempty"` } // NewNodeReservedResources instantiates a new NodeReservedResources object @@ -40,147 +40,187 @@ func NewNodeReservedResourcesWithDefaults() *NodeReservedResources { return &this } -// GetCpu returns the Cpu field value if set, zero value otherwise. +// GetCpu returns the Cpu field value if set, zero value otherwise (both if not set or set to explicit null). func (o *NodeReservedResources) GetCpu() NodeReservedCpuResources { - if o == nil || o.Cpu == nil { + if o == nil || o.Cpu.Get() == nil { var ret NodeReservedCpuResources return ret } - return *o.Cpu + return *o.Cpu.Get() } // GetCpuOk returns a tuple with the Cpu field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *NodeReservedResources) GetCpuOk() (*NodeReservedCpuResources, bool) { - if o == nil || o.Cpu == nil { + if o == nil { return nil, false } - return o.Cpu, true + return o.Cpu.Get(), o.Cpu.IsSet() } // HasCpu returns a boolean if a field has been set. func (o *NodeReservedResources) HasCpu() bool { - if o != nil && o.Cpu != nil { + if o != nil && o.Cpu.IsSet() { return true } return false } -// SetCpu gets a reference to the given NodeReservedCpuResources and assigns it to the Cpu field. +// SetCpu gets a reference to the given NullableNodeReservedCpuResources and assigns it to the Cpu field. func (o *NodeReservedResources) SetCpu(v NodeReservedCpuResources) { - o.Cpu = &v + o.Cpu.Set(&v) +} +// SetCpuNil sets the value for Cpu to be an explicit nil +func (o *NodeReservedResources) SetCpuNil() { + o.Cpu.Set(nil) } -// GetDisk returns the Disk field value if set, zero value otherwise. +// UnsetCpu ensures that no value is present for Cpu, not even an explicit nil +func (o *NodeReservedResources) UnsetCpu() { + o.Cpu.Unset() +} + +// GetDisk returns the Disk field value if set, zero value otherwise (both if not set or set to explicit null). func (o *NodeReservedResources) GetDisk() NodeReservedDiskResources { - if o == nil || o.Disk == nil { + if o == nil || o.Disk.Get() == nil { var ret NodeReservedDiskResources return ret } - return *o.Disk + return *o.Disk.Get() } // GetDiskOk returns a tuple with the Disk field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *NodeReservedResources) GetDiskOk() (*NodeReservedDiskResources, bool) { - if o == nil || o.Disk == nil { + if o == nil { return nil, false } - return o.Disk, true + return o.Disk.Get(), o.Disk.IsSet() } // HasDisk returns a boolean if a field has been set. func (o *NodeReservedResources) HasDisk() bool { - if o != nil && o.Disk != nil { + if o != nil && o.Disk.IsSet() { return true } return false } -// SetDisk gets a reference to the given NodeReservedDiskResources and assigns it to the Disk field. +// SetDisk gets a reference to the given NullableNodeReservedDiskResources and assigns it to the Disk field. func (o *NodeReservedResources) SetDisk(v NodeReservedDiskResources) { - o.Disk = &v + o.Disk.Set(&v) +} +// SetDiskNil sets the value for Disk to be an explicit nil +func (o *NodeReservedResources) SetDiskNil() { + o.Disk.Set(nil) +} + +// UnsetDisk ensures that no value is present for Disk, not even an explicit nil +func (o *NodeReservedResources) UnsetDisk() { + o.Disk.Unset() } -// GetMemory returns the Memory field value if set, zero value otherwise. +// GetMemory returns the Memory field value if set, zero value otherwise (both if not set or set to explicit null). func (o *NodeReservedResources) GetMemory() NodeReservedMemoryResources { - if o == nil || o.Memory == nil { + if o == nil || o.Memory.Get() == nil { var ret NodeReservedMemoryResources return ret } - return *o.Memory + return *o.Memory.Get() } // GetMemoryOk returns a tuple with the Memory field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *NodeReservedResources) GetMemoryOk() (*NodeReservedMemoryResources, bool) { - if o == nil || o.Memory == nil { + if o == nil { return nil, false } - return o.Memory, true + return o.Memory.Get(), o.Memory.IsSet() } // HasMemory returns a boolean if a field has been set. func (o *NodeReservedResources) HasMemory() bool { - if o != nil && o.Memory != nil { + if o != nil && o.Memory.IsSet() { return true } return false } -// SetMemory gets a reference to the given NodeReservedMemoryResources and assigns it to the Memory field. +// SetMemory gets a reference to the given NullableNodeReservedMemoryResources and assigns it to the Memory field. func (o *NodeReservedResources) SetMemory(v NodeReservedMemoryResources) { - o.Memory = &v + o.Memory.Set(&v) +} +// SetMemoryNil sets the value for Memory to be an explicit nil +func (o *NodeReservedResources) SetMemoryNil() { + o.Memory.Set(nil) +} + +// UnsetMemory ensures that no value is present for Memory, not even an explicit nil +func (o *NodeReservedResources) UnsetMemory() { + o.Memory.Unset() } -// GetNetworks returns the Networks field value if set, zero value otherwise. +// GetNetworks returns the Networks field value if set, zero value otherwise (both if not set or set to explicit null). func (o *NodeReservedResources) GetNetworks() NodeReservedNetworkResources { - if o == nil || o.Networks == nil { + if o == nil || o.Networks.Get() == nil { var ret NodeReservedNetworkResources return ret } - return *o.Networks + return *o.Networks.Get() } // GetNetworksOk returns a tuple with the Networks field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *NodeReservedResources) GetNetworksOk() (*NodeReservedNetworkResources, bool) { - if o == nil || o.Networks == nil { + if o == nil { return nil, false } - return o.Networks, true + return o.Networks.Get(), o.Networks.IsSet() } // HasNetworks returns a boolean if a field has been set. func (o *NodeReservedResources) HasNetworks() bool { - if o != nil && o.Networks != nil { + if o != nil && o.Networks.IsSet() { return true } return false } -// SetNetworks gets a reference to the given NodeReservedNetworkResources and assigns it to the Networks field. +// SetNetworks gets a reference to the given NullableNodeReservedNetworkResources and assigns it to the Networks field. func (o *NodeReservedResources) SetNetworks(v NodeReservedNetworkResources) { - o.Networks = &v + o.Networks.Set(&v) +} +// SetNetworksNil sets the value for Networks to be an explicit nil +func (o *NodeReservedResources) SetNetworksNil() { + o.Networks.Set(nil) +} + +// UnsetNetworks ensures that no value is present for Networks, not even an explicit nil +func (o *NodeReservedResources) UnsetNetworks() { + o.Networks.Unset() } func (o NodeReservedResources) MarshalJSON() ([]byte, error) { toSerialize := map[string]interface{}{} - if o.Cpu != nil { - toSerialize["Cpu"] = o.Cpu + if o.Cpu.IsSet() { + toSerialize["Cpu"] = o.Cpu.Get() } - if o.Disk != nil { - toSerialize["Disk"] = o.Disk + if o.Disk.IsSet() { + toSerialize["Disk"] = o.Disk.Get() } - if o.Memory != nil { - toSerialize["Memory"] = o.Memory + if o.Memory.IsSet() { + toSerialize["Memory"] = o.Memory.Get() } - if o.Networks != nil { - toSerialize["Networks"] = o.Networks + if o.Networks.IsSet() { + toSerialize["Networks"] = o.Networks.Get() } return json.Marshal(toSerialize) } diff --git a/clients/go/v1/model_node_resources.go b/clients/go/v1/model_node_resources.go index 9b3b7281..aaff620e 100644 --- a/clients/go/v1/model_node_resources.go +++ b/clients/go/v1/model_node_resources.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,13 +17,13 @@ import ( // NodeResources struct for NodeResources type NodeResources struct { - Cpu *NodeCpuResources `json:"Cpu,omitempty"` - Devices *[]NodeDeviceResource `json:"Devices,omitempty"` - Disk *NodeDiskResources `json:"Disk,omitempty"` + Cpu NullableNodeCpuResources `json:"Cpu,omitempty"` + Devices []NodeDeviceResource `json:"Devices,omitempty"` + Disk NullableNodeDiskResources `json:"Disk,omitempty"` MaxDynamicPort *int32 `json:"MaxDynamicPort,omitempty"` - Memory *NodeMemoryResources `json:"Memory,omitempty"` + Memory NullableNodeMemoryResources `json:"Memory,omitempty"` MinDynamicPort *int32 `json:"MinDynamicPort,omitempty"` - Networks *[]NetworkResource `json:"Networks,omitempty"` + Networks []NetworkResource `json:"Networks,omitempty"` } // NewNodeResources instantiates a new NodeResources object @@ -43,36 +43,46 @@ func NewNodeResourcesWithDefaults() *NodeResources { return &this } -// GetCpu returns the Cpu field value if set, zero value otherwise. +// GetCpu returns the Cpu field value if set, zero value otherwise (both if not set or set to explicit null). func (o *NodeResources) GetCpu() NodeCpuResources { - if o == nil || o.Cpu == nil { + if o == nil || o.Cpu.Get() == nil { var ret NodeCpuResources return ret } - return *o.Cpu + return *o.Cpu.Get() } // GetCpuOk returns a tuple with the Cpu field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *NodeResources) GetCpuOk() (*NodeCpuResources, bool) { - if o == nil || o.Cpu == nil { + if o == nil { return nil, false } - return o.Cpu, true + return o.Cpu.Get(), o.Cpu.IsSet() } // HasCpu returns a boolean if a field has been set. func (o *NodeResources) HasCpu() bool { - if o != nil && o.Cpu != nil { + if o != nil && o.Cpu.IsSet() { return true } return false } -// SetCpu gets a reference to the given NodeCpuResources and assigns it to the Cpu field. +// SetCpu gets a reference to the given NullableNodeCpuResources and assigns it to the Cpu field. func (o *NodeResources) SetCpu(v NodeCpuResources) { - o.Cpu = &v + o.Cpu.Set(&v) +} +// SetCpuNil sets the value for Cpu to be an explicit nil +func (o *NodeResources) SetCpuNil() { + o.Cpu.Set(nil) +} + +// UnsetCpu ensures that no value is present for Cpu, not even an explicit nil +func (o *NodeResources) UnsetCpu() { + o.Cpu.Unset() } // GetDevices returns the Devices field value if set, zero value otherwise. @@ -81,12 +91,12 @@ func (o *NodeResources) GetDevices() []NodeDeviceResource { var ret []NodeDeviceResource return ret } - return *o.Devices + return o.Devices } // GetDevicesOk returns a tuple with the Devices field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *NodeResources) GetDevicesOk() (*[]NodeDeviceResource, bool) { +func (o *NodeResources) GetDevicesOk() ([]NodeDeviceResource, bool) { if o == nil || o.Devices == nil { return nil, false } @@ -104,39 +114,49 @@ func (o *NodeResources) HasDevices() bool { // SetDevices gets a reference to the given []NodeDeviceResource and assigns it to the Devices field. func (o *NodeResources) SetDevices(v []NodeDeviceResource) { - o.Devices = &v + o.Devices = v } -// GetDisk returns the Disk field value if set, zero value otherwise. +// GetDisk returns the Disk field value if set, zero value otherwise (both if not set or set to explicit null). func (o *NodeResources) GetDisk() NodeDiskResources { - if o == nil || o.Disk == nil { + if o == nil || o.Disk.Get() == nil { var ret NodeDiskResources return ret } - return *o.Disk + return *o.Disk.Get() } // GetDiskOk returns a tuple with the Disk field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *NodeResources) GetDiskOk() (*NodeDiskResources, bool) { - if o == nil || o.Disk == nil { + if o == nil { return nil, false } - return o.Disk, true + return o.Disk.Get(), o.Disk.IsSet() } // HasDisk returns a boolean if a field has been set. func (o *NodeResources) HasDisk() bool { - if o != nil && o.Disk != nil { + if o != nil && o.Disk.IsSet() { return true } return false } -// SetDisk gets a reference to the given NodeDiskResources and assigns it to the Disk field. +// SetDisk gets a reference to the given NullableNodeDiskResources and assigns it to the Disk field. func (o *NodeResources) SetDisk(v NodeDiskResources) { - o.Disk = &v + o.Disk.Set(&v) +} +// SetDiskNil sets the value for Disk to be an explicit nil +func (o *NodeResources) SetDiskNil() { + o.Disk.Set(nil) +} + +// UnsetDisk ensures that no value is present for Disk, not even an explicit nil +func (o *NodeResources) UnsetDisk() { + o.Disk.Unset() } // GetMaxDynamicPort returns the MaxDynamicPort field value if set, zero value otherwise. @@ -171,36 +191,46 @@ func (o *NodeResources) SetMaxDynamicPort(v int32) { o.MaxDynamicPort = &v } -// GetMemory returns the Memory field value if set, zero value otherwise. +// GetMemory returns the Memory field value if set, zero value otherwise (both if not set or set to explicit null). func (o *NodeResources) GetMemory() NodeMemoryResources { - if o == nil || o.Memory == nil { + if o == nil || o.Memory.Get() == nil { var ret NodeMemoryResources return ret } - return *o.Memory + return *o.Memory.Get() } // GetMemoryOk returns a tuple with the Memory field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *NodeResources) GetMemoryOk() (*NodeMemoryResources, bool) { - if o == nil || o.Memory == nil { + if o == nil { return nil, false } - return o.Memory, true + return o.Memory.Get(), o.Memory.IsSet() } // HasMemory returns a boolean if a field has been set. func (o *NodeResources) HasMemory() bool { - if o != nil && o.Memory != nil { + if o != nil && o.Memory.IsSet() { return true } return false } -// SetMemory gets a reference to the given NodeMemoryResources and assigns it to the Memory field. +// SetMemory gets a reference to the given NullableNodeMemoryResources and assigns it to the Memory field. func (o *NodeResources) SetMemory(v NodeMemoryResources) { - o.Memory = &v + o.Memory.Set(&v) +} +// SetMemoryNil sets the value for Memory to be an explicit nil +func (o *NodeResources) SetMemoryNil() { + o.Memory.Set(nil) +} + +// UnsetMemory ensures that no value is present for Memory, not even an explicit nil +func (o *NodeResources) UnsetMemory() { + o.Memory.Unset() } // GetMinDynamicPort returns the MinDynamicPort field value if set, zero value otherwise. @@ -241,12 +271,12 @@ func (o *NodeResources) GetNetworks() []NetworkResource { var ret []NetworkResource return ret } - return *o.Networks + return o.Networks } // GetNetworksOk returns a tuple with the Networks field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *NodeResources) GetNetworksOk() (*[]NetworkResource, bool) { +func (o *NodeResources) GetNetworksOk() ([]NetworkResource, bool) { if o == nil || o.Networks == nil { return nil, false } @@ -264,25 +294,25 @@ func (o *NodeResources) HasNetworks() bool { // SetNetworks gets a reference to the given []NetworkResource and assigns it to the Networks field. func (o *NodeResources) SetNetworks(v []NetworkResource) { - o.Networks = &v + o.Networks = v } func (o NodeResources) MarshalJSON() ([]byte, error) { toSerialize := map[string]interface{}{} - if o.Cpu != nil { - toSerialize["Cpu"] = o.Cpu + if o.Cpu.IsSet() { + toSerialize["Cpu"] = o.Cpu.Get() } if o.Devices != nil { toSerialize["Devices"] = o.Devices } - if o.Disk != nil { - toSerialize["Disk"] = o.Disk + if o.Disk.IsSet() { + toSerialize["Disk"] = o.Disk.Get() } if o.MaxDynamicPort != nil { toSerialize["MaxDynamicPort"] = o.MaxDynamicPort } - if o.Memory != nil { - toSerialize["Memory"] = o.Memory + if o.Memory.IsSet() { + toSerialize["Memory"] = o.Memory.Get() } if o.MinDynamicPort != nil { toSerialize["MinDynamicPort"] = o.MinDynamicPort diff --git a/clients/go/v1/model_node_score_meta.go b/clients/go/v1/model_node_score_meta.go index 83cd01c3..2e6c819c 100644 --- a/clients/go/v1/model_node_score_meta.go +++ b/clients/go/v1/model_node_score_meta.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_node_update_drain_request.go b/clients/go/v1/model_node_update_drain_request.go index cf656aa2..17f3c515 100644 --- a/clients/go/v1/model_node_update_drain_request.go +++ b/clients/go/v1/model_node_update_drain_request.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,7 +17,7 @@ import ( // NodeUpdateDrainRequest struct for NodeUpdateDrainRequest type NodeUpdateDrainRequest struct { - DrainSpec *DrainSpec `json:"DrainSpec,omitempty"` + DrainSpec NullableDrainSpec `json:"DrainSpec,omitempty"` MarkEligible *bool `json:"MarkEligible,omitempty"` Meta *map[string]string `json:"Meta,omitempty"` NodeID *string `json:"NodeID,omitempty"` @@ -40,36 +40,46 @@ func NewNodeUpdateDrainRequestWithDefaults() *NodeUpdateDrainRequest { return &this } -// GetDrainSpec returns the DrainSpec field value if set, zero value otherwise. +// GetDrainSpec returns the DrainSpec field value if set, zero value otherwise (both if not set or set to explicit null). func (o *NodeUpdateDrainRequest) GetDrainSpec() DrainSpec { - if o == nil || o.DrainSpec == nil { + if o == nil || o.DrainSpec.Get() == nil { var ret DrainSpec return ret } - return *o.DrainSpec + return *o.DrainSpec.Get() } // GetDrainSpecOk returns a tuple with the DrainSpec field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *NodeUpdateDrainRequest) GetDrainSpecOk() (*DrainSpec, bool) { - if o == nil || o.DrainSpec == nil { + if o == nil { return nil, false } - return o.DrainSpec, true + return o.DrainSpec.Get(), o.DrainSpec.IsSet() } // HasDrainSpec returns a boolean if a field has been set. func (o *NodeUpdateDrainRequest) HasDrainSpec() bool { - if o != nil && o.DrainSpec != nil { + if o != nil && o.DrainSpec.IsSet() { return true } return false } -// SetDrainSpec gets a reference to the given DrainSpec and assigns it to the DrainSpec field. +// SetDrainSpec gets a reference to the given NullableDrainSpec and assigns it to the DrainSpec field. func (o *NodeUpdateDrainRequest) SetDrainSpec(v DrainSpec) { - o.DrainSpec = &v + o.DrainSpec.Set(&v) +} +// SetDrainSpecNil sets the value for DrainSpec to be an explicit nil +func (o *NodeUpdateDrainRequest) SetDrainSpecNil() { + o.DrainSpec.Set(nil) +} + +// UnsetDrainSpec ensures that no value is present for DrainSpec, not even an explicit nil +func (o *NodeUpdateDrainRequest) UnsetDrainSpec() { + o.DrainSpec.Unset() } // GetMarkEligible returns the MarkEligible field value if set, zero value otherwise. @@ -170,8 +180,8 @@ func (o *NodeUpdateDrainRequest) SetNodeID(v string) { func (o NodeUpdateDrainRequest) MarshalJSON() ([]byte, error) { toSerialize := map[string]interface{}{} - if o.DrainSpec != nil { - toSerialize["DrainSpec"] = o.DrainSpec + if o.DrainSpec.IsSet() { + toSerialize["DrainSpec"] = o.DrainSpec.Get() } if o.MarkEligible != nil { toSerialize["MarkEligible"] = o.MarkEligible diff --git a/clients/go/v1/model_node_update_eligibility_request.go b/clients/go/v1/model_node_update_eligibility_request.go index 7d16d57a..859c1273 100644 --- a/clients/go/v1/model_node_update_eligibility_request.go +++ b/clients/go/v1/model_node_update_eligibility_request.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_object_diff.go b/clients/go/v1/model_object_diff.go index c9028801..1936861e 100644 --- a/clients/go/v1/model_object_diff.go +++ b/clients/go/v1/model_object_diff.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,9 +17,9 @@ import ( // ObjectDiff struct for ObjectDiff type ObjectDiff struct { - Fields *[]FieldDiff `json:"Fields,omitempty"` + Fields []FieldDiff `json:"Fields,omitempty"` Name *string `json:"Name,omitempty"` - Objects *[]ObjectDiff `json:"Objects,omitempty"` + Objects []ObjectDiff `json:"Objects,omitempty"` Type *string `json:"Type,omitempty"` } @@ -46,12 +46,12 @@ func (o *ObjectDiff) GetFields() []FieldDiff { var ret []FieldDiff return ret } - return *o.Fields + return o.Fields } // GetFieldsOk returns a tuple with the Fields field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *ObjectDiff) GetFieldsOk() (*[]FieldDiff, bool) { +func (o *ObjectDiff) GetFieldsOk() ([]FieldDiff, bool) { if o == nil || o.Fields == nil { return nil, false } @@ -69,7 +69,7 @@ func (o *ObjectDiff) HasFields() bool { // SetFields gets a reference to the given []FieldDiff and assigns it to the Fields field. func (o *ObjectDiff) SetFields(v []FieldDiff) { - o.Fields = &v + o.Fields = v } // GetName returns the Name field value if set, zero value otherwise. @@ -110,12 +110,12 @@ func (o *ObjectDiff) GetObjects() []ObjectDiff { var ret []ObjectDiff return ret } - return *o.Objects + return o.Objects } // GetObjectsOk returns a tuple with the Objects field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *ObjectDiff) GetObjectsOk() (*[]ObjectDiff, bool) { +func (o *ObjectDiff) GetObjectsOk() ([]ObjectDiff, bool) { if o == nil || o.Objects == nil { return nil, false } @@ -133,7 +133,7 @@ func (o *ObjectDiff) HasObjects() bool { // SetObjects gets a reference to the given []ObjectDiff and assigns it to the Objects field. func (o *ObjectDiff) SetObjects(v []ObjectDiff) { - o.Objects = &v + o.Objects = v } // GetType returns the Type field value if set, zero value otherwise. diff --git a/clients/go/v1/model_one_time_token.go b/clients/go/v1/model_one_time_token.go index 54ace0f8..fe4442fe 100644 --- a/clients/go/v1/model_one_time_token.go +++ b/clients/go/v1/model_one_time_token.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -20,7 +20,7 @@ import ( type OneTimeToken struct { AccessorID *string `json:"AccessorID,omitempty"` CreateIndex *int32 `json:"CreateIndex,omitempty"` - ExpiresAt *time.Time `json:"ExpiresAt,omitempty"` + ExpiresAt NullableTime `json:"ExpiresAt,omitempty"` ModifyIndex *int32 `json:"ModifyIndex,omitempty"` OneTimeSecretID *string `json:"OneTimeSecretID,omitempty"` } @@ -106,36 +106,46 @@ func (o *OneTimeToken) SetCreateIndex(v int32) { o.CreateIndex = &v } -// GetExpiresAt returns the ExpiresAt field value if set, zero value otherwise. +// GetExpiresAt returns the ExpiresAt field value if set, zero value otherwise (both if not set or set to explicit null). func (o *OneTimeToken) GetExpiresAt() time.Time { - if o == nil || o.ExpiresAt == nil { + if o == nil || o.ExpiresAt.Get() == nil { var ret time.Time return ret } - return *o.ExpiresAt + return *o.ExpiresAt.Get() } // GetExpiresAtOk returns a tuple with the ExpiresAt field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *OneTimeToken) GetExpiresAtOk() (*time.Time, bool) { - if o == nil || o.ExpiresAt == nil { + if o == nil { return nil, false } - return o.ExpiresAt, true + return o.ExpiresAt.Get(), o.ExpiresAt.IsSet() } // HasExpiresAt returns a boolean if a field has been set. func (o *OneTimeToken) HasExpiresAt() bool { - if o != nil && o.ExpiresAt != nil { + if o != nil && o.ExpiresAt.IsSet() { return true } return false } -// SetExpiresAt gets a reference to the given time.Time and assigns it to the ExpiresAt field. +// SetExpiresAt gets a reference to the given NullableTime and assigns it to the ExpiresAt field. func (o *OneTimeToken) SetExpiresAt(v time.Time) { - o.ExpiresAt = &v + o.ExpiresAt.Set(&v) +} +// SetExpiresAtNil sets the value for ExpiresAt to be an explicit nil +func (o *OneTimeToken) SetExpiresAtNil() { + o.ExpiresAt.Set(nil) +} + +// UnsetExpiresAt ensures that no value is present for ExpiresAt, not even an explicit nil +func (o *OneTimeToken) UnsetExpiresAt() { + o.ExpiresAt.Unset() } // GetModifyIndex returns the ModifyIndex field value if set, zero value otherwise. @@ -210,8 +220,8 @@ func (o OneTimeToken) MarshalJSON() ([]byte, error) { if o.CreateIndex != nil { toSerialize["CreateIndex"] = o.CreateIndex } - if o.ExpiresAt != nil { - toSerialize["ExpiresAt"] = o.ExpiresAt + if o.ExpiresAt.IsSet() { + toSerialize["ExpiresAt"] = o.ExpiresAt.Get() } if o.ModifyIndex != nil { toSerialize["ModifyIndex"] = o.ModifyIndex diff --git a/clients/go/v1/model_one_time_token_exchange_request.go b/clients/go/v1/model_one_time_token_exchange_request.go index 3740c41c..baad1b36 100644 --- a/clients/go/v1/model_one_time_token_exchange_request.go +++ b/clients/go/v1/model_one_time_token_exchange_request.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_operator_health_reply.go b/clients/go/v1/model_operator_health_reply.go index b10d11e4..9510868a 100644 --- a/clients/go/v1/model_operator_health_reply.go +++ b/clients/go/v1/model_operator_health_reply.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -19,7 +19,7 @@ import ( type OperatorHealthReply struct { FailureTolerance *int32 `json:"FailureTolerance,omitempty"` Healthy *bool `json:"Healthy,omitempty"` - Servers *[]ServerHealth `json:"Servers,omitempty"` + Servers []ServerHealth `json:"Servers,omitempty"` } // NewOperatorHealthReply instantiates a new OperatorHealthReply object @@ -109,12 +109,12 @@ func (o *OperatorHealthReply) GetServers() []ServerHealth { var ret []ServerHealth return ret } - return *o.Servers + return o.Servers } // GetServersOk returns a tuple with the Servers field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *OperatorHealthReply) GetServersOk() (*[]ServerHealth, bool) { +func (o *OperatorHealthReply) GetServersOk() ([]ServerHealth, bool) { if o == nil || o.Servers == nil { return nil, false } @@ -132,7 +132,7 @@ func (o *OperatorHealthReply) HasServers() bool { // SetServers gets a reference to the given []ServerHealth and assigns it to the Servers field. func (o *OperatorHealthReply) SetServers(v []ServerHealth) { - o.Servers = &v + o.Servers = v } func (o OperatorHealthReply) MarshalJSON() ([]byte, error) { diff --git a/clients/go/v1/model_parameterized_job_config.go b/clients/go/v1/model_parameterized_job_config.go index 2aa7d1dc..9446f51f 100644 --- a/clients/go/v1/model_parameterized_job_config.go +++ b/clients/go/v1/model_parameterized_job_config.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,8 +17,8 @@ import ( // ParameterizedJobConfig struct for ParameterizedJobConfig type ParameterizedJobConfig struct { - MetaOptional *[]string `json:"MetaOptional,omitempty"` - MetaRequired *[]string `json:"MetaRequired,omitempty"` + MetaOptional []string `json:"MetaOptional,omitempty"` + MetaRequired []string `json:"MetaRequired,omitempty"` Payload *string `json:"Payload,omitempty"` } @@ -45,12 +45,12 @@ func (o *ParameterizedJobConfig) GetMetaOptional() []string { var ret []string return ret } - return *o.MetaOptional + return o.MetaOptional } // GetMetaOptionalOk returns a tuple with the MetaOptional field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *ParameterizedJobConfig) GetMetaOptionalOk() (*[]string, bool) { +func (o *ParameterizedJobConfig) GetMetaOptionalOk() ([]string, bool) { if o == nil || o.MetaOptional == nil { return nil, false } @@ -68,7 +68,7 @@ func (o *ParameterizedJobConfig) HasMetaOptional() bool { // SetMetaOptional gets a reference to the given []string and assigns it to the MetaOptional field. func (o *ParameterizedJobConfig) SetMetaOptional(v []string) { - o.MetaOptional = &v + o.MetaOptional = v } // GetMetaRequired returns the MetaRequired field value if set, zero value otherwise. @@ -77,12 +77,12 @@ func (o *ParameterizedJobConfig) GetMetaRequired() []string { var ret []string return ret } - return *o.MetaRequired + return o.MetaRequired } // GetMetaRequiredOk returns a tuple with the MetaRequired field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *ParameterizedJobConfig) GetMetaRequiredOk() (*[]string, bool) { +func (o *ParameterizedJobConfig) GetMetaRequiredOk() ([]string, bool) { if o == nil || o.MetaRequired == nil { return nil, false } @@ -100,7 +100,7 @@ func (o *ParameterizedJobConfig) HasMetaRequired() bool { // SetMetaRequired gets a reference to the given []string and assigns it to the MetaRequired field. func (o *ParameterizedJobConfig) SetMetaRequired(v []string) { - o.MetaRequired = &v + o.MetaRequired = v } // GetPayload returns the Payload field value if set, zero value otherwise. diff --git a/clients/go/v1/model_periodic_config.go b/clients/go/v1/model_periodic_config.go index 7c56e7a0..d53e163a 100644 --- a/clients/go/v1/model_periodic_config.go +++ b/clients/go/v1/model_periodic_config.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_periodic_force_response.go b/clients/go/v1/model_periodic_force_response.go index 81d3469f..31e71307 100644 --- a/clients/go/v1/model_periodic_force_response.go +++ b/clients/go/v1/model_periodic_force_response.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_plan_annotations.go b/clients/go/v1/model_plan_annotations.go index 019d3c46..3c32889c 100644 --- a/clients/go/v1/model_plan_annotations.go +++ b/clients/go/v1/model_plan_annotations.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -18,7 +18,7 @@ import ( // PlanAnnotations struct for PlanAnnotations type PlanAnnotations struct { DesiredTGUpdates *map[string]DesiredUpdates `json:"DesiredTGUpdates,omitempty"` - PreemptedAllocs *[]AllocationListStub `json:"PreemptedAllocs,omitempty"` + PreemptedAllocs []AllocationListStub `json:"PreemptedAllocs,omitempty"` } // NewPlanAnnotations instantiates a new PlanAnnotations object @@ -76,12 +76,12 @@ func (o *PlanAnnotations) GetPreemptedAllocs() []AllocationListStub { var ret []AllocationListStub return ret } - return *o.PreemptedAllocs + return o.PreemptedAllocs } // GetPreemptedAllocsOk returns a tuple with the PreemptedAllocs field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *PlanAnnotations) GetPreemptedAllocsOk() (*[]AllocationListStub, bool) { +func (o *PlanAnnotations) GetPreemptedAllocsOk() ([]AllocationListStub, bool) { if o == nil || o.PreemptedAllocs == nil { return nil, false } @@ -99,7 +99,7 @@ func (o *PlanAnnotations) HasPreemptedAllocs() bool { // SetPreemptedAllocs gets a reference to the given []AllocationListStub and assigns it to the PreemptedAllocs field. func (o *PlanAnnotations) SetPreemptedAllocs(v []AllocationListStub) { - o.PreemptedAllocs = &v + o.PreemptedAllocs = v } func (o PlanAnnotations) MarshalJSON() ([]byte, error) { diff --git a/clients/go/v1/model_point_value.go b/clients/go/v1/model_point_value.go index 4f55b9bb..ba56e4b0 100644 --- a/clients/go/v1/model_point_value.go +++ b/clients/go/v1/model_point_value.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -18,7 +18,7 @@ import ( // PointValue struct for PointValue type PointValue struct { Name *string `json:"Name,omitempty"` - Points *[]float32 `json:"Points,omitempty"` + Points []float32 `json:"Points,omitempty"` } // NewPointValue instantiates a new PointValue object @@ -76,12 +76,12 @@ func (o *PointValue) GetPoints() []float32 { var ret []float32 return ret } - return *o.Points + return o.Points } // GetPointsOk returns a tuple with the Points field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *PointValue) GetPointsOk() (*[]float32, bool) { +func (o *PointValue) GetPointsOk() ([]float32, bool) { if o == nil || o.Points == nil { return nil, false } @@ -99,7 +99,7 @@ func (o *PointValue) HasPoints() bool { // SetPoints gets a reference to the given []float32 and assigns it to the Points field. func (o *PointValue) SetPoints(v []float32) { - o.Points = &v + o.Points = v } func (o PointValue) MarshalJSON() ([]byte, error) { diff --git a/clients/go/v1/model_port.go b/clients/go/v1/model_port.go index a5b43152..b8ebabc8 100644 --- a/clients/go/v1/model_port.go +++ b/clients/go/v1/model_port.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_port_mapping.go b/clients/go/v1/model_port_mapping.go index 0a639e78..4761cf75 100644 --- a/clients/go/v1/model_port_mapping.go +++ b/clients/go/v1/model_port_mapping.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_preemption_config.go b/clients/go/v1/model_preemption_config.go index a681d503..70c25bfe 100644 --- a/clients/go/v1/model_preemption_config.go +++ b/clients/go/v1/model_preemption_config.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_quota_limit.go b/clients/go/v1/model_quota_limit.go index 3c6649a8..c04d6856 100644 --- a/clients/go/v1/model_quota_limit.go +++ b/clients/go/v1/model_quota_limit.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -19,7 +19,7 @@ import ( type QuotaLimit struct { Hash *string `json:"Hash,omitempty"` Region *string `json:"Region,omitempty"` - RegionLimit *Resources `json:"RegionLimit,omitempty"` + RegionLimit NullableResources `json:"RegionLimit,omitempty"` } // NewQuotaLimit instantiates a new QuotaLimit object @@ -103,36 +103,46 @@ func (o *QuotaLimit) SetRegion(v string) { o.Region = &v } -// GetRegionLimit returns the RegionLimit field value if set, zero value otherwise. +// GetRegionLimit returns the RegionLimit field value if set, zero value otherwise (both if not set or set to explicit null). func (o *QuotaLimit) GetRegionLimit() Resources { - if o == nil || o.RegionLimit == nil { + if o == nil || o.RegionLimit.Get() == nil { var ret Resources return ret } - return *o.RegionLimit + return *o.RegionLimit.Get() } // GetRegionLimitOk returns a tuple with the RegionLimit field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *QuotaLimit) GetRegionLimitOk() (*Resources, bool) { - if o == nil || o.RegionLimit == nil { + if o == nil { return nil, false } - return o.RegionLimit, true + return o.RegionLimit.Get(), o.RegionLimit.IsSet() } // HasRegionLimit returns a boolean if a field has been set. func (o *QuotaLimit) HasRegionLimit() bool { - if o != nil && o.RegionLimit != nil { + if o != nil && o.RegionLimit.IsSet() { return true } return false } -// SetRegionLimit gets a reference to the given Resources and assigns it to the RegionLimit field. +// SetRegionLimit gets a reference to the given NullableResources and assigns it to the RegionLimit field. func (o *QuotaLimit) SetRegionLimit(v Resources) { - o.RegionLimit = &v + o.RegionLimit.Set(&v) +} +// SetRegionLimitNil sets the value for RegionLimit to be an explicit nil +func (o *QuotaLimit) SetRegionLimitNil() { + o.RegionLimit.Set(nil) +} + +// UnsetRegionLimit ensures that no value is present for RegionLimit, not even an explicit nil +func (o *QuotaLimit) UnsetRegionLimit() { + o.RegionLimit.Unset() } func (o QuotaLimit) MarshalJSON() ([]byte, error) { @@ -143,8 +153,8 @@ func (o QuotaLimit) MarshalJSON() ([]byte, error) { if o.Region != nil { toSerialize["Region"] = o.Region } - if o.RegionLimit != nil { - toSerialize["RegionLimit"] = o.RegionLimit + if o.RegionLimit.IsSet() { + toSerialize["RegionLimit"] = o.RegionLimit.Get() } return json.Marshal(toSerialize) } diff --git a/clients/go/v1/model_quota_spec.go b/clients/go/v1/model_quota_spec.go index 155e88d6..711accef 100644 --- a/clients/go/v1/model_quota_spec.go +++ b/clients/go/v1/model_quota_spec.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -19,7 +19,7 @@ import ( type QuotaSpec struct { CreateIndex *int32 `json:"CreateIndex,omitempty"` Description *string `json:"Description,omitempty"` - Limits *[]QuotaLimit `json:"Limits,omitempty"` + Limits []QuotaLimit `json:"Limits,omitempty"` ModifyIndex *int32 `json:"ModifyIndex,omitempty"` Name *string `json:"Name,omitempty"` } @@ -111,12 +111,12 @@ func (o *QuotaSpec) GetLimits() []QuotaLimit { var ret []QuotaLimit return ret } - return *o.Limits + return o.Limits } // GetLimitsOk returns a tuple with the Limits field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *QuotaSpec) GetLimitsOk() (*[]QuotaLimit, bool) { +func (o *QuotaSpec) GetLimitsOk() ([]QuotaLimit, bool) { if o == nil || o.Limits == nil { return nil, false } @@ -134,7 +134,7 @@ func (o *QuotaSpec) HasLimits() bool { // SetLimits gets a reference to the given []QuotaLimit and assigns it to the Limits field. func (o *QuotaSpec) SetLimits(v []QuotaLimit) { - o.Limits = &v + o.Limits = v } // GetModifyIndex returns the ModifyIndex field value if set, zero value otherwise. diff --git a/clients/go/v1/model_raft_configuration.go b/clients/go/v1/model_raft_configuration.go index fec2851f..36582512 100644 --- a/clients/go/v1/model_raft_configuration.go +++ b/clients/go/v1/model_raft_configuration.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -18,7 +18,7 @@ import ( // RaftConfiguration struct for RaftConfiguration type RaftConfiguration struct { Index *int32 `json:"Index,omitempty"` - Servers *[]RaftServer `json:"Servers,omitempty"` + Servers []RaftServer `json:"Servers,omitempty"` } // NewRaftConfiguration instantiates a new RaftConfiguration object @@ -76,12 +76,12 @@ func (o *RaftConfiguration) GetServers() []RaftServer { var ret []RaftServer return ret } - return *o.Servers + return o.Servers } // GetServersOk returns a tuple with the Servers field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *RaftConfiguration) GetServersOk() (*[]RaftServer, bool) { +func (o *RaftConfiguration) GetServersOk() ([]RaftServer, bool) { if o == nil || o.Servers == nil { return nil, false } @@ -99,7 +99,7 @@ func (o *RaftConfiguration) HasServers() bool { // SetServers gets a reference to the given []RaftServer and assigns it to the Servers field. func (o *RaftConfiguration) SetServers(v []RaftServer) { - o.Servers = &v + o.Servers = v } func (o RaftConfiguration) MarshalJSON() ([]byte, error) { diff --git a/clients/go/v1/model_raft_server.go b/clients/go/v1/model_raft_server.go index edc3e7c1..f201777d 100644 --- a/clients/go/v1/model_raft_server.go +++ b/clients/go/v1/model_raft_server.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_requested_device.go b/clients/go/v1/model_requested_device.go index 0f9a5f17..170bda95 100644 --- a/clients/go/v1/model_requested_device.go +++ b/clients/go/v1/model_requested_device.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,8 +17,8 @@ import ( // RequestedDevice struct for RequestedDevice type RequestedDevice struct { - Affinities *[]Affinity `json:"Affinities,omitempty"` - Constraints *[]Constraint `json:"Constraints,omitempty"` + Affinities []Affinity `json:"Affinities,omitempty"` + Constraints []Constraint `json:"Constraints,omitempty"` Count *int32 `json:"Count,omitempty"` Name *string `json:"Name,omitempty"` } @@ -46,12 +46,12 @@ func (o *RequestedDevice) GetAffinities() []Affinity { var ret []Affinity return ret } - return *o.Affinities + return o.Affinities } // GetAffinitiesOk returns a tuple with the Affinities field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *RequestedDevice) GetAffinitiesOk() (*[]Affinity, bool) { +func (o *RequestedDevice) GetAffinitiesOk() ([]Affinity, bool) { if o == nil || o.Affinities == nil { return nil, false } @@ -69,7 +69,7 @@ func (o *RequestedDevice) HasAffinities() bool { // SetAffinities gets a reference to the given []Affinity and assigns it to the Affinities field. func (o *RequestedDevice) SetAffinities(v []Affinity) { - o.Affinities = &v + o.Affinities = v } // GetConstraints returns the Constraints field value if set, zero value otherwise. @@ -78,12 +78,12 @@ func (o *RequestedDevice) GetConstraints() []Constraint { var ret []Constraint return ret } - return *o.Constraints + return o.Constraints } // GetConstraintsOk returns a tuple with the Constraints field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *RequestedDevice) GetConstraintsOk() (*[]Constraint, bool) { +func (o *RequestedDevice) GetConstraintsOk() ([]Constraint, bool) { if o == nil || o.Constraints == nil { return nil, false } @@ -101,7 +101,7 @@ func (o *RequestedDevice) HasConstraints() bool { // SetConstraints gets a reference to the given []Constraint and assigns it to the Constraints field. func (o *RequestedDevice) SetConstraints(v []Constraint) { - o.Constraints = &v + o.Constraints = v } // GetCount returns the Count field value if set, zero value otherwise. diff --git a/clients/go/v1/model_reschedule_event.go b/clients/go/v1/model_reschedule_event.go index 75c30a16..b0176829 100644 --- a/clients/go/v1/model_reschedule_event.go +++ b/clients/go/v1/model_reschedule_event.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_reschedule_policy.go b/clients/go/v1/model_reschedule_policy.go index 7c4d8f94..bc9ce7ea 100644 --- a/clients/go/v1/model_reschedule_policy.go +++ b/clients/go/v1/model_reschedule_policy.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_reschedule_tracker.go b/clients/go/v1/model_reschedule_tracker.go index b041b204..22e54f68 100644 --- a/clients/go/v1/model_reschedule_tracker.go +++ b/clients/go/v1/model_reschedule_tracker.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,7 +17,7 @@ import ( // RescheduleTracker struct for RescheduleTracker type RescheduleTracker struct { - Events *[]RescheduleEvent `json:"Events,omitempty"` + Events []RescheduleEvent `json:"Events,omitempty"` } // NewRescheduleTracker instantiates a new RescheduleTracker object @@ -43,12 +43,12 @@ func (o *RescheduleTracker) GetEvents() []RescheduleEvent { var ret []RescheduleEvent return ret } - return *o.Events + return o.Events } // GetEventsOk returns a tuple with the Events field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *RescheduleTracker) GetEventsOk() (*[]RescheduleEvent, bool) { +func (o *RescheduleTracker) GetEventsOk() ([]RescheduleEvent, bool) { if o == nil || o.Events == nil { return nil, false } @@ -66,7 +66,7 @@ func (o *RescheduleTracker) HasEvents() bool { // SetEvents gets a reference to the given []RescheduleEvent and assigns it to the Events field. func (o *RescheduleTracker) SetEvents(v []RescheduleEvent) { - o.Events = &v + o.Events = v } func (o RescheduleTracker) MarshalJSON() ([]byte, error) { diff --git a/clients/go/v1/model_resources.go b/clients/go/v1/model_resources.go index 7fd2ca03..39f51ab5 100644 --- a/clients/go/v1/model_resources.go +++ b/clients/go/v1/model_resources.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -19,12 +19,12 @@ import ( type Resources struct { CPU *int32 `json:"CPU,omitempty"` Cores *int32 `json:"Cores,omitempty"` - Devices *[]RequestedDevice `json:"Devices,omitempty"` + Devices []RequestedDevice `json:"Devices,omitempty"` DiskMB *int32 `json:"DiskMB,omitempty"` IOPS *int32 `json:"IOPS,omitempty"` MemoryMB *int32 `json:"MemoryMB,omitempty"` MemoryMaxMB *int32 `json:"MemoryMaxMB,omitempty"` - Networks *[]NetworkResource `json:"Networks,omitempty"` + Networks []NetworkResource `json:"Networks,omitempty"` } // NewResources instantiates a new Resources object @@ -114,12 +114,12 @@ func (o *Resources) GetDevices() []RequestedDevice { var ret []RequestedDevice return ret } - return *o.Devices + return o.Devices } // GetDevicesOk returns a tuple with the Devices field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *Resources) GetDevicesOk() (*[]RequestedDevice, bool) { +func (o *Resources) GetDevicesOk() ([]RequestedDevice, bool) { if o == nil || o.Devices == nil { return nil, false } @@ -137,7 +137,7 @@ func (o *Resources) HasDevices() bool { // SetDevices gets a reference to the given []RequestedDevice and assigns it to the Devices field. func (o *Resources) SetDevices(v []RequestedDevice) { - o.Devices = &v + o.Devices = v } // GetDiskMB returns the DiskMB field value if set, zero value otherwise. @@ -274,12 +274,12 @@ func (o *Resources) GetNetworks() []NetworkResource { var ret []NetworkResource return ret } - return *o.Networks + return o.Networks } // GetNetworksOk returns a tuple with the Networks field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *Resources) GetNetworksOk() (*[]NetworkResource, bool) { +func (o *Resources) GetNetworksOk() ([]NetworkResource, bool) { if o == nil || o.Networks == nil { return nil, false } @@ -297,7 +297,7 @@ func (o *Resources) HasNetworks() bool { // SetNetworks gets a reference to the given []NetworkResource and assigns it to the Networks field. func (o *Resources) SetNetworks(v []NetworkResource) { - o.Networks = &v + o.Networks = v } func (o Resources) MarshalJSON() ([]byte, error) { diff --git a/clients/go/v1/model_restart_policy.go b/clients/go/v1/model_restart_policy.go index 0e422753..d6233523 100644 --- a/clients/go/v1/model_restart_policy.go +++ b/clients/go/v1/model_restart_policy.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_sampled_value.go b/clients/go/v1/model_sampled_value.go index cd637e6c..83ed70ae 100644 --- a/clients/go/v1/model_sampled_value.go +++ b/clients/go/v1/model_sampled_value.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_scaling_event.go b/clients/go/v1/model_scaling_event.go index aa16f92e..ad737ac9 100644 --- a/clients/go/v1/model_scaling_event.go +++ b/clients/go/v1/model_scaling_event.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -22,7 +22,7 @@ type ScalingEvent struct { Error *bool `json:"Error,omitempty"` EvalID *string `json:"EvalID,omitempty"` Message *string `json:"Message,omitempty"` - Meta *map[string]interface{} `json:"Meta,omitempty"` + Meta map[string]interface{} `json:"Meta,omitempty"` PreviousCount *int64 `json:"PreviousCount,omitempty"` Time *int32 `json:"Time,omitempty"` } @@ -210,12 +210,12 @@ func (o *ScalingEvent) GetMeta() map[string]interface{} { var ret map[string]interface{} return ret } - return *o.Meta + return o.Meta } // GetMetaOk returns a tuple with the Meta field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *ScalingEvent) GetMetaOk() (*map[string]interface{}, bool) { +func (o *ScalingEvent) GetMetaOk() (map[string]interface{}, bool) { if o == nil || o.Meta == nil { return nil, false } @@ -233,7 +233,7 @@ func (o *ScalingEvent) HasMeta() bool { // SetMeta gets a reference to the given map[string]interface{} and assigns it to the Meta field. func (o *ScalingEvent) SetMeta(v map[string]interface{}) { - o.Meta = &v + o.Meta = v } // GetPreviousCount returns the PreviousCount field value if set, zero value otherwise. diff --git a/clients/go/v1/model_scaling_policy.go b/clients/go/v1/model_scaling_policy.go index ddddac2d..f82b4a32 100644 --- a/clients/go/v1/model_scaling_policy.go +++ b/clients/go/v1/model_scaling_policy.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -24,7 +24,7 @@ type ScalingPolicy struct { Min *int64 `json:"Min,omitempty"` ModifyIndex *int32 `json:"ModifyIndex,omitempty"` Namespace *string `json:"Namespace,omitempty"` - Policy *map[string]interface{} `json:"Policy,omitempty"` + Policy map[string]interface{} `json:"Policy,omitempty"` Target *map[string]string `json:"Target,omitempty"` Type *string `json:"Type,omitempty"` } @@ -276,12 +276,12 @@ func (o *ScalingPolicy) GetPolicy() map[string]interface{} { var ret map[string]interface{} return ret } - return *o.Policy + return o.Policy } // GetPolicyOk returns a tuple with the Policy field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *ScalingPolicy) GetPolicyOk() (*map[string]interface{}, bool) { +func (o *ScalingPolicy) GetPolicyOk() (map[string]interface{}, bool) { if o == nil || o.Policy == nil { return nil, false } @@ -299,7 +299,7 @@ func (o *ScalingPolicy) HasPolicy() bool { // SetPolicy gets a reference to the given map[string]interface{} and assigns it to the Policy field. func (o *ScalingPolicy) SetPolicy(v map[string]interface{}) { - o.Policy = &v + o.Policy = v } // GetTarget returns the Target field value if set, zero value otherwise. diff --git a/clients/go/v1/model_scaling_policy_list_stub.go b/clients/go/v1/model_scaling_policy_list_stub.go index e709005b..b6c0c430 100644 --- a/clients/go/v1/model_scaling_policy_list_stub.go +++ b/clients/go/v1/model_scaling_policy_list_stub.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_scaling_request.go b/clients/go/v1/model_scaling_request.go index 9d2755db..09d78949 100644 --- a/clients/go/v1/model_scaling_request.go +++ b/clients/go/v1/model_scaling_request.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -20,7 +20,7 @@ type ScalingRequest struct { Count *int64 `json:"Count,omitempty"` Error *bool `json:"Error,omitempty"` Message *string `json:"Message,omitempty"` - Meta *map[string]interface{} `json:"Meta,omitempty"` + Meta map[string]interface{} `json:"Meta,omitempty"` Namespace *string `json:"Namespace,omitempty"` PolicyOverride *bool `json:"PolicyOverride,omitempty"` Region *string `json:"Region,omitempty"` @@ -147,12 +147,12 @@ func (o *ScalingRequest) GetMeta() map[string]interface{} { var ret map[string]interface{} return ret } - return *o.Meta + return o.Meta } // GetMetaOk returns a tuple with the Meta field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *ScalingRequest) GetMetaOk() (*map[string]interface{}, bool) { +func (o *ScalingRequest) GetMetaOk() (map[string]interface{}, bool) { if o == nil || o.Meta == nil { return nil, false } @@ -170,7 +170,7 @@ func (o *ScalingRequest) HasMeta() bool { // SetMeta gets a reference to the given map[string]interface{} and assigns it to the Meta field. func (o *ScalingRequest) SetMeta(v map[string]interface{}) { - o.Meta = &v + o.Meta = v } // GetNamespace returns the Namespace field value if set, zero value otherwise. diff --git a/clients/go/v1/model_scheduler_configuration.go b/clients/go/v1/model_scheduler_configuration.go index e2622aa7..b7125add 100644 --- a/clients/go/v1/model_scheduler_configuration.go +++ b/clients/go/v1/model_scheduler_configuration.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -21,7 +21,7 @@ type SchedulerConfiguration struct { MemoryOversubscriptionEnabled *bool `json:"MemoryOversubscriptionEnabled,omitempty"` ModifyIndex *int32 `json:"ModifyIndex,omitempty"` PauseEvalBroker *bool `json:"PauseEvalBroker,omitempty"` - PreemptionConfig *PreemptionConfig `json:"PreemptionConfig,omitempty"` + PreemptionConfig NullablePreemptionConfig `json:"PreemptionConfig,omitempty"` RejectJobRegistration *bool `json:"RejectJobRegistration,omitempty"` SchedulerAlgorithm *string `json:"SchedulerAlgorithm,omitempty"` } @@ -171,36 +171,46 @@ func (o *SchedulerConfiguration) SetPauseEvalBroker(v bool) { o.PauseEvalBroker = &v } -// GetPreemptionConfig returns the PreemptionConfig field value if set, zero value otherwise. +// GetPreemptionConfig returns the PreemptionConfig field value if set, zero value otherwise (both if not set or set to explicit null). func (o *SchedulerConfiguration) GetPreemptionConfig() PreemptionConfig { - if o == nil || o.PreemptionConfig == nil { + if o == nil || o.PreemptionConfig.Get() == nil { var ret PreemptionConfig return ret } - return *o.PreemptionConfig + return *o.PreemptionConfig.Get() } // GetPreemptionConfigOk returns a tuple with the PreemptionConfig field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *SchedulerConfiguration) GetPreemptionConfigOk() (*PreemptionConfig, bool) { - if o == nil || o.PreemptionConfig == nil { + if o == nil { return nil, false } - return o.PreemptionConfig, true + return o.PreemptionConfig.Get(), o.PreemptionConfig.IsSet() } // HasPreemptionConfig returns a boolean if a field has been set. func (o *SchedulerConfiguration) HasPreemptionConfig() bool { - if o != nil && o.PreemptionConfig != nil { + if o != nil && o.PreemptionConfig.IsSet() { return true } return false } -// SetPreemptionConfig gets a reference to the given PreemptionConfig and assigns it to the PreemptionConfig field. +// SetPreemptionConfig gets a reference to the given NullablePreemptionConfig and assigns it to the PreemptionConfig field. func (o *SchedulerConfiguration) SetPreemptionConfig(v PreemptionConfig) { - o.PreemptionConfig = &v + o.PreemptionConfig.Set(&v) +} +// SetPreemptionConfigNil sets the value for PreemptionConfig to be an explicit nil +func (o *SchedulerConfiguration) SetPreemptionConfigNil() { + o.PreemptionConfig.Set(nil) +} + +// UnsetPreemptionConfig ensures that no value is present for PreemptionConfig, not even an explicit nil +func (o *SchedulerConfiguration) UnsetPreemptionConfig() { + o.PreemptionConfig.Unset() } // GetRejectJobRegistration returns the RejectJobRegistration field value if set, zero value otherwise. @@ -281,8 +291,8 @@ func (o SchedulerConfiguration) MarshalJSON() ([]byte, error) { if o.PauseEvalBroker != nil { toSerialize["PauseEvalBroker"] = o.PauseEvalBroker } - if o.PreemptionConfig != nil { - toSerialize["PreemptionConfig"] = o.PreemptionConfig + if o.PreemptionConfig.IsSet() { + toSerialize["PreemptionConfig"] = o.PreemptionConfig.Get() } if o.RejectJobRegistration != nil { toSerialize["RejectJobRegistration"] = o.RejectJobRegistration diff --git a/clients/go/v1/model_scheduler_configuration_response.go b/clients/go/v1/model_scheduler_configuration_response.go index 5590a39b..01cb5703 100644 --- a/clients/go/v1/model_scheduler_configuration_response.go +++ b/clients/go/v1/model_scheduler_configuration_response.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -22,7 +22,7 @@ type SchedulerConfigurationResponse struct { LastIndex *int32 `json:"LastIndex,omitempty"` NextToken *string `json:"NextToken,omitempty"` RequestTime *int64 `json:"RequestTime,omitempty"` - SchedulerConfig *SchedulerConfiguration `json:"SchedulerConfig,omitempty"` + SchedulerConfig NullableSchedulerConfiguration `json:"SchedulerConfig,omitempty"` } // NewSchedulerConfigurationResponse instantiates a new SchedulerConfigurationResponse object @@ -202,36 +202,46 @@ func (o *SchedulerConfigurationResponse) SetRequestTime(v int64) { o.RequestTime = &v } -// GetSchedulerConfig returns the SchedulerConfig field value if set, zero value otherwise. +// GetSchedulerConfig returns the SchedulerConfig field value if set, zero value otherwise (both if not set or set to explicit null). func (o *SchedulerConfigurationResponse) GetSchedulerConfig() SchedulerConfiguration { - if o == nil || o.SchedulerConfig == nil { + if o == nil || o.SchedulerConfig.Get() == nil { var ret SchedulerConfiguration return ret } - return *o.SchedulerConfig + return *o.SchedulerConfig.Get() } // GetSchedulerConfigOk returns a tuple with the SchedulerConfig field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *SchedulerConfigurationResponse) GetSchedulerConfigOk() (*SchedulerConfiguration, bool) { - if o == nil || o.SchedulerConfig == nil { + if o == nil { return nil, false } - return o.SchedulerConfig, true + return o.SchedulerConfig.Get(), o.SchedulerConfig.IsSet() } // HasSchedulerConfig returns a boolean if a field has been set. func (o *SchedulerConfigurationResponse) HasSchedulerConfig() bool { - if o != nil && o.SchedulerConfig != nil { + if o != nil && o.SchedulerConfig.IsSet() { return true } return false } -// SetSchedulerConfig gets a reference to the given SchedulerConfiguration and assigns it to the SchedulerConfig field. +// SetSchedulerConfig gets a reference to the given NullableSchedulerConfiguration and assigns it to the SchedulerConfig field. func (o *SchedulerConfigurationResponse) SetSchedulerConfig(v SchedulerConfiguration) { - o.SchedulerConfig = &v + o.SchedulerConfig.Set(&v) +} +// SetSchedulerConfigNil sets the value for SchedulerConfig to be an explicit nil +func (o *SchedulerConfigurationResponse) SetSchedulerConfigNil() { + o.SchedulerConfig.Set(nil) +} + +// UnsetSchedulerConfig ensures that no value is present for SchedulerConfig, not even an explicit nil +func (o *SchedulerConfigurationResponse) UnsetSchedulerConfig() { + o.SchedulerConfig.Unset() } func (o SchedulerConfigurationResponse) MarshalJSON() ([]byte, error) { @@ -251,8 +261,8 @@ func (o SchedulerConfigurationResponse) MarshalJSON() ([]byte, error) { if o.RequestTime != nil { toSerialize["RequestTime"] = o.RequestTime } - if o.SchedulerConfig != nil { - toSerialize["SchedulerConfig"] = o.SchedulerConfig + if o.SchedulerConfig.IsSet() { + toSerialize["SchedulerConfig"] = o.SchedulerConfig.Get() } return json.Marshal(toSerialize) } diff --git a/clients/go/v1/model_scheduler_set_configuration_response.go b/clients/go/v1/model_scheduler_set_configuration_response.go index 6b654a78..7d0479b6 100644 --- a/clients/go/v1/model_scheduler_set_configuration_response.go +++ b/clients/go/v1/model_scheduler_set_configuration_response.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_search_request.go b/clients/go/v1/model_search_request.go index 76ee71aa..852e49b3 100644 --- a/clients/go/v1/model_search_request.go +++ b/clients/go/v1/model_search_request.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_search_response.go b/clients/go/v1/model_search_response.go index fb6ef2f8..1a02ffa2 100644 --- a/clients/go/v1/model_search_response.go +++ b/clients/go/v1/model_search_response.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_server_health.go b/clients/go/v1/model_server_health.go index 8b9c0d7e..eeddf753 100644 --- a/clients/go/v1/model_server_health.go +++ b/clients/go/v1/model_server_health.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -27,7 +27,7 @@ type ServerHealth struct { Leader *bool `json:"Leader,omitempty"` Name *string `json:"Name,omitempty"` SerfStatus *string `json:"SerfStatus,omitempty"` - StableSince *time.Time `json:"StableSince,omitempty"` + StableSince NullableTime `json:"StableSince,omitempty"` Version *string `json:"Version,omitempty"` Voter *bool `json:"Voter,omitempty"` } @@ -337,36 +337,46 @@ func (o *ServerHealth) SetSerfStatus(v string) { o.SerfStatus = &v } -// GetStableSince returns the StableSince field value if set, zero value otherwise. +// GetStableSince returns the StableSince field value if set, zero value otherwise (both if not set or set to explicit null). func (o *ServerHealth) GetStableSince() time.Time { - if o == nil || o.StableSince == nil { + if o == nil || o.StableSince.Get() == nil { var ret time.Time return ret } - return *o.StableSince + return *o.StableSince.Get() } // GetStableSinceOk returns a tuple with the StableSince field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *ServerHealth) GetStableSinceOk() (*time.Time, bool) { - if o == nil || o.StableSince == nil { + if o == nil { return nil, false } - return o.StableSince, true + return o.StableSince.Get(), o.StableSince.IsSet() } // HasStableSince returns a boolean if a field has been set. func (o *ServerHealth) HasStableSince() bool { - if o != nil && o.StableSince != nil { + if o != nil && o.StableSince.IsSet() { return true } return false } -// SetStableSince gets a reference to the given time.Time and assigns it to the StableSince field. +// SetStableSince gets a reference to the given NullableTime and assigns it to the StableSince field. func (o *ServerHealth) SetStableSince(v time.Time) { - o.StableSince = &v + o.StableSince.Set(&v) +} +// SetStableSinceNil sets the value for StableSince to be an explicit nil +func (o *ServerHealth) SetStableSinceNil() { + o.StableSince.Set(nil) +} + +// UnsetStableSince ensures that no value is present for StableSince, not even an explicit nil +func (o *ServerHealth) UnsetStableSince() { + o.StableSince.Unset() } // GetVersion returns the Version field value if set, zero value otherwise. @@ -462,8 +472,8 @@ func (o ServerHealth) MarshalJSON() ([]byte, error) { if o.SerfStatus != nil { toSerialize["SerfStatus"] = o.SerfStatus } - if o.StableSince != nil { - toSerialize["StableSince"] = o.StableSince + if o.StableSince.IsSet() { + toSerialize["StableSince"] = o.StableSince.Get() } if o.Version != nil { toSerialize["Version"] = o.Version diff --git a/clients/go/v1/model_service.go b/clients/go/v1/model_service.go index 556b457f..8288ee62 100644 --- a/clients/go/v1/model_service.go +++ b/clients/go/v1/model_service.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -20,10 +20,10 @@ type Service struct { Address *string `json:"Address,omitempty"` AddressMode *string `json:"AddressMode,omitempty"` CanaryMeta *map[string]string `json:"CanaryMeta,omitempty"` - CanaryTags *[]string `json:"CanaryTags,omitempty"` - CheckRestart *CheckRestart `json:"CheckRestart,omitempty"` - Checks *[]ServiceCheck `json:"Checks,omitempty"` - Connect *ConsulConnect `json:"Connect,omitempty"` + CanaryTags []string `json:"CanaryTags,omitempty"` + CheckRestart NullableCheckRestart `json:"CheckRestart,omitempty"` + Checks []ServiceCheck `json:"Checks,omitempty"` + Connect NullableConsulConnect `json:"Connect,omitempty"` EnableTagOverride *bool `json:"EnableTagOverride,omitempty"` Meta *map[string]string `json:"Meta,omitempty"` Name *string `json:"Name,omitempty"` @@ -31,7 +31,7 @@ type Service struct { PortLabel *string `json:"PortLabel,omitempty"` Provider *string `json:"Provider,omitempty"` TaggedAddresses *map[string]string `json:"TaggedAddresses,omitempty"` - Tags *[]string `json:"Tags,omitempty"` + Tags []string `json:"Tags,omitempty"` TaskName *string `json:"TaskName,omitempty"` } @@ -154,12 +154,12 @@ func (o *Service) GetCanaryTags() []string { var ret []string return ret } - return *o.CanaryTags + return o.CanaryTags } // GetCanaryTagsOk returns a tuple with the CanaryTags field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *Service) GetCanaryTagsOk() (*[]string, bool) { +func (o *Service) GetCanaryTagsOk() ([]string, bool) { if o == nil || o.CanaryTags == nil { return nil, false } @@ -177,39 +177,49 @@ func (o *Service) HasCanaryTags() bool { // SetCanaryTags gets a reference to the given []string and assigns it to the CanaryTags field. func (o *Service) SetCanaryTags(v []string) { - o.CanaryTags = &v + o.CanaryTags = v } -// GetCheckRestart returns the CheckRestart field value if set, zero value otherwise. +// GetCheckRestart returns the CheckRestart field value if set, zero value otherwise (both if not set or set to explicit null). func (o *Service) GetCheckRestart() CheckRestart { - if o == nil || o.CheckRestart == nil { + if o == nil || o.CheckRestart.Get() == nil { var ret CheckRestart return ret } - return *o.CheckRestart + return *o.CheckRestart.Get() } // GetCheckRestartOk returns a tuple with the CheckRestart field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *Service) GetCheckRestartOk() (*CheckRestart, bool) { - if o == nil || o.CheckRestart == nil { + if o == nil { return nil, false } - return o.CheckRestart, true + return o.CheckRestart.Get(), o.CheckRestart.IsSet() } // HasCheckRestart returns a boolean if a field has been set. func (o *Service) HasCheckRestart() bool { - if o != nil && o.CheckRestart != nil { + if o != nil && o.CheckRestart.IsSet() { return true } return false } -// SetCheckRestart gets a reference to the given CheckRestart and assigns it to the CheckRestart field. +// SetCheckRestart gets a reference to the given NullableCheckRestart and assigns it to the CheckRestart field. func (o *Service) SetCheckRestart(v CheckRestart) { - o.CheckRestart = &v + o.CheckRestart.Set(&v) +} +// SetCheckRestartNil sets the value for CheckRestart to be an explicit nil +func (o *Service) SetCheckRestartNil() { + o.CheckRestart.Set(nil) +} + +// UnsetCheckRestart ensures that no value is present for CheckRestart, not even an explicit nil +func (o *Service) UnsetCheckRestart() { + o.CheckRestart.Unset() } // GetChecks returns the Checks field value if set, zero value otherwise. @@ -218,12 +228,12 @@ func (o *Service) GetChecks() []ServiceCheck { var ret []ServiceCheck return ret } - return *o.Checks + return o.Checks } // GetChecksOk returns a tuple with the Checks field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *Service) GetChecksOk() (*[]ServiceCheck, bool) { +func (o *Service) GetChecksOk() ([]ServiceCheck, bool) { if o == nil || o.Checks == nil { return nil, false } @@ -241,39 +251,49 @@ func (o *Service) HasChecks() bool { // SetChecks gets a reference to the given []ServiceCheck and assigns it to the Checks field. func (o *Service) SetChecks(v []ServiceCheck) { - o.Checks = &v + o.Checks = v } -// GetConnect returns the Connect field value if set, zero value otherwise. +// GetConnect returns the Connect field value if set, zero value otherwise (both if not set or set to explicit null). func (o *Service) GetConnect() ConsulConnect { - if o == nil || o.Connect == nil { + if o == nil || o.Connect.Get() == nil { var ret ConsulConnect return ret } - return *o.Connect + return *o.Connect.Get() } // GetConnectOk returns a tuple with the Connect field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *Service) GetConnectOk() (*ConsulConnect, bool) { - if o == nil || o.Connect == nil { + if o == nil { return nil, false } - return o.Connect, true + return o.Connect.Get(), o.Connect.IsSet() } // HasConnect returns a boolean if a field has been set. func (o *Service) HasConnect() bool { - if o != nil && o.Connect != nil { + if o != nil && o.Connect.IsSet() { return true } return false } -// SetConnect gets a reference to the given ConsulConnect and assigns it to the Connect field. +// SetConnect gets a reference to the given NullableConsulConnect and assigns it to the Connect field. func (o *Service) SetConnect(v ConsulConnect) { - o.Connect = &v + o.Connect.Set(&v) +} +// SetConnectNil sets the value for Connect to be an explicit nil +func (o *Service) SetConnectNil() { + o.Connect.Set(nil) +} + +// UnsetConnect ensures that no value is present for Connect, not even an explicit nil +func (o *Service) UnsetConnect() { + o.Connect.Unset() } // GetEnableTagOverride returns the EnableTagOverride field value if set, zero value otherwise. @@ -506,12 +526,12 @@ func (o *Service) GetTags() []string { var ret []string return ret } - return *o.Tags + return o.Tags } // GetTagsOk returns a tuple with the Tags field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *Service) GetTagsOk() (*[]string, bool) { +func (o *Service) GetTagsOk() ([]string, bool) { if o == nil || o.Tags == nil { return nil, false } @@ -529,7 +549,7 @@ func (o *Service) HasTags() bool { // SetTags gets a reference to the given []string and assigns it to the Tags field. func (o *Service) SetTags(v []string) { - o.Tags = &v + o.Tags = v } // GetTaskName returns the TaskName field value if set, zero value otherwise. @@ -578,14 +598,14 @@ func (o Service) MarshalJSON() ([]byte, error) { if o.CanaryTags != nil { toSerialize["CanaryTags"] = o.CanaryTags } - if o.CheckRestart != nil { - toSerialize["CheckRestart"] = o.CheckRestart + if o.CheckRestart.IsSet() { + toSerialize["CheckRestart"] = o.CheckRestart.Get() } if o.Checks != nil { toSerialize["Checks"] = o.Checks } - if o.Connect != nil { - toSerialize["Connect"] = o.Connect + if o.Connect.IsSet() { + toSerialize["Connect"] = o.Connect.Get() } if o.EnableTagOverride != nil { toSerialize["EnableTagOverride"] = o.EnableTagOverride diff --git a/clients/go/v1/model_service_check.go b/clients/go/v1/model_service_check.go index 0d562a29..d6bf2372 100644 --- a/clients/go/v1/model_service_check.go +++ b/clients/go/v1/model_service_check.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -19,9 +19,9 @@ import ( type ServiceCheck struct { AddressMode *string `json:"AddressMode,omitempty"` Advertise *string `json:"Advertise,omitempty"` - Args *[]string `json:"Args,omitempty"` + Args []string `json:"Args,omitempty"` Body *string `json:"Body,omitempty"` - CheckRestart *CheckRestart `json:"CheckRestart,omitempty"` + CheckRestart NullableCheckRestart `json:"CheckRestart,omitempty"` Command *string `json:"Command,omitempty"` Expose *bool `json:"Expose,omitempty"` FailuresBeforeCritical *int32 `json:"FailuresBeforeCritical,omitempty"` @@ -130,12 +130,12 @@ func (o *ServiceCheck) GetArgs() []string { var ret []string return ret } - return *o.Args + return o.Args } // GetArgsOk returns a tuple with the Args field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *ServiceCheck) GetArgsOk() (*[]string, bool) { +func (o *ServiceCheck) GetArgsOk() ([]string, bool) { if o == nil || o.Args == nil { return nil, false } @@ -153,7 +153,7 @@ func (o *ServiceCheck) HasArgs() bool { // SetArgs gets a reference to the given []string and assigns it to the Args field. func (o *ServiceCheck) SetArgs(v []string) { - o.Args = &v + o.Args = v } // GetBody returns the Body field value if set, zero value otherwise. @@ -188,36 +188,46 @@ func (o *ServiceCheck) SetBody(v string) { o.Body = &v } -// GetCheckRestart returns the CheckRestart field value if set, zero value otherwise. +// GetCheckRestart returns the CheckRestart field value if set, zero value otherwise (both if not set or set to explicit null). func (o *ServiceCheck) GetCheckRestart() CheckRestart { - if o == nil || o.CheckRestart == nil { + if o == nil || o.CheckRestart.Get() == nil { var ret CheckRestart return ret } - return *o.CheckRestart + return *o.CheckRestart.Get() } // GetCheckRestartOk returns a tuple with the CheckRestart field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *ServiceCheck) GetCheckRestartOk() (*CheckRestart, bool) { - if o == nil || o.CheckRestart == nil { + if o == nil { return nil, false } - return o.CheckRestart, true + return o.CheckRestart.Get(), o.CheckRestart.IsSet() } // HasCheckRestart returns a boolean if a field has been set. func (o *ServiceCheck) HasCheckRestart() bool { - if o != nil && o.CheckRestart != nil { + if o != nil && o.CheckRestart.IsSet() { return true } return false } -// SetCheckRestart gets a reference to the given CheckRestart and assigns it to the CheckRestart field. +// SetCheckRestart gets a reference to the given NullableCheckRestart and assigns it to the CheckRestart field. func (o *ServiceCheck) SetCheckRestart(v CheckRestart) { - o.CheckRestart = &v + o.CheckRestart.Set(&v) +} +// SetCheckRestartNil sets the value for CheckRestart to be an explicit nil +func (o *ServiceCheck) SetCheckRestartNil() { + o.CheckRestart.Set(nil) +} + +// UnsetCheckRestart ensures that no value is present for CheckRestart, not even an explicit nil +func (o *ServiceCheck) UnsetCheckRestart() { + o.CheckRestart.Unset() } // GetCommand returns the Command field value if set, zero value otherwise. @@ -842,8 +852,8 @@ func (o ServiceCheck) MarshalJSON() ([]byte, error) { if o.Body != nil { toSerialize["Body"] = o.Body } - if o.CheckRestart != nil { - toSerialize["CheckRestart"] = o.CheckRestart + if o.CheckRestart.IsSet() { + toSerialize["CheckRestart"] = o.CheckRestart.Get() } if o.Command != nil { toSerialize["Command"] = o.Command diff --git a/clients/go/v1/model_service_registration.go b/clients/go/v1/model_service_registration.go index df50987c..9cd46e88 100644 --- a/clients/go/v1/model_service_registration.go +++ b/clients/go/v1/model_service_registration.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -28,7 +28,7 @@ type ServiceRegistration struct { NodeID *string `json:"NodeID,omitempty"` Port *int32 `json:"Port,omitempty"` ServiceName *string `json:"ServiceName,omitempty"` - Tags *[]string `json:"Tags,omitempty"` + Tags []string `json:"Tags,omitempty"` } // NewServiceRegistration instantiates a new ServiceRegistration object @@ -406,12 +406,12 @@ func (o *ServiceRegistration) GetTags() []string { var ret []string return ret } - return *o.Tags + return o.Tags } // GetTagsOk returns a tuple with the Tags field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *ServiceRegistration) GetTagsOk() (*[]string, bool) { +func (o *ServiceRegistration) GetTagsOk() ([]string, bool) { if o == nil || o.Tags == nil { return nil, false } @@ -429,7 +429,7 @@ func (o *ServiceRegistration) HasTags() bool { // SetTags gets a reference to the given []string and assigns it to the Tags field. func (o *ServiceRegistration) SetTags(v []string) { - o.Tags = &v + o.Tags = v } func (o ServiceRegistration) MarshalJSON() ([]byte, error) { diff --git a/clients/go/v1/model_sidecar_task.go b/clients/go/v1/model_sidecar_task.go index 2601ed88..bb9619ca 100644 --- a/clients/go/v1/model_sidecar_task.go +++ b/clients/go/v1/model_sidecar_task.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,7 +17,7 @@ import ( // SidecarTask struct for SidecarTask type SidecarTask struct { - Config *map[string]interface{} `json:"Config,omitempty"` + Config map[string]interface{} `json:"Config,omitempty"` Driver *string `json:"Driver,omitempty"` Env *map[string]string `json:"Env,omitempty"` KillSignal *string `json:"KillSignal,omitempty"` @@ -25,7 +25,7 @@ type SidecarTask struct { LogConfig *LogConfig `json:"LogConfig,omitempty"` Meta *map[string]string `json:"Meta,omitempty"` Name *string `json:"Name,omitempty"` - Resources *Resources `json:"Resources,omitempty"` + Resources NullableResources `json:"Resources,omitempty"` ShutdownDelay *int64 `json:"ShutdownDelay,omitempty"` User *string `json:"User,omitempty"` } @@ -53,12 +53,12 @@ func (o *SidecarTask) GetConfig() map[string]interface{} { var ret map[string]interface{} return ret } - return *o.Config + return o.Config } // GetConfigOk returns a tuple with the Config field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *SidecarTask) GetConfigOk() (*map[string]interface{}, bool) { +func (o *SidecarTask) GetConfigOk() (map[string]interface{}, bool) { if o == nil || o.Config == nil { return nil, false } @@ -76,7 +76,7 @@ func (o *SidecarTask) HasConfig() bool { // SetConfig gets a reference to the given map[string]interface{} and assigns it to the Config field. func (o *SidecarTask) SetConfig(v map[string]interface{}) { - o.Config = &v + o.Config = v } // GetDriver returns the Driver field value if set, zero value otherwise. @@ -303,36 +303,46 @@ func (o *SidecarTask) SetName(v string) { o.Name = &v } -// GetResources returns the Resources field value if set, zero value otherwise. +// GetResources returns the Resources field value if set, zero value otherwise (both if not set or set to explicit null). func (o *SidecarTask) GetResources() Resources { - if o == nil || o.Resources == nil { + if o == nil || o.Resources.Get() == nil { var ret Resources return ret } - return *o.Resources + return *o.Resources.Get() } // GetResourcesOk returns a tuple with the Resources field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *SidecarTask) GetResourcesOk() (*Resources, bool) { - if o == nil || o.Resources == nil { + if o == nil { return nil, false } - return o.Resources, true + return o.Resources.Get(), o.Resources.IsSet() } // HasResources returns a boolean if a field has been set. func (o *SidecarTask) HasResources() bool { - if o != nil && o.Resources != nil { + if o != nil && o.Resources.IsSet() { return true } return false } -// SetResources gets a reference to the given Resources and assigns it to the Resources field. +// SetResources gets a reference to the given NullableResources and assigns it to the Resources field. func (o *SidecarTask) SetResources(v Resources) { - o.Resources = &v + o.Resources.Set(&v) +} +// SetResourcesNil sets the value for Resources to be an explicit nil +func (o *SidecarTask) SetResourcesNil() { + o.Resources.Set(nil) +} + +// UnsetResources ensures that no value is present for Resources, not even an explicit nil +func (o *SidecarTask) UnsetResources() { + o.Resources.Unset() } // GetShutdownDelay returns the ShutdownDelay field value if set, zero value otherwise. @@ -425,8 +435,8 @@ func (o SidecarTask) MarshalJSON() ([]byte, error) { if o.Name != nil { toSerialize["Name"] = o.Name } - if o.Resources != nil { - toSerialize["Resources"] = o.Resources + if o.Resources.IsSet() { + toSerialize["Resources"] = o.Resources.Get() } if o.ShutdownDelay != nil { toSerialize["ShutdownDelay"] = o.ShutdownDelay diff --git a/clients/go/v1/model_spread.go b/clients/go/v1/model_spread.go index 9d3acde4..6ec16c1f 100644 --- a/clients/go/v1/model_spread.go +++ b/clients/go/v1/model_spread.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -18,7 +18,7 @@ import ( // Spread struct for Spread type Spread struct { Attribute *string `json:"Attribute,omitempty"` - SpreadTarget *[]SpreadTarget `json:"SpreadTarget,omitempty"` + SpreadTarget []SpreadTarget `json:"SpreadTarget,omitempty"` Weight *int32 `json:"Weight,omitempty"` } @@ -77,12 +77,12 @@ func (o *Spread) GetSpreadTarget() []SpreadTarget { var ret []SpreadTarget return ret } - return *o.SpreadTarget + return o.SpreadTarget } // GetSpreadTargetOk returns a tuple with the SpreadTarget field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *Spread) GetSpreadTargetOk() (*[]SpreadTarget, bool) { +func (o *Spread) GetSpreadTargetOk() ([]SpreadTarget, bool) { if o == nil || o.SpreadTarget == nil { return nil, false } @@ -100,7 +100,7 @@ func (o *Spread) HasSpreadTarget() bool { // SetSpreadTarget gets a reference to the given []SpreadTarget and assigns it to the SpreadTarget field. func (o *Spread) SetSpreadTarget(v []SpreadTarget) { - o.SpreadTarget = &v + o.SpreadTarget = v } // GetWeight returns the Weight field value if set, zero value otherwise. diff --git a/clients/go/v1/model_spread_target.go b/clients/go/v1/model_spread_target.go index 0c44799d..da839c6c 100644 --- a/clients/go/v1/model_spread_target.go +++ b/clients/go/v1/model_spread_target.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_task.go b/clients/go/v1/model_task.go index 8311f7e4..692be38b 100644 --- a/clients/go/v1/model_task.go +++ b/clients/go/v1/model_task.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,31 +17,31 @@ import ( // Task struct for Task type Task struct { - Affinities *[]Affinity `json:"Affinities,omitempty"` - Artifacts *[]TaskArtifact `json:"Artifacts,omitempty"` - CSIPluginConfig *TaskCSIPluginConfig `json:"CSIPluginConfig,omitempty"` - Config *map[string]interface{} `json:"Config,omitempty"` - Constraints *[]Constraint `json:"Constraints,omitempty"` - DispatchPayload *DispatchPayloadConfig `json:"DispatchPayload,omitempty"` + Affinities []Affinity `json:"Affinities,omitempty"` + Artifacts []TaskArtifact `json:"Artifacts,omitempty"` + CSIPluginConfig NullableTaskCSIPluginConfig `json:"CSIPluginConfig,omitempty"` + Config map[string]interface{} `json:"Config,omitempty"` + Constraints []Constraint `json:"Constraints,omitempty"` + DispatchPayload NullableDispatchPayloadConfig `json:"DispatchPayload,omitempty"` Driver *string `json:"Driver,omitempty"` Env *map[string]string `json:"Env,omitempty"` KillSignal *string `json:"KillSignal,omitempty"` KillTimeout *int64 `json:"KillTimeout,omitempty"` Kind *string `json:"Kind,omitempty"` Leader *bool `json:"Leader,omitempty"` - Lifecycle *TaskLifecycle `json:"Lifecycle,omitempty"` + Lifecycle NullableTaskLifecycle `json:"Lifecycle,omitempty"` LogConfig *LogConfig `json:"LogConfig,omitempty"` Meta *map[string]string `json:"Meta,omitempty"` Name *string `json:"Name,omitempty"` - Resources *Resources `json:"Resources,omitempty"` + Resources NullableResources `json:"Resources,omitempty"` RestartPolicy *RestartPolicy `json:"RestartPolicy,omitempty"` - ScalingPolicies *[]ScalingPolicy `json:"ScalingPolicies,omitempty"` - Services *[]Service `json:"Services,omitempty"` + ScalingPolicies []ScalingPolicy `json:"ScalingPolicies,omitempty"` + Services []Service `json:"Services,omitempty"` ShutdownDelay *int64 `json:"ShutdownDelay,omitempty"` - Templates *[]Template `json:"Templates,omitempty"` + Templates []Template `json:"Templates,omitempty"` User *string `json:"User,omitempty"` - Vault *Vault `json:"Vault,omitempty"` - VolumeMounts *[]VolumeMount `json:"VolumeMounts,omitempty"` + Vault NullableVault `json:"Vault,omitempty"` + VolumeMounts []VolumeMount `json:"VolumeMounts,omitempty"` } // NewTask instantiates a new Task object @@ -67,12 +67,12 @@ func (o *Task) GetAffinities() []Affinity { var ret []Affinity return ret } - return *o.Affinities + return o.Affinities } // GetAffinitiesOk returns a tuple with the Affinities field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *Task) GetAffinitiesOk() (*[]Affinity, bool) { +func (o *Task) GetAffinitiesOk() ([]Affinity, bool) { if o == nil || o.Affinities == nil { return nil, false } @@ -90,7 +90,7 @@ func (o *Task) HasAffinities() bool { // SetAffinities gets a reference to the given []Affinity and assigns it to the Affinities field. func (o *Task) SetAffinities(v []Affinity) { - o.Affinities = &v + o.Affinities = v } // GetArtifacts returns the Artifacts field value if set, zero value otherwise. @@ -99,12 +99,12 @@ func (o *Task) GetArtifacts() []TaskArtifact { var ret []TaskArtifact return ret } - return *o.Artifacts + return o.Artifacts } // GetArtifactsOk returns a tuple with the Artifacts field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *Task) GetArtifactsOk() (*[]TaskArtifact, bool) { +func (o *Task) GetArtifactsOk() ([]TaskArtifact, bool) { if o == nil || o.Artifacts == nil { return nil, false } @@ -122,39 +122,49 @@ func (o *Task) HasArtifacts() bool { // SetArtifacts gets a reference to the given []TaskArtifact and assigns it to the Artifacts field. func (o *Task) SetArtifacts(v []TaskArtifact) { - o.Artifacts = &v + o.Artifacts = v } -// GetCSIPluginConfig returns the CSIPluginConfig field value if set, zero value otherwise. +// GetCSIPluginConfig returns the CSIPluginConfig field value if set, zero value otherwise (both if not set or set to explicit null). func (o *Task) GetCSIPluginConfig() TaskCSIPluginConfig { - if o == nil || o.CSIPluginConfig == nil { + if o == nil || o.CSIPluginConfig.Get() == nil { var ret TaskCSIPluginConfig return ret } - return *o.CSIPluginConfig + return *o.CSIPluginConfig.Get() } // GetCSIPluginConfigOk returns a tuple with the CSIPluginConfig field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *Task) GetCSIPluginConfigOk() (*TaskCSIPluginConfig, bool) { - if o == nil || o.CSIPluginConfig == nil { + if o == nil { return nil, false } - return o.CSIPluginConfig, true + return o.CSIPluginConfig.Get(), o.CSIPluginConfig.IsSet() } // HasCSIPluginConfig returns a boolean if a field has been set. func (o *Task) HasCSIPluginConfig() bool { - if o != nil && o.CSIPluginConfig != nil { + if o != nil && o.CSIPluginConfig.IsSet() { return true } return false } -// SetCSIPluginConfig gets a reference to the given TaskCSIPluginConfig and assigns it to the CSIPluginConfig field. +// SetCSIPluginConfig gets a reference to the given NullableTaskCSIPluginConfig and assigns it to the CSIPluginConfig field. func (o *Task) SetCSIPluginConfig(v TaskCSIPluginConfig) { - o.CSIPluginConfig = &v + o.CSIPluginConfig.Set(&v) +} +// SetCSIPluginConfigNil sets the value for CSIPluginConfig to be an explicit nil +func (o *Task) SetCSIPluginConfigNil() { + o.CSIPluginConfig.Set(nil) +} + +// UnsetCSIPluginConfig ensures that no value is present for CSIPluginConfig, not even an explicit nil +func (o *Task) UnsetCSIPluginConfig() { + o.CSIPluginConfig.Unset() } // GetConfig returns the Config field value if set, zero value otherwise. @@ -163,12 +173,12 @@ func (o *Task) GetConfig() map[string]interface{} { var ret map[string]interface{} return ret } - return *o.Config + return o.Config } // GetConfigOk returns a tuple with the Config field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *Task) GetConfigOk() (*map[string]interface{}, bool) { +func (o *Task) GetConfigOk() (map[string]interface{}, bool) { if o == nil || o.Config == nil { return nil, false } @@ -186,7 +196,7 @@ func (o *Task) HasConfig() bool { // SetConfig gets a reference to the given map[string]interface{} and assigns it to the Config field. func (o *Task) SetConfig(v map[string]interface{}) { - o.Config = &v + o.Config = v } // GetConstraints returns the Constraints field value if set, zero value otherwise. @@ -195,12 +205,12 @@ func (o *Task) GetConstraints() []Constraint { var ret []Constraint return ret } - return *o.Constraints + return o.Constraints } // GetConstraintsOk returns a tuple with the Constraints field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *Task) GetConstraintsOk() (*[]Constraint, bool) { +func (o *Task) GetConstraintsOk() ([]Constraint, bool) { if o == nil || o.Constraints == nil { return nil, false } @@ -218,39 +228,49 @@ func (o *Task) HasConstraints() bool { // SetConstraints gets a reference to the given []Constraint and assigns it to the Constraints field. func (o *Task) SetConstraints(v []Constraint) { - o.Constraints = &v + o.Constraints = v } -// GetDispatchPayload returns the DispatchPayload field value if set, zero value otherwise. +// GetDispatchPayload returns the DispatchPayload field value if set, zero value otherwise (both if not set or set to explicit null). func (o *Task) GetDispatchPayload() DispatchPayloadConfig { - if o == nil || o.DispatchPayload == nil { + if o == nil || o.DispatchPayload.Get() == nil { var ret DispatchPayloadConfig return ret } - return *o.DispatchPayload + return *o.DispatchPayload.Get() } // GetDispatchPayloadOk returns a tuple with the DispatchPayload field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *Task) GetDispatchPayloadOk() (*DispatchPayloadConfig, bool) { - if o == nil || o.DispatchPayload == nil { + if o == nil { return nil, false } - return o.DispatchPayload, true + return o.DispatchPayload.Get(), o.DispatchPayload.IsSet() } // HasDispatchPayload returns a boolean if a field has been set. func (o *Task) HasDispatchPayload() bool { - if o != nil && o.DispatchPayload != nil { + if o != nil && o.DispatchPayload.IsSet() { return true } return false } -// SetDispatchPayload gets a reference to the given DispatchPayloadConfig and assigns it to the DispatchPayload field. +// SetDispatchPayload gets a reference to the given NullableDispatchPayloadConfig and assigns it to the DispatchPayload field. func (o *Task) SetDispatchPayload(v DispatchPayloadConfig) { - o.DispatchPayload = &v + o.DispatchPayload.Set(&v) +} +// SetDispatchPayloadNil sets the value for DispatchPayload to be an explicit nil +func (o *Task) SetDispatchPayloadNil() { + o.DispatchPayload.Set(nil) +} + +// UnsetDispatchPayload ensures that no value is present for DispatchPayload, not even an explicit nil +func (o *Task) UnsetDispatchPayload() { + o.DispatchPayload.Unset() } // GetDriver returns the Driver field value if set, zero value otherwise. @@ -445,36 +465,46 @@ func (o *Task) SetLeader(v bool) { o.Leader = &v } -// GetLifecycle returns the Lifecycle field value if set, zero value otherwise. +// GetLifecycle returns the Lifecycle field value if set, zero value otherwise (both if not set or set to explicit null). func (o *Task) GetLifecycle() TaskLifecycle { - if o == nil || o.Lifecycle == nil { + if o == nil || o.Lifecycle.Get() == nil { var ret TaskLifecycle return ret } - return *o.Lifecycle + return *o.Lifecycle.Get() } // GetLifecycleOk returns a tuple with the Lifecycle field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *Task) GetLifecycleOk() (*TaskLifecycle, bool) { - if o == nil || o.Lifecycle == nil { + if o == nil { return nil, false } - return o.Lifecycle, true + return o.Lifecycle.Get(), o.Lifecycle.IsSet() } // HasLifecycle returns a boolean if a field has been set. func (o *Task) HasLifecycle() bool { - if o != nil && o.Lifecycle != nil { + if o != nil && o.Lifecycle.IsSet() { return true } return false } -// SetLifecycle gets a reference to the given TaskLifecycle and assigns it to the Lifecycle field. +// SetLifecycle gets a reference to the given NullableTaskLifecycle and assigns it to the Lifecycle field. func (o *Task) SetLifecycle(v TaskLifecycle) { - o.Lifecycle = &v + o.Lifecycle.Set(&v) +} +// SetLifecycleNil sets the value for Lifecycle to be an explicit nil +func (o *Task) SetLifecycleNil() { + o.Lifecycle.Set(nil) +} + +// UnsetLifecycle ensures that no value is present for Lifecycle, not even an explicit nil +func (o *Task) UnsetLifecycle() { + o.Lifecycle.Unset() } // GetLogConfig returns the LogConfig field value if set, zero value otherwise. @@ -573,36 +603,46 @@ func (o *Task) SetName(v string) { o.Name = &v } -// GetResources returns the Resources field value if set, zero value otherwise. +// GetResources returns the Resources field value if set, zero value otherwise (both if not set or set to explicit null). func (o *Task) GetResources() Resources { - if o == nil || o.Resources == nil { + if o == nil || o.Resources.Get() == nil { var ret Resources return ret } - return *o.Resources + return *o.Resources.Get() } // GetResourcesOk returns a tuple with the Resources field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *Task) GetResourcesOk() (*Resources, bool) { - if o == nil || o.Resources == nil { + if o == nil { return nil, false } - return o.Resources, true + return o.Resources.Get(), o.Resources.IsSet() } // HasResources returns a boolean if a field has been set. func (o *Task) HasResources() bool { - if o != nil && o.Resources != nil { + if o != nil && o.Resources.IsSet() { return true } return false } -// SetResources gets a reference to the given Resources and assigns it to the Resources field. +// SetResources gets a reference to the given NullableResources and assigns it to the Resources field. func (o *Task) SetResources(v Resources) { - o.Resources = &v + o.Resources.Set(&v) +} +// SetResourcesNil sets the value for Resources to be an explicit nil +func (o *Task) SetResourcesNil() { + o.Resources.Set(nil) +} + +// UnsetResources ensures that no value is present for Resources, not even an explicit nil +func (o *Task) UnsetResources() { + o.Resources.Unset() } // GetRestartPolicy returns the RestartPolicy field value if set, zero value otherwise. @@ -643,12 +683,12 @@ func (o *Task) GetScalingPolicies() []ScalingPolicy { var ret []ScalingPolicy return ret } - return *o.ScalingPolicies + return o.ScalingPolicies } // GetScalingPoliciesOk returns a tuple with the ScalingPolicies field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *Task) GetScalingPoliciesOk() (*[]ScalingPolicy, bool) { +func (o *Task) GetScalingPoliciesOk() ([]ScalingPolicy, bool) { if o == nil || o.ScalingPolicies == nil { return nil, false } @@ -666,7 +706,7 @@ func (o *Task) HasScalingPolicies() bool { // SetScalingPolicies gets a reference to the given []ScalingPolicy and assigns it to the ScalingPolicies field. func (o *Task) SetScalingPolicies(v []ScalingPolicy) { - o.ScalingPolicies = &v + o.ScalingPolicies = v } // GetServices returns the Services field value if set, zero value otherwise. @@ -675,12 +715,12 @@ func (o *Task) GetServices() []Service { var ret []Service return ret } - return *o.Services + return o.Services } // GetServicesOk returns a tuple with the Services field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *Task) GetServicesOk() (*[]Service, bool) { +func (o *Task) GetServicesOk() ([]Service, bool) { if o == nil || o.Services == nil { return nil, false } @@ -698,7 +738,7 @@ func (o *Task) HasServices() bool { // SetServices gets a reference to the given []Service and assigns it to the Services field. func (o *Task) SetServices(v []Service) { - o.Services = &v + o.Services = v } // GetShutdownDelay returns the ShutdownDelay field value if set, zero value otherwise. @@ -739,12 +779,12 @@ func (o *Task) GetTemplates() []Template { var ret []Template return ret } - return *o.Templates + return o.Templates } // GetTemplatesOk returns a tuple with the Templates field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *Task) GetTemplatesOk() (*[]Template, bool) { +func (o *Task) GetTemplatesOk() ([]Template, bool) { if o == nil || o.Templates == nil { return nil, false } @@ -762,7 +802,7 @@ func (o *Task) HasTemplates() bool { // SetTemplates gets a reference to the given []Template and assigns it to the Templates field. func (o *Task) SetTemplates(v []Template) { - o.Templates = &v + o.Templates = v } // GetUser returns the User field value if set, zero value otherwise. @@ -797,36 +837,46 @@ func (o *Task) SetUser(v string) { o.User = &v } -// GetVault returns the Vault field value if set, zero value otherwise. +// GetVault returns the Vault field value if set, zero value otherwise (both if not set or set to explicit null). func (o *Task) GetVault() Vault { - if o == nil || o.Vault == nil { + if o == nil || o.Vault.Get() == nil { var ret Vault return ret } - return *o.Vault + return *o.Vault.Get() } // GetVaultOk returns a tuple with the Vault field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *Task) GetVaultOk() (*Vault, bool) { - if o == nil || o.Vault == nil { + if o == nil { return nil, false } - return o.Vault, true + return o.Vault.Get(), o.Vault.IsSet() } // HasVault returns a boolean if a field has been set. func (o *Task) HasVault() bool { - if o != nil && o.Vault != nil { + if o != nil && o.Vault.IsSet() { return true } return false } -// SetVault gets a reference to the given Vault and assigns it to the Vault field. +// SetVault gets a reference to the given NullableVault and assigns it to the Vault field. func (o *Task) SetVault(v Vault) { - o.Vault = &v + o.Vault.Set(&v) +} +// SetVaultNil sets the value for Vault to be an explicit nil +func (o *Task) SetVaultNil() { + o.Vault.Set(nil) +} + +// UnsetVault ensures that no value is present for Vault, not even an explicit nil +func (o *Task) UnsetVault() { + o.Vault.Unset() } // GetVolumeMounts returns the VolumeMounts field value if set, zero value otherwise. @@ -835,12 +885,12 @@ func (o *Task) GetVolumeMounts() []VolumeMount { var ret []VolumeMount return ret } - return *o.VolumeMounts + return o.VolumeMounts } // GetVolumeMountsOk returns a tuple with the VolumeMounts field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *Task) GetVolumeMountsOk() (*[]VolumeMount, bool) { +func (o *Task) GetVolumeMountsOk() ([]VolumeMount, bool) { if o == nil || o.VolumeMounts == nil { return nil, false } @@ -858,7 +908,7 @@ func (o *Task) HasVolumeMounts() bool { // SetVolumeMounts gets a reference to the given []VolumeMount and assigns it to the VolumeMounts field. func (o *Task) SetVolumeMounts(v []VolumeMount) { - o.VolumeMounts = &v + o.VolumeMounts = v } func (o Task) MarshalJSON() ([]byte, error) { @@ -869,8 +919,8 @@ func (o Task) MarshalJSON() ([]byte, error) { if o.Artifacts != nil { toSerialize["Artifacts"] = o.Artifacts } - if o.CSIPluginConfig != nil { - toSerialize["CSIPluginConfig"] = o.CSIPluginConfig + if o.CSIPluginConfig.IsSet() { + toSerialize["CSIPluginConfig"] = o.CSIPluginConfig.Get() } if o.Config != nil { toSerialize["Config"] = o.Config @@ -878,8 +928,8 @@ func (o Task) MarshalJSON() ([]byte, error) { if o.Constraints != nil { toSerialize["Constraints"] = o.Constraints } - if o.DispatchPayload != nil { - toSerialize["DispatchPayload"] = o.DispatchPayload + if o.DispatchPayload.IsSet() { + toSerialize["DispatchPayload"] = o.DispatchPayload.Get() } if o.Driver != nil { toSerialize["Driver"] = o.Driver @@ -899,8 +949,8 @@ func (o Task) MarshalJSON() ([]byte, error) { if o.Leader != nil { toSerialize["Leader"] = o.Leader } - if o.Lifecycle != nil { - toSerialize["Lifecycle"] = o.Lifecycle + if o.Lifecycle.IsSet() { + toSerialize["Lifecycle"] = o.Lifecycle.Get() } if o.LogConfig != nil { toSerialize["LogConfig"] = o.LogConfig @@ -911,8 +961,8 @@ func (o Task) MarshalJSON() ([]byte, error) { if o.Name != nil { toSerialize["Name"] = o.Name } - if o.Resources != nil { - toSerialize["Resources"] = o.Resources + if o.Resources.IsSet() { + toSerialize["Resources"] = o.Resources.Get() } if o.RestartPolicy != nil { toSerialize["RestartPolicy"] = o.RestartPolicy @@ -932,8 +982,8 @@ func (o Task) MarshalJSON() ([]byte, error) { if o.User != nil { toSerialize["User"] = o.User } - if o.Vault != nil { - toSerialize["Vault"] = o.Vault + if o.Vault.IsSet() { + toSerialize["Vault"] = o.Vault.Get() } if o.VolumeMounts != nil { toSerialize["VolumeMounts"] = o.VolumeMounts diff --git a/clients/go/v1/model_task_artifact.go b/clients/go/v1/model_task_artifact.go index b96a9225..03fc457b 100644 --- a/clients/go/v1/model_task_artifact.go +++ b/clients/go/v1/model_task_artifact.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_task_csi_plugin_config.go b/clients/go/v1/model_task_csi_plugin_config.go index bfe7c93c..ab76101a 100644 --- a/clients/go/v1/model_task_csi_plugin_config.go +++ b/clients/go/v1/model_task_csi_plugin_config.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_task_diff.go b/clients/go/v1/model_task_diff.go index d20555ea..af46bf9f 100644 --- a/clients/go/v1/model_task_diff.go +++ b/clients/go/v1/model_task_diff.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,10 +17,10 @@ import ( // TaskDiff struct for TaskDiff type TaskDiff struct { - Annotations *[]string `json:"Annotations,omitempty"` - Fields *[]FieldDiff `json:"Fields,omitempty"` + Annotations []string `json:"Annotations,omitempty"` + Fields []FieldDiff `json:"Fields,omitempty"` Name *string `json:"Name,omitempty"` - Objects *[]ObjectDiff `json:"Objects,omitempty"` + Objects []ObjectDiff `json:"Objects,omitempty"` Type *string `json:"Type,omitempty"` } @@ -47,12 +47,12 @@ func (o *TaskDiff) GetAnnotations() []string { var ret []string return ret } - return *o.Annotations + return o.Annotations } // GetAnnotationsOk returns a tuple with the Annotations field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *TaskDiff) GetAnnotationsOk() (*[]string, bool) { +func (o *TaskDiff) GetAnnotationsOk() ([]string, bool) { if o == nil || o.Annotations == nil { return nil, false } @@ -70,7 +70,7 @@ func (o *TaskDiff) HasAnnotations() bool { // SetAnnotations gets a reference to the given []string and assigns it to the Annotations field. func (o *TaskDiff) SetAnnotations(v []string) { - o.Annotations = &v + o.Annotations = v } // GetFields returns the Fields field value if set, zero value otherwise. @@ -79,12 +79,12 @@ func (o *TaskDiff) GetFields() []FieldDiff { var ret []FieldDiff return ret } - return *o.Fields + return o.Fields } // GetFieldsOk returns a tuple with the Fields field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *TaskDiff) GetFieldsOk() (*[]FieldDiff, bool) { +func (o *TaskDiff) GetFieldsOk() ([]FieldDiff, bool) { if o == nil || o.Fields == nil { return nil, false } @@ -102,7 +102,7 @@ func (o *TaskDiff) HasFields() bool { // SetFields gets a reference to the given []FieldDiff and assigns it to the Fields field. func (o *TaskDiff) SetFields(v []FieldDiff) { - o.Fields = &v + o.Fields = v } // GetName returns the Name field value if set, zero value otherwise. @@ -143,12 +143,12 @@ func (o *TaskDiff) GetObjects() []ObjectDiff { var ret []ObjectDiff return ret } - return *o.Objects + return o.Objects } // GetObjectsOk returns a tuple with the Objects field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *TaskDiff) GetObjectsOk() (*[]ObjectDiff, bool) { +func (o *TaskDiff) GetObjectsOk() ([]ObjectDiff, bool) { if o == nil || o.Objects == nil { return nil, false } @@ -166,7 +166,7 @@ func (o *TaskDiff) HasObjects() bool { // SetObjects gets a reference to the given []ObjectDiff and assigns it to the Objects field. func (o *TaskDiff) SetObjects(v []ObjectDiff) { - o.Objects = &v + o.Objects = v } // GetType returns the Type field value if set, zero value otherwise. diff --git a/clients/go/v1/model_task_event.go b/clients/go/v1/model_task_event.go index eba44cf4..94c164a1 100644 --- a/clients/go/v1/model_task_event.go +++ b/clients/go/v1/model_task_event.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_task_group.go b/clients/go/v1/model_task_group.go index 9468f375..dcae50a2 100644 --- a/clients/go/v1/model_task_group.go +++ b/clients/go/v1/model_task_group.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,24 +17,24 @@ import ( // TaskGroup struct for TaskGroup type TaskGroup struct { - Affinities *[]Affinity `json:"Affinities,omitempty"` - Constraints *[]Constraint `json:"Constraints,omitempty"` - Consul *Consul `json:"Consul,omitempty"` + Affinities []Affinity `json:"Affinities,omitempty"` + Constraints []Constraint `json:"Constraints,omitempty"` + Consul NullableConsul `json:"Consul,omitempty"` Count *int32 `json:"Count,omitempty"` EphemeralDisk *EphemeralDisk `json:"EphemeralDisk,omitempty"` MaxClientDisconnect *int64 `json:"MaxClientDisconnect,omitempty"` Meta *map[string]string `json:"Meta,omitempty"` Migrate *MigrateStrategy `json:"Migrate,omitempty"` Name *string `json:"Name,omitempty"` - Networks *[]NetworkResource `json:"Networks,omitempty"` + Networks []NetworkResource `json:"Networks,omitempty"` ReschedulePolicy *ReschedulePolicy `json:"ReschedulePolicy,omitempty"` RestartPolicy *RestartPolicy `json:"RestartPolicy,omitempty"` - Scaling *ScalingPolicy `json:"Scaling,omitempty"` - Services *[]Service `json:"Services,omitempty"` + Scaling NullableScalingPolicy `json:"Scaling,omitempty"` + Services []Service `json:"Services,omitempty"` ShutdownDelay *int64 `json:"ShutdownDelay,omitempty"` - Spreads *[]Spread `json:"Spreads,omitempty"` + Spreads []Spread `json:"Spreads,omitempty"` StopAfterClientDisconnect *int64 `json:"StopAfterClientDisconnect,omitempty"` - Tasks *[]Task `json:"Tasks,omitempty"` + Tasks []Task `json:"Tasks,omitempty"` Update *UpdateStrategy `json:"Update,omitempty"` Volumes *map[string]VolumeRequest `json:"Volumes,omitempty"` } @@ -62,12 +62,12 @@ func (o *TaskGroup) GetAffinities() []Affinity { var ret []Affinity return ret } - return *o.Affinities + return o.Affinities } // GetAffinitiesOk returns a tuple with the Affinities field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *TaskGroup) GetAffinitiesOk() (*[]Affinity, bool) { +func (o *TaskGroup) GetAffinitiesOk() ([]Affinity, bool) { if o == nil || o.Affinities == nil { return nil, false } @@ -85,7 +85,7 @@ func (o *TaskGroup) HasAffinities() bool { // SetAffinities gets a reference to the given []Affinity and assigns it to the Affinities field. func (o *TaskGroup) SetAffinities(v []Affinity) { - o.Affinities = &v + o.Affinities = v } // GetConstraints returns the Constraints field value if set, zero value otherwise. @@ -94,12 +94,12 @@ func (o *TaskGroup) GetConstraints() []Constraint { var ret []Constraint return ret } - return *o.Constraints + return o.Constraints } // GetConstraintsOk returns a tuple with the Constraints field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *TaskGroup) GetConstraintsOk() (*[]Constraint, bool) { +func (o *TaskGroup) GetConstraintsOk() ([]Constraint, bool) { if o == nil || o.Constraints == nil { return nil, false } @@ -117,39 +117,49 @@ func (o *TaskGroup) HasConstraints() bool { // SetConstraints gets a reference to the given []Constraint and assigns it to the Constraints field. func (o *TaskGroup) SetConstraints(v []Constraint) { - o.Constraints = &v + o.Constraints = v } -// GetConsul returns the Consul field value if set, zero value otherwise. +// GetConsul returns the Consul field value if set, zero value otherwise (both if not set or set to explicit null). func (o *TaskGroup) GetConsul() Consul { - if o == nil || o.Consul == nil { + if o == nil || o.Consul.Get() == nil { var ret Consul return ret } - return *o.Consul + return *o.Consul.Get() } // GetConsulOk returns a tuple with the Consul field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *TaskGroup) GetConsulOk() (*Consul, bool) { - if o == nil || o.Consul == nil { + if o == nil { return nil, false } - return o.Consul, true + return o.Consul.Get(), o.Consul.IsSet() } // HasConsul returns a boolean if a field has been set. func (o *TaskGroup) HasConsul() bool { - if o != nil && o.Consul != nil { + if o != nil && o.Consul.IsSet() { return true } return false } -// SetConsul gets a reference to the given Consul and assigns it to the Consul field. +// SetConsul gets a reference to the given NullableConsul and assigns it to the Consul field. func (o *TaskGroup) SetConsul(v Consul) { - o.Consul = &v + o.Consul.Set(&v) +} +// SetConsulNil sets the value for Consul to be an explicit nil +func (o *TaskGroup) SetConsulNil() { + o.Consul.Set(nil) +} + +// UnsetConsul ensures that no value is present for Consul, not even an explicit nil +func (o *TaskGroup) UnsetConsul() { + o.Consul.Unset() } // GetCount returns the Count field value if set, zero value otherwise. @@ -350,12 +360,12 @@ func (o *TaskGroup) GetNetworks() []NetworkResource { var ret []NetworkResource return ret } - return *o.Networks + return o.Networks } // GetNetworksOk returns a tuple with the Networks field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *TaskGroup) GetNetworksOk() (*[]NetworkResource, bool) { +func (o *TaskGroup) GetNetworksOk() ([]NetworkResource, bool) { if o == nil || o.Networks == nil { return nil, false } @@ -373,7 +383,7 @@ func (o *TaskGroup) HasNetworks() bool { // SetNetworks gets a reference to the given []NetworkResource and assigns it to the Networks field. func (o *TaskGroup) SetNetworks(v []NetworkResource) { - o.Networks = &v + o.Networks = v } // GetReschedulePolicy returns the ReschedulePolicy field value if set, zero value otherwise. @@ -440,36 +450,46 @@ func (o *TaskGroup) SetRestartPolicy(v RestartPolicy) { o.RestartPolicy = &v } -// GetScaling returns the Scaling field value if set, zero value otherwise. +// GetScaling returns the Scaling field value if set, zero value otherwise (both if not set or set to explicit null). func (o *TaskGroup) GetScaling() ScalingPolicy { - if o == nil || o.Scaling == nil { + if o == nil || o.Scaling.Get() == nil { var ret ScalingPolicy return ret } - return *o.Scaling + return *o.Scaling.Get() } // GetScalingOk returns a tuple with the Scaling field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *TaskGroup) GetScalingOk() (*ScalingPolicy, bool) { - if o == nil || o.Scaling == nil { + if o == nil { return nil, false } - return o.Scaling, true + return o.Scaling.Get(), o.Scaling.IsSet() } // HasScaling returns a boolean if a field has been set. func (o *TaskGroup) HasScaling() bool { - if o != nil && o.Scaling != nil { + if o != nil && o.Scaling.IsSet() { return true } return false } -// SetScaling gets a reference to the given ScalingPolicy and assigns it to the Scaling field. +// SetScaling gets a reference to the given NullableScalingPolicy and assigns it to the Scaling field. func (o *TaskGroup) SetScaling(v ScalingPolicy) { - o.Scaling = &v + o.Scaling.Set(&v) +} +// SetScalingNil sets the value for Scaling to be an explicit nil +func (o *TaskGroup) SetScalingNil() { + o.Scaling.Set(nil) +} + +// UnsetScaling ensures that no value is present for Scaling, not even an explicit nil +func (o *TaskGroup) UnsetScaling() { + o.Scaling.Unset() } // GetServices returns the Services field value if set, zero value otherwise. @@ -478,12 +498,12 @@ func (o *TaskGroup) GetServices() []Service { var ret []Service return ret } - return *o.Services + return o.Services } // GetServicesOk returns a tuple with the Services field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *TaskGroup) GetServicesOk() (*[]Service, bool) { +func (o *TaskGroup) GetServicesOk() ([]Service, bool) { if o == nil || o.Services == nil { return nil, false } @@ -501,7 +521,7 @@ func (o *TaskGroup) HasServices() bool { // SetServices gets a reference to the given []Service and assigns it to the Services field. func (o *TaskGroup) SetServices(v []Service) { - o.Services = &v + o.Services = v } // GetShutdownDelay returns the ShutdownDelay field value if set, zero value otherwise. @@ -542,12 +562,12 @@ func (o *TaskGroup) GetSpreads() []Spread { var ret []Spread return ret } - return *o.Spreads + return o.Spreads } // GetSpreadsOk returns a tuple with the Spreads field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *TaskGroup) GetSpreadsOk() (*[]Spread, bool) { +func (o *TaskGroup) GetSpreadsOk() ([]Spread, bool) { if o == nil || o.Spreads == nil { return nil, false } @@ -565,7 +585,7 @@ func (o *TaskGroup) HasSpreads() bool { // SetSpreads gets a reference to the given []Spread and assigns it to the Spreads field. func (o *TaskGroup) SetSpreads(v []Spread) { - o.Spreads = &v + o.Spreads = v } // GetStopAfterClientDisconnect returns the StopAfterClientDisconnect field value if set, zero value otherwise. @@ -606,12 +626,12 @@ func (o *TaskGroup) GetTasks() []Task { var ret []Task return ret } - return *o.Tasks + return o.Tasks } // GetTasksOk returns a tuple with the Tasks field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *TaskGroup) GetTasksOk() (*[]Task, bool) { +func (o *TaskGroup) GetTasksOk() ([]Task, bool) { if o == nil || o.Tasks == nil { return nil, false } @@ -629,7 +649,7 @@ func (o *TaskGroup) HasTasks() bool { // SetTasks gets a reference to the given []Task and assigns it to the Tasks field. func (o *TaskGroup) SetTasks(v []Task) { - o.Tasks = &v + o.Tasks = v } // GetUpdate returns the Update field value if set, zero value otherwise. @@ -704,8 +724,8 @@ func (o TaskGroup) MarshalJSON() ([]byte, error) { if o.Constraints != nil { toSerialize["Constraints"] = o.Constraints } - if o.Consul != nil { - toSerialize["Consul"] = o.Consul + if o.Consul.IsSet() { + toSerialize["Consul"] = o.Consul.Get() } if o.Count != nil { toSerialize["Count"] = o.Count @@ -734,8 +754,8 @@ func (o TaskGroup) MarshalJSON() ([]byte, error) { if o.RestartPolicy != nil { toSerialize["RestartPolicy"] = o.RestartPolicy } - if o.Scaling != nil { - toSerialize["Scaling"] = o.Scaling + if o.Scaling.IsSet() { + toSerialize["Scaling"] = o.Scaling.Get() } if o.Services != nil { toSerialize["Services"] = o.Services diff --git a/clients/go/v1/model_task_group_diff.go b/clients/go/v1/model_task_group_diff.go index 120fc8cd..8e8ba5a8 100644 --- a/clients/go/v1/model_task_group_diff.go +++ b/clients/go/v1/model_task_group_diff.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -17,10 +17,10 @@ import ( // TaskGroupDiff struct for TaskGroupDiff type TaskGroupDiff struct { - Fields *[]FieldDiff `json:"Fields,omitempty"` + Fields []FieldDiff `json:"Fields,omitempty"` Name *string `json:"Name,omitempty"` - Objects *[]ObjectDiff `json:"Objects,omitempty"` - Tasks *[]TaskDiff `json:"Tasks,omitempty"` + Objects []ObjectDiff `json:"Objects,omitempty"` + Tasks []TaskDiff `json:"Tasks,omitempty"` Type *string `json:"Type,omitempty"` Updates *map[string]int32 `json:"Updates,omitempty"` } @@ -48,12 +48,12 @@ func (o *TaskGroupDiff) GetFields() []FieldDiff { var ret []FieldDiff return ret } - return *o.Fields + return o.Fields } // GetFieldsOk returns a tuple with the Fields field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *TaskGroupDiff) GetFieldsOk() (*[]FieldDiff, bool) { +func (o *TaskGroupDiff) GetFieldsOk() ([]FieldDiff, bool) { if o == nil || o.Fields == nil { return nil, false } @@ -71,7 +71,7 @@ func (o *TaskGroupDiff) HasFields() bool { // SetFields gets a reference to the given []FieldDiff and assigns it to the Fields field. func (o *TaskGroupDiff) SetFields(v []FieldDiff) { - o.Fields = &v + o.Fields = v } // GetName returns the Name field value if set, zero value otherwise. @@ -112,12 +112,12 @@ func (o *TaskGroupDiff) GetObjects() []ObjectDiff { var ret []ObjectDiff return ret } - return *o.Objects + return o.Objects } // GetObjectsOk returns a tuple with the Objects field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *TaskGroupDiff) GetObjectsOk() (*[]ObjectDiff, bool) { +func (o *TaskGroupDiff) GetObjectsOk() ([]ObjectDiff, bool) { if o == nil || o.Objects == nil { return nil, false } @@ -135,7 +135,7 @@ func (o *TaskGroupDiff) HasObjects() bool { // SetObjects gets a reference to the given []ObjectDiff and assigns it to the Objects field. func (o *TaskGroupDiff) SetObjects(v []ObjectDiff) { - o.Objects = &v + o.Objects = v } // GetTasks returns the Tasks field value if set, zero value otherwise. @@ -144,12 +144,12 @@ func (o *TaskGroupDiff) GetTasks() []TaskDiff { var ret []TaskDiff return ret } - return *o.Tasks + return o.Tasks } // GetTasksOk returns a tuple with the Tasks field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *TaskGroupDiff) GetTasksOk() (*[]TaskDiff, bool) { +func (o *TaskGroupDiff) GetTasksOk() ([]TaskDiff, bool) { if o == nil || o.Tasks == nil { return nil, false } @@ -167,7 +167,7 @@ func (o *TaskGroupDiff) HasTasks() bool { // SetTasks gets a reference to the given []TaskDiff and assigns it to the Tasks field. func (o *TaskGroupDiff) SetTasks(v []TaskDiff) { - o.Tasks = &v + o.Tasks = v } // GetType returns the Type field value if set, zero value otherwise. diff --git a/clients/go/v1/model_task_group_scale_status.go b/clients/go/v1/model_task_group_scale_status.go index 03b0bdb4..29f21948 100644 --- a/clients/go/v1/model_task_group_scale_status.go +++ b/clients/go/v1/model_task_group_scale_status.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -18,7 +18,7 @@ import ( // TaskGroupScaleStatus struct for TaskGroupScaleStatus type TaskGroupScaleStatus struct { Desired *int32 `json:"Desired,omitempty"` - Events *[]ScalingEvent `json:"Events,omitempty"` + Events []ScalingEvent `json:"Events,omitempty"` Healthy *int32 `json:"Healthy,omitempty"` Placed *int32 `json:"Placed,omitempty"` Running *int32 `json:"Running,omitempty"` @@ -80,12 +80,12 @@ func (o *TaskGroupScaleStatus) GetEvents() []ScalingEvent { var ret []ScalingEvent return ret } - return *o.Events + return o.Events } // GetEventsOk returns a tuple with the Events field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *TaskGroupScaleStatus) GetEventsOk() (*[]ScalingEvent, bool) { +func (o *TaskGroupScaleStatus) GetEventsOk() ([]ScalingEvent, bool) { if o == nil || o.Events == nil { return nil, false } @@ -103,7 +103,7 @@ func (o *TaskGroupScaleStatus) HasEvents() bool { // SetEvents gets a reference to the given []ScalingEvent and assigns it to the Events field. func (o *TaskGroupScaleStatus) SetEvents(v []ScalingEvent) { - o.Events = &v + o.Events = v } // GetHealthy returns the Healthy field value if set, zero value otherwise. diff --git a/clients/go/v1/model_task_group_summary.go b/clients/go/v1/model_task_group_summary.go index 444926f3..af8497bd 100644 --- a/clients/go/v1/model_task_group_summary.go +++ b/clients/go/v1/model_task_group_summary.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_task_handle.go b/clients/go/v1/model_task_handle.go index 50d5c8a7..c148a0a5 100644 --- a/clients/go/v1/model_task_handle.go +++ b/clients/go/v1/model_task_handle.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_task_lifecycle.go b/clients/go/v1/model_task_lifecycle.go index 352095b7..396dcf1d 100644 --- a/clients/go/v1/model_task_lifecycle.go +++ b/clients/go/v1/model_task_lifecycle.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_task_state.go b/clients/go/v1/model_task_state.go index d930a27e..718915f8 100644 --- a/clients/go/v1/model_task_state.go +++ b/clients/go/v1/model_task_state.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -18,14 +18,14 @@ import ( // TaskState struct for TaskState type TaskState struct { - Events *[]TaskEvent `json:"Events,omitempty"` + Events []TaskEvent `json:"Events,omitempty"` Failed *bool `json:"Failed,omitempty"` - FinishedAt *time.Time `json:"FinishedAt,omitempty"` - LastRestart *time.Time `json:"LastRestart,omitempty"` + FinishedAt NullableTime `json:"FinishedAt,omitempty"` + LastRestart NullableTime `json:"LastRestart,omitempty"` Restarts *int32 `json:"Restarts,omitempty"` - StartedAt *time.Time `json:"StartedAt,omitempty"` + StartedAt NullableTime `json:"StartedAt,omitempty"` State *string `json:"State,omitempty"` - TaskHandle *TaskHandle `json:"TaskHandle,omitempty"` + TaskHandle NullableTaskHandle `json:"TaskHandle,omitempty"` } // NewTaskState instantiates a new TaskState object @@ -51,12 +51,12 @@ func (o *TaskState) GetEvents() []TaskEvent { var ret []TaskEvent return ret } - return *o.Events + return o.Events } // GetEventsOk returns a tuple with the Events field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *TaskState) GetEventsOk() (*[]TaskEvent, bool) { +func (o *TaskState) GetEventsOk() ([]TaskEvent, bool) { if o == nil || o.Events == nil { return nil, false } @@ -74,7 +74,7 @@ func (o *TaskState) HasEvents() bool { // SetEvents gets a reference to the given []TaskEvent and assigns it to the Events field. func (o *TaskState) SetEvents(v []TaskEvent) { - o.Events = &v + o.Events = v } // GetFailed returns the Failed field value if set, zero value otherwise. @@ -109,68 +109,88 @@ func (o *TaskState) SetFailed(v bool) { o.Failed = &v } -// GetFinishedAt returns the FinishedAt field value if set, zero value otherwise. +// GetFinishedAt returns the FinishedAt field value if set, zero value otherwise (both if not set or set to explicit null). func (o *TaskState) GetFinishedAt() time.Time { - if o == nil || o.FinishedAt == nil { + if o == nil || o.FinishedAt.Get() == nil { var ret time.Time return ret } - return *o.FinishedAt + return *o.FinishedAt.Get() } // GetFinishedAtOk returns a tuple with the FinishedAt field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *TaskState) GetFinishedAtOk() (*time.Time, bool) { - if o == nil || o.FinishedAt == nil { + if o == nil { return nil, false } - return o.FinishedAt, true + return o.FinishedAt.Get(), o.FinishedAt.IsSet() } // HasFinishedAt returns a boolean if a field has been set. func (o *TaskState) HasFinishedAt() bool { - if o != nil && o.FinishedAt != nil { + if o != nil && o.FinishedAt.IsSet() { return true } return false } -// SetFinishedAt gets a reference to the given time.Time and assigns it to the FinishedAt field. +// SetFinishedAt gets a reference to the given NullableTime and assigns it to the FinishedAt field. func (o *TaskState) SetFinishedAt(v time.Time) { - o.FinishedAt = &v + o.FinishedAt.Set(&v) +} +// SetFinishedAtNil sets the value for FinishedAt to be an explicit nil +func (o *TaskState) SetFinishedAtNil() { + o.FinishedAt.Set(nil) } -// GetLastRestart returns the LastRestart field value if set, zero value otherwise. +// UnsetFinishedAt ensures that no value is present for FinishedAt, not even an explicit nil +func (o *TaskState) UnsetFinishedAt() { + o.FinishedAt.Unset() +} + +// GetLastRestart returns the LastRestart field value if set, zero value otherwise (both if not set or set to explicit null). func (o *TaskState) GetLastRestart() time.Time { - if o == nil || o.LastRestart == nil { + if o == nil || o.LastRestart.Get() == nil { var ret time.Time return ret } - return *o.LastRestart + return *o.LastRestart.Get() } // GetLastRestartOk returns a tuple with the LastRestart field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *TaskState) GetLastRestartOk() (*time.Time, bool) { - if o == nil || o.LastRestart == nil { + if o == nil { return nil, false } - return o.LastRestart, true + return o.LastRestart.Get(), o.LastRestart.IsSet() } // HasLastRestart returns a boolean if a field has been set. func (o *TaskState) HasLastRestart() bool { - if o != nil && o.LastRestart != nil { + if o != nil && o.LastRestart.IsSet() { return true } return false } -// SetLastRestart gets a reference to the given time.Time and assigns it to the LastRestart field. +// SetLastRestart gets a reference to the given NullableTime and assigns it to the LastRestart field. func (o *TaskState) SetLastRestart(v time.Time) { - o.LastRestart = &v + o.LastRestart.Set(&v) +} +// SetLastRestartNil sets the value for LastRestart to be an explicit nil +func (o *TaskState) SetLastRestartNil() { + o.LastRestart.Set(nil) +} + +// UnsetLastRestart ensures that no value is present for LastRestart, not even an explicit nil +func (o *TaskState) UnsetLastRestart() { + o.LastRestart.Unset() } // GetRestarts returns the Restarts field value if set, zero value otherwise. @@ -205,36 +225,46 @@ func (o *TaskState) SetRestarts(v int32) { o.Restarts = &v } -// GetStartedAt returns the StartedAt field value if set, zero value otherwise. +// GetStartedAt returns the StartedAt field value if set, zero value otherwise (both if not set or set to explicit null). func (o *TaskState) GetStartedAt() time.Time { - if o == nil || o.StartedAt == nil { + if o == nil || o.StartedAt.Get() == nil { var ret time.Time return ret } - return *o.StartedAt + return *o.StartedAt.Get() } // GetStartedAtOk returns a tuple with the StartedAt field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *TaskState) GetStartedAtOk() (*time.Time, bool) { - if o == nil || o.StartedAt == nil { + if o == nil { return nil, false } - return o.StartedAt, true + return o.StartedAt.Get(), o.StartedAt.IsSet() } // HasStartedAt returns a boolean if a field has been set. func (o *TaskState) HasStartedAt() bool { - if o != nil && o.StartedAt != nil { + if o != nil && o.StartedAt.IsSet() { return true } return false } -// SetStartedAt gets a reference to the given time.Time and assigns it to the StartedAt field. +// SetStartedAt gets a reference to the given NullableTime and assigns it to the StartedAt field. func (o *TaskState) SetStartedAt(v time.Time) { - o.StartedAt = &v + o.StartedAt.Set(&v) +} +// SetStartedAtNil sets the value for StartedAt to be an explicit nil +func (o *TaskState) SetStartedAtNil() { + o.StartedAt.Set(nil) +} + +// UnsetStartedAt ensures that no value is present for StartedAt, not even an explicit nil +func (o *TaskState) UnsetStartedAt() { + o.StartedAt.Unset() } // GetState returns the State field value if set, zero value otherwise. @@ -269,36 +299,46 @@ func (o *TaskState) SetState(v string) { o.State = &v } -// GetTaskHandle returns the TaskHandle field value if set, zero value otherwise. +// GetTaskHandle returns the TaskHandle field value if set, zero value otherwise (both if not set or set to explicit null). func (o *TaskState) GetTaskHandle() TaskHandle { - if o == nil || o.TaskHandle == nil { + if o == nil || o.TaskHandle.Get() == nil { var ret TaskHandle return ret } - return *o.TaskHandle + return *o.TaskHandle.Get() } // GetTaskHandleOk returns a tuple with the TaskHandle field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *TaskState) GetTaskHandleOk() (*TaskHandle, bool) { - if o == nil || o.TaskHandle == nil { + if o == nil { return nil, false } - return o.TaskHandle, true + return o.TaskHandle.Get(), o.TaskHandle.IsSet() } // HasTaskHandle returns a boolean if a field has been set. func (o *TaskState) HasTaskHandle() bool { - if o != nil && o.TaskHandle != nil { + if o != nil && o.TaskHandle.IsSet() { return true } return false } -// SetTaskHandle gets a reference to the given TaskHandle and assigns it to the TaskHandle field. +// SetTaskHandle gets a reference to the given NullableTaskHandle and assigns it to the TaskHandle field. func (o *TaskState) SetTaskHandle(v TaskHandle) { - o.TaskHandle = &v + o.TaskHandle.Set(&v) +} +// SetTaskHandleNil sets the value for TaskHandle to be an explicit nil +func (o *TaskState) SetTaskHandleNil() { + o.TaskHandle.Set(nil) +} + +// UnsetTaskHandle ensures that no value is present for TaskHandle, not even an explicit nil +func (o *TaskState) UnsetTaskHandle() { + o.TaskHandle.Unset() } func (o TaskState) MarshalJSON() ([]byte, error) { @@ -309,23 +349,23 @@ func (o TaskState) MarshalJSON() ([]byte, error) { if o.Failed != nil { toSerialize["Failed"] = o.Failed } - if o.FinishedAt != nil { - toSerialize["FinishedAt"] = o.FinishedAt + if o.FinishedAt.IsSet() { + toSerialize["FinishedAt"] = o.FinishedAt.Get() } - if o.LastRestart != nil { - toSerialize["LastRestart"] = o.LastRestart + if o.LastRestart.IsSet() { + toSerialize["LastRestart"] = o.LastRestart.Get() } if o.Restarts != nil { toSerialize["Restarts"] = o.Restarts } - if o.StartedAt != nil { - toSerialize["StartedAt"] = o.StartedAt + if o.StartedAt.IsSet() { + toSerialize["StartedAt"] = o.StartedAt.Get() } if o.State != nil { toSerialize["State"] = o.State } - if o.TaskHandle != nil { - toSerialize["TaskHandle"] = o.TaskHandle + if o.TaskHandle.IsSet() { + toSerialize["TaskHandle"] = o.TaskHandle.Get() } return json.Marshal(toSerialize) } diff --git a/clients/go/v1/model_template.go b/clients/go/v1/model_template.go index 48013705..4f873afa 100644 --- a/clients/go/v1/model_template.go +++ b/clients/go/v1/model_template.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_update_strategy.go b/clients/go/v1/model_update_strategy.go index f9e67fe3..c3a5345a 100644 --- a/clients/go/v1/model_update_strategy.go +++ b/clients/go/v1/model_update_strategy.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_vault.go b/clients/go/v1/model_vault.go index 1ea7554c..f47ff34f 100644 --- a/clients/go/v1/model_vault.go +++ b/clients/go/v1/model_vault.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -21,7 +21,7 @@ type Vault struct { ChangeSignal *string `json:"ChangeSignal,omitempty"` Env *bool `json:"Env,omitempty"` Namespace *string `json:"Namespace,omitempty"` - Policies *[]string `json:"Policies,omitempty"` + Policies []string `json:"Policies,omitempty"` } // NewVault instantiates a new Vault object @@ -175,12 +175,12 @@ func (o *Vault) GetPolicies() []string { var ret []string return ret } - return *o.Policies + return o.Policies } // GetPoliciesOk returns a tuple with the Policies field value if set, nil otherwise // and a boolean to check if the value has been set. -func (o *Vault) GetPoliciesOk() (*[]string, bool) { +func (o *Vault) GetPoliciesOk() ([]string, bool) { if o == nil || o.Policies == nil { return nil, false } @@ -198,7 +198,7 @@ func (o *Vault) HasPolicies() bool { // SetPolicies gets a reference to the given []string and assigns it to the Policies field. func (o *Vault) SetPolicies(v []string) { - o.Policies = &v + o.Policies = v } func (o Vault) MarshalJSON() ([]byte, error) { diff --git a/clients/go/v1/model_volume_mount.go b/clients/go/v1/model_volume_mount.go index 0adcbdda..f6b67a92 100644 --- a/clients/go/v1/model_volume_mount.go +++ b/clients/go/v1/model_volume_mount.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/model_volume_request.go b/clients/go/v1/model_volume_request.go index c2079272..8e893c70 100644 --- a/clients/go/v1/model_volume_request.go +++ b/clients/go/v1/model_volume_request.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -19,7 +19,7 @@ import ( type VolumeRequest struct { AccessMode *string `json:"AccessMode,omitempty"` AttachmentMode *string `json:"AttachmentMode,omitempty"` - MountOptions *CSIMountOptions `json:"MountOptions,omitempty"` + MountOptions NullableCSIMountOptions `json:"MountOptions,omitempty"` Name *string `json:"Name,omitempty"` PerAlloc *bool `json:"PerAlloc,omitempty"` ReadOnly *bool `json:"ReadOnly,omitempty"` @@ -108,36 +108,46 @@ func (o *VolumeRequest) SetAttachmentMode(v string) { o.AttachmentMode = &v } -// GetMountOptions returns the MountOptions field value if set, zero value otherwise. +// GetMountOptions returns the MountOptions field value if set, zero value otherwise (both if not set or set to explicit null). func (o *VolumeRequest) GetMountOptions() CSIMountOptions { - if o == nil || o.MountOptions == nil { + if o == nil || o.MountOptions.Get() == nil { var ret CSIMountOptions return ret } - return *o.MountOptions + return *o.MountOptions.Get() } // GetMountOptionsOk returns a tuple with the MountOptions field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *VolumeRequest) GetMountOptionsOk() (*CSIMountOptions, bool) { - if o == nil || o.MountOptions == nil { + if o == nil { return nil, false } - return o.MountOptions, true + return o.MountOptions.Get(), o.MountOptions.IsSet() } // HasMountOptions returns a boolean if a field has been set. func (o *VolumeRequest) HasMountOptions() bool { - if o != nil && o.MountOptions != nil { + if o != nil && o.MountOptions.IsSet() { return true } return false } -// SetMountOptions gets a reference to the given CSIMountOptions and assigns it to the MountOptions field. +// SetMountOptions gets a reference to the given NullableCSIMountOptions and assigns it to the MountOptions field. func (o *VolumeRequest) SetMountOptions(v CSIMountOptions) { - o.MountOptions = &v + o.MountOptions.Set(&v) +} +// SetMountOptionsNil sets the value for MountOptions to be an explicit nil +func (o *VolumeRequest) SetMountOptionsNil() { + o.MountOptions.Set(nil) +} + +// UnsetMountOptions ensures that no value is present for MountOptions, not even an explicit nil +func (o *VolumeRequest) UnsetMountOptions() { + o.MountOptions.Unset() } // GetName returns the Name field value if set, zero value otherwise. @@ -308,8 +318,8 @@ func (o VolumeRequest) MarshalJSON() ([]byte, error) { if o.AttachmentMode != nil { toSerialize["AttachmentMode"] = o.AttachmentMode } - if o.MountOptions != nil { - toSerialize["MountOptions"] = o.MountOptions + if o.MountOptions.IsSet() { + toSerialize["MountOptions"] = o.MountOptions.Get() } if o.Name != nil { toSerialize["Name"] = o.Name diff --git a/clients/go/v1/model_wait_config.go b/clients/go/v1/model_wait_config.go index 337764e2..884e1550 100644 --- a/clients/go/v1/model_wait_config.go +++ b/clients/go/v1/model_wait_config.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/response.go b/clients/go/v1/response.go index 3f15ab50..628fe729 100644 --- a/clients/go/v1/response.go +++ b/clients/go/v1/response.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/go/v1/utils.go b/clients/go/v1/utils.go index e72b3d96..dfd8243d 100644 --- a/clients/go/v1/utils.go +++ b/clients/go/v1/utils.go @@ -1,11 +1,11 @@ /* - * Nomad - * - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * API version: 1.1.4 - * Contact: support@hashicorp.com - */ +Nomad + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 1.1.4 +Contact: support@hashicorp.com +*/ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/clients/java/v1/.github/workflows/maven.yml b/clients/java/v1/.github/workflows/maven.yml new file mode 100644 index 00000000..c91d3e28 --- /dev/null +++ b/clients/java/v1/.github/workflows/maven.yml @@ -0,0 +1,30 @@ +# This workflow will build a Java project with Maven, and cache/restore any dependencies to improve the workflow execution time +# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven +# +# This file is auto-generated by OpenAPI Generator (https://openapi-generator.tech) + +name: Java CI with Maven + +on: + push: + branches: [ main, master ] + pull_request: + branches: [ main, master ] + +jobs: + build: + name: Build Nomad + runs-on: ubuntu-latest + strategy: + matrix: + java: [ '8' ] + steps: + - uses: actions/checkout@v2 + - name: Set up JDK + uses: actions/setup-java@v2 + with: + java-version: ${{ matrix.java }} + distribution: 'temurin' + cache: maven + - name: Build with Maven + run: mvn -B package --no-transfer-progress --file pom.xml diff --git a/clients/java/v1/.openapi-generator/VERSION b/clients/java/v1/.openapi-generator/VERSION index 7cbea073..1e20ec35 100644 --- a/clients/java/v1/.openapi-generator/VERSION +++ b/clients/java/v1/.openapi-generator/VERSION @@ -1 +1 @@ -5.2.0 \ No newline at end of file +5.4.0 \ No newline at end of file diff --git a/clients/java/v1/README.md b/clients/java/v1/README.md index c8e310c7..b623ae15 100644 --- a/clients/java/v1/README.md +++ b/clients/java/v1/README.md @@ -13,7 +13,7 @@ No description provided (generated by Openapi Generator https://github.com/opena Building the API client library requires: 1. Java 1.7+ -2. Maven/Gradle +2. Maven (3.8.3+)/Gradle (7.2+) ## Installation @@ -49,7 +49,14 @@ Add this dependency to your project's POM: Add this dependency to your project's build file: ```groovy -compile "io.nomadproject:nomad-openapi-java-client:1.1.4" + repositories { + mavenCentral() // Needed if the 'nomad-openapi-java-client' jar has been published to maven central. + mavenLocal() // Needed if the 'nomad-openapi-java-client' jar has been published to the local maven repo. + } + + dependencies { + implementation "io.nomadproject:nomad-openapi-java-client:1.1.4" + } ``` ### Others diff --git a/clients/java/v1/api/openapi.yaml b/clients/java/v1/api/openapi.yaml index ede31d1c..32903127 100644 --- a/clients/java/v1/api/openapi.yaml +++ b/clients/java/v1/api/openapi.yaml @@ -7171,7 +7171,8 @@ paths: content: application/json: schema: - items: {} + items: + $ref: '#/components/schemas/Quotas' type: array headers: X-Nomad-Index: @@ -10728,7 +10729,8 @@ components: content: application/json: schema: - items: {} + items: + $ref: '#/components/schemas/Quotas' type: array headers: X-Nomad-Index: @@ -11324,6 +11326,7 @@ components: Rules: Rules ModifyIndex: 2147483647 Name: Name + nullable: true properties: CreateIndex: maximum: 1.8446744073709552E+19 @@ -11346,6 +11349,7 @@ components: Description: Description ModifyIndex: 2147483647 Name: Name + nullable: true properties: CreateIndex: maximum: 1.8446744073709552E+19 @@ -11373,6 +11377,7 @@ components: Global: true ModifyIndex: 2147483647 Name: Name + nullable: true properties: AccessorID: type: string @@ -11382,6 +11387,7 @@ components: type: integer CreateTime: format: date-time + nullable: true type: string Global: type: boolean @@ -11412,6 +11418,7 @@ components: Global: true ModifyIndex: 2147483647 Name: Name + nullable: true properties: AccessorID: type: string @@ -11421,6 +11428,7 @@ components: type: integer CreateTime: format: date-time + nullable: true type: string Global: type: boolean @@ -11443,6 +11451,7 @@ components: RTarget: RTarget Operand: Operand Weight: -101 + nullable: true properties: LTarget: type: string @@ -11461,6 +11470,7 @@ components: Timestamp: 2000-01-23T04:56:07.000+00:00 Healthy: true ModifyIndex: 2147483647 + nullable: true properties: Canary: type: boolean @@ -11472,12 +11482,14 @@ components: type: integer Timestamp: format: date-time + nullable: true type: string type: object AllocStopResponse: example: Index: 2147483647 EvalID: EvalID + nullable: true properties: EvalID: type: string @@ -11489,6 +11501,7 @@ components: AllocatedCpuResources: example: CpuShares: 9 + nullable: true properties: CpuShares: format: int64 @@ -11502,6 +11515,7 @@ components: Type: Type Vendor: Vendor Name: Name + nullable: true properties: DeviceIDs: items: @@ -11518,6 +11532,7 @@ components: example: MemoryMB: 3 MemoryMaxMB: 2 + nullable: true properties: MemoryMB: format: int64 @@ -11697,6 +11712,7 @@ components: Label: Label Value: 7 To: 2 + nullable: true properties: Shared: $ref: '#/components/schemas/AllocatedSharedResources' @@ -11786,6 +11802,7 @@ components: Label: Label Value: 7 To: 2 + nullable: true properties: DiskMB: format: int64 @@ -11888,6 +11905,7 @@ components: Type: Type Vendor: Vendor Name: Name + nullable: true properties: Cpu: $ref: '#/components/schemas/AllocatedCpuResources' @@ -11904,7 +11922,7 @@ components: type: object Allocation: example: - ModifyTime: 8 + ModifyTime: 9 PreemptedAllocations: - PreemptedAllocations - PreemptedAllocations @@ -12081,35 +12099,27 @@ components: To: 2 Name: Name Metrics: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -17438,23 +17448,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -17464,23 +17474,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -17495,7 +17505,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -17751,11 +17761,12 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID + nullable: true properties: AllocModifyIndex: maximum: 1.8446744073709552E+19 @@ -18028,23 +18039,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -18054,23 +18065,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -18085,7 +18096,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -18107,11 +18118,12 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID + nullable: true properties: AllocatedResources: $ref: '#/components/schemas/AllocatedResources' @@ -18178,35 +18190,27 @@ components: type: object AllocationMetric: example: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -18321,31 +18325,32 @@ components: Count: 2147483647 Name: Name MemoryMaxMB: 5 + nullable: true properties: AllocationTime: format: int64 type: integer ClassExhausted: additionalProperties: - type: integer + $ref: '#/components/schemas/int' type: object ClassFiltered: additionalProperties: - type: integer + $ref: '#/components/schemas/int' type: object CoalescedFailures: type: integer ConstraintFiltered: additionalProperties: - type: integer + $ref: '#/components/schemas/int' type: object DimensionExhausted: additionalProperties: - type: integer + $ref: '#/components/schemas/int' type: object NodesAvailable: additionalProperties: - type: integer + $ref: '#/components/schemas/int' type: object NodesEvaluated: type: integer @@ -18367,8 +18372,7 @@ components: type: array Scores: additionalProperties: - format: double - type: number + $ref: '#/components/schemas/float64' type: object type: object Attribute: @@ -18378,6 +18382,7 @@ components: String: String Unit: Unit Int: 2 + nullable: true properties: Bool: type: boolean @@ -18404,6 +18409,7 @@ components: EnableRedundancyZones: true ModifyIndex: 2147483647 CleanupDeadServers: true + nullable: true properties: CleanupDeadServers: type: boolean @@ -18447,6 +18453,7 @@ components: SupportsExpand: true SupportsGet: true SupportsCondition: true + nullable: true properties: SupportsAttachDetach: type: boolean @@ -18505,6 +18512,7 @@ components: SupportsCondition: true Healthy: true RequiresControllerPlugin: true + nullable: true properties: AllocID: type: string @@ -18524,6 +18532,7 @@ components: type: boolean UpdateTime: format: date-time + nullable: true type: string type: object CSIMountOptions: @@ -18532,6 +18541,7 @@ components: - MountFlags - MountFlags FSType: FSType + nullable: true properties: FSType: type: string @@ -18551,6 +18561,7 @@ components: key: Segments SupportsCondition: true SupportsStats: true + nullable: true properties: AccessibleTopology: $ref: '#/components/schemas/CSITopology' @@ -18789,23 +18800,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -18815,23 +18826,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -18846,7 +18857,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -18868,10 +18879,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - ModifyTime: 5 PreemptedAllocations: @@ -19059,23 +19070,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -19085,23 +19096,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -19116,7 +19127,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -19138,10 +19149,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID ControllersExpected: 0 NodesHealthy: 2 @@ -19185,6 +19196,7 @@ components: Version: Version ID: ID ModifyIndex: 2147483647 + nullable: true properties: Allocations: items: @@ -19234,6 +19246,7 @@ components: ID: ID ModifyIndex: 2147483647 Provider: Provider + nullable: true properties: ControllerRequired: type: boolean @@ -19278,6 +19291,7 @@ components: SourceVolumeID: SourceVolumeID ExternalSourceVolumeID: ExternalSourceVolumeID Name: Name + nullable: true properties: CreateTime: format: int64 @@ -19336,6 +19350,7 @@ components: ExternalSourceVolumeID: ExternalSourceVolumeID Name: Name Namespace: Namespace + nullable: true properties: Namespace: type: string @@ -19380,6 +19395,7 @@ components: SourceVolumeID: SourceVolumeID ExternalSourceVolumeID: ExternalSourceVolumeID Name: Name + nullable: true properties: KnownLeader: type: boolean @@ -19432,6 +19448,7 @@ components: SourceVolumeID: SourceVolumeID ExternalSourceVolumeID: ExternalSourceVolumeID Name: Name + nullable: true properties: KnownLeader: type: boolean @@ -19456,6 +19473,7 @@ components: example: Segments: key: Segments + nullable: true properties: Segments: additionalProperties: @@ -19474,6 +19492,7 @@ components: key: Segments - Segments: key: Segments + nullable: true properties: Preferred: items: @@ -19674,23 +19693,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -19700,23 +19719,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -19731,7 +19750,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -19753,10 +19772,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - ModifyTime: 5 PreemptedAllocations: @@ -19944,23 +19963,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -19970,23 +19989,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -20001,7 +20020,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -20023,10 +20042,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID RequestedTopologies: Preferred: @@ -20050,7 +20069,7 @@ components: SnapshotID: SnapshotID WriteAllocs: key: - ModifyTime: 8 + ModifyTime: 9 PreemptedAllocations: - PreemptedAllocations - PreemptedAllocations @@ -20227,35 +20246,27 @@ components: To: 2 Name: Name Metrics: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -25584,23 +25595,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -25610,23 +25621,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -25641,7 +25652,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -25897,10 +25908,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID CreateIndex: 2147483647 Capacity: 0 @@ -25916,7 +25927,7 @@ components: ControllersExpected: 6 ReadAllocs: key: - ModifyTime: 8 + ModifyTime: 9 PreemptedAllocations: - PreemptedAllocations - PreemptedAllocations @@ -26093,35 +26104,27 @@ components: To: 2 Name: Name Metrics: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -31450,23 +31453,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -31476,23 +31479,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -31507,7 +31510,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -31763,10 +31766,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID Parameters: key: Parameters @@ -31790,6 +31793,7 @@ components: FSType: FSType ModifyIndex: 2147483647 ProviderVersion: ProviderVersion + nullable: true properties: AccessMode: type: string @@ -31864,6 +31868,7 @@ components: $ref: '#/components/schemas/CSITopologyRequest' ResourceExhausted: format: date-time + nullable: true type: string Schedulable: type: boolean @@ -31890,6 +31895,7 @@ components: example: AccessMode: AccessMode AttachmentMode: AttachmentMode + nullable: true properties: AccessMode: type: string @@ -32087,23 +32093,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -32113,23 +32119,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -32144,7 +32150,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -32166,10 +32172,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - ModifyTime: 5 PreemptedAllocations: @@ -32357,23 +32363,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -32383,23 +32389,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -32414,7 +32420,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -32436,10 +32442,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID RequestedTopologies: Preferred: @@ -32463,7 +32469,7 @@ components: SnapshotID: SnapshotID WriteAllocs: key: - ModifyTime: 8 + ModifyTime: 9 PreemptedAllocations: - PreemptedAllocations - PreemptedAllocations @@ -32640,35 +32646,27 @@ components: To: 2 Name: Name Metrics: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -37997,23 +37995,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -38023,23 +38021,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -38054,7 +38052,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -38310,10 +38308,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID CreateIndex: 2147483647 Capacity: 0 @@ -38329,7 +38327,7 @@ components: ControllersExpected: 6 ReadAllocs: key: - ModifyTime: 8 + ModifyTime: 9 PreemptedAllocations: - PreemptedAllocations - PreemptedAllocations @@ -38506,35 +38504,27 @@ components: To: 2 Name: Name Metrics: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -43863,23 +43853,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -43889,23 +43879,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -43920,7 +43910,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -44176,10 +44166,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID Parameters: key: Parameters @@ -44391,23 +44381,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -44417,23 +44407,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -44448,7 +44438,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -44470,10 +44460,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - ModifyTime: 5 PreemptedAllocations: @@ -44661,23 +44651,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -44687,23 +44677,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -44718,7 +44708,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -44740,10 +44730,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID RequestedTopologies: Preferred: @@ -44767,7 +44757,7 @@ components: SnapshotID: SnapshotID WriteAllocs: key: - ModifyTime: 8 + ModifyTime: 9 PreemptedAllocations: - PreemptedAllocations - PreemptedAllocations @@ -44944,35 +44934,27 @@ components: To: 2 Name: Name Metrics: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -50301,23 +50283,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -50327,23 +50309,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -50358,7 +50340,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -50614,10 +50596,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID CreateIndex: 2147483647 Capacity: 0 @@ -50633,7 +50615,7 @@ components: ControllersExpected: 6 ReadAllocs: key: - ModifyTime: 8 + ModifyTime: 9 PreemptedAllocations: - PreemptedAllocations - PreemptedAllocations @@ -50810,35 +50792,27 @@ components: To: 2 Name: Name Metrics: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -56167,23 +56141,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -56193,23 +56167,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -56224,7 +56198,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -56480,10 +56454,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID Parameters: key: Parameters @@ -56510,6 +56484,7 @@ components: SecretID: SecretID Region: Region Namespace: Namespace + nullable: true properties: Namespace: type: string @@ -56535,6 +56510,7 @@ components: PublishedExternalNodeIDs: - PublishedExternalNodeIDs - PublishedExternalNodeIDs + nullable: true properties: CapacityBytes: format: int64 @@ -56584,6 +56560,7 @@ components: - PublishedExternalNodeIDs - PublishedExternalNodeIDs NextToken: NextToken + nullable: true properties: NextToken: type: string @@ -56616,6 +56593,7 @@ components: ID: ID AttachmentMode: AttachmentMode ModifyIndex: 2147483647 + nullable: true properties: AccessMode: type: string @@ -56653,6 +56631,7 @@ components: type: string ResourceExhausted: format: date-time + nullable: true type: string Schedulable: type: boolean @@ -56852,23 +56831,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -56878,23 +56857,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -56909,7 +56888,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -56931,10 +56910,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - ModifyTime: 5 PreemptedAllocations: @@ -57122,23 +57101,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -57148,23 +57127,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -57179,7 +57158,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -57201,10 +57180,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID RequestedTopologies: Preferred: @@ -57228,7 +57207,7 @@ components: SnapshotID: SnapshotID WriteAllocs: key: - ModifyTime: 8 + ModifyTime: 9 PreemptedAllocations: - PreemptedAllocations - PreemptedAllocations @@ -57405,35 +57384,27 @@ components: To: 2 Name: Name Metrics: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -62762,23 +62733,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -62788,23 +62759,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -62819,7 +62790,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -63075,10 +63046,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID CreateIndex: 2147483647 Capacity: 0 @@ -63094,7 +63065,7 @@ components: ControllersExpected: 6 ReadAllocs: key: - ModifyTime: 8 + ModifyTime: 9 PreemptedAllocations: - PreemptedAllocations - PreemptedAllocations @@ -63271,35 +63242,27 @@ components: To: 2 Name: Name Metrics: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -68628,23 +68591,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -68654,23 +68617,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -68685,7 +68648,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -68941,10 +68904,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID Parameters: key: Parameters @@ -69156,23 +69119,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -69182,23 +69145,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -69213,7 +69176,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -69235,10 +69198,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - ModifyTime: 5 PreemptedAllocations: @@ -69426,23 +69389,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -69452,23 +69415,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -69483,7 +69446,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -69505,10 +69468,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID RequestedTopologies: Preferred: @@ -69532,7 +69495,7 @@ components: SnapshotID: SnapshotID WriteAllocs: key: - ModifyTime: 8 + ModifyTime: 9 PreemptedAllocations: - PreemptedAllocations - PreemptedAllocations @@ -69709,35 +69672,27 @@ components: To: 2 Name: Name Metrics: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -75066,23 +75021,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -75092,23 +75047,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -75123,7 +75078,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -75379,10 +75334,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID CreateIndex: 2147483647 Capacity: 0 @@ -75398,7 +75353,7 @@ components: ControllersExpected: 6 ReadAllocs: key: - ModifyTime: 8 + ModifyTime: 9 PreemptedAllocations: - PreemptedAllocations - PreemptedAllocations @@ -75575,35 +75530,27 @@ components: To: 2 Name: Name Metrics: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -80932,23 +80879,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -80958,23 +80905,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -80989,7 +80936,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -81245,10 +81192,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID Parameters: key: Parameters @@ -81275,6 +81222,7 @@ components: SecretID: SecretID Region: Region Namespace: Namespace + nullable: true properties: Namespace: type: string @@ -81292,6 +81240,7 @@ components: Grace: 0 IgnoreWarnings: true Limit: 4 + nullable: true properties: Grace: format: int64 @@ -81306,6 +81255,7 @@ components: LTarget: LTarget RTarget: RTarget Operand: Operand + nullable: true properties: LTarget: type: string @@ -81317,6 +81267,7 @@ components: Consul: example: Namespace: Namespace + nullable: true properties: Namespace: type: string @@ -81546,6 +81497,7 @@ components: MaxFiles: 4 MaxFileSizeMB: 1 Name: Name + nullable: true properties: Gateway: $ref: '#/components/schemas/ConsulGateway' @@ -81567,6 +81519,7 @@ components: ListenerPort: ListenerPort Protocol: Protocol LocalPathPort: 4 + nullable: true properties: Path: items: @@ -81579,6 +81532,7 @@ components: ListenerPort: ListenerPort Protocol: Protocol LocalPathPort: 4 + nullable: true properties: ListenerPort: type: string @@ -81661,6 +81615,7 @@ components: Address: Address Port: 3 Name: Name + nullable: true properties: Address: type: string @@ -81682,6 +81637,7 @@ components: Address: Address Port: 3 Name: Name + nullable: true properties: Config: additionalProperties: {} @@ -81708,6 +81664,7 @@ components: - CipherSuites - CipherSuites TLSMaxVersion: TLSMaxVersion + nullable: true properties: CipherSuites: items: @@ -81752,6 +81709,7 @@ components: - CipherSuites - CipherSuites TLSMaxVersion: TLSMaxVersion + nullable: true properties: Listeners: items: @@ -81773,6 +81731,7 @@ components: Name: Name Port: 7 Protocol: Protocol + nullable: true properties: Port: type: integer @@ -81789,6 +81748,7 @@ components: - Hosts - Hosts Name: Name + nullable: true properties: Hosts: items: @@ -81804,6 +81764,7 @@ components: KeyFile: KeyFile Name: Name SNI: SNI + nullable: true properties: CAFile: type: string @@ -81820,6 +81781,7 @@ components: ConsulMeshGateway: example: Mode: Mode + nullable: true properties: Mode: type: string @@ -81855,6 +81817,7 @@ components: Mode: Mode LocalBindAddress: LocalBindAddress LocalServicePort: 0 + nullable: true properties: Config: additionalProperties: {} @@ -81907,6 +81870,7 @@ components: Tags: - Tags - Tags + nullable: true properties: DisableDefaultTCPCheck: type: boolean @@ -81932,6 +81896,7 @@ components: KeyFile: KeyFile Name: Name SNI: SNI + nullable: true properties: Services: items: @@ -81947,6 +81912,7 @@ components: MeshGateway: Mode: Mode LocalBindAddress: LocalBindAddress + nullable: true properties: Datacenter: type: string @@ -81974,6 +81940,7 @@ components: Servers: - Servers - Servers + nullable: true properties: Options: items: @@ -82016,6 +81983,7 @@ components: JobVersion: 2147483647 JobID: JobID ModifyIndex: 2147483647 + nullable: true properties: CreateIndex: maximum: 1.8446744073709552E+19 @@ -82070,6 +82038,7 @@ components: UnhealthyAllocationIDs: - UnhealthyAllocationIDs - UnhealthyAllocationIDs + nullable: true properties: DeploymentID: type: string @@ -82095,6 +82064,7 @@ components: SecretID: SecretID Region: Region Namespace: Namespace + nullable: true properties: DeploymentID: type: string @@ -82117,6 +82087,7 @@ components: SecretID: SecretID Region: Region Namespace: Namespace + nullable: true properties: All: type: boolean @@ -82147,6 +82118,7 @@ components: - PlacedCanaries UnhealthyAllocs: 7 AutoRevert: true + nullable: true properties: AutoRevert: type: boolean @@ -82169,6 +82141,7 @@ components: type: boolean RequireProgressBy: format: date-time + nullable: true type: string UnhealthyAllocs: type: integer @@ -82179,6 +82152,7 @@ components: SecretID: SecretID Region: Region Namespace: Namespace + nullable: true properties: DeploymentID: type: string @@ -82197,6 +82171,7 @@ components: RequestTime: 5 RevertedJobVersion: 2147483647 EvalID: EvalID + nullable: true properties: DeploymentModifyIndex: maximum: 1.8446744073709552E+19 @@ -82240,6 +82215,7 @@ components: InPlaceUpdate: 2147483647 Place: 2147483647 DestructiveUpdate: 2147483647 + nullable: true properties: Canary: maximum: 1.8446744073709552E+19 @@ -82277,6 +82253,7 @@ components: DispatchPayloadConfig: example: File: File + nullable: true properties: File: type: string @@ -82289,6 +82266,7 @@ components: StartedAt: 2000-01-23T04:56:07.000+00:00 UpdatedAt: 2000-01-23T04:56:07.000+00:00 AccessorID: AccessorID + nullable: true properties: AccessorID: type: string @@ -82298,17 +82276,20 @@ components: type: object StartedAt: format: date-time + nullable: true type: string Status: type: string UpdatedAt: format: date-time + nullable: true type: string type: object DrainSpec: example: IgnoreSystemJobs: true Deadline: 0 + nullable: true properties: Deadline: format: int64 @@ -82324,17 +82305,20 @@ components: IgnoreSystemJobs: true Deadline: 1 StartedAt: 2000-01-23T04:56:07.000+00:00 + nullable: true properties: Deadline: format: int64 type: integer ForceDeadline: format: date-time + nullable: true type: string IgnoreSystemJobs: type: boolean StartedAt: format: date-time + nullable: true type: string type: object DriverInfo: @@ -82345,6 +82329,7 @@ components: key: Attributes UpdateTime: 2000-01-23T04:56:07.000+00:00 Healthy: true + nullable: true properties: Attributes: additionalProperties: @@ -82358,6 +82343,7 @@ components: type: boolean UpdateTime: format: date-time + nullable: true type: string type: object Duration: @@ -82379,6 +82365,7 @@ components: EvalOptions: example: ForceReschedule: true + nullable: true properties: ForceReschedule: type: boolean @@ -82399,10 +82386,10 @@ components: RelatedEvals: - BlockedEval: BlockedEval Status: Status - ModifyTime: 7 + ModifyTime: 4 DeploymentID: DeploymentID - Priority: 1 - CreateTime: 2 + Priority: 7 + CreateTime: 3 Namespace: Namespace Type: Type CreateIndex: 2147483647 @@ -82417,10 +82404,10 @@ components: ModifyIndex: 2147483647 - BlockedEval: BlockedEval Status: Status - ModifyTime: 7 + ModifyTime: 4 DeploymentID: DeploymentID - Priority: 1 - CreateTime: 2 + Priority: 7 + CreateTime: 3 Namespace: Namespace Type: Type CreateIndex: 2147483647 @@ -82433,8 +82420,7 @@ components: WaitUntil: 2000-01-23T04:56:07.000+00:00 JobID: JobID ModifyIndex: 2147483647 - QueuedAllocations: - key: 9 + QueuedAllocations: {} BlockedEval: BlockedEval Status: Status DeploymentID: DeploymentID @@ -82442,35 +82428,27 @@ components: CreateTime: 6 FailedTGAllocs: key: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -82596,6 +82574,7 @@ components: Wait: 1 JobID: JobID ModifyIndex: 2147483647 + nullable: true properties: AnnotatePlan: type: boolean @@ -82651,7 +82630,7 @@ components: type: integer QueuedAllocations: additionalProperties: - type: integer + $ref: '#/components/schemas/int' type: object QuotaLimitReached: type: string @@ -82676,16 +82655,17 @@ components: type: integer WaitUntil: format: date-time + nullable: true type: string type: object EvaluationStub: example: BlockedEval: BlockedEval Status: Status - ModifyTime: 7 + ModifyTime: 4 DeploymentID: DeploymentID - Priority: 1 - CreateTime: 2 + Priority: 7 + CreateTime: 3 Namespace: Namespace Type: Type CreateIndex: 2147483647 @@ -82698,6 +82678,7 @@ components: WaitUntil: 2000-01-23T04:56:07.000+00:00 JobID: JobID ModifyIndex: 2147483647 + nullable: true properties: BlockedEval: type: string @@ -82741,6 +82722,7 @@ components: type: string WaitUntil: format: date-time + nullable: true type: string type: object FieldDiff: @@ -82752,6 +82734,7 @@ components: - Annotations Old: Old Name: Name + nullable: true properties: Annotations: items: @@ -82772,6 +82755,7 @@ components: - Scope - Scope ID: ID + nullable: true properties: ID: type: string @@ -82799,6 +82783,7 @@ components: Region: Region WaitTime: 1 AllowStale: true + nullable: true properties: AllowStale: type: boolean @@ -82858,6 +82843,7 @@ components: LastIndex: 2147483647 RequestTime: 1 KnownLeader: true + nullable: true properties: KnownLeader: type: boolean @@ -82890,6 +82876,7 @@ components: Labels: key: Labels Name: Name + nullable: true properties: Labels: additionalProperties: @@ -82907,6 +82894,7 @@ components: CIDR: CIDR Interface: Interface Name: Name + nullable: true properties: CIDR: type: string @@ -82921,6 +82909,7 @@ components: example: Path: Path ReadOnly: true + nullable: true properties: Path: type: string @@ -88132,6 +88121,7 @@ components: Payload: Payload ModifyIndex: 2147483647 NomadTokenID: NomadTokenID + nullable: true properties: Affinities: items: @@ -88235,6 +88225,7 @@ components: Dead: 0 Running: 1 Pending: 6 + nullable: true properties: Dead: format: int64 @@ -88256,6 +88247,7 @@ components: EvalID: EvalID KnownLeader: true JobModifyIndex: 2147483647 + nullable: true properties: EvalCreateIndex: maximum: 1.8446744073709552E+19 @@ -88424,8 +88416,7 @@ components: - null Name: Name Name: Name - Updates: - key: 2147483647 + Updates: {} Objects: - Type: Type Fields: @@ -88607,8 +88598,7 @@ components: - null Name: Name Name: Name - Updates: - key: 2147483647 + Updates: {} Objects: - Type: Type Fields: @@ -88709,6 +88699,7 @@ components: - null Name: Name ID: ID + nullable: true properties: Fields: items: @@ -88733,6 +88724,7 @@ components: key: Meta Payload: Payload JobID: JobID + nullable: true properties: JobID: type: string @@ -88752,6 +88744,7 @@ components: RequestTime: 5 JobCreateIndex: 2147483647 EvalID: EvalID + nullable: true properties: DispatchedJobID: type: string @@ -88781,6 +88774,7 @@ components: Region: Region JobID: JobID Namespace: Namespace + nullable: true properties: EvalOptions: $ref: '#/components/schemas/EvalOptions' @@ -88831,6 +88825,7 @@ components: - Datacenters ID: ID ModifyIndex: 2147483647 + nullable: true properties: CreateIndex: maximum: 1.8446744073709552E+19 @@ -94087,6 +94082,7 @@ components: ModifyIndex: 2147483647 NomadTokenID: NomadTokenID Namespace: Namespace + nullable: true properties: Diff: type: boolean @@ -94301,23 +94297,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -94327,23 +94323,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -94358,7 +94354,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -94380,10 +94376,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - ModifyTime: 5 PreemptedAllocations: @@ -94571,23 +94567,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -94597,23 +94593,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -94628,7 +94624,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -94650,10 +94646,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID NextPeriodicLaunch: 2000-01-23T04:56:07.000+00:00 Diff: @@ -94797,8 +94793,7 @@ components: - null Name: Name Name: Name - Updates: - key: 2147483647 + Updates: {} Objects: - Type: Type Fields: @@ -94980,8 +94975,7 @@ components: - null Name: Name Name: Name - Updates: - key: 2147483647 + Updates: {} Objects: - Type: Type Fields: @@ -95084,35 +95078,27 @@ components: ID: ID FailedTGAllocs: key: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -95242,10 +95228,10 @@ components: RelatedEvals: - BlockedEval: BlockedEval Status: Status - ModifyTime: 7 + ModifyTime: 4 DeploymentID: DeploymentID - Priority: 1 - CreateTime: 2 + Priority: 7 + CreateTime: 3 Namespace: Namespace Type: Type CreateIndex: 2147483647 @@ -95260,10 +95246,10 @@ components: ModifyIndex: 2147483647 - BlockedEval: BlockedEval Status: Status - ModifyTime: 7 + ModifyTime: 4 DeploymentID: DeploymentID - Priority: 1 - CreateTime: 2 + Priority: 7 + CreateTime: 3 Namespace: Namespace Type: Type CreateIndex: 2147483647 @@ -95276,8 +95262,7 @@ components: WaitUntil: 2000-01-23T04:56:07.000+00:00 JobID: JobID ModifyIndex: 2147483647 - QueuedAllocations: - key: 9 + QueuedAllocations: {} BlockedEval: BlockedEval Status: Status DeploymentID: DeploymentID @@ -95285,35 +95270,27 @@ components: CreateTime: 6 FailedTGAllocs: key: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -95453,10 +95430,10 @@ components: RelatedEvals: - BlockedEval: BlockedEval Status: Status - ModifyTime: 7 + ModifyTime: 4 DeploymentID: DeploymentID - Priority: 1 - CreateTime: 2 + Priority: 7 + CreateTime: 3 Namespace: Namespace Type: Type CreateIndex: 2147483647 @@ -95471,10 +95448,10 @@ components: ModifyIndex: 2147483647 - BlockedEval: BlockedEval Status: Status - ModifyTime: 7 + ModifyTime: 4 DeploymentID: DeploymentID - Priority: 1 - CreateTime: 2 + Priority: 7 + CreateTime: 3 Namespace: Namespace Type: Type CreateIndex: 2147483647 @@ -95487,8 +95464,7 @@ components: WaitUntil: 2000-01-23T04:56:07.000+00:00 JobID: JobID ModifyIndex: 2147483647 - QueuedAllocations: - key: 9 + QueuedAllocations: {} BlockedEval: BlockedEval Status: Status DeploymentID: DeploymentID @@ -95496,35 +95472,27 @@ components: CreateTime: 6 FailedTGAllocs: key: - ClassExhausted: - key: 5 - ConstraintFiltered: - key: 7 + ClassExhausted: {} + ConstraintFiltered: {} ScoreMetaData: - - NormScore: 0.4768402382624515 + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - - NormScore: 0.4768402382624515 + Scores: {} + - NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 - Scores: - key: 2.380090174313445 - DimensionExhausted: - key: 3 - NodesAvailable: - key: 3 - NodesExhausted: 5 + Scores: {} + Scores: {} + DimensionExhausted: {} + NodesAvailable: {} + NodesExhausted: 8 QuotaExhausted: - QuotaExhausted - QuotaExhausted AllocationTime: 0 - ClassFiltered: - key: 5 + ClassFiltered: {} NodesFiltered: 7 - CoalescedFailures: 8 - NodesEvaluated: 9 + CoalescedFailures: 5 + NodesEvaluated: 5 ResourcesExhausted: key: Cores: 9 @@ -95652,6 +95620,7 @@ components: ModifyIndex: 2147483647 Warnings: Warnings JobModifyIndex: 2147483647 + nullable: true properties: Annotations: $ref: '#/components/schemas/PlanAnnotations' @@ -95671,6 +95640,7 @@ components: type: integer NextPeriodicLaunch: format: date-time + nullable: true type: string Warnings: type: string @@ -100889,6 +100859,7 @@ components: NomadTokenID: NomadTokenID Namespace: Namespace JobModifyIndex: 2147483647 + nullable: true properties: EnforceIndex: type: boolean @@ -100922,6 +100893,7 @@ components: KnownLeader: true Warnings: Warnings JobModifyIndex: 2147483647 + nullable: true properties: EvalCreateIndex: maximum: 1.8446744073709552E+19 @@ -100960,6 +100932,7 @@ components: JobID: JobID Namespace: Namespace EnforcePriorVersion: 2147483647 + nullable: true properties: ConsulToken: type: string @@ -101015,6 +100988,7 @@ components: JobID: JobID Namespace: Namespace JobModifyIndex: 2147483647 + nullable: true properties: JobCreateIndex: maximum: 1.8446744073709552E+19 @@ -101043,6 +101017,7 @@ components: JobVersion: 2147483647 JobID: JobID Namespace: Namespace + nullable: true properties: JobID: type: string @@ -101062,6 +101037,7 @@ components: JobStabilityResponse: example: Index: 2147483647 + nullable: true properties: Index: maximum: 1.8446744073709552E+19 @@ -101087,6 +101063,7 @@ components: JobID: JobID ModifyIndex: 2147483647 Namespace: Namespace + nullable: true properties: Children: $ref: '#/components/schemas/JobChildrenSummary' @@ -106316,6 +106293,7 @@ components: ModifyIndex: 2147483647 NomadTokenID: NomadTokenID Namespace: Namespace + nullable: true properties: Job: $ref: '#/components/schemas/Job' @@ -106334,6 +106312,7 @@ components: Error: Error DriverConfigValidated: true Warnings: Warnings + nullable: true properties: DriverConfigValidated: type: boolean @@ -106489,8 +106468,7 @@ components: - null Name: Name Name: Name - Updates: - key: 2147483647 + Updates: {} Objects: - Type: Type Fields: @@ -106672,8 +106650,7 @@ components: - null Name: Name Name: Name - Updates: - key: 2147483647 + Updates: {} Objects: - Type: Type Fields: @@ -106914,8 +106891,7 @@ components: - null Name: Name Name: Name - Updates: - key: 2147483647 + Updates: {} Objects: - Type: Type Fields: @@ -107097,8 +107073,7 @@ components: - null Name: Name Name: Name - Updates: - key: 2147483647 + Updates: {} Objects: - Type: Type Fields: @@ -117611,6 +117586,7 @@ components: LastIndex: 2147483647 RequestTime: 1 KnownLeader: true + nullable: true properties: Diffs: items: @@ -117640,6 +117616,7 @@ components: JobHCL: JobHCL hclv1: true Canonicalize: true + nullable: true properties: Canonicalize: type: boolean @@ -117721,6 +117698,7 @@ components: Labels: key: Labels Name: Name + nullable: true properties: Counters: items: @@ -117779,6 +117757,7 @@ components: - Datacenters Count: 9 Name: Name + nullable: true properties: Regions: items: @@ -117796,6 +117775,7 @@ components: - Datacenters Count: 9 Name: Name + nullable: true properties: Count: type: integer @@ -117836,6 +117816,7 @@ components: - EnabledTaskDrivers ModifyIndex: 2147483647 Name: Name + nullable: true properties: Capabilities: $ref: '#/components/schemas/NamespaceCapabilities' @@ -117866,6 +117847,7 @@ components: EnabledTaskDrivers: - EnabledTaskDrivers - EnabledTaskDrivers + nullable: true properties: DisabledTaskDrivers: items: @@ -117912,6 +117894,7 @@ components: To: 1 HostNetwork: HostNetwork MBits: 5 + nullable: true properties: CIDR: type: string @@ -118425,6 +118408,7 @@ components: Count: 2147483647 Name: Name MemoryMaxMB: 5 + nullable: true properties: Attributes: additionalProperties: @@ -118515,6 +118499,7 @@ components: - 46276 - 46276 TotalCpuCores: 60957 + nullable: true properties: CpuShares: format: int64 @@ -118537,6 +118522,7 @@ components: PciBusID: PciBusID ID: ID Healthy: true + nullable: true properties: HealthDescription: type: string @@ -118550,6 +118536,7 @@ components: NodeDeviceLocality: example: PciBusID: PciBusID + nullable: true properties: PciBusID: type: string @@ -118577,6 +118564,7 @@ components: Int: 2 Vendor: Vendor Name: Name + nullable: true properties: Attributes: additionalProperties: @@ -118596,6 +118584,7 @@ components: NodeDiskResources: example: DiskMB: 4 + nullable: true properties: DiskMB: format: int64 @@ -118610,6 +118599,7 @@ components: EvalIDs: - EvalIDs - EvalIDs + nullable: true properties: EvalCreateIndex: maximum: 1.8446744073709552E+19 @@ -118640,6 +118630,7 @@ components: EvalIDs: - EvalIDs - EvalIDs + nullable: true properties: EvalCreateIndex: maximum: 1.8446744073709552E+19 @@ -118669,6 +118660,7 @@ components: Message: Message Subsystem: Subsystem Timestamp: 2000-01-23T04:56:07.000+00:00 + nullable: true properties: CreateIndex: maximum: 1.8446744073709552E+19 @@ -118684,6 +118676,7 @@ components: type: string Timestamp: format: date-time + nullable: true type: string type: object NodeListStub: @@ -118851,6 +118844,7 @@ components: Datacenter: Datacenter ID: ID ModifyIndex: 2147483647 + nullable: true properties: Address: type: string @@ -118898,6 +118892,7 @@ components: NodeMemoryResources: example: MemoryMB: 1 + nullable: true properties: MemoryMB: format: int64 @@ -118910,6 +118905,7 @@ components: EvalIDs: - EvalIDs - EvalIDs + nullable: true properties: EvalCreateIndex: maximum: 1.8446744073709552E+19 @@ -118927,6 +118923,7 @@ components: NodeReservedCpuResources: example: CpuShares: 2147483647 + nullable: true properties: CpuShares: maximum: 1.8446744073709552E+19 @@ -118936,6 +118933,7 @@ components: NodeReservedDiskResources: example: DiskMB: 2147483647 + nullable: true properties: DiskMB: maximum: 1.8446744073709552E+19 @@ -118945,6 +118943,7 @@ components: NodeReservedMemoryResources: example: MemoryMB: 2147483647 + nullable: true properties: MemoryMB: maximum: 1.8446744073709552E+19 @@ -118954,6 +118953,7 @@ components: NodeReservedNetworkResources: example: ReservedHostPorts: ReservedHostPorts + nullable: true properties: ReservedHostPorts: type: string @@ -118968,6 +118968,7 @@ components: CpuShares: 2147483647 Disk: DiskMB: 2147483647 + nullable: true properties: Cpu: $ref: '#/components/schemas/NodeReservedCpuResources' @@ -119104,6 +119105,7 @@ components: Name: Name Disk: DiskMB: 4 + nullable: true properties: Cpu: $ref: '#/components/schemas/NodeCpuResources' @@ -119126,10 +119128,10 @@ components: type: object NodeScoreMeta: example: - NormScore: 0.4768402382624515 + NormScore: 3.7814124730767915 NodeID: NodeID - Scores: - key: 3.1497903714250555 + Scores: {} + nullable: true properties: NodeID: type: string @@ -119138,8 +119140,7 @@ components: type: number Scores: additionalProperties: - format: double - type: number + $ref: '#/components/schemas/float64' type: object type: object NodeUpdateDrainRequest: @@ -119151,6 +119152,7 @@ components: key: Meta MarkEligible: true NodeID: NodeID + nullable: true properties: DrainSpec: $ref: '#/components/schemas/DrainSpec' @@ -119167,6 +119169,7 @@ components: example: Eligibility: Eligibility NodeID: NodeID + nullable: true properties: Eligibility: type: string @@ -119195,6 +119198,7 @@ components: - null - null Name: Name + nullable: true properties: Fields: items: @@ -119216,6 +119220,7 @@ components: ExpiresAt: 2000-01-23T04:56:07.000+00:00 AccessorID: AccessorID ModifyIndex: 2147483647 + nullable: true properties: AccessorID: type: string @@ -119225,6 +119230,7 @@ components: type: integer ExpiresAt: format: date-time + nullable: true type: string ModifyIndex: maximum: 1.8446744073709552E+19 @@ -119236,6 +119242,7 @@ components: OneTimeTokenExchangeRequest: example: OneTimeSecretID: OneTimeSecretID + nullable: true properties: OneTimeSecretID: type: string @@ -119269,6 +119276,7 @@ components: LastTerm: 2147483647 Name: Name Healthy: true + nullable: true properties: FailureTolerance: type: integer @@ -119288,6 +119296,7 @@ components: MetaRequired: - MetaRequired - MetaRequired + nullable: true properties: MetaOptional: items: @@ -119324,6 +119333,7 @@ components: EvalCreateIndex: 2147483647 Index: 2147483647 EvalID: EvalID + nullable: true properties: EvalCreateIndex: maximum: 1.8446744073709552E+19 @@ -119535,23 +119545,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -119561,23 +119571,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -119592,7 +119602,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -119614,10 +119624,10 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - ModifyTime: 5 PreemptedAllocations: @@ -119805,23 +119815,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -119831,23 +119841,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -119862,7 +119872,7 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState DesiredDescription: DesiredDescription ClientStatus: ClientStatus @@ -119884,11 +119894,12 @@ components: RescheduleTracker: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID + nullable: true properties: DesiredTGUpdates: additionalProperties: @@ -119905,6 +119916,7 @@ components: - 3.6160767 - 3.6160767 Name: Name + nullable: true properties: Name: type: string @@ -119920,6 +119932,7 @@ components: Value: 5 To: 1 HostNetwork: HostNetwork + nullable: true properties: HostNetwork: type: string @@ -119936,6 +119949,7 @@ components: Label: Label Value: 7 To: 2 + nullable: true properties: HostIP: type: string @@ -119952,6 +119966,7 @@ components: BatchSchedulerEnabled: true ServiceSchedulerEnabled: true SysBatchSchedulerEnabled: true + nullable: true properties: BatchSchedulerEnabled: type: boolean @@ -120079,6 +120094,7 @@ components: Count: 2147483647 Name: Name MemoryMaxMB: 5 + nullable: true properties: Hash: format: byte @@ -120325,6 +120341,7 @@ components: MemoryMaxMB: 5 ModifyIndex: 2147483647 Name: Name + nullable: true properties: CreateIndex: maximum: 1.8446744073709552E+19 @@ -120360,6 +120377,7 @@ components: Voter: true ID: ID RaftProtocol: RaftProtocol + nullable: true properties: Index: maximum: 1.8446744073709552E+19 @@ -120378,6 +120396,7 @@ components: Voter: true ID: ID RaftProtocol: RaftProtocol + nullable: true properties: Address: type: string @@ -120412,6 +120431,7 @@ components: Weight: -101 Count: 2147483647 Name: Name + nullable: true properties: Affinities: items: @@ -120431,8 +120451,9 @@ components: RescheduleEvent: example: PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID + nullable: true properties: PrevAllocID: type: string @@ -120471,11 +120492,12 @@ components: example: Events: - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID - PrevAllocID: PrevAllocID - RescheduleTime: 4 + RescheduleTime: 5 PrevNodeID: PrevNodeID + nullable: true properties: Events: items: @@ -120596,6 +120618,7 @@ components: Count: 2147483647 Name: Name MemoryMaxMB: 5 + nullable: true properties: CPU: type: integer @@ -120648,6 +120671,7 @@ components: Sum: 7.061401241503109 Count: 0 Name: Name + nullable: true properties: Count: type: integer @@ -120687,6 +120711,7 @@ components: Time: 2147483647 Count: 5 EvalID: EvalID + nullable: true properties: Count: format: int64 @@ -120726,6 +120751,7 @@ components: ID: ID ModifyIndex: 2147483647 Namespace: Namespace + nullable: true properties: CreateIndex: maximum: 1.8446744073709552E+19 @@ -120766,6 +120792,7 @@ components: Enabled: true ID: ID ModifyIndex: 2147483647 + nullable: true properties: CreateIndex: maximum: 1.8446744073709552E+19 @@ -120799,6 +120826,7 @@ components: Region: Region Count: 0 Namespace: Namespace + nullable: true properties: Count: format: int64 @@ -120838,6 +120866,7 @@ components: RejectJobRegistration: true SchedulerAlgorithm: SchedulerAlgorithm ModifyIndex: 2147483647 + nullable: true properties: CreateIndex: maximum: 1.8446744073709552E+19 @@ -120877,6 +120906,7 @@ components: RejectJobRegistration: true SchedulerAlgorithm: SchedulerAlgorithm ModifyIndex: 2147483647 + nullable: true properties: KnownLeader: type: boolean @@ -120900,6 +120930,7 @@ components: Updated: true LastIndex: 2147483647 RequestTime: 6 + nullable: true properties: LastIndex: maximum: 1.8446744073709552E+19 @@ -120929,6 +120960,7 @@ components: Region: Region WaitTime: 1 AllowStale: true + nullable: true properties: AllowStale: type: boolean @@ -120980,6 +121012,7 @@ components: LastIndex: 2147483647 RequestTime: 1 KnownLeader: true + nullable: true properties: KnownLeader: type: boolean @@ -121020,6 +121053,7 @@ components: Healthy: true LastTerm: 2147483647 Name: Name + nullable: true properties: Address: type: string @@ -121046,6 +121080,7 @@ components: type: string StableSince: format: date-time + nullable: true type: string Version: type: string @@ -121367,6 +121402,7 @@ components: Grace: 0 IgnoreWarnings: true Limit: 4 + nullable: true properties: Address: type: string @@ -121447,6 +121483,7 @@ components: IgnoreWarnings: true Limit: 4 Interval: 7 + nullable: true properties: AddressMode: type: string @@ -121521,6 +121558,7 @@ components: Tags: - Tags - Tags + nullable: true properties: Address: type: string @@ -121683,6 +121721,7 @@ components: MaxFiles: 4 MaxFileSizeMB: 1 Name: Name + nullable: true properties: Config: additionalProperties: {} @@ -121723,6 +121762,7 @@ components: - Percent: 177 Value: Value Weight: -95 + nullable: true properties: Attribute: type: string @@ -121739,6 +121779,7 @@ components: example: Percent: 177 Value: Value + nullable: true properties: Percent: maximum: 255 @@ -122623,6 +122664,7 @@ components: LogConfig: MaxFiles: 4 MaxFileSizeMB: 1 + nullable: true properties: Affinities: items: @@ -122705,6 +122747,7 @@ components: GetterOptions: key: GetterOptions GetterSource: GetterSource + nullable: true properties: GetterHeaders: additionalProperties: @@ -122727,6 +122770,7 @@ components: Type: Type ID: ID MountDir: MountDir + nullable: true properties: HealthTimeout: format: int64 @@ -122801,6 +122845,7 @@ components: - null Name: Name Name: Name + nullable: true properties: Annotations: items: @@ -122823,23 +122868,23 @@ components: example: KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -122847,6 +122892,7 @@ components: key: Details DisplayMessage: DisplayMessage KillError: KillError + nullable: true properties: Details: additionalProperties: @@ -125451,6 +125497,7 @@ components: SizeMB: 6 Migrate: true Sticky: true + nullable: true properties: Affinities: items: @@ -125653,8 +125700,7 @@ components: - null Name: Name Name: Name - Updates: - key: 2147483647 + Updates: {} Objects: - Type: Type Fields: @@ -125697,6 +125743,7 @@ components: - null Name: Name Name: Name + nullable: true properties: Fields: items: @@ -125716,9 +125763,7 @@ components: type: string Updates: additionalProperties: - maximum: 1.8446744073709552E+19 - minimum: 0 - type: integer + $ref: '#/components/schemas/uint64' type: object type: object TaskGroupScaleStatus: @@ -125747,6 +125792,7 @@ components: Desired: 1 Healthy: 9 Placed: 3 + nullable: true properties: Desired: type: integer @@ -125772,6 +125818,7 @@ components: Starting: 4 Running: 2 Queued: 3 + nullable: true properties: Complete: type: integer @@ -125790,8 +125837,9 @@ components: type: object TaskHandle: example: - Version: 6 + Version: 0 DriverState: DriverState + nullable: true properties: DriverState: format: byte @@ -125803,6 +125851,7 @@ components: example: Hook: Hook Sidecar: true + nullable: true properties: Hook: type: string @@ -125814,23 +125863,23 @@ components: Events: - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -125840,23 +125889,23 @@ components: KillError: KillError - KillReason: KillReason Message: Message - ExitCode: 7 - Time: 0 + ExitCode: 3 + Time: 4 GenericSource: GenericSource TaskSignalReason: TaskSignalReason VaultError: VaultError DriverError: DriverError RestartReason: RestartReason - DiskLimit: 0 - Signal: 2 + DiskLimit: 7 + Signal: 3 DownloadError: DownloadError DiskSize: 0 SetupError: SetupError ValidationError: ValidationError FailsTask: true DriverMessage: DriverMessage - KillTimeout: 4 - StartDelay: 9 + KillTimeout: 2 + StartDelay: 8 FailedSibling: FailedSibling TaskSignal: TaskSignal Type: Type @@ -125871,8 +125920,9 @@ components: LastRestart: 2000-01-23T04:56:07.000+00:00 StartedAt: 2000-01-23T04:56:07.000+00:00 TaskHandle: - Version: 6 + Version: 0 DriverState: DriverState + nullable: true properties: Events: items: @@ -125882,9 +125932,11 @@ components: type: boolean FinishedAt: format: date-time + nullable: true type: string LastRestart: format: date-time + nullable: true type: string Restarts: maximum: 1.8446744073709552E+19 @@ -125892,6 +125944,7 @@ components: type: integer StartedAt: format: date-time + nullable: true type: string State: type: string @@ -125944,6 +125997,7 @@ components: type: object Time: format: date-time + nullable: true type: string UpdateStrategy: example: @@ -125989,6 +126043,7 @@ components: Env: true Namespace: Namespace ChangeMode: ChangeMode + nullable: true properties: ChangeMode: type: string @@ -126033,6 +126088,7 @@ components: FSType: FSType Source: Source Name: Name + nullable: true properties: AccessMode: type: string diff --git a/clients/java/v1/build.gradle b/clients/java/v1/build.gradle index ef0a26fb..aec77842 100644 --- a/clients/java/v1/build.gradle +++ b/clients/java/v1/build.gradle @@ -1,23 +1,24 @@ apply plugin: 'idea' apply plugin: 'eclipse' apply plugin: 'java' +apply plugin: 'com.diffplug.spotless' group = 'io.nomadproject' version = '1.1.4' buildscript { repositories { - maven { url "https://repo1.maven.org/maven2" } - jcenter() + mavenCentral() } dependencies { classpath 'com.android.tools.build:gradle:2.3.+' classpath 'com.github.dcendents:android-maven-gradle-plugin:1.5' + classpath 'com.diffplug.spotless:spotless-plugin-gradle:5.17.1' } } repositories { - jcenter() + mavenCentral() } sourceSets { main.java.srcDirs = ['src/main/java'] @@ -52,7 +53,7 @@ if(hasProperty('target') && target == 'android') { } dependencies { - provided 'javax.annotation:javax.annotation-api:1.3.2' + provided "jakarta.annotation:jakarta.annotation-api:$jakarta_annotation_version" } } @@ -80,14 +81,17 @@ if(hasProperty('target') && target == 'android') { } else { apply plugin: 'java' - apply plugin: 'maven' + apply plugin: 'maven-publish' sourceCompatibility = JavaVersion.VERSION_1_8 targetCompatibility = JavaVersion.VERSION_1_8 - install { - repositories.mavenInstaller { - pom.artifactId = 'nomad-openapi-java-client' + publishing { + publications { + maven(MavenPublication) { + artifactId = 'nomad-openapi-java-client' + from components.java + } } } @@ -97,6 +101,10 @@ if(hasProperty('target') && target == 'android') { } } +ext { + jakarta_annotation_version = "1.3.5" +} + dependencies { implementation 'io.swagger:swagger-annotations:1.5.24' implementation "com.google.code.findbugs:jsr305:3.0.2" @@ -104,12 +112,41 @@ dependencies { implementation 'com.squareup.okhttp3:logging-interceptor:4.9.1' implementation 'com.google.code.gson:gson:2.8.6' implementation 'io.gsonfire:gson-fire:1.8.4' + implementation 'org.openapitools:jackson-databind-nullable:0.2.1' implementation group: 'org.apache.commons', name: 'commons-lang3', version: '3.10' implementation 'org.threeten:threetenbp:1.4.3' - implementation 'javax.annotation:javax.annotation-api:1.3.2' + implementation "jakarta.annotation:jakarta.annotation-api:$jakarta_annotation_version" testImplementation 'junit:junit:4.13.1' + testImplementation 'org.mockito:mockito-core:3.11.2' } javadoc { options.tags = [ "http.response.details:a:Http Response Details" ] } + +// Use spotless plugin to automatically format code, remove unused import, etc +// To apply changes directly to the file, run `gradlew spotlessApply` +// Ref: https://github.com/diffplug/spotless/tree/main/plugin-gradle +spotless { + // comment out below to run spotless as part of the `check` task + enforceCheck false + + format 'misc', { + // define the files (e.g. '*.gradle', '*.md') to apply `misc` to + target '.gitignore' + + // define the steps to apply to those files + trimTrailingWhitespace() + indentWithSpaces() // Takes an integer argument if you don't like 4 + endWithNewline() + } + java { + // don't need to set target, it is inferred from java + + // apply a specific flavor of google-java-format + googleJavaFormat('1.8').aosp().reflowLongStrings() + + removeUnusedImports() + importOrder() + } +} diff --git a/clients/java/v1/build.sbt b/clients/java/v1/build.sbt index 56c79186..fc25696f 100644 --- a/clients/java/v1/build.sbt +++ b/clients/java/v1/build.sbt @@ -14,11 +14,12 @@ lazy val root = (project in file(".")). "com.squareup.okhttp3" % "logging-interceptor" % "4.9.1", "com.google.code.gson" % "gson" % "2.8.6", "org.apache.commons" % "commons-lang3" % "3.10", + "org.openapitools" % "jackson-databind-nullable" % "0.2.2", "org.threeten" % "threetenbp" % "1.4.3" % "compile", "io.gsonfire" % "gson-fire" % "1.8.3" % "compile", - "javax.annotation" % "javax.annotation-api" % "1.3.2" % "compile", + "jakarta.annotation" % "jakarta.annotation-api" % "1.3.5" % "compile", "com.google.code.findbugs" % "jsr305" % "3.0.2" % "compile", - "javax.annotation" % "javax.annotation-api" % "1.3.2" % "compile", + "jakarta.annotation" % "jakarta.annotation-api" % "1.3.5" % "compile", "junit" % "junit" % "4.13.1" % "test", "com.novocode" % "junit-interface" % "0.10" % "test" ) diff --git a/clients/java/v1/docs/DispatchPayloadConfig.md b/clients/java/v1/docs/DispatchPayloadConfig.md index 1c5f0c37..5b37e34e 100644 --- a/clients/java/v1/docs/DispatchPayloadConfig.md +++ b/clients/java/v1/docs/DispatchPayloadConfig.md @@ -7,7 +7,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**file** | **String** | | [optional] +**_file** | **String** | | [optional] diff --git a/clients/java/v1/gradle.properties b/clients/java/v1/gradle.properties index 05644f07..a3408578 100644 --- a/clients/java/v1/gradle.properties +++ b/clients/java/v1/gradle.properties @@ -1,2 +1,6 @@ -# Uncomment to build for Android -#target = android \ No newline at end of file +# This file is automatically generated by OpenAPI Generator (https://github.com/openAPITools/openapi-generator). +# To include other gradle properties as part of the code generation process, please use the `gradleProperties` option. +# +# Gradle properties reference: https://docs.gradle.org/current/userguide/build_environment.html#sec:gradle_configuration_properties +# For example, uncomment below to build for Android +#target = android diff --git a/clients/java/v1/gradle/wrapper/gradle-wrapper.jar b/clients/java/v1/gradle/wrapper/gradle-wrapper.jar index e708b1c0..7454180f 100644 Binary files a/clients/java/v1/gradle/wrapper/gradle-wrapper.jar and b/clients/java/v1/gradle/wrapper/gradle-wrapper.jar differ diff --git a/clients/java/v1/gradle/wrapper/gradle-wrapper.properties b/clients/java/v1/gradle/wrapper/gradle-wrapper.properties index 4d9ca164..ffed3a25 100644 --- a/clients/java/v1/gradle/wrapper/gradle-wrapper.properties +++ b/clients/java/v1/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,5 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-6.7.1-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-7.2-bin.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists diff --git a/clients/java/v1/gradlew b/clients/java/v1/gradlew index 4f906e0c..005bcde0 100644 --- a/clients/java/v1/gradlew +++ b/clients/java/v1/gradlew @@ -1,7 +1,7 @@ -#!/usr/bin/env sh +#!/bin/sh # -# Copyright 2015 the original author or authors. +# Copyright © 2015-2021 the original authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -17,67 +17,101 @@ # ############################################################################## -## -## Gradle start up script for UN*X -## +# +# Gradle start up script for POSIX generated by Gradle. +# +# Important for running: +# +# (1) You need a POSIX-compliant shell to run this script. If your /bin/sh is +# noncompliant, but you have some other compliant shell such as ksh or +# bash, then to run this script, type that shell name before the whole +# command line, like: +# +# ksh Gradle +# +# Busybox and similar reduced shells will NOT work, because this script +# requires all of these POSIX shell features: +# * functions; +# * expansions «$var», «${var}», «${var:-default}», «${var+SET}», +# «${var#prefix}», «${var%suffix}», and «$( cmd )»; +# * compound commands having a testable exit status, especially «case»; +# * various built-in commands including «command», «set», and «ulimit». +# +# Important for patching: +# +# (2) This script targets any POSIX shell, so it avoids extensions provided +# by Bash, Ksh, etc; in particular arrays are avoided. +# +# The "traditional" practice of packing multiple parameters into a +# space-separated string is a well documented source of bugs and security +# problems, so this is (mostly) avoided, by progressively accumulating +# options in "$@", and eventually passing that to Java. +# +# Where the inherited environment variables (DEFAULT_JVM_OPTS, JAVA_OPTS, +# and GRADLE_OPTS) rely on word-splitting, this is performed explicitly; +# see the in-line comments for details. +# +# There are tweaks for specific operating systems such as AIX, CygWin, +# Darwin, MinGW, and NonStop. +# +# (3) This script is generated from the Groovy template +# https://github.com/gradle/gradle/blob/master/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt +# within the Gradle project. +# +# You can find Gradle at https://github.com/gradle/gradle/. +# ############################################################################## # Attempt to set APP_HOME + # Resolve links: $0 may be a link -PRG="$0" -# Need this for relative symlinks. -while [ -h "$PRG" ] ; do - ls=`ls -ld "$PRG"` - link=`expr "$ls" : '.*-> \(.*\)$'` - if expr "$link" : '/.*' > /dev/null; then - PRG="$link" - else - PRG=`dirname "$PRG"`"/$link" - fi +app_path=$0 + +# Need this for daisy-chained symlinks. +while + APP_HOME=${app_path%"${app_path##*/}"} # leaves a trailing /; empty if no leading path + [ -h "$app_path" ] +do + ls=$( ls -ld "$app_path" ) + link=${ls#*' -> '} + case $link in #( + /*) app_path=$link ;; #( + *) app_path=$APP_HOME$link ;; + esac done -SAVED="`pwd`" -cd "`dirname \"$PRG\"`/" >/dev/null -APP_HOME="`pwd -P`" -cd "$SAVED" >/dev/null + +APP_HOME=$( cd "${APP_HOME:-./}" && pwd -P ) || exit APP_NAME="Gradle" -APP_BASE_NAME=`basename "$0"` +APP_BASE_NAME=${0##*/} # Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. -DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"' +DEFAULT_JVM_OPTS='-Dfile.encoding=UTF-8 "-Xmx64m" "-Xms64m"' # Use the maximum available, or set MAX_FD != -1 to use that value. -MAX_FD="maximum" +MAX_FD=maximum warn () { echo "$*" -} +} >&2 die () { echo echo "$*" echo exit 1 -} +} >&2 # OS specific support (must be 'true' or 'false'). cygwin=false msys=false darwin=false nonstop=false -case "`uname`" in - CYGWIN* ) - cygwin=true - ;; - Darwin* ) - darwin=true - ;; - MINGW* ) - msys=true - ;; - NONSTOP* ) - nonstop=true - ;; +case "$( uname )" in #( + CYGWIN* ) cygwin=true ;; #( + Darwin* ) darwin=true ;; #( + MSYS* | MINGW* ) msys=true ;; #( + NONSTOP* ) nonstop=true ;; esac CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar @@ -87,9 +121,9 @@ CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar if [ -n "$JAVA_HOME" ] ; then if [ -x "$JAVA_HOME/jre/sh/java" ] ; then # IBM's JDK on AIX uses strange locations for the executables - JAVACMD="$JAVA_HOME/jre/sh/java" + JAVACMD=$JAVA_HOME/jre/sh/java else - JAVACMD="$JAVA_HOME/bin/java" + JAVACMD=$JAVA_HOME/bin/java fi if [ ! -x "$JAVACMD" ] ; then die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME @@ -98,7 +132,7 @@ Please set the JAVA_HOME variable in your environment to match the location of your Java installation." fi else - JAVACMD="java" + JAVACMD=java which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. Please set the JAVA_HOME variable in your environment to match the @@ -106,80 +140,95 @@ location of your Java installation." fi # Increase the maximum file descriptors if we can. -if [ "$cygwin" = "false" -a "$darwin" = "false" -a "$nonstop" = "false" ] ; then - MAX_FD_LIMIT=`ulimit -H -n` - if [ $? -eq 0 ] ; then - if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then - MAX_FD="$MAX_FD_LIMIT" - fi - ulimit -n $MAX_FD - if [ $? -ne 0 ] ; then - warn "Could not set maximum file descriptor limit: $MAX_FD" - fi - else - warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT" - fi +if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then + case $MAX_FD in #( + max*) + MAX_FD=$( ulimit -H -n ) || + warn "Could not query maximum file descriptor limit" + esac + case $MAX_FD in #( + '' | soft) :;; #( + *) + ulimit -n "$MAX_FD" || + warn "Could not set maximum file descriptor limit to $MAX_FD" + esac fi -# For Darwin, add options to specify how the application appears in the dock -if $darwin; then - GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\"" -fi +# Collect all arguments for the java command, stacking in reverse order: +# * args from the command line +# * the main class name +# * -classpath +# * -D...appname settings +# * --module-path (only if needed) +# * DEFAULT_JVM_OPTS, JAVA_OPTS, and GRADLE_OPTS environment variables. # For Cygwin or MSYS, switch paths to Windows format before running java -if [ "$cygwin" = "true" -o "$msys" = "true" ] ; then - APP_HOME=`cygpath --path --mixed "$APP_HOME"` - CLASSPATH=`cygpath --path --mixed "$CLASSPATH"` - - JAVACMD=`cygpath --unix "$JAVACMD"` - - # We build the pattern for arguments to be converted via cygpath - ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null` - SEP="" - for dir in $ROOTDIRSRAW ; do - ROOTDIRS="$ROOTDIRS$SEP$dir" - SEP="|" - done - OURCYGPATTERN="(^($ROOTDIRS))" - # Add a user-defined pattern to the cygpath arguments - if [ "$GRADLE_CYGPATTERN" != "" ] ; then - OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)" - fi +if "$cygwin" || "$msys" ; then + APP_HOME=$( cygpath --path --mixed "$APP_HOME" ) + CLASSPATH=$( cygpath --path --mixed "$CLASSPATH" ) + + JAVACMD=$( cygpath --unix "$JAVACMD" ) + # Now convert the arguments - kludge to limit ourselves to /bin/sh - i=0 - for arg in "$@" ; do - CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -` - CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option - - if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition - eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"` - else - eval `echo args$i`="\"$arg\"" + for arg do + if + case $arg in #( + -*) false ;; # don't mess with options #( + /?*) t=${arg#/} t=/${t%%/*} # looks like a POSIX filepath + [ -e "$t" ] ;; #( + *) false ;; + esac + then + arg=$( cygpath --path --ignore --mixed "$arg" ) fi - i=`expr $i + 1` + # Roll the args list around exactly as many times as the number of + # args, so each arg winds up back in the position where it started, but + # possibly modified. + # + # NB: a `for` loop captures its iteration list before it begins, so + # changing the positional parameters here affects neither the number of + # iterations, nor the values presented in `arg`. + shift # remove old arg + set -- "$@" "$arg" # push replacement arg done - case $i in - 0) set -- ;; - 1) set -- "$args0" ;; - 2) set -- "$args0" "$args1" ;; - 3) set -- "$args0" "$args1" "$args2" ;; - 4) set -- "$args0" "$args1" "$args2" "$args3" ;; - 5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;; - 6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;; - 7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;; - 8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;; - 9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;; - esac fi -# Escape application args -save () { - for i do printf %s\\n "$i" | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/' \\\\/" ; done - echo " " -} -APP_ARGS=`save "$@"` +# Collect all arguments for the java command; +# * $DEFAULT_JVM_OPTS, $JAVA_OPTS, and $GRADLE_OPTS can contain fragments of +# shell script including quotes and variable substitutions, so put them in +# double quotes to make sure that they get re-expanded; and +# * put everything else in single quotes, so that it's not re-expanded. + +set -- \ + "-Dorg.gradle.appname=$APP_BASE_NAME" \ + -classpath "$CLASSPATH" \ + org.gradle.wrapper.GradleWrapperMain \ + "$@" + +# Use "xargs" to parse quoted args. +# +# With -n1 it outputs one arg per line, with the quotes and backslashes removed. +# +# In Bash we could simply go: +# +# readarray ARGS < <( xargs -n1 <<<"$var" ) && +# set -- "${ARGS[@]}" "$@" +# +# but POSIX shell has neither arrays nor command substitution, so instead we +# post-process each arg (as a line of input to sed) to backslash-escape any +# character that might be a shell metacharacter, then use eval to reverse +# that process (while maintaining the separation between arguments), and wrap +# the whole thing up as a single "set" statement. +# +# This will of course break if any of these variables contains a newline or +# an unmatched quote. +# -# Collect all arguments for the java command, following the shell quoting and substitution rules -eval set -- $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS "\"-Dorg.gradle.appname=$APP_BASE_NAME\"" -classpath "\"$CLASSPATH\"" org.gradle.wrapper.GradleWrapperMain "$APP_ARGS" +eval "set -- $( + printf '%s\n' "$DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS" | + xargs -n1 | + sed ' s~[^-[:alnum:]+,./:=@_]~\\&~g; ' | + tr '\n' ' ' + )" '"$@"' exec "$JAVACMD" "$@" diff --git a/clients/java/v1/gradlew.bat b/clients/java/v1/gradlew.bat index 107acd32..6a68175e 100644 --- a/clients/java/v1/gradlew.bat +++ b/clients/java/v1/gradlew.bat @@ -33,7 +33,7 @@ set APP_HOME=%DIRNAME% for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi @rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. -set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m" +set DEFAULT_JVM_OPTS=-Dfile.encoding=UTF-8 "-Xmx64m" "-Xms64m" @rem Find java.exe if defined JAVA_HOME goto findJavaFromJavaHome diff --git a/clients/java/v1/pom.xml b/clients/java/v1/pom.xml index a5eb678b..5fc9621e 100644 --- a/clients/java/v1/pom.xml +++ b/clients/java/v1/pom.xml @@ -50,7 +50,7 @@ org.apache.maven.plugins maven-enforcer-plugin - 3.0.0-M1 + 3.0.0 enforce-maven @@ -70,7 +70,7 @@ org.apache.maven.plugins maven-surefire-plugin - 3.0.0-M4 + 3.0.0-M5 @@ -97,16 +97,14 @@ - org.apache.maven.plugins maven-jar-plugin - 2.2 + 3.2.0 - jar test-jar @@ -114,11 +112,10 @@ - org.codehaus.mojo build-helper-maven-plugin - 1.10 + 3.2.0 add_sources @@ -149,7 +146,7 @@ org.apache.maven.plugins maven-javadoc-plugin - 3.1.1 + 3.3.1 attach-javadocs @@ -172,7 +169,7 @@ org.apache.maven.plugins maven-source-plugin - 2.2.1 + 3.2.0 attach-sources @@ -182,6 +179,48 @@ + + + com.diffplug.spotless + spotless-maven-plugin + ${spotless.version} + + + + + + + .gitignore + + + + + + true + 4 + + + + + + + + + + 1.8 + + true + + + + + + + + @@ -193,7 +232,7 @@ org.apache.maven.plugins maven-gpg-plugin - 1.5 + 3.0.1 sign-artifacts @@ -252,11 +291,16 @@ ${threetenbp-version} - javax.annotation - javax.annotation-api - ${javax-annotation-version} + jakarta.annotation + jakarta.annotation-api + ${jakarta-annotation-version} provided + + org.openapitools + jackson-databind-nullable + ${jackson-databind-nullable-version} + junit @@ -264,19 +308,27 @@ ${junit-version} test + + org.mockito + mockito-core + 3.12.4 + test + - 1.7 + 1.8 ${java.version} ${java.version} 1.8.5 - 1.6.2 - 4.9.1 - 2.8.6 - 3.11 + 1.6.3 + 4.9.2 + 2.8.8 + 3.12.0 + 0.2.2 1.5.0 - 1.3.2 - 4.13.1 + 1.3.5 + 4.13.2 UTF-8 + 2.17.3 diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/ApiCallback.java b/clients/java/v1/src/main/java/io/nomadproject/client/ApiCallback.java index 5cbbdd7a..0006b0be 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/ApiCallback.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/ApiCallback.java @@ -52,10 +52,10 @@ public interface ApiCallback { void onUploadProgress(long bytesWritten, long contentLength, boolean done); /** - * This is called when the API downlond processing. + * This is called when the API download processing. * * @param bytesRead bytes Read - * @param contentLength content lenngth of the response + * @param contentLength content length of the response * @param done Read end */ void onDownloadProgress(long bytesRead, long contentLength, boolean done); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/ApiClient.java b/clients/java/v1/src/main/java/io/nomadproject/client/ApiClient.java index 30a8f5e7..2d0414e7 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/ApiClient.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/ApiClient.java @@ -18,6 +18,7 @@ import okhttp3.internal.tls.OkHostnameVerifier; import okhttp3.logging.HttpLoggingInterceptor; import okhttp3.logging.HttpLoggingInterceptor.Level; +import okio.Buffer; import okio.BufferedSink; import okio.Okio; import org.threeten.bp.LocalDate; @@ -54,6 +55,9 @@ import io.nomadproject.client.auth.HttpBearerAuth; import io.nomadproject.client.auth.ApiKeyAuth; +/** + *

ApiClient class.

+ */ public class ApiClient { private String basePath = "https://127.0.0.1:4646/v1"; @@ -78,7 +82,7 @@ public class ApiClient { private HttpLoggingInterceptor loggingInterceptor; - /* + /** * Basic constructor for ApiClient */ public ApiClient() { @@ -91,8 +95,10 @@ public ApiClient() { authentications = Collections.unmodifiableMap(authentications); } - /* + /** * Basic constructor with custom OkHttpClient + * + * @param client a {@link okhttp3.OkHttpClient} object */ public ApiClient(OkHttpClient client) { init(); @@ -164,7 +170,7 @@ public OkHttpClient getHttpClient() { * * @param newHttpClient An instance of OkHttpClient * @return Api Client - * @throws NullPointerException when newHttpClient is null + * @throws java.lang.NullPointerException when newHttpClient is null */ public ApiClient setHttpClient(OkHttpClient newHttpClient) { this.httpClient = Objects.requireNonNull(newHttpClient, "HttpClient must not be null!"); @@ -236,6 +242,11 @@ public ApiClient setSslCaCert(InputStream sslCaCert) { return this; } + /** + *

Getter for the field keyManagers.

+ * + * @return an array of {@link javax.net.ssl.KeyManager} objects + */ public KeyManager[] getKeyManagers() { return keyManagers; } @@ -253,30 +264,65 @@ public ApiClient setKeyManagers(KeyManager[] managers) { return this; } + /** + *

Getter for the field dateFormat.

+ * + * @return a {@link java.text.DateFormat} object + */ public DateFormat getDateFormat() { return dateFormat; } + /** + *

Setter for the field dateFormat.

+ * + * @param dateFormat a {@link java.text.DateFormat} object + * @return a {@link org.openapitools.client.ApiClient} object + */ public ApiClient setDateFormat(DateFormat dateFormat) { this.json.setDateFormat(dateFormat); return this; } + /** + *

Set SqlDateFormat.

+ * + * @param dateFormat a {@link java.text.DateFormat} object + * @return a {@link org.openapitools.client.ApiClient} object + */ public ApiClient setSqlDateFormat(DateFormat dateFormat) { this.json.setSqlDateFormat(dateFormat); return this; } + /** + *

Set OffsetDateTimeFormat.

+ * + * @param dateFormat a {@link org.threeten.bp.format.DateTimeFormatter} object + * @return a {@link org.openapitools.client.ApiClient} object + */ public ApiClient setOffsetDateTimeFormat(DateTimeFormatter dateFormat) { this.json.setOffsetDateTimeFormat(dateFormat); return this; } + /** + *

Set LocalDateFormat.

+ * + * @param dateFormat a {@link org.threeten.bp.format.DateTimeFormatter} object + * @return a {@link org.openapitools.client.ApiClient} object + */ public ApiClient setLocalDateFormat(DateTimeFormatter dateFormat) { this.json.setLocalDateFormat(dateFormat); return this; } + /** + *

Set LenientOnJson.

+ * + * @param lenientOnJson a boolean + * @return a {@link org.openapitools.client.ApiClient} object + */ public ApiClient setLenientOnJson(boolean lenientOnJson) { this.json.setLenientOnJson(lenientOnJson); return this; @@ -441,7 +487,7 @@ public ApiClient setDebugging(boolean debugging) { /** * The path of temporary folder used to store downloaded files from endpoints * with file response. The default value is null, i.e. using - * the system's default tempopary folder. + * the system's default temporary folder. * * @see createTempFile * @return Temporary folder path @@ -473,7 +519,7 @@ public int getConnectTimeout() { /** * Sets the connect timeout (in milliseconds). * A value of 0 means no timeout, otherwise values must be between 1 and - * {@link Integer#MAX_VALUE}. + * {@link java.lang.Integer#MAX_VALUE}. * * @param connectionTimeout connection timeout in milliseconds * @return Api client @@ -495,7 +541,7 @@ public int getReadTimeout() { /** * Sets the read timeout (in milliseconds). * A value of 0 means no timeout, otherwise values must be between 1 and - * {@link Integer#MAX_VALUE}. + * {@link java.lang.Integer#MAX_VALUE}. * * @param readTimeout read timeout in milliseconds * @return Api client @@ -517,7 +563,7 @@ public int getWriteTimeout() { /** * Sets the write timeout (in milliseconds). * A value of 0 means no timeout, otherwise values must be between 1 and - * {@link Integer#MAX_VALUE}. + * {@link java.lang.Integer#MAX_VALUE}. * * @param writeTimeout connection timeout in milliseconds * @return Api client @@ -715,17 +761,23 @@ public String selectHeaderAccept(String[] accepts) { * * @param contentTypes The Content-Type array to select from * @return The Content-Type header to use. If the given array is empty, - * or matches "any", JSON will be used. + * returns null. If it matches "any", JSON will be used. */ public String selectHeaderContentType(String[] contentTypes) { - if (contentTypes.length == 0 || contentTypes[0].equals("*/*")) { + if (contentTypes.length == 0) { + return null; + } + + if (contentTypes[0].equals("*/*")) { return "application/json"; } + for (String contentType : contentTypes) { if (isJsonMime(contentType)) { return contentType; } } + return contentTypes[0]; } @@ -751,7 +803,7 @@ public String escapeString(String str) { * @param response HTTP response * @param returnType The type of the Java object * @return The deserialized Java object - * @throws ApiException If fail to deserialize response body, i.e. cannot read response body + * @throws org.openapitools.client.ApiException If fail to deserialize response body, i.e. cannot read response body * or the Content-Type of the response is not supported. */ @SuppressWarnings("unchecked") @@ -812,7 +864,7 @@ public T deserialize(Response response, Type returnType) throws ApiException * @param obj The Java object * @param contentType The request Content-Type * @return The serialized request body - * @throws ApiException If fail to serialize the given object + * @throws org.openapitools.client.ApiException If fail to serialize the given object */ public RequestBody serialize(Object obj, String contentType) throws ApiException { if (obj instanceof byte[]) { @@ -821,6 +873,8 @@ public RequestBody serialize(Object obj, String contentType) throws ApiException } else if (obj instanceof File) { // File body parameter support. return RequestBody.create((File) obj, MediaType.parse(contentType)); + } else if ("text/plain".equals(contentType) && obj instanceof String) { + return RequestBody.create((String) obj, MediaType.parse(contentType)); } else if (isJsonMime(contentType)) { String content; if (obj != null) { @@ -838,7 +892,7 @@ public RequestBody serialize(Object obj, String contentType) throws ApiException * Download file from the given response. * * @param response An instance of the Response object - * @throws ApiException If fail to read file content from response and write to disk + * @throws org.openapitools.client.ApiException If fail to read file content from response and write to disk * @return Downloaded file */ public File downloadFileFromResponse(Response response) throws ApiException { @@ -858,7 +912,7 @@ public File downloadFileFromResponse(Response response) throws ApiException { * * @param response An instance of the Response object * @return Prepared file for the download - * @throws IOException If fail to prepare file for download + * @throws java.io.IOException If fail to prepare file for download */ public File prepareDownloadFile(Response response) throws IOException { String filename = null; @@ -902,7 +956,7 @@ public File prepareDownloadFile(Response response) throws IOException { * @param Type * @param call An instance of the Call object * @return ApiResponse<T> - * @throws ApiException If fail to execute the call + * @throws org.openapitools.client.ApiException If fail to execute the call */ public ApiResponse execute(Call call) throws ApiException { return execute(call, null); @@ -917,7 +971,7 @@ public ApiResponse execute(Call call) throws ApiException { * @return ApiResponse object containing response status, headers and * data, which is a Java object deserialized from response body and would be null * when returnType is null. - * @throws ApiException If fail to execute the call + * @throws org.openapitools.client.ApiException If fail to execute the call */ public ApiResponse execute(Call call, Type returnType) throws ApiException { try { @@ -981,7 +1035,7 @@ public void onResponse(Call call, Response response) throws IOException { * @param response Response * @param returnType Return type * @return Type - * @throws ApiException If the response has an unsuccessful status code or + * @throws org.openapitools.client.ApiException If the response has an unsuccessful status code or * fail to deserialize the response body */ public T handleResponse(Response response, Type returnType) throws ApiException { @@ -1027,10 +1081,10 @@ public T handleResponse(Response response, Type returnType) throws ApiExcept * @param authNames The authentications to apply * @param callback Callback for upload/download progress * @return The HTTP call - * @throws ApiException If fail to serialize the request body object + * @throws org.openapitools.client.ApiException If fail to serialize the request body object */ - public Call buildCall(String path, String method, List queryParams, List collectionQueryParams, Object body, Map headerParams, Map cookieParams, Map formParams, String[] authNames, ApiCallback callback) throws ApiException { - Request request = buildRequest(path, method, queryParams, collectionQueryParams, body, headerParams, cookieParams, formParams, authNames, callback); + public Call buildCall(String baseUrl, String path, String method, List queryParams, List collectionQueryParams, Object body, Map headerParams, Map cookieParams, Map formParams, String[] authNames, ApiCallback callback) throws ApiException { + Request request = buildRequest(baseUrl, path, method, queryParams, collectionQueryParams, body, headerParams, cookieParams, formParams, authNames, callback); return httpClient.newCall(request); } @@ -1049,23 +1103,19 @@ public Call buildCall(String path, String method, List queryParams, List

queryParams, List collectionQueryParams, Object body, Map headerParams, Map cookieParams, Map formParams, String[] authNames, ApiCallback callback) throws ApiException { - updateParamsForAuth(authNames, queryParams, headerParams, cookieParams); + public Request buildRequest(String baseUrl, String path, String method, List queryParams, List collectionQueryParams, Object body, Map headerParams, Map cookieParams, Map formParams, String[] authNames, ApiCallback callback) throws ApiException { + // aggregate queryParams (non-collection) and collectionQueryParams into allQueryParams + List allQueryParams = new ArrayList(queryParams); + allQueryParams.addAll(collectionQueryParams); - final String url = buildUrl(path, queryParams, collectionQueryParams); - final Request.Builder reqBuilder = new Request.Builder().url(url); - processHeaderParams(headerParams, reqBuilder); - processCookieParams(cookieParams, reqBuilder); - - String contentType = (String) headerParams.get("Content-Type"); - // ensuring a default content type - if (contentType == null) { - contentType = "application/json"; - } + final String url = buildUrl(baseUrl, path, queryParams, collectionQueryParams); + // prepare HTTP request body RequestBody reqBody; + String contentType = headerParams.get("Content-Type"); + if (!HttpMethod.permitsRequestBody(method)) { reqBody = null; } else if ("application/x-www-form-urlencoded".equals(contentType)) { @@ -1084,6 +1134,13 @@ public Request buildRequest(String path, String method, List queryParams, reqBody = serialize(body, contentType); } + // update parameters with authentication settings + updateParamsForAuth(authNames, allQueryParams, headerParams, cookieParams, requestBodyToString(reqBody), method, URI.create(url)); + + final Request.Builder reqBuilder = new Request.Builder().url(url); + processHeaderParams(headerParams, reqBuilder); + processCookieParams(cookieParams, reqBuilder); + // Associate callback with request (if not null) so interceptor can // access it when creating ProgressResponseBody reqBuilder.tag(callback); @@ -1108,9 +1165,13 @@ public Request buildRequest(String path, String method, List queryParams, * @param collectionQueryParams The collection query parameters * @return The full URL */ - public String buildUrl(String path, List queryParams, List collectionQueryParams) { + public String buildUrl(String baseUrl, String path, List queryParams, List collectionQueryParams) { final StringBuilder url = new StringBuilder(); - url.append(basePath).append(path); + if (baseUrl != null) { + url.append(baseUrl).append(path); + } else { + url.append(basePath).append(path); + } if (queryParams != null && !queryParams.isEmpty()) { // support (constant) query string in `path`, e.g. "/posts?draft=1" @@ -1190,14 +1251,18 @@ public void processCookieParams(Map cookieParams, Request.Builde * @param queryParams List of query parameters * @param headerParams Map of header parameters * @param cookieParams Map of cookie parameters + * @param payload HTTP request body + * @param method HTTP method + * @param uri URI */ - public void updateParamsForAuth(String[] authNames, List queryParams, Map headerParams, Map cookieParams) { + public void updateParamsForAuth(String[] authNames, List queryParams, Map headerParams, + Map cookieParams, String payload, String method, URI uri) throws ApiException { for (String authName : authNames) { Authentication auth = authentications.get(authName); if (auth == null) { throw new RuntimeException("Authentication undefined: " + authName); } - auth.applyToParams(queryParams, headerParams, cookieParams); + auth.applyToParams(queryParams, headerParams, cookieParams, payload, method, uri); } } @@ -1349,4 +1414,26 @@ private KeyStore newEmptyKeyStore(char[] password) throws GeneralSecurityExcepti throw new AssertionError(e); } } + + /** + * Convert the HTTP request body to a string. + * + * @param request The HTTP request object + * @return The string representation of the HTTP request body + * @throws org.openapitools.client.ApiException If fail to serialize the request body object into a string + */ + private String requestBodyToString(RequestBody requestBody) throws ApiException { + if (requestBody != null) { + try { + final Buffer buffer = new Buffer(); + requestBody.writeTo(buffer); + return buffer.readUtf8(); + } catch (final IOException e) { + throw new ApiException(e); + } + } + + // empty http request body + return ""; + } } diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/ApiException.java b/clients/java/v1/src/main/java/io/nomadproject/client/ApiException.java index 966f3ef7..05b329cc 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/ApiException.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/ApiException.java @@ -16,22 +16,48 @@ import java.util.Map; import java.util.List; +/** + *

ApiException class.

+ */ +@SuppressWarnings("serial") @javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") public class ApiException extends Exception { private int code = 0; private Map> responseHeaders = null; private String responseBody = null; - + + /** + *

Constructor for ApiException.

+ */ public ApiException() {} + /** + *

Constructor for ApiException.

+ * + * @param throwable a {@link java.lang.Throwable} object + */ public ApiException(Throwable throwable) { super(throwable); } + /** + *

Constructor for ApiException.

+ * + * @param message the error message + */ public ApiException(String message) { super(message); } + /** + *

Constructor for ApiException.

+ * + * @param message the error message + * @param throwable a {@link java.lang.Throwable} object + * @param code HTTP status code + * @param responseHeaders a {@link java.util.Map} of HTTP response headers + * @param responseBody the response body + */ public ApiException(String message, Throwable throwable, int code, Map> responseHeaders, String responseBody) { super(message, throwable); this.code = code; @@ -39,23 +65,60 @@ public ApiException(String message, Throwable throwable, int code, MapConstructor for ApiException.

+ * + * @param message the error message + * @param code HTTP status code + * @param responseHeaders a {@link java.util.Map} of HTTP response headers + * @param responseBody the response body + */ public ApiException(String message, int code, Map> responseHeaders, String responseBody) { this(message, (Throwable) null, code, responseHeaders, responseBody); } + /** + *

Constructor for ApiException.

+ * + * @param message the error message + * @param throwable a {@link java.lang.Throwable} object + * @param code HTTP status code + * @param responseHeaders a {@link java.util.Map} of HTTP response headers + */ public ApiException(String message, Throwable throwable, int code, Map> responseHeaders) { this(message, throwable, code, responseHeaders, null); } + /** + *

Constructor for ApiException.

+ * + * @param code HTTP status code + * @param responseHeaders a {@link java.util.Map} of HTTP response headers + * @param responseBody the response body + */ public ApiException(int code, Map> responseHeaders, String responseBody) { this((String) null, (Throwable) null, code, responseHeaders, responseBody); } + /** + *

Constructor for ApiException.

+ * + * @param code HTTP status code + * @param message a {@link java.lang.String} object + */ public ApiException(int code, String message) { super(message); this.code = code; } + /** + *

Constructor for ApiException.

+ * + * @param code HTTP status code + * @param message the error message + * @param responseHeaders a {@link java.util.Map} of HTTP response headers + * @param responseBody the response body + */ public ApiException(int code, String message, Map> responseHeaders, String responseBody) { this(code, message); this.responseHeaders = responseHeaders; diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/ApiResponse.java b/clients/java/v1/src/main/java/io/nomadproject/client/ApiResponse.java index 94418ca5..9f39be9b 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/ApiResponse.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/ApiResponse.java @@ -18,8 +18,6 @@ /** * API response returned by API call. - * - * @param The type of data that is deserialized from response body */ public class ApiResponse { final private int statusCode; @@ -27,6 +25,8 @@ public class ApiResponse { final private T data; /** + *

Constructor for ApiResponse.

+ * * @param statusCode The status code of HTTP response * @param headers The headers of HTTP response */ @@ -35,6 +35,8 @@ public ApiResponse(int statusCode, Map> headers) { } /** + *

Constructor for ApiResponse.

+ * * @param statusCode The status code of HTTP response * @param headers The headers of HTTP response * @param data The object deserialized from response bod @@ -45,14 +47,29 @@ public ApiResponse(int statusCode, Map> headers, T data) { this.data = data; } + /** + *

Get the status code.

+ * + * @return the status code + */ public int getStatusCode() { return statusCode; } + /** + *

Get the headers.

+ * + * @return a {@link java.util.Map} of headers + */ public Map> getHeaders() { return headers; } + /** + *

Get the data.

+ * + * @return the data + */ public T getData() { return data; } diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/JSON.java b/clients/java/v1/src/main/java/io/nomadproject/client/JSON.java index bfacce5b..4b1d79b1 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/JSON.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/JSON.java @@ -111,6 +111,13 @@ public JSON setGson(Gson gson) { return this; } + /** + * Configure the parser to be liberal in what it accepts. + * + * @param lenientOnJson Set it to true to ignore some syntax errors + * @return JSON + * @see https://www.javadoc.io/doc/com.google.code.gson/gson/2.8.5/com/google/gson/stream/JsonReader.html + */ public JSON setLenientOnJson(boolean lenientOnJson) { isLenientOnJson = lenientOnJson; return this; @@ -139,7 +146,7 @@ public T deserialize(String body, Type returnType) { try { if (isLenientOnJson) { JsonReader jsonReader = new JsonReader(new StringReader(body)); - // see https://google-gson.googlecode.com/svn/trunk/gson/docs/javadocs/com/google/gson/stream/JsonReader.html#setLenient(boolean) + // see https://www.javadoc.io/doc/com.google.code.gson/gson/2.8.5/com/google/gson/stream/JsonReader.html jsonReader.setLenient(true); return gson.fromJson(jsonReader, returnType); } else { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/Pair.java b/clients/java/v1/src/main/java/io/nomadproject/client/Pair.java index 2b086dc7..d8449017 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/Pair.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/Pair.java @@ -52,10 +52,6 @@ private boolean isValidString(String arg) { return false; } - if (arg.trim().isEmpty()) { - return false; - } - return true; } } diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/ProgressResponseBody.java b/clients/java/v1/src/main/java/io/nomadproject/client/ProgressResponseBody.java index e3b5e5f3..3155e30c 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/ProgressResponseBody.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/ProgressResponseBody.java @@ -68,5 +68,3 @@ public long read(Buffer sink, long byteCount) throws IOException { }; } } - - diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/ServerConfiguration.java b/clients/java/v1/src/main/java/io/nomadproject/client/ServerConfiguration.java index 5763ef2e..eed86411 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/ServerConfiguration.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/ServerConfiguration.java @@ -12,7 +12,7 @@ public class ServerConfiguration { /** * @param URL A URL to the target host. - * @param description A describtion of the host designated by the URL. + * @param description A description of the host designated by the URL. * @param variables A map between a variable name and its value. The value is used for substitution in the server's URL template. */ public ServerConfiguration(String URL, String description, Map variables) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/api/AclApi.java b/clients/java/v1/src/main/java/io/nomadproject/client/api/AclApi.java index 1db8ef03..ec8025a8 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/api/AclApi.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/api/AclApi.java @@ -42,6 +42,8 @@ public class AclApi { private ApiClient localVarApiClient; + private int localHostIndex; + private String localCustomBaseUrl; public AclApi() { this(Configuration.getDefaultApiClient()); @@ -59,6 +61,22 @@ public void setApiClient(ApiClient apiClient) { this.localVarApiClient = apiClient; } + public int getHostIndex() { + return localHostIndex; + } + + public void setHostIndex(int hostIndex) { + this.localHostIndex = hostIndex; + } + + public String getCustomBaseUrl() { + return localCustomBaseUrl; + } + + public void setCustomBaseUrl(String customBaseUrl) { + this.localCustomBaseUrl = customBaseUrl; + } + /** * Build call for deleteACLPolicy * @param policyName The ACL policy name. (required) @@ -80,6 +98,20 @@ public void setApiClient(ApiClient apiClient) { */ public okhttp3.Call deleteACLPolicyCall(String policyName, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -120,10 +152,12 @@ public okhttp3.Call deleteACLPolicyCall(String policyName, String region, String }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -236,6 +270,20 @@ public okhttp3.Call deleteACLPolicyAsync(String policyName, String region, Strin */ public okhttp3.Call deleteACLTokenCall(String tokenAccessor, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -276,10 +324,12 @@ public okhttp3.Call deleteACLTokenCall(String tokenAccessor, String region, Stri }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -396,6 +446,20 @@ public okhttp3.Call deleteACLTokenAsync(String tokenAccessor, String region, Str */ public okhttp3.Call getACLPoliciesCall(String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -455,10 +519,12 @@ public okhttp3.Call getACLPoliciesCall(String region, String namespace, Integer }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -587,6 +653,20 @@ public okhttp3.Call getACLPoliciesAsync(String region, String namespace, Integer */ public okhttp3.Call getACLPolicyCall(String policyName, String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -647,10 +727,12 @@ public okhttp3.Call getACLPolicyCall(String policyName, String region, String na }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -787,6 +869,20 @@ public okhttp3.Call getACLPolicyAsync(String policyName, String region, String n */ public okhttp3.Call getACLTokenCall(String tokenAccessor, String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -847,10 +943,12 @@ public okhttp3.Call getACLTokenCall(String tokenAccessor, String region, String }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -986,6 +1084,20 @@ public okhttp3.Call getACLTokenAsync(String tokenAccessor, String region, String */ public okhttp3.Call getACLTokenSelfCall(String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -1045,10 +1157,12 @@ public okhttp3.Call getACLTokenSelfCall(String region, String namespace, Integer }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -1176,6 +1290,20 @@ public okhttp3.Call getACLTokenSelfAsync(String region, String namespace, Intege */ public okhttp3.Call getACLTokensCall(String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -1235,10 +1363,12 @@ public okhttp3.Call getACLTokensCall(String region, String namespace, Integer in }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -1361,6 +1491,20 @@ public okhttp3.Call getACLTokensAsync(String region, String namespace, Integer i */ public okhttp3.Call postACLBootstrapCall(String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -1400,10 +1544,12 @@ public okhttp3.Call postACLBootstrapCall(String region, String namespace, String }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -1513,6 +1659,20 @@ public okhttp3.Call postACLBootstrapAsync(String region, String namespace, Strin */ public okhttp3.Call postACLPolicyCall(String policyName, ACLPolicy acLPolicy, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = acLPolicy; // create path and map variables @@ -1553,10 +1713,12 @@ public okhttp3.Call postACLPolicyCall(String policyName, ACLPolicy acLPolicy, St "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -1678,6 +1840,20 @@ public okhttp3.Call postACLPolicyAsync(String policyName, ACLPolicy acLPolicy, S */ public okhttp3.Call postACLTokenCall(String tokenAccessor, ACLToken acLToken, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = acLToken; // create path and map variables @@ -1718,10 +1894,12 @@ public okhttp3.Call postACLTokenCall(String tokenAccessor, ACLToken acLToken, St "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -1845,6 +2023,20 @@ public okhttp3.Call postACLTokenAsync(String tokenAccessor, ACLToken acLToken, S */ public okhttp3.Call postACLTokenOnetimeCall(String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -1884,10 +2076,12 @@ public okhttp3.Call postACLTokenOnetimeCall(String region, String namespace, Str }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -1996,6 +2190,20 @@ public okhttp3.Call postACLTokenOnetimeAsync(String region, String namespace, St */ public okhttp3.Call postACLTokenOnetimeExchangeCall(OneTimeTokenExchangeRequest oneTimeTokenExchangeRequest, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = oneTimeTokenExchangeRequest; // create path and map variables @@ -2035,10 +2243,12 @@ public okhttp3.Call postACLTokenOnetimeExchangeCall(OneTimeTokenExchangeRequest "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/api/AllocationsApi.java b/clients/java/v1/src/main/java/io/nomadproject/client/api/AllocationsApi.java index a96c9d24..11e013a1 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/api/AllocationsApi.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/api/AllocationsApi.java @@ -40,6 +40,8 @@ public class AllocationsApi { private ApiClient localVarApiClient; + private int localHostIndex; + private String localCustomBaseUrl; public AllocationsApi() { this(Configuration.getDefaultApiClient()); @@ -57,6 +59,22 @@ public void setApiClient(ApiClient apiClient) { this.localVarApiClient = apiClient; } + public int getHostIndex() { + return localHostIndex; + } + + public void setHostIndex(int hostIndex) { + this.localHostIndex = hostIndex; + } + + public String getCustomBaseUrl() { + return localCustomBaseUrl; + } + + public void setCustomBaseUrl(String customBaseUrl) { + this.localCustomBaseUrl = customBaseUrl; + } + /** * Build call for getAllocation * @param allocID Allocation ID. (required) @@ -83,6 +101,20 @@ public void setApiClient(ApiClient apiClient) { */ public okhttp3.Call getAllocationCall(String allocID, String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -143,10 +175,12 @@ public okhttp3.Call getAllocationCall(String allocID, String region, String name }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -283,6 +317,20 @@ public okhttp3.Call getAllocationAsync(String allocID, String region, String nam */ public okhttp3.Call getAllocationServicesCall(String allocID, String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -343,10 +391,12 @@ public okhttp3.Call getAllocationServicesCall(String allocID, String region, Str }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -484,6 +534,20 @@ public okhttp3.Call getAllocationServicesAsync(String allocID, String region, St */ public okhttp3.Call getAllocationsCall(String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, Boolean resources, Boolean taskStates, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -551,10 +615,12 @@ public okhttp3.Call getAllocationsCall(String region, String namespace, Integer }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -690,6 +756,20 @@ public okhttp3.Call getAllocationsAsync(String region, String namespace, Integer */ public okhttp3.Call postAllocationStopCall(String allocID, String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, Boolean noShutdownDelay, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -754,10 +834,12 @@ public okhttp3.Call postAllocationStopCall(String allocID, String region, String }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/api/DeploymentsApi.java b/clients/java/v1/src/main/java/io/nomadproject/client/api/DeploymentsApi.java index 2be9c0ec..32064a77 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/api/DeploymentsApi.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/api/DeploymentsApi.java @@ -43,6 +43,8 @@ public class DeploymentsApi { private ApiClient localVarApiClient; + private int localHostIndex; + private String localCustomBaseUrl; public DeploymentsApi() { this(Configuration.getDefaultApiClient()); @@ -60,6 +62,22 @@ public void setApiClient(ApiClient apiClient) { this.localVarApiClient = apiClient; } + public int getHostIndex() { + return localHostIndex; + } + + public void setHostIndex(int hostIndex) { + this.localHostIndex = hostIndex; + } + + public String getCustomBaseUrl() { + return localCustomBaseUrl; + } + + public void setCustomBaseUrl(String customBaseUrl) { + this.localCustomBaseUrl = customBaseUrl; + } + /** * Build call for getDeployment * @param deploymentID Deployment ID. (required) @@ -86,6 +104,20 @@ public void setApiClient(ApiClient apiClient) { */ public okhttp3.Call getDeploymentCall(String deploymentID, String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -146,10 +178,12 @@ public okhttp3.Call getDeploymentCall(String deploymentID, String region, String }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -286,6 +320,20 @@ public okhttp3.Call getDeploymentAsync(String deploymentID, String region, Strin */ public okhttp3.Call getDeploymentAllocationsCall(String deploymentID, String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -346,10 +394,12 @@ public okhttp3.Call getDeploymentAllocationsCall(String deploymentID, String reg }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -485,6 +535,20 @@ public okhttp3.Call getDeploymentAllocationsAsync(String deploymentID, String re */ public okhttp3.Call getDeploymentsCall(String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -544,10 +608,12 @@ public okhttp3.Call getDeploymentsCall(String region, String namespace, Integer }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -672,6 +738,20 @@ public okhttp3.Call getDeploymentsAsync(String region, String namespace, Integer */ public okhttp3.Call postDeploymentAllocationHealthCall(String deploymentID, DeploymentAllocHealthRequest deploymentAllocHealthRequest, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = deploymentAllocHealthRequest; // create path and map variables @@ -712,10 +792,12 @@ public okhttp3.Call postDeploymentAllocationHealthCall(String deploymentID, Depl "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -840,6 +922,20 @@ public okhttp3.Call postDeploymentAllocationHealthAsync(String deploymentID, Dep */ public okhttp3.Call postDeploymentFailCall(String deploymentID, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -880,10 +976,12 @@ public okhttp3.Call postDeploymentFailCall(String deploymentID, String region, S }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -1001,6 +1099,20 @@ public okhttp3.Call postDeploymentFailAsync(String deploymentID, String region, */ public okhttp3.Call postDeploymentPauseCall(String deploymentID, DeploymentPauseRequest deploymentPauseRequest, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = deploymentPauseRequest; // create path and map variables @@ -1041,10 +1153,12 @@ public okhttp3.Call postDeploymentPauseCall(String deploymentID, DeploymentPause "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -1170,6 +1284,20 @@ public okhttp3.Call postDeploymentPauseAsync(String deploymentID, DeploymentPaus */ public okhttp3.Call postDeploymentPromoteCall(String deploymentID, DeploymentPromoteRequest deploymentPromoteRequest, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = deploymentPromoteRequest; // create path and map variables @@ -1210,10 +1338,12 @@ public okhttp3.Call postDeploymentPromoteCall(String deploymentID, DeploymentPro "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -1339,6 +1469,20 @@ public okhttp3.Call postDeploymentPromoteAsync(String deploymentID, DeploymentPr */ public okhttp3.Call postDeploymentUnblockCall(String deploymentID, DeploymentUnblockRequest deploymentUnblockRequest, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = deploymentUnblockRequest; // create path and map variables @@ -1379,10 +1523,12 @@ public okhttp3.Call postDeploymentUnblockCall(String deploymentID, DeploymentUnb "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/api/EnterpriseApi.java b/clients/java/v1/src/main/java/io/nomadproject/client/api/EnterpriseApi.java index dc7bbd34..0f5177bf 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/api/EnterpriseApi.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/api/EnterpriseApi.java @@ -37,6 +37,8 @@ public class EnterpriseApi { private ApiClient localVarApiClient; + private int localHostIndex; + private String localCustomBaseUrl; public EnterpriseApi() { this(Configuration.getDefaultApiClient()); @@ -54,6 +56,22 @@ public void setApiClient(ApiClient apiClient) { this.localVarApiClient = apiClient; } + public int getHostIndex() { + return localHostIndex; + } + + public void setHostIndex(int hostIndex) { + this.localHostIndex = hostIndex; + } + + public String getCustomBaseUrl() { + return localCustomBaseUrl; + } + + public void setCustomBaseUrl(String customBaseUrl) { + this.localCustomBaseUrl = customBaseUrl; + } + /** * Build call for createQuotaSpec * @param quotaSpec (required) @@ -75,6 +93,20 @@ public void setApiClient(ApiClient apiClient) { */ public okhttp3.Call createQuotaSpecCall(QuotaSpec quotaSpec, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = quotaSpec; // create path and map variables @@ -114,10 +146,12 @@ public okhttp3.Call createQuotaSpecCall(QuotaSpec quotaSpec, String region, Stri "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -230,6 +264,20 @@ public okhttp3.Call createQuotaSpecAsync(QuotaSpec quotaSpec, String region, Str */ public okhttp3.Call deleteQuotaSpecCall(String specName, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -270,10 +318,12 @@ public okhttp3.Call deleteQuotaSpecCall(String specName, String region, String n }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -391,6 +441,20 @@ public okhttp3.Call deleteQuotaSpecAsync(String specName, String region, String */ public okhttp3.Call getQuotaSpecCall(String specName, String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -451,10 +515,12 @@ public okhttp3.Call getQuotaSpecCall(String specName, String region, String name }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -590,6 +656,20 @@ public okhttp3.Call getQuotaSpecAsync(String specName, String region, String nam */ public okhttp3.Call getQuotasCall(String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -649,10 +729,12 @@ public okhttp3.Call getQuotasCall(String region, String namespace, Integer index }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -777,6 +859,20 @@ public okhttp3.Call getQuotasAsync(String region, String namespace, Integer inde */ public okhttp3.Call postQuotaSpecCall(String specName, QuotaSpec quotaSpec, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = quotaSpec; // create path and map variables @@ -817,10 +913,12 @@ public okhttp3.Call postQuotaSpecCall(String specName, QuotaSpec quotaSpec, Stri "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/api/EvaluationsApi.java b/clients/java/v1/src/main/java/io/nomadproject/client/api/EvaluationsApi.java index ed230bbc..0d25ed60 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/api/EvaluationsApi.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/api/EvaluationsApi.java @@ -38,6 +38,8 @@ public class EvaluationsApi { private ApiClient localVarApiClient; + private int localHostIndex; + private String localCustomBaseUrl; public EvaluationsApi() { this(Configuration.getDefaultApiClient()); @@ -55,6 +57,22 @@ public void setApiClient(ApiClient apiClient) { this.localVarApiClient = apiClient; } + public int getHostIndex() { + return localHostIndex; + } + + public void setHostIndex(int hostIndex) { + this.localHostIndex = hostIndex; + } + + public String getCustomBaseUrl() { + return localCustomBaseUrl; + } + + public void setCustomBaseUrl(String customBaseUrl) { + this.localCustomBaseUrl = customBaseUrl; + } + /** * Build call for getEvaluation * @param evalID Evaluation ID. (required) @@ -81,6 +99,20 @@ public void setApiClient(ApiClient apiClient) { */ public okhttp3.Call getEvaluationCall(String evalID, String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -141,10 +173,12 @@ public okhttp3.Call getEvaluationCall(String evalID, String region, String names }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -281,6 +315,20 @@ public okhttp3.Call getEvaluationAsync(String evalID, String region, String name */ public okhttp3.Call getEvaluationAllocationsCall(String evalID, String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -341,10 +389,12 @@ public okhttp3.Call getEvaluationAllocationsCall(String evalID, String region, S }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -480,6 +530,20 @@ public okhttp3.Call getEvaluationAllocationsAsync(String evalID, String region, */ public okhttp3.Call getEvaluationsCall(String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -539,10 +603,12 @@ public okhttp3.Call getEvaluationsCall(String region, String namespace, Integer }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/api/JobsApi.java b/clients/java/v1/src/main/java/io/nomadproject/client/api/JobsApi.java index 26def9f1..45f2773e 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/api/JobsApi.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/api/JobsApi.java @@ -60,6 +60,8 @@ public class JobsApi { private ApiClient localVarApiClient; + private int localHostIndex; + private String localCustomBaseUrl; public JobsApi() { this(Configuration.getDefaultApiClient()); @@ -77,6 +79,22 @@ public void setApiClient(ApiClient apiClient) { this.localVarApiClient = apiClient; } + public int getHostIndex() { + return localHostIndex; + } + + public void setHostIndex(int hostIndex) { + this.localHostIndex = hostIndex; + } + + public String getCustomBaseUrl() { + return localCustomBaseUrl; + } + + public void setCustomBaseUrl(String customBaseUrl) { + this.localCustomBaseUrl = customBaseUrl; + } + /** * Build call for deleteJob * @param jobName The job identifier. (required) @@ -100,6 +118,20 @@ public void setApiClient(ApiClient apiClient) { */ public okhttp3.Call deleteJobCall(String jobName, String region, String namespace, String xNomadToken, String idempotencyToken, Boolean purge, Boolean global, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -148,10 +180,12 @@ public okhttp3.Call deleteJobCall(String jobName, String region, String namespac }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -279,6 +313,20 @@ public okhttp3.Call deleteJobAsync(String jobName, String region, String namespa */ public okhttp3.Call getJobCall(String jobName, String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -339,10 +387,12 @@ public okhttp3.Call getJobCall(String jobName, String region, String namespace, }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -480,6 +530,20 @@ public okhttp3.Call getJobAsync(String jobName, String region, String namespace, */ public okhttp3.Call getJobAllocationsCall(String jobName, String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, Boolean all, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -544,10 +608,12 @@ public okhttp3.Call getJobAllocationsCall(String jobName, String region, String }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -687,6 +753,20 @@ public okhttp3.Call getJobAllocationsAsync(String jobName, String region, String */ public okhttp3.Call getJobDeploymentCall(String jobName, String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -747,10 +827,12 @@ public okhttp3.Call getJobDeploymentCall(String jobName, String region, String n }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -888,6 +970,20 @@ public okhttp3.Call getJobDeploymentAsync(String jobName, String region, String */ public okhttp3.Call getJobDeploymentsCall(String jobName, String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, Integer all, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -952,10 +1048,12 @@ public okhttp3.Call getJobDeploymentsCall(String jobName, String region, String }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -1095,6 +1193,20 @@ public okhttp3.Call getJobDeploymentsAsync(String jobName, String region, String */ public okhttp3.Call getJobEvaluationsCall(String jobName, String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -1155,10 +1267,12 @@ public okhttp3.Call getJobEvaluationsCall(String jobName, String region, String }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -1295,6 +1409,20 @@ public okhttp3.Call getJobEvaluationsAsync(String jobName, String region, String */ public okhttp3.Call getJobScaleStatusCall(String jobName, String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -1355,10 +1483,12 @@ public okhttp3.Call getJobScaleStatusCall(String jobName, String region, String }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -1495,6 +1625,20 @@ public okhttp3.Call getJobScaleStatusAsync(String jobName, String region, String */ public okhttp3.Call getJobSummaryCall(String jobName, String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -1555,10 +1699,12 @@ public okhttp3.Call getJobSummaryCall(String jobName, String region, String name }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -1696,6 +1842,20 @@ public okhttp3.Call getJobSummaryAsync(String jobName, String region, String nam */ public okhttp3.Call getJobVersionsCall(String jobName, String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, Boolean diffs, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -1760,10 +1920,12 @@ public okhttp3.Call getJobVersionsCall(String jobName, String region, String nam }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -1902,6 +2064,20 @@ public okhttp3.Call getJobVersionsAsync(String jobName, String region, String na */ public okhttp3.Call getJobsCall(String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -1961,10 +2137,12 @@ public okhttp3.Call getJobsCall(String region, String namespace, Integer index, }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -2089,6 +2267,20 @@ public okhttp3.Call getJobsAsync(String region, String namespace, Integer index, */ public okhttp3.Call postJobCall(String jobName, JobRegisterRequest jobRegisterRequest, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = jobRegisterRequest; // create path and map variables @@ -2129,10 +2321,12 @@ public okhttp3.Call postJobCall(String jobName, JobRegisterRequest jobRegisterRe "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -2258,6 +2452,20 @@ public okhttp3.Call postJobAsync(String jobName, JobRegisterRequest jobRegisterR */ public okhttp3.Call postJobDispatchCall(String jobName, JobDispatchRequest jobDispatchRequest, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = jobDispatchRequest; // create path and map variables @@ -2298,10 +2506,12 @@ public okhttp3.Call postJobDispatchCall(String jobName, JobDispatchRequest jobDi "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -2427,6 +2637,20 @@ public okhttp3.Call postJobDispatchAsync(String jobName, JobDispatchRequest jobD */ public okhttp3.Call postJobEvaluateCall(String jobName, JobEvaluateRequest jobEvaluateRequest, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = jobEvaluateRequest; // create path and map variables @@ -2467,10 +2691,12 @@ public okhttp3.Call postJobEvaluateCall(String jobName, JobEvaluateRequest jobEv "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -2591,6 +2817,20 @@ public okhttp3.Call postJobEvaluateAsync(String jobName, JobEvaluateRequest jobE */ public okhttp3.Call postJobParseCall(JobsParseRequest jobsParseRequest, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = jobsParseRequest; // create path and map variables @@ -2614,10 +2854,12 @@ public okhttp3.Call postJobParseCall(JobsParseRequest jobsParseRequest, final Ap "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -2722,6 +2964,20 @@ public okhttp3.Call postJobParseAsync(JobsParseRequest jobsParseRequest, final A */ public okhttp3.Call postJobPeriodicForceCall(String jobName, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -2762,10 +3018,12 @@ public okhttp3.Call postJobPeriodicForceCall(String jobName, String region, Stri }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -2883,6 +3141,20 @@ public okhttp3.Call postJobPeriodicForceAsync(String jobName, String region, Str */ public okhttp3.Call postJobPlanCall(String jobName, JobPlanRequest jobPlanRequest, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = jobPlanRequest; // create path and map variables @@ -2923,10 +3195,12 @@ public okhttp3.Call postJobPlanCall(String jobName, JobPlanRequest jobPlanReques "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -3052,6 +3326,20 @@ public okhttp3.Call postJobPlanAsync(String jobName, JobPlanRequest jobPlanReque */ public okhttp3.Call postJobRevertCall(String jobName, JobRevertRequest jobRevertRequest, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = jobRevertRequest; // create path and map variables @@ -3092,10 +3380,12 @@ public okhttp3.Call postJobRevertCall(String jobName, JobRevertRequest jobRevert "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -3221,6 +3511,20 @@ public okhttp3.Call postJobRevertAsync(String jobName, JobRevertRequest jobRever */ public okhttp3.Call postJobScalingRequestCall(String jobName, ScalingRequest scalingRequest, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = scalingRequest; // create path and map variables @@ -3261,10 +3565,12 @@ public okhttp3.Call postJobScalingRequestCall(String jobName, ScalingRequest sca "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -3390,6 +3696,20 @@ public okhttp3.Call postJobScalingRequestAsync(String jobName, ScalingRequest sc */ public okhttp3.Call postJobStabilityCall(String jobName, JobStabilityRequest jobStabilityRequest, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = jobStabilityRequest; // create path and map variables @@ -3430,10 +3750,12 @@ public okhttp3.Call postJobStabilityCall(String jobName, JobStabilityRequest job "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -3558,6 +3880,20 @@ public okhttp3.Call postJobStabilityAsync(String jobName, JobStabilityRequest jo */ public okhttp3.Call postJobValidateRequestCall(JobValidateRequest jobValidateRequest, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = jobValidateRequest; // create path and map variables @@ -3597,10 +3933,12 @@ public okhttp3.Call postJobValidateRequestCall(JobValidateRequest jobValidateReq "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -3717,6 +4055,20 @@ public okhttp3.Call postJobValidateRequestAsync(JobValidateRequest jobValidateRe */ public okhttp3.Call registerJobCall(JobRegisterRequest jobRegisterRequest, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = jobRegisterRequest; // create path and map variables @@ -3756,10 +4108,12 @@ public okhttp3.Call registerJobCall(JobRegisterRequest jobRegisterRequest, Strin "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/api/MetricsApi.java b/clients/java/v1/src/main/java/io/nomadproject/client/api/MetricsApi.java index fd798a4e..4a7bf39b 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/api/MetricsApi.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/api/MetricsApi.java @@ -37,6 +37,8 @@ public class MetricsApi { private ApiClient localVarApiClient; + private int localHostIndex; + private String localCustomBaseUrl; public MetricsApi() { this(Configuration.getDefaultApiClient()); @@ -54,6 +56,22 @@ public void setApiClient(ApiClient apiClient) { this.localVarApiClient = apiClient; } + public int getHostIndex() { + return localHostIndex; + } + + public void setHostIndex(int hostIndex) { + this.localHostIndex = hostIndex; + } + + public String getCustomBaseUrl() { + return localCustomBaseUrl; + } + + public void setCustomBaseUrl(String customBaseUrl) { + this.localCustomBaseUrl = customBaseUrl; + } + /** * Build call for getMetricsSummary * @param format The format the user requested for the metrics summary (e.g. prometheus) (optional) @@ -71,6 +89,20 @@ public void setApiClient(ApiClient apiClient) { */ public okhttp3.Call getMetricsSummaryCall(String format, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -98,10 +130,12 @@ public okhttp3.Call getMetricsSummaryCall(String format, final ApiCallback _call }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/api/NamespacesApi.java b/clients/java/v1/src/main/java/io/nomadproject/client/api/NamespacesApi.java index 83fa0976..6fb6fa8f 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/api/NamespacesApi.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/api/NamespacesApi.java @@ -37,6 +37,8 @@ public class NamespacesApi { private ApiClient localVarApiClient; + private int localHostIndex; + private String localCustomBaseUrl; public NamespacesApi() { this(Configuration.getDefaultApiClient()); @@ -54,6 +56,22 @@ public void setApiClient(ApiClient apiClient) { this.localVarApiClient = apiClient; } + public int getHostIndex() { + return localHostIndex; + } + + public void setHostIndex(int hostIndex) { + this.localHostIndex = hostIndex; + } + + public String getCustomBaseUrl() { + return localCustomBaseUrl; + } + + public void setCustomBaseUrl(String customBaseUrl) { + this.localCustomBaseUrl = customBaseUrl; + } + /** * Build call for createNamespace * @param region Filters results based on the specified region. (optional) @@ -74,6 +92,20 @@ public void setApiClient(ApiClient apiClient) { */ public okhttp3.Call createNamespaceCall(String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -113,10 +145,12 @@ public okhttp3.Call createNamespaceCall(String region, String namespace, String }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -221,6 +255,20 @@ public okhttp3.Call createNamespaceAsync(String region, String namespace, String */ public okhttp3.Call deleteNamespaceCall(String namespaceName, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -261,10 +309,12 @@ public okhttp3.Call deleteNamespaceCall(String namespaceName, String region, Str }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -382,6 +432,20 @@ public okhttp3.Call deleteNamespaceAsync(String namespaceName, String region, St */ public okhttp3.Call getNamespaceCall(String namespaceName, String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -442,10 +506,12 @@ public okhttp3.Call getNamespaceCall(String namespaceName, String region, String }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -581,6 +647,20 @@ public okhttp3.Call getNamespaceAsync(String namespaceName, String region, Strin */ public okhttp3.Call getNamespacesCall(String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -640,10 +720,12 @@ public okhttp3.Call getNamespacesCall(String region, String namespace, Integer i }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -768,6 +850,20 @@ public okhttp3.Call getNamespacesAsync(String region, String namespace, Integer */ public okhttp3.Call postNamespaceCall(String namespaceName, Namespace namespace2, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = namespace2; // create path and map variables @@ -808,10 +904,12 @@ public okhttp3.Call postNamespaceCall(String namespaceName, Namespace namespace2 "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/api/NodesApi.java b/clients/java/v1/src/main/java/io/nomadproject/client/api/NodesApi.java index 7cdeb40a..4813d912 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/api/NodesApi.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/api/NodesApi.java @@ -44,6 +44,8 @@ public class NodesApi { private ApiClient localVarApiClient; + private int localHostIndex; + private String localCustomBaseUrl; public NodesApi() { this(Configuration.getDefaultApiClient()); @@ -61,6 +63,22 @@ public void setApiClient(ApiClient apiClient) { this.localVarApiClient = apiClient; } + public int getHostIndex() { + return localHostIndex; + } + + public void setHostIndex(int hostIndex) { + this.localHostIndex = hostIndex; + } + + public String getCustomBaseUrl() { + return localCustomBaseUrl; + } + + public void setCustomBaseUrl(String customBaseUrl) { + this.localCustomBaseUrl = customBaseUrl; + } + /** * Build call for getNode * @param nodeId The ID of the node. (required) @@ -87,6 +105,20 @@ public void setApiClient(ApiClient apiClient) { */ public okhttp3.Call getNodeCall(String nodeId, String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -147,10 +179,12 @@ public okhttp3.Call getNodeCall(String nodeId, String region, String namespace, }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -287,6 +321,20 @@ public okhttp3.Call getNodeAsync(String nodeId, String region, String namespace, */ public okhttp3.Call getNodeAllocationsCall(String nodeId, String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -347,10 +395,12 @@ public okhttp3.Call getNodeAllocationsCall(String nodeId, String region, String }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -487,6 +537,20 @@ public okhttp3.Call getNodeAllocationsAsync(String nodeId, String region, String */ public okhttp3.Call getNodesCall(String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, Boolean resources, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -550,10 +614,12 @@ public okhttp3.Call getNodesCall(String region, String namespace, Integer index, }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -686,6 +752,20 @@ public okhttp3.Call getNodesAsync(String region, String namespace, Integer index */ public okhttp3.Call updateNodeDrainCall(String nodeId, NodeUpdateDrainRequest nodeUpdateDrainRequest, String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = nodeUpdateDrainRequest; // create path and map variables @@ -746,10 +826,12 @@ public okhttp3.Call updateNodeDrainCall(String nodeId, NodeUpdateDrainRequest no "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -895,6 +977,20 @@ public okhttp3.Call updateNodeDrainAsync(String nodeId, NodeUpdateDrainRequest n */ public okhttp3.Call updateNodeEligibilityCall(String nodeId, NodeUpdateEligibilityRequest nodeUpdateEligibilityRequest, String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = nodeUpdateEligibilityRequest; // create path and map variables @@ -955,10 +1051,12 @@ public okhttp3.Call updateNodeEligibilityCall(String nodeId, NodeUpdateEligibili "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -1103,6 +1201,20 @@ public okhttp3.Call updateNodeEligibilityAsync(String nodeId, NodeUpdateEligibil */ public okhttp3.Call updateNodePurgeCall(String nodeId, String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -1163,10 +1275,12 @@ public okhttp3.Call updateNodePurgeCall(String nodeId, String region, String nam }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/api/OperatorApi.java b/clients/java/v1/src/main/java/io/nomadproject/client/api/OperatorApi.java index 6a1cc77f..bfe38beb 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/api/OperatorApi.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/api/OperatorApi.java @@ -42,6 +42,8 @@ public class OperatorApi { private ApiClient localVarApiClient; + private int localHostIndex; + private String localCustomBaseUrl; public OperatorApi() { this(Configuration.getDefaultApiClient()); @@ -59,6 +61,22 @@ public void setApiClient(ApiClient apiClient) { this.localVarApiClient = apiClient; } + public int getHostIndex() { + return localHostIndex; + } + + public void setHostIndex(int hostIndex) { + this.localHostIndex = hostIndex; + } + + public String getCustomBaseUrl() { + return localCustomBaseUrl; + } + + public void setCustomBaseUrl(String customBaseUrl) { + this.localCustomBaseUrl = customBaseUrl; + } + /** * Build call for deleteOperatorRaftPeer * @param region Filters results based on the specified region. (optional) @@ -79,6 +97,20 @@ public void setApiClient(ApiClient apiClient) { */ public okhttp3.Call deleteOperatorRaftPeerCall(String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -118,10 +150,12 @@ public okhttp3.Call deleteOperatorRaftPeerCall(String region, String namespace, }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -230,6 +264,20 @@ public okhttp3.Call deleteOperatorRaftPeerAsync(String region, String namespace, */ public okhttp3.Call getOperatorAutopilotConfigurationCall(String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -289,10 +337,12 @@ public okhttp3.Call getOperatorAutopilotConfigurationCall(String region, String }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -420,6 +470,20 @@ public okhttp3.Call getOperatorAutopilotConfigurationAsync(String region, String */ public okhttp3.Call getOperatorAutopilotHealthCall(String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -479,10 +543,12 @@ public okhttp3.Call getOperatorAutopilotHealthCall(String region, String namespa }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -610,6 +676,20 @@ public okhttp3.Call getOperatorAutopilotHealthAsync(String region, String namesp */ public okhttp3.Call getOperatorRaftConfigurationCall(String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -669,10 +749,12 @@ public okhttp3.Call getOperatorRaftConfigurationCall(String region, String names }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -800,6 +882,20 @@ public okhttp3.Call getOperatorRaftConfigurationAsync(String region, String name */ public okhttp3.Call getOperatorSchedulerConfigurationCall(String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -859,10 +955,12 @@ public okhttp3.Call getOperatorSchedulerConfigurationCall(String region, String }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -986,6 +1084,20 @@ public okhttp3.Call getOperatorSchedulerConfigurationAsync(String region, String */ public okhttp3.Call postOperatorSchedulerConfigurationCall(SchedulerConfiguration schedulerConfiguration, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = schedulerConfiguration; // create path and map variables @@ -1025,10 +1137,12 @@ public okhttp3.Call postOperatorSchedulerConfigurationCall(SchedulerConfiguratio "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -1145,6 +1259,20 @@ public okhttp3.Call postOperatorSchedulerConfigurationAsync(SchedulerConfigurati */ public okhttp3.Call putOperatorAutopilotConfigurationCall(AutopilotConfiguration autopilotConfiguration, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = autopilotConfiguration; // create path and map variables @@ -1184,10 +1312,12 @@ public okhttp3.Call putOperatorAutopilotConfigurationCall(AutopilotConfiguration "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "PUT", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/api/PluginsApi.java b/clients/java/v1/src/main/java/io/nomadproject/client/api/PluginsApi.java index d002120b..38a309b8 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/api/PluginsApi.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/api/PluginsApi.java @@ -38,6 +38,8 @@ public class PluginsApi { private ApiClient localVarApiClient; + private int localHostIndex; + private String localCustomBaseUrl; public PluginsApi() { this(Configuration.getDefaultApiClient()); @@ -55,6 +57,22 @@ public void setApiClient(ApiClient apiClient) { this.localVarApiClient = apiClient; } + public int getHostIndex() { + return localHostIndex; + } + + public void setHostIndex(int hostIndex) { + this.localHostIndex = hostIndex; + } + + public String getCustomBaseUrl() { + return localCustomBaseUrl; + } + + public void setCustomBaseUrl(String customBaseUrl) { + this.localCustomBaseUrl = customBaseUrl; + } + /** * Build call for getPluginCSI * @param pluginID The CSI plugin identifier. (required) @@ -81,6 +99,20 @@ public void setApiClient(ApiClient apiClient) { */ public okhttp3.Call getPluginCSICall(String pluginID, String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -141,10 +173,12 @@ public okhttp3.Call getPluginCSICall(String pluginID, String region, String name }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -280,6 +314,20 @@ public okhttp3.Call getPluginCSIAsync(String pluginID, String region, String nam */ public okhttp3.Call getPluginsCall(String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -339,10 +387,12 @@ public okhttp3.Call getPluginsCall(String region, String namespace, Integer inde }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/api/RegionsApi.java b/clients/java/v1/src/main/java/io/nomadproject/client/api/RegionsApi.java index 7365cd49..d257b087 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/api/RegionsApi.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/api/RegionsApi.java @@ -36,6 +36,8 @@ public class RegionsApi { private ApiClient localVarApiClient; + private int localHostIndex; + private String localCustomBaseUrl; public RegionsApi() { this(Configuration.getDefaultApiClient()); @@ -53,6 +55,22 @@ public void setApiClient(ApiClient apiClient) { this.localVarApiClient = apiClient; } + public int getHostIndex() { + return localHostIndex; + } + + public void setHostIndex(int hostIndex) { + this.localHostIndex = hostIndex; + } + + public String getCustomBaseUrl() { + return localCustomBaseUrl; + } + + public void setCustomBaseUrl(String customBaseUrl) { + this.localCustomBaseUrl = customBaseUrl; + } + /** * Build call for getRegions * @param _callback Callback for upload/download progress @@ -69,6 +87,20 @@ public void setApiClient(ApiClient apiClient) { */ public okhttp3.Call getRegionsCall(final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -92,10 +124,12 @@ public okhttp3.Call getRegionsCall(final ApiCallback _callback) throws ApiExcept }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/api/ScalingApi.java b/clients/java/v1/src/main/java/io/nomadproject/client/api/ScalingApi.java index c70cf739..639d0315 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/api/ScalingApi.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/api/ScalingApi.java @@ -38,6 +38,8 @@ public class ScalingApi { private ApiClient localVarApiClient; + private int localHostIndex; + private String localCustomBaseUrl; public ScalingApi() { this(Configuration.getDefaultApiClient()); @@ -55,6 +57,22 @@ public void setApiClient(ApiClient apiClient) { this.localVarApiClient = apiClient; } + public int getHostIndex() { + return localHostIndex; + } + + public void setHostIndex(int hostIndex) { + this.localHostIndex = hostIndex; + } + + public String getCustomBaseUrl() { + return localCustomBaseUrl; + } + + public void setCustomBaseUrl(String customBaseUrl) { + this.localCustomBaseUrl = customBaseUrl; + } + /** * Build call for getScalingPolicies * @param region Filters results based on the specified region. (optional) @@ -80,6 +98,20 @@ public void setApiClient(ApiClient apiClient) { */ public okhttp3.Call getScalingPoliciesCall(String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -139,10 +171,12 @@ public okhttp3.Call getScalingPoliciesCall(String region, String namespace, Inte }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -271,6 +305,20 @@ public okhttp3.Call getScalingPoliciesAsync(String region, String namespace, Int */ public okhttp3.Call getScalingPolicyCall(String policyID, String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -331,10 +379,12 @@ public okhttp3.Call getScalingPolicyCall(String policyID, String region, String }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/api/SearchApi.java b/clients/java/v1/src/main/java/io/nomadproject/client/api/SearchApi.java index 38515243..260f0998 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/api/SearchApi.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/api/SearchApi.java @@ -40,6 +40,8 @@ public class SearchApi { private ApiClient localVarApiClient; + private int localHostIndex; + private String localCustomBaseUrl; public SearchApi() { this(Configuration.getDefaultApiClient()); @@ -57,6 +59,22 @@ public void setApiClient(ApiClient apiClient) { this.localVarApiClient = apiClient; } + public int getHostIndex() { + return localHostIndex; + } + + public void setHostIndex(int hostIndex) { + this.localHostIndex = hostIndex; + } + + public String getCustomBaseUrl() { + return localCustomBaseUrl; + } + + public void setCustomBaseUrl(String customBaseUrl) { + this.localCustomBaseUrl = customBaseUrl; + } + /** * Build call for getFuzzySearch * @param fuzzySearchRequest (required) @@ -83,6 +101,20 @@ public void setApiClient(ApiClient apiClient) { */ public okhttp3.Call getFuzzySearchCall(FuzzySearchRequest fuzzySearchRequest, String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = fuzzySearchRequest; // create path and map variables @@ -142,10 +174,12 @@ public okhttp3.Call getFuzzySearchCall(FuzzySearchRequest fuzzySearchRequest, St "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -282,6 +316,20 @@ public okhttp3.Call getFuzzySearchAsync(FuzzySearchRequest fuzzySearchRequest, S */ public okhttp3.Call getSearchCall(SearchRequest searchRequest, String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = searchRequest; // create path and map variables @@ -341,10 +389,12 @@ public okhttp3.Call getSearchCall(SearchRequest searchRequest, String region, St "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/api/StatusApi.java b/clients/java/v1/src/main/java/io/nomadproject/client/api/StatusApi.java index 07020895..58894784 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/api/StatusApi.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/api/StatusApi.java @@ -36,6 +36,8 @@ public class StatusApi { private ApiClient localVarApiClient; + private int localHostIndex; + private String localCustomBaseUrl; public StatusApi() { this(Configuration.getDefaultApiClient()); @@ -53,6 +55,22 @@ public void setApiClient(ApiClient apiClient) { this.localVarApiClient = apiClient; } + public int getHostIndex() { + return localHostIndex; + } + + public void setHostIndex(int hostIndex) { + this.localHostIndex = hostIndex; + } + + public String getCustomBaseUrl() { + return localCustomBaseUrl; + } + + public void setCustomBaseUrl(String customBaseUrl) { + this.localCustomBaseUrl = customBaseUrl; + } + /** * Build call for getStatusLeader * @param region Filters results based on the specified region. (optional) @@ -78,6 +96,20 @@ public void setApiClient(ApiClient apiClient) { */ public okhttp3.Call getStatusLeaderCall(String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -137,10 +169,12 @@ public okhttp3.Call getStatusLeaderCall(String region, String namespace, Integer }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -268,6 +302,20 @@ public okhttp3.Call getStatusLeaderAsync(String region, String namespace, Intege */ public okhttp3.Call getStatusPeersCall(String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -327,10 +375,12 @@ public okhttp3.Call getStatusPeersCall(String region, String namespace, Integer }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/api/SystemApi.java b/clients/java/v1/src/main/java/io/nomadproject/client/api/SystemApi.java index 2cba8217..d277b1c9 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/api/SystemApi.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/api/SystemApi.java @@ -36,6 +36,8 @@ public class SystemApi { private ApiClient localVarApiClient; + private int localHostIndex; + private String localCustomBaseUrl; public SystemApi() { this(Configuration.getDefaultApiClient()); @@ -53,6 +55,22 @@ public void setApiClient(ApiClient apiClient) { this.localVarApiClient = apiClient; } + public int getHostIndex() { + return localHostIndex; + } + + public void setHostIndex(int hostIndex) { + this.localHostIndex = hostIndex; + } + + public String getCustomBaseUrl() { + return localCustomBaseUrl; + } + + public void setCustomBaseUrl(String customBaseUrl) { + this.localCustomBaseUrl = customBaseUrl; + } + /** * Build call for putSystemGC * @param region Filters results based on the specified region. (optional) @@ -73,6 +91,20 @@ public void setApiClient(ApiClient apiClient) { */ public okhttp3.Call putSystemGCCall(String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -112,10 +144,12 @@ public okhttp3.Call putSystemGCCall(String region, String namespace, String xNom }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "PUT", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -219,6 +253,20 @@ public okhttp3.Call putSystemGCAsync(String region, String namespace, String xNo */ public okhttp3.Call putSystemReconcileSummariesCall(String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -258,10 +306,12 @@ public okhttp3.Call putSystemReconcileSummariesCall(String region, String namesp }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "PUT", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/api/VolumesApi.java b/clients/java/v1/src/main/java/io/nomadproject/client/api/VolumesApi.java index 02ea8890..b959c424 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/api/VolumesApi.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/api/VolumesApi.java @@ -44,6 +44,8 @@ public class VolumesApi { private ApiClient localVarApiClient; + private int localHostIndex; + private String localCustomBaseUrl; public VolumesApi() { this(Configuration.getDefaultApiClient()); @@ -61,6 +63,22 @@ public void setApiClient(ApiClient apiClient) { this.localVarApiClient = apiClient; } + public int getHostIndex() { + return localHostIndex; + } + + public void setHostIndex(int hostIndex) { + this.localHostIndex = hostIndex; + } + + public String getCustomBaseUrl() { + return localCustomBaseUrl; + } + + public void setCustomBaseUrl(String customBaseUrl) { + this.localCustomBaseUrl = customBaseUrl; + } + /** * Build call for createVolume * @param volumeId Volume unique identifier. (required) @@ -84,6 +102,20 @@ public void setApiClient(ApiClient apiClient) { */ public okhttp3.Call createVolumeCall(String volumeId, String action, CSIVolumeCreateRequest csIVolumeCreateRequest, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = csIVolumeCreateRequest; // create path and map variables @@ -125,10 +157,12 @@ public okhttp3.Call createVolumeCall(String volumeId, String action, CSIVolumeCr "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -258,6 +292,20 @@ public okhttp3.Call createVolumeAsync(String volumeId, String action, CSIVolumeC */ public okhttp3.Call deleteSnapshotCall(String region, String namespace, String xNomadToken, String idempotencyToken, String pluginId, String snapshotId, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -305,10 +353,12 @@ public okhttp3.Call deleteSnapshotCall(String region, String namespace, String x }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -420,6 +470,20 @@ public okhttp3.Call deleteSnapshotAsync(String region, String namespace, String */ public okhttp3.Call deleteVolumeRegistrationCall(String volumeId, String region, String namespace, String xNomadToken, String idempotencyToken, String force, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -464,10 +528,12 @@ public okhttp3.Call deleteVolumeRegistrationCall(String volumeId, String region, }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -585,6 +651,20 @@ public okhttp3.Call deleteVolumeRegistrationAsync(String volumeId, String region */ public okhttp3.Call detachOrDeleteVolumeCall(String volumeId, String action, String region, String namespace, String xNomadToken, String idempotencyToken, String node, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -630,10 +710,12 @@ public okhttp3.Call detachOrDeleteVolumeCall(String volumeId, String action, Str }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -762,6 +844,20 @@ public okhttp3.Call detachOrDeleteVolumeAsync(String volumeId, String action, St */ public okhttp3.Call getExternalVolumesCall(String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, String pluginId, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -825,10 +921,12 @@ public okhttp3.Call getExternalVolumesCall(String region, String namespace, Inte }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -960,6 +1058,20 @@ public okhttp3.Call getExternalVolumesAsync(String region, String namespace, Int */ public okhttp3.Call getSnapshotsCall(String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, String pluginId, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -1023,10 +1135,12 @@ public okhttp3.Call getSnapshotsCall(String region, String namespace, Integer in }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -1158,6 +1272,20 @@ public okhttp3.Call getSnapshotsAsync(String region, String namespace, Integer i */ public okhttp3.Call getVolumeCall(String volumeId, String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -1218,10 +1346,12 @@ public okhttp3.Call getVolumeCall(String volumeId, String region, String namespa }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -1360,6 +1490,20 @@ public okhttp3.Call getVolumeAsync(String volumeId, String region, String namesp */ public okhttp3.Call getVolumesCall(String region, String namespace, Integer index, String wait, String stale, String prefix, String xNomadToken, Integer perPage, String nextToken, String nodeId, String pluginId, String type, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = null; // create path and map variables @@ -1431,10 +1575,12 @@ public okhttp3.Call getVolumesCall(String region, String namespace, Integer inde }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -1567,6 +1713,20 @@ public okhttp3.Call getVolumesAsync(String region, String namespace, Integer ind */ public okhttp3.Call postSnapshotCall(CSISnapshotCreateRequest csISnapshotCreateRequest, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = csISnapshotCreateRequest; // create path and map variables @@ -1606,10 +1766,12 @@ public okhttp3.Call postSnapshotCall(CSISnapshotCreateRequest csISnapshotCreateR "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -1726,6 +1888,20 @@ public okhttp3.Call postSnapshotAsync(CSISnapshotCreateRequest csISnapshotCreate */ public okhttp3.Call postVolumeCall(CSIVolumeRegisterRequest csIVolumeRegisterRequest, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = csIVolumeRegisterRequest; // create path and map variables @@ -1765,10 +1941,12 @@ public okhttp3.Call postVolumeCall(CSIVolumeRegisterRequest csIVolumeRegisterReq "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") @@ -1882,6 +2060,20 @@ public okhttp3.Call postVolumeAsync(CSIVolumeRegisterRequest csIVolumeRegisterRe */ public okhttp3.Call postVolumeRegistrationCall(String volumeId, CSIVolumeRegisterRequest csIVolumeRegisterRequest, String region, String namespace, String xNomadToken, String idempotencyToken, final ApiCallback _callback) throws ApiException { + String basePath = null; + + // Operation Servers + String[] localBasePaths = new String[] { }; + + // Determine Base Path to Use + if (localCustomBaseUrl != null){ + basePath = localCustomBaseUrl; + } else if ( localBasePaths.length > 0 ) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + Object localVarPostBody = csIVolumeRegisterRequest; // create path and map variables @@ -1922,10 +2114,12 @@ public okhttp3.Call postVolumeRegistrationCall(String volumeId, CSIVolumeRegiste "application/json" }; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } String[] localVarAuthNames = new String[] { "X-Nomad-Token" }; - return localVarApiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); + return localVarApiClient.buildCall(basePath, localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAuthNames, _callback); } @SuppressWarnings("rawtypes") diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/auth/ApiKeyAuth.java b/clients/java/v1/src/main/java/io/nomadproject/client/auth/ApiKeyAuth.java index 74f3a584..8cbe1b9b 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/auth/ApiKeyAuth.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/auth/ApiKeyAuth.java @@ -13,8 +13,10 @@ package io.nomadproject.client.auth; +import io.nomadproject.client.ApiException; import io.nomadproject.client.Pair; +import java.net.URI; import java.util.Map; import java.util.List; @@ -56,7 +58,8 @@ public void setApiKeyPrefix(String apiKeyPrefix) { } @Override - public void applyToParams(List queryParams, Map headerParams, Map cookieParams) { + public void applyToParams(List queryParams, Map headerParams, Map cookieParams, + String payload, String method, URI uri) throws ApiException { if (apiKey == null) { return; } diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/auth/Authentication.java b/clients/java/v1/src/main/java/io/nomadproject/client/auth/Authentication.java index 045a3098..e2f76861 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/auth/Authentication.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/auth/Authentication.java @@ -14,7 +14,9 @@ package io.nomadproject.client.auth; import io.nomadproject.client.Pair; +import io.nomadproject.client.ApiException; +import java.net.URI; import java.util.Map; import java.util.List; @@ -25,6 +27,10 @@ public interface Authentication { * @param queryParams List of query parameters * @param headerParams Map of header parameters * @param cookieParams Map of cookie parameters + * @param payload HTTP request body + * @param method HTTP method + * @param uri URI + * @throws ApiException if failed to update the parameters */ - void applyToParams(List queryParams, Map headerParams, Map cookieParams); + void applyToParams(List queryParams, Map headerParams, Map cookieParams, String payload, String method, URI uri) throws ApiException; } diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/auth/HttpBasicAuth.java b/clients/java/v1/src/main/java/io/nomadproject/client/auth/HttpBasicAuth.java index 5a498ab3..a90a39ab 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/auth/HttpBasicAuth.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/auth/HttpBasicAuth.java @@ -14,9 +14,11 @@ package io.nomadproject.client.auth; import io.nomadproject.client.Pair; +import io.nomadproject.client.ApiException; import okhttp3.Credentials; +import java.net.URI; import java.util.Map; import java.util.List; @@ -43,7 +45,8 @@ public void setPassword(String password) { } @Override - public void applyToParams(List queryParams, Map headerParams, Map cookieParams) { + public void applyToParams(List queryParams, Map headerParams, Map cookieParams, + String payload, String method, URI uri) throws ApiException { if (username == null && password == null) { return; } diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/auth/HttpBearerAuth.java b/clients/java/v1/src/main/java/io/nomadproject/client/auth/HttpBearerAuth.java index 9c0a233a..91cab53f 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/auth/HttpBearerAuth.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/auth/HttpBearerAuth.java @@ -13,8 +13,10 @@ package io.nomadproject.client.auth; +import io.nomadproject.client.ApiException; import io.nomadproject.client.Pair; +import java.net.URI; import java.util.Map; import java.util.List; @@ -46,8 +48,9 @@ public void setBearerToken(String bearerToken) { } @Override - public void applyToParams(List queryParams, Map headerParams, Map cookieParams) { - if(bearerToken == null) { + public void applyToParams(List queryParams, Map headerParams, Map cookieParams, + String payload, String method, URI uri) throws ApiException { + if (bearerToken == null) { return; } diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/ACLPolicy.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/ACLPolicy.java index a8296989..f176f91e 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/ACLPolicy.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/ACLPolicy.java @@ -49,6 +49,8 @@ public class ACLPolicy { @SerializedName(SERIALIZED_NAME_RULES) private String rules; + public ACLPolicy() { + } public ACLPolicy createIndex(Integer createIndex) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/ACLPolicyListStub.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/ACLPolicyListStub.java index 98b7431f..75639446 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/ACLPolicyListStub.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/ACLPolicyListStub.java @@ -45,6 +45,8 @@ public class ACLPolicyListStub { @SerializedName(SERIALIZED_NAME_NAME) private String name; + public ACLPolicyListStub() { + } public ACLPolicyListStub createIndex(Integer createIndex) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/ACLToken.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/ACLToken.java index 715ad38c..584844e3 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/ACLToken.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/ACLToken.java @@ -25,6 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; /** @@ -68,6 +69,8 @@ public class ACLToken { @SerializedName(SERIALIZED_NAME_TYPE) private String type; + public ACLToken() { + } public ACLToken accessorID(String accessorID) { @@ -308,11 +311,22 @@ public boolean equals(Object o) { Objects.equals(this.type, acLToken.type); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(accessorID, createIndex, createTime, global, modifyIndex, name, policies, secretID, type); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/ACLTokenListStub.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/ACLTokenListStub.java index a07b0ea7..ade17ab2 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/ACLTokenListStub.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/ACLTokenListStub.java @@ -25,6 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; /** @@ -64,6 +65,8 @@ public class ACLTokenListStub { @SerializedName(SERIALIZED_NAME_TYPE) private String type; + public ACLTokenListStub() { + } public ACLTokenListStub accessorID(String accessorID) { @@ -280,11 +283,22 @@ public boolean equals(Object o) { Objects.equals(this.type, acLTokenListStub.type); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(accessorID, createIndex, createTime, global, modifyIndex, name, policies, type); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/Affinity.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/Affinity.java index 77448c78..d64b860f 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/Affinity.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/Affinity.java @@ -45,6 +45,8 @@ public class Affinity { @SerializedName(SERIALIZED_NAME_WEIGHT) private Integer weight; + public Affinity() { + } public Affinity ltarget(String ltarget) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocDeploymentStatus.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocDeploymentStatus.java index fb74515f..fa3a2fca 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocDeploymentStatus.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocDeploymentStatus.java @@ -23,6 +23,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; /** @@ -46,6 +47,8 @@ public class AllocDeploymentStatus { @SerializedName(SERIALIZED_NAME_TIMESTAMP) private OffsetDateTime timestamp; + public AllocDeploymentStatus() { + } public AllocDeploymentStatus canary(Boolean canary) { @@ -156,11 +159,22 @@ public boolean equals(Object o) { Objects.equals(this.timestamp, allocDeploymentStatus.timestamp); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(canary, healthy, modifyIndex, timestamp); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocStopResponse.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocStopResponse.java index fe6ef282..abba69ae 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocStopResponse.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocStopResponse.java @@ -37,6 +37,8 @@ public class AllocStopResponse { @SerializedName(SERIALIZED_NAME_INDEX) private Integer index; + public AllocStopResponse() { + } public AllocStopResponse evalID(String evalID) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocatedCpuResources.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocatedCpuResources.java index 8a3aee33..4e866659 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocatedCpuResources.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocatedCpuResources.java @@ -33,6 +33,8 @@ public class AllocatedCpuResources { @SerializedName(SERIALIZED_NAME_CPU_SHARES) private Long cpuShares; + public AllocatedCpuResources() { + } public AllocatedCpuResources cpuShares(Long cpuShares) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocatedDeviceResource.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocatedDeviceResource.java index 4389877d..03c25065 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocatedDeviceResource.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocatedDeviceResource.java @@ -47,6 +47,8 @@ public class AllocatedDeviceResource { @SerializedName(SERIALIZED_NAME_VENDOR) private String vendor; + public AllocatedDeviceResource() { + } public AllocatedDeviceResource deviceIDs(List deviceIDs) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocatedMemoryResources.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocatedMemoryResources.java index 6729463f..c177ce1d 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocatedMemoryResources.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocatedMemoryResources.java @@ -37,6 +37,8 @@ public class AllocatedMemoryResources { @SerializedName(SERIALIZED_NAME_MEMORY_MAX_M_B) private Long memoryMaxMB; + public AllocatedMemoryResources() { + } public AllocatedMemoryResources memoryMB(Long memoryMB) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocatedResources.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocatedResources.java index 2e1b3a2a..1b862e98 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocatedResources.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocatedResources.java @@ -28,6 +28,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; /** * AllocatedResources @@ -42,6 +43,8 @@ public class AllocatedResources { @SerializedName(SERIALIZED_NAME_TASKS) private Map tasks = null; + public AllocatedResources() { + } public AllocatedResources shared(AllocatedSharedResources shared) { @@ -110,11 +113,22 @@ public boolean equals(Object o) { Objects.equals(this.tasks, allocatedResources.tasks); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(shared, tasks); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocatedSharedResources.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocatedSharedResources.java index c8efafff..e826aa2f 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocatedSharedResources.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocatedSharedResources.java @@ -45,6 +45,8 @@ public class AllocatedSharedResources { @SerializedName(SERIALIZED_NAME_PORTS) private List ports = null; + public AllocatedSharedResources() { + } public AllocatedSharedResources diskMB(Long diskMB) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocatedTaskResources.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocatedTaskResources.java index bd2cea8c..b6813935 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocatedTaskResources.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocatedTaskResources.java @@ -29,6 +29,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import org.openapitools.jackson.nullable.JsonNullable; /** * AllocatedTaskResources @@ -51,6 +52,8 @@ public class AllocatedTaskResources { @SerializedName(SERIALIZED_NAME_NETWORKS) private List networks = null; + public AllocatedTaskResources() { + } public AllocatedTaskResources cpu(AllocatedCpuResources cpu) { @@ -175,11 +178,22 @@ public boolean equals(Object o) { Objects.equals(this.networks, allocatedTaskResources.networks); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(cpu, devices, memory, networks); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/Allocation.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/Allocation.java index ccebb6e4..ef91df00 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/Allocation.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/Allocation.java @@ -35,6 +35,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; /** * Allocation @@ -173,6 +174,8 @@ public class Allocation { @SerializedName(SERIALIZED_NAME_TASK_STATES) private Map taskStates = null; + public Allocation() { + } public Allocation allocModifyIndex(Integer allocModifyIndex) { @@ -1015,11 +1018,22 @@ public boolean equals(Object o) { Objects.equals(this.taskStates, allocation.taskStates); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(allocModifyIndex, allocatedResources, clientDescription, clientStatus, createIndex, createTime, deploymentID, deploymentStatus, desiredDescription, desiredStatus, desiredTransition, evalID, followupEvalID, ID, job, jobID, metrics, modifyIndex, modifyTime, name, namespace, nextAllocation, nodeID, nodeName, preemptedAllocations, preemptedByAllocation, previousAllocation, rescheduleTracker, resources, services, taskGroup, taskResources, taskStates); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocationListStub.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocationListStub.java index 99790353..42493053 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocationListStub.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocationListStub.java @@ -31,6 +31,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; /** * AllocationListStub @@ -137,6 +138,8 @@ public class AllocationListStub { @SerializedName(SERIALIZED_NAME_TASK_STATES) private Map taskStates = null; + public AllocationListStub() { + } public AllocationListStub allocatedResources(AllocatedResources allocatedResources) { @@ -771,11 +774,22 @@ public boolean equals(Object o) { Objects.equals(this.taskStates, allocationListStub.taskStates); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(allocatedResources, clientDescription, clientStatus, createIndex, createTime, deploymentStatus, desiredDescription, desiredStatus, evalID, followupEvalID, ID, jobID, jobType, jobVersion, modifyIndex, modifyTime, name, namespace, nodeID, nodeName, preemptedAllocations, preemptedByAllocation, rescheduleTracker, taskGroup, taskStates); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocationMetric.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocationMetric.java index c59e2a0c..23227287 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocationMetric.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/AllocationMetric.java @@ -91,6 +91,8 @@ public class AllocationMetric { @SerializedName(SERIALIZED_NAME_SCORES) private Map scores = null; + public AllocationMetric() { + } public AllocationMetric allocationTime(Long allocationTime) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/Attribute.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/Attribute.java index b307efe0..402302e6 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/Attribute.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/Attribute.java @@ -49,6 +49,8 @@ public class Attribute { @SerializedName(SERIALIZED_NAME_UNIT) private String unit; + public Attribute() { + } public Attribute bool(Boolean bool) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/AutopilotConfiguration.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/AutopilotConfiguration.java index 471fd535..49237b4f 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/AutopilotConfiguration.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/AutopilotConfiguration.java @@ -69,6 +69,8 @@ public class AutopilotConfiguration { @SerializedName(SERIALIZED_NAME_SERVER_STABILIZATION_TIME) private String serverStabilizationTime; + public AutopilotConfiguration() { + } public AutopilotConfiguration cleanupDeadServers(Boolean cleanupDeadServers) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIControllerInfo.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIControllerInfo.java index ab7e902e..3ab6f063 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIControllerInfo.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIControllerInfo.java @@ -77,6 +77,8 @@ public class CSIControllerInfo { @SerializedName(SERIALIZED_NAME_SUPPORTS_READ_ONLY_ATTACH) private Boolean supportsReadOnlyAttach; + public CSIControllerInfo() { + } public CSIControllerInfo supportsAttachDetach(Boolean supportsAttachDetach) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIInfo.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIInfo.java index ff56e320..55aa8bb0 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIInfo.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIInfo.java @@ -25,6 +25,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; /** @@ -68,6 +69,8 @@ public class CSIInfo { @SerializedName(SERIALIZED_NAME_UPDATE_TIME) private OffsetDateTime updateTime; + public CSIInfo() { + } public CSIInfo allocID(String allocID) { @@ -296,11 +299,22 @@ public boolean equals(Object o) { Objects.equals(this.updateTime, csIInfo.updateTime); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(allocID, controllerInfo, healthDescription, healthy, nodeInfo, pluginID, requiresControllerPlugin, requiresTopologies, updateTime); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIMountOptions.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIMountOptions.java index 1341980d..afdf0dd5 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIMountOptions.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIMountOptions.java @@ -39,6 +39,8 @@ public class CSIMountOptions { @SerializedName(SERIALIZED_NAME_MOUNT_FLAGS) private List mountFlags = null; + public CSIMountOptions() { + } public CSIMountOptions fsType(String fsType) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSINodeInfo.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSINodeInfo.java index 53c0a5b5..8b076f9f 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSINodeInfo.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSINodeInfo.java @@ -24,6 +24,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; /** * CSINodeInfo @@ -58,6 +59,8 @@ public class CSINodeInfo { @SerializedName(SERIALIZED_NAME_SUPPORTS_STATS) private Boolean supportsStats; + public CSINodeInfo() { + } public CSINodeInfo accessibleTopology(CSITopology accessibleTopology) { @@ -238,11 +241,22 @@ public boolean equals(Object o) { Objects.equals(this.supportsStats, csINodeInfo.supportsStats); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(accessibleTopology, ID, maxVolumes, requiresNodeStageVolume, supportsCondition, supportsExpand, supportsStats); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIPlugin.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIPlugin.java index 15fe9c36..a89bbf5f 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIPlugin.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIPlugin.java @@ -87,6 +87,8 @@ public class CSIPlugin { @SerializedName(SERIALIZED_NAME_VERSION) private String version; + public CSIPlugin() { + } public CSIPlugin allocations(List allocations) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIPluginListStub.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIPluginListStub.java index 1964485c..8930de08 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIPluginListStub.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIPluginListStub.java @@ -65,6 +65,8 @@ public class CSIPluginListStub { @SerializedName(SERIALIZED_NAME_PROVIDER) private String provider; + public CSIPluginListStub() { + } public CSIPluginListStub controllerRequired(Boolean controllerRequired) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSISnapshot.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSISnapshot.java index 4e0ec947..40325dab 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSISnapshot.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSISnapshot.java @@ -72,6 +72,8 @@ public class CSISnapshot { @SerializedName(SERIALIZED_NAME_SOURCE_VOLUME_I_D) private String sourceVolumeID; + public CSISnapshot() { + } public CSISnapshot createTime(Long createTime) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSISnapshotCreateRequest.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSISnapshotCreateRequest.java index 7ee5df06..d65186f7 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSISnapshotCreateRequest.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSISnapshotCreateRequest.java @@ -48,6 +48,8 @@ public class CSISnapshotCreateRequest { @SerializedName(SERIALIZED_NAME_SNAPSHOTS) private List snapshots = null; + public CSISnapshotCreateRequest() { + } public CSISnapshotCreateRequest namespace(String namespace) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSISnapshotCreateResponse.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSISnapshotCreateResponse.java index afdf18cb..d8971cac 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSISnapshotCreateResponse.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSISnapshotCreateResponse.java @@ -56,6 +56,8 @@ public class CSISnapshotCreateResponse { @SerializedName(SERIALIZED_NAME_SNAPSHOTS) private List snapshots = null; + public CSISnapshotCreateResponse() { + } public CSISnapshotCreateResponse knownLeader(Boolean knownLeader) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSISnapshotListResponse.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSISnapshotListResponse.java index c102fed1..d2c2b46a 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSISnapshotListResponse.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSISnapshotListResponse.java @@ -56,6 +56,8 @@ public class CSISnapshotListResponse { @SerializedName(SERIALIZED_NAME_SNAPSHOTS) private List snapshots = null; + public CSISnapshotListResponse() { + } public CSISnapshotListResponse knownLeader(Boolean knownLeader) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSITopology.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSITopology.java index 2c2462a0..9fd79300 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSITopology.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSITopology.java @@ -36,6 +36,8 @@ public class CSITopology { @SerializedName(SERIALIZED_NAME_SEGMENTS) private Map segments = null; + public CSITopology() { + } public CSITopology segments(Map segments) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSITopologyRequest.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSITopologyRequest.java index ef1c9eac..7b38b711 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSITopologyRequest.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSITopologyRequest.java @@ -40,6 +40,8 @@ public class CSITopologyRequest { @SerializedName(SERIALIZED_NAME_REQUIRED) private List required = null; + public CSITopologyRequest() { + } public CSITopologyRequest preferred(List preferred) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIVolume.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIVolume.java index 53a4e87f..97a0f0b9 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIVolume.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIVolume.java @@ -33,6 +33,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; /** @@ -172,6 +173,8 @@ public class CSIVolume { @SerializedName(SERIALIZED_NAME_WRITE_ALLOCS) private Map writeAllocs = null; + public CSIVolume() { + } public CSIVolume accessMode(String accessMode) { @@ -1044,11 +1047,22 @@ public boolean equals(Object o) { Objects.equals(this.writeAllocs, csIVolume.writeAllocs); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(accessMode, allocations, attachmentMode, capacity, cloneID, context, controllerRequired, controllersExpected, controllersHealthy, createIndex, externalID, ID, modifyIndex, mountOptions, name, namespace, nodesExpected, nodesHealthy, parameters, pluginID, provider, providerVersion, readAllocs, requestedCapabilities, requestedCapacityMax, requestedCapacityMin, requestedTopologies, resourceExhausted, schedulable, secrets, snapshotID, topologies, writeAllocs); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIVolumeCapability.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIVolumeCapability.java index 518ad47d..038a6bed 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIVolumeCapability.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIVolumeCapability.java @@ -37,6 +37,8 @@ public class CSIVolumeCapability { @SerializedName(SERIALIZED_NAME_ATTACHMENT_MODE) private String attachmentMode; + public CSIVolumeCapability() { + } public CSIVolumeCapability accessMode(String accessMode) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIVolumeCreateRequest.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIVolumeCreateRequest.java index ff5e1e98..38353710 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIVolumeCreateRequest.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIVolumeCreateRequest.java @@ -48,6 +48,8 @@ public class CSIVolumeCreateRequest { @SerializedName(SERIALIZED_NAME_VOLUMES) private List volumes = null; + public CSIVolumeCreateRequest() { + } public CSIVolumeCreateRequest namespace(String namespace) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIVolumeExternalStub.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIVolumeExternalStub.java index 4f249f48..b21656c8 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIVolumeExternalStub.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIVolumeExternalStub.java @@ -65,6 +65,8 @@ public class CSIVolumeExternalStub { @SerializedName(SERIALIZED_NAME_VOLUME_CONTEXT) private Map volumeContext = null; + public CSIVolumeExternalStub() { + } public CSIVolumeExternalStub capacityBytes(Long capacityBytes) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIVolumeListExternalResponse.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIVolumeListExternalResponse.java index 6d114cc6..26f85f9a 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIVolumeListExternalResponse.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIVolumeListExternalResponse.java @@ -40,6 +40,8 @@ public class CSIVolumeListExternalResponse { @SerializedName(SERIALIZED_NAME_VOLUMES) private List volumes = null; + public CSIVolumeListExternalResponse() { + } public CSIVolumeListExternalResponse nextToken(String nextToken) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIVolumeListStub.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIVolumeListStub.java index 19a9db4a..46e0bdd9 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIVolumeListStub.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIVolumeListStub.java @@ -26,6 +26,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; /** @@ -105,6 +106,8 @@ public class CSIVolumeListStub { @SerializedName(SERIALIZED_NAME_TOPOLOGIES) private List topologies = null; + public CSIVolumeListStub() { + } public CSIVolumeListStub accessMode(String accessMode) { @@ -561,11 +564,22 @@ public boolean equals(Object o) { Objects.equals(this.topologies, csIVolumeListStub.topologies); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(accessMode, attachmentMode, controllerRequired, controllersExpected, controllersHealthy, createIndex, externalID, ID, modifyIndex, name, namespace, nodesExpected, nodesHealthy, pluginID, provider, resourceExhausted, schedulable, topologies); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIVolumeRegisterRequest.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIVolumeRegisterRequest.java index 6db8919d..7082ae00 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIVolumeRegisterRequest.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/CSIVolumeRegisterRequest.java @@ -48,6 +48,8 @@ public class CSIVolumeRegisterRequest { @SerializedName(SERIALIZED_NAME_VOLUMES) private List volumes = null; + public CSIVolumeRegisterRequest() { + } public CSIVolumeRegisterRequest namespace(String namespace) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/CheckRestart.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/CheckRestart.java index 75c781ed..a2eb6ed5 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/CheckRestart.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/CheckRestart.java @@ -41,6 +41,8 @@ public class CheckRestart { @SerializedName(SERIALIZED_NAME_LIMIT) private Integer limit; + public CheckRestart() { + } public CheckRestart grace(Long grace) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/Constraint.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/Constraint.java index 5714cbc7..aa4b5474 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/Constraint.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/Constraint.java @@ -41,6 +41,8 @@ public class Constraint { @SerializedName(SERIALIZED_NAME_RTARGET) private String rtarget; + public Constraint() { + } public Constraint ltarget(String ltarget) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/Consul.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/Consul.java index 5c33fcdd..ececbb00 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/Consul.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/Consul.java @@ -33,6 +33,8 @@ public class Consul { @SerializedName(SERIALIZED_NAME_NAMESPACE) private String namespace; + public Consul() { + } public Consul namespace(String namespace) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulConnect.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulConnect.java index 6667f03d..46cc64a7 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulConnect.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulConnect.java @@ -26,6 +26,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; /** * ConsulConnect @@ -48,6 +49,8 @@ public class ConsulConnect { @SerializedName(SERIALIZED_NAME_SIDECAR_TASK) private SidecarTask sidecarTask; + public ConsulConnect() { + } public ConsulConnect gateway(ConsulGateway gateway) { @@ -156,11 +159,22 @@ public boolean equals(Object o) { Objects.equals(this.sidecarTask, consulConnect.sidecarTask); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(gateway, _native, sidecarService, sidecarTask); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulExposeConfig.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulExposeConfig.java index 90ed963c..68ee29aa 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulExposeConfig.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulExposeConfig.java @@ -36,6 +36,8 @@ public class ConsulExposeConfig { @SerializedName(SERIALIZED_NAME_PATH) private List path = null; + public ConsulExposeConfig() { + } public ConsulExposeConfig path(List path) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulExposePath.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulExposePath.java index e38d4981..571a42b7 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulExposePath.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulExposePath.java @@ -45,6 +45,8 @@ public class ConsulExposePath { @SerializedName(SERIALIZED_NAME_PROTOCOL) private String protocol; + public ConsulExposePath() { + } public ConsulExposePath listenerPort(String listenerPort) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulGateway.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulGateway.java index 51b66ab2..c8138790 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulGateway.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulGateway.java @@ -26,6 +26,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; /** * ConsulGateway @@ -48,6 +49,8 @@ public class ConsulGateway { @SerializedName(SERIALIZED_NAME_TERMINATING) private ConsulTerminatingConfigEntry terminating; + public ConsulGateway() { + } public ConsulGateway ingress(ConsulIngressConfigEntry ingress) { @@ -156,11 +159,22 @@ public boolean equals(Object o) { Objects.equals(this.terminating, consulGateway.terminating); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(ingress, mesh, proxy, terminating); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulGatewayBindAddress.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulGatewayBindAddress.java index b0d905ac..3e86de98 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulGatewayBindAddress.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulGatewayBindAddress.java @@ -41,6 +41,8 @@ public class ConsulGatewayBindAddress { @SerializedName(SERIALIZED_NAME_PORT) private Integer port; + public ConsulGatewayBindAddress() { + } public ConsulGatewayBindAddress address(String address) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulGatewayProxy.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulGatewayProxy.java index b533339a..adba0266 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulGatewayProxy.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulGatewayProxy.java @@ -57,6 +57,8 @@ public class ConsulGatewayProxy { @SerializedName(SERIALIZED_NAME_ENVOY_GATEWAY_NO_DEFAULT_BIND) private Boolean envoyGatewayNoDefaultBind; + public ConsulGatewayProxy() { + } public ConsulGatewayProxy config(Map config) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulGatewayTLSConfig.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulGatewayTLSConfig.java index 1e03a090..1fd03583 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulGatewayTLSConfig.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulGatewayTLSConfig.java @@ -47,6 +47,8 @@ public class ConsulGatewayTLSConfig { @SerializedName(SERIALIZED_NAME_TL_S_MIN_VERSION) private String tlSMinVersion; + public ConsulGatewayTLSConfig() { + } public ConsulGatewayTLSConfig cipherSuites(List cipherSuites) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulIngressConfigEntry.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulIngressConfigEntry.java index e0a56194..54863d63 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulIngressConfigEntry.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulIngressConfigEntry.java @@ -27,6 +27,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import org.openapitools.jackson.nullable.JsonNullable; /** * ConsulIngressConfigEntry @@ -41,6 +42,8 @@ public class ConsulIngressConfigEntry { @SerializedName(SERIALIZED_NAME_T_L_S) private ConsulGatewayTLSConfig TLS; + public ConsulIngressConfigEntry() { + } public ConsulIngressConfigEntry listeners(List listeners) { @@ -109,11 +112,22 @@ public boolean equals(Object o) { Objects.equals(this.TLS, consulIngressConfigEntry.TLS); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(listeners, TLS); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulIngressListener.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulIngressListener.java index 52017f5d..e4fc7187 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulIngressListener.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulIngressListener.java @@ -44,6 +44,8 @@ public class ConsulIngressListener { @SerializedName(SERIALIZED_NAME_SERVICES) private List services = null; + public ConsulIngressListener() { + } public ConsulIngressListener port(Integer port) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulIngressService.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulIngressService.java index 42ee7e78..cfcfea10 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulIngressService.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulIngressService.java @@ -39,6 +39,8 @@ public class ConsulIngressService { @SerializedName(SERIALIZED_NAME_NAME) private String name; + public ConsulIngressService() { + } public ConsulIngressService hosts(List hosts) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulLinkedService.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulLinkedService.java index 2ecffaba..5e9238d4 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulLinkedService.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulLinkedService.java @@ -49,6 +49,8 @@ public class ConsulLinkedService { @SerializedName(SERIALIZED_NAME_S_N_I) private String SNI; + public ConsulLinkedService() { + } public ConsulLinkedService caFile(String caFile) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulMeshGateway.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulMeshGateway.java index 7d349b46..45e4ceb8 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulMeshGateway.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulMeshGateway.java @@ -33,6 +33,8 @@ public class ConsulMeshGateway { @SerializedName(SERIALIZED_NAME_MODE) private String mode; + public ConsulMeshGateway() { + } public ConsulMeshGateway mode(String mode) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulProxy.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulProxy.java index 8362030b..92dfcdc2 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulProxy.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulProxy.java @@ -29,6 +29,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; /** * ConsulProxy @@ -55,6 +56,8 @@ public class ConsulProxy { @SerializedName(SERIALIZED_NAME_UPSTREAMS) private List upstreams = null; + public ConsulProxy() { + } public ConsulProxy config(Map config) { @@ -203,11 +206,22 @@ public boolean equals(Object o) { Objects.equals(this.upstreams, consulProxy.upstreams); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(config, exposeConfig, localServiceAddress, localServicePort, upstreams); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulSidecarService.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulSidecarService.java index 5d4f977e..ecc573ca 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulSidecarService.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulSidecarService.java @@ -26,6 +26,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import org.openapitools.jackson.nullable.JsonNullable; /** * ConsulSidecarService @@ -48,6 +49,8 @@ public class ConsulSidecarService { @SerializedName(SERIALIZED_NAME_TAGS) private List tags = null; + public ConsulSidecarService() { + } public ConsulSidecarService disableDefaultTCPCheck(Boolean disableDefaultTCPCheck) { @@ -164,11 +167,22 @@ public boolean equals(Object o) { Objects.equals(this.tags, consulSidecarService.tags); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(disableDefaultTCPCheck, port, proxy, tags); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulTerminatingConfigEntry.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulTerminatingConfigEntry.java index 69049d52..70833358 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulTerminatingConfigEntry.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulTerminatingConfigEntry.java @@ -36,6 +36,8 @@ public class ConsulTerminatingConfigEntry { @SerializedName(SERIALIZED_NAME_SERVICES) private List services = null; + public ConsulTerminatingConfigEntry() { + } public ConsulTerminatingConfigEntry services(List services) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulUpstream.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulUpstream.java index b41e7c5d..cebf09cb 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulUpstream.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/ConsulUpstream.java @@ -24,6 +24,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; /** * ConsulUpstream @@ -54,6 +55,8 @@ public class ConsulUpstream { @SerializedName(SERIALIZED_NAME_MESH_GATEWAY) private ConsulMeshGateway meshGateway; + public ConsulUpstream() { + } public ConsulUpstream datacenter(String datacenter) { @@ -210,11 +213,22 @@ public boolean equals(Object o) { Objects.equals(this.meshGateway, consulUpstream.meshGateway); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(datacenter, destinationName, destinationNamespace, localBindAddress, localBindPort, meshGateway); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/DNSConfig.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/DNSConfig.java index 30118980..e021440d 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/DNSConfig.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/DNSConfig.java @@ -43,6 +43,8 @@ public class DNSConfig { @SerializedName(SERIALIZED_NAME_SERVERS) private List servers = null; + public DNSConfig() { + } public DNSConfig options(List options) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/Deployment.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/Deployment.java index 9ad5cb93..c6e3a44a 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/Deployment.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/Deployment.java @@ -85,6 +85,8 @@ public class Deployment { @SerializedName(SERIALIZED_NAME_TASK_GROUPS) private Map taskGroups = null; + public Deployment() { + } public Deployment createIndex(Integer createIndex) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/DeploymentAllocHealthRequest.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/DeploymentAllocHealthRequest.java index 223f1505..53be8ece 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/DeploymentAllocHealthRequest.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/DeploymentAllocHealthRequest.java @@ -55,6 +55,8 @@ public class DeploymentAllocHealthRequest { @SerializedName(SERIALIZED_NAME_UNHEALTHY_ALLOCATION_I_DS) private List unhealthyAllocationIDs = null; + public DeploymentAllocHealthRequest() { + } public DeploymentAllocHealthRequest deploymentID(String deploymentID) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/DeploymentPauseRequest.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/DeploymentPauseRequest.java index 946e1f40..61d00148 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/DeploymentPauseRequest.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/DeploymentPauseRequest.java @@ -49,6 +49,8 @@ public class DeploymentPauseRequest { @SerializedName(SERIALIZED_NAME_SECRET_I_D) private String secretID; + public DeploymentPauseRequest() { + } public DeploymentPauseRequest deploymentID(String deploymentID) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/DeploymentPromoteRequest.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/DeploymentPromoteRequest.java index a7181680..3d54772b 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/DeploymentPromoteRequest.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/DeploymentPromoteRequest.java @@ -55,6 +55,8 @@ public class DeploymentPromoteRequest { @SerializedName(SERIALIZED_NAME_SECRET_I_D) private String secretID; + public DeploymentPromoteRequest() { + } public DeploymentPromoteRequest all(Boolean all) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/DeploymentState.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/DeploymentState.java index 6d47d7dd..3dbff2e5 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/DeploymentState.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/DeploymentState.java @@ -25,6 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; /** @@ -72,6 +73,8 @@ public class DeploymentState { @SerializedName(SERIALIZED_NAME_UNHEALTHY_ALLOCS) private Integer unhealthyAllocs; + public DeploymentState() { + } public DeploymentState autoRevert(Boolean autoRevert) { @@ -332,11 +335,22 @@ public boolean equals(Object o) { Objects.equals(this.unhealthyAllocs, deploymentState.unhealthyAllocs); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(autoRevert, desiredCanaries, desiredTotal, healthyAllocs, placedAllocs, placedCanaries, progressDeadline, promoted, requireProgressBy, unhealthyAllocs); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/DeploymentUnblockRequest.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/DeploymentUnblockRequest.java index 2bdbdb19..a1de0505 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/DeploymentUnblockRequest.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/DeploymentUnblockRequest.java @@ -45,6 +45,8 @@ public class DeploymentUnblockRequest { @SerializedName(SERIALIZED_NAME_SECRET_I_D) private String secretID; + public DeploymentUnblockRequest() { + } public DeploymentUnblockRequest deploymentID(String deploymentID) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/DeploymentUpdateResponse.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/DeploymentUpdateResponse.java index d41e1ea5..04126803 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/DeploymentUpdateResponse.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/DeploymentUpdateResponse.java @@ -53,6 +53,8 @@ public class DeploymentUpdateResponse { @SerializedName(SERIALIZED_NAME_REVERTED_JOB_VERSION) private Integer revertedJobVersion; + public DeploymentUpdateResponse() { + } public DeploymentUpdateResponse deploymentModifyIndex(Integer deploymentModifyIndex) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/DesiredTransition.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/DesiredTransition.java index 01530089..999234b6 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/DesiredTransition.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/DesiredTransition.java @@ -37,6 +37,8 @@ public class DesiredTransition { @SerializedName(SERIALIZED_NAME_RESCHEDULE) private Boolean reschedule; + public DesiredTransition() { + } public DesiredTransition migrate(Boolean migrate) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/DesiredUpdates.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/DesiredUpdates.java index 67e60136..4c60d1e2 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/DesiredUpdates.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/DesiredUpdates.java @@ -61,6 +61,8 @@ public class DesiredUpdates { @SerializedName(SERIALIZED_NAME_STOP) private Integer stop; + public DesiredUpdates() { + } public DesiredUpdates canary(Integer canary) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/DispatchPayloadConfig.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/DispatchPayloadConfig.java index 75f4cedc..44e13efd 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/DispatchPayloadConfig.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/DispatchPayloadConfig.java @@ -31,29 +31,31 @@ public class DispatchPayloadConfig { public static final String SERIALIZED_NAME_FILE = "File"; @SerializedName(SERIALIZED_NAME_FILE) - private String file; + private String _file; + public DispatchPayloadConfig() { + } - public DispatchPayloadConfig file(String file) { + public DispatchPayloadConfig _file(String _file) { - this.file = file; + this._file = _file; return this; } /** - * Get file - * @return file + * Get _file + * @return _file **/ @javax.annotation.Nullable @ApiModelProperty(value = "") public String getFile() { - return file; + return _file; } - public void setFile(String file) { - this.file = file; + public void setFile(String _file) { + this._file = _file; } @@ -66,19 +68,19 @@ public boolean equals(Object o) { return false; } DispatchPayloadConfig dispatchPayloadConfig = (DispatchPayloadConfig) o; - return Objects.equals(this.file, dispatchPayloadConfig.file); + return Objects.equals(this._file, dispatchPayloadConfig._file); } @Override public int hashCode() { - return Objects.hash(file); + return Objects.hash(_file); } @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class DispatchPayloadConfig {\n"); - sb.append(" file: ").append(toIndentedString(file)).append("\n"); + sb.append(" _file: ").append(toIndentedString(_file)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/DrainMetadata.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/DrainMetadata.java index a29495fe..1849ab79 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/DrainMetadata.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/DrainMetadata.java @@ -26,6 +26,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; /** @@ -53,6 +54,8 @@ public class DrainMetadata { @SerializedName(SERIALIZED_NAME_UPDATED_AT) private OffsetDateTime updatedAt; + public DrainMetadata() { + } public DrainMetadata accessorID(String accessorID) { @@ -193,11 +196,22 @@ public boolean equals(Object o) { Objects.equals(this.updatedAt, drainMetadata.updatedAt); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(accessorID, meta, startedAt, status, updatedAt); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/DrainSpec.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/DrainSpec.java index a84c9d9b..fbecb4d8 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/DrainSpec.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/DrainSpec.java @@ -37,6 +37,8 @@ public class DrainSpec { @SerializedName(SERIALIZED_NAME_IGNORE_SYSTEM_JOBS) private Boolean ignoreSystemJobs; + public DrainSpec() { + } public DrainSpec deadline(Long deadline) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/DrainStrategy.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/DrainStrategy.java index 461f190f..2b51a038 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/DrainStrategy.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/DrainStrategy.java @@ -23,6 +23,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; /** @@ -46,6 +47,8 @@ public class DrainStrategy { @SerializedName(SERIALIZED_NAME_STARTED_AT) private OffsetDateTime startedAt; + public DrainStrategy() { + } public DrainStrategy deadline(Long deadline) { @@ -154,11 +157,22 @@ public boolean equals(Object o) { Objects.equals(this.startedAt, drainStrategy.startedAt); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(deadline, forceDeadline, ignoreSystemJobs, startedAt); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/DriverInfo.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/DriverInfo.java index 367ada33..95bfd5ef 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/DriverInfo.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/DriverInfo.java @@ -26,6 +26,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; /** @@ -53,6 +54,8 @@ public class DriverInfo { @SerializedName(SERIALIZED_NAME_UPDATE_TIME) private OffsetDateTime updateTime; + public DriverInfo() { + } public DriverInfo attributes(Map attributes) { @@ -193,11 +196,22 @@ public boolean equals(Object o) { Objects.equals(this.updateTime, driverInfo.updateTime); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(attributes, detected, healthDescription, healthy, updateTime); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/EphemeralDisk.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/EphemeralDisk.java index b3e7d9f7..e9daa7a9 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/EphemeralDisk.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/EphemeralDisk.java @@ -41,6 +41,8 @@ public class EphemeralDisk { @SerializedName(SERIALIZED_NAME_STICKY) private Boolean sticky; + public EphemeralDisk() { + } public EphemeralDisk migrate(Boolean migrate) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/EvalOptions.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/EvalOptions.java index cde516b6..809f1ef1 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/EvalOptions.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/EvalOptions.java @@ -33,6 +33,8 @@ public class EvalOptions { @SerializedName(SERIALIZED_NAME_FORCE_RESCHEDULE) private Boolean forceReschedule; + public EvalOptions() { + } public EvalOptions forceReschedule(Boolean forceReschedule) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/Evaluation.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/Evaluation.java index fe92e168..69fae417 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/Evaluation.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/Evaluation.java @@ -29,6 +29,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; /** @@ -152,6 +153,8 @@ public class Evaluation { @SerializedName(SERIALIZED_NAME_WAIT_UNTIL) private OffsetDateTime waitUntil; + public Evaluation() { + } public Evaluation annotatePlan(Boolean annotatePlan) { @@ -902,11 +905,22 @@ public boolean equals(Object o) { Objects.equals(this.waitUntil, evaluation.waitUntil); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(annotatePlan, blockedEval, classEligibility, createIndex, createTime, deploymentID, escapedComputedClass, failedTGAllocs, ID, jobID, jobModifyIndex, modifyIndex, modifyTime, namespace, nextEval, nodeID, nodeModifyIndex, previousEval, priority, queuedAllocations, quotaLimitReached, relatedEvals, snapshotIndex, status, statusDescription, triggeredBy, type, wait, waitUntil); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/EvaluationStub.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/EvaluationStub.java index b716bfb4..5e58fca1 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/EvaluationStub.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/EvaluationStub.java @@ -23,6 +23,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; /** @@ -102,6 +103,8 @@ public class EvaluationStub { @SerializedName(SERIALIZED_NAME_WAIT_UNTIL) private OffsetDateTime waitUntil; + public EvaluationStub() { + } public EvaluationStub blockedEval(String blockedEval) { @@ -550,11 +553,22 @@ public boolean equals(Object o) { Objects.equals(this.waitUntil, evaluationStub.waitUntil); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(blockedEval, createIndex, createTime, deploymentID, ID, jobID, modifyIndex, modifyTime, namespace, nextEval, nodeID, previousEval, priority, status, statusDescription, triggeredBy, type, waitUntil); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/FieldDiff.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/FieldDiff.java index 0ac826c0..ebb239ba 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/FieldDiff.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/FieldDiff.java @@ -51,6 +51,8 @@ public class FieldDiff { @SerializedName(SERIALIZED_NAME_TYPE) private String type; + public FieldDiff() { + } public FieldDiff annotations(List annotations) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/FuzzyMatch.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/FuzzyMatch.java index 4be39fe5..93c36992 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/FuzzyMatch.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/FuzzyMatch.java @@ -39,6 +39,8 @@ public class FuzzyMatch { @SerializedName(SERIALIZED_NAME_SCOPE) private List scope = null; + public FuzzyMatch() { + } public FuzzyMatch ID(String ID) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/FuzzySearchRequest.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/FuzzySearchRequest.java index 113de303..eb74868e 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/FuzzySearchRequest.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/FuzzySearchRequest.java @@ -92,6 +92,8 @@ public class FuzzySearchRequest { @SerializedName(SERIALIZED_NAME_WAIT_TIME) private Long waitTime; + public FuzzySearchRequest() { + } public FuzzySearchRequest allowStale(Boolean allowStale) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/FuzzySearchResponse.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/FuzzySearchResponse.java index a7ee632c..c4b70bc7 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/FuzzySearchResponse.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/FuzzySearchResponse.java @@ -61,6 +61,8 @@ public class FuzzySearchResponse { @SerializedName(SERIALIZED_NAME_TRUNCATIONS) private Map truncations = null; + public FuzzySearchResponse() { + } public FuzzySearchResponse knownLeader(Boolean knownLeader) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/GaugeValue.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/GaugeValue.java index 64ecf37e..fd60b068 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/GaugeValue.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/GaugeValue.java @@ -44,6 +44,8 @@ public class GaugeValue { @SerializedName(SERIALIZED_NAME_VALUE) private Float value; + public GaugeValue() { + } public GaugeValue labels(Map labels) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/HostNetworkInfo.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/HostNetworkInfo.java index 67f92add..38cba152 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/HostNetworkInfo.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/HostNetworkInfo.java @@ -45,6 +45,8 @@ public class HostNetworkInfo { @SerializedName(SERIALIZED_NAME_RESERVED_PORTS) private String reservedPorts; + public HostNetworkInfo() { + } public HostNetworkInfo CIDR(String CIDR) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/HostVolumeInfo.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/HostVolumeInfo.java index 87470f9f..320cd57e 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/HostVolumeInfo.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/HostVolumeInfo.java @@ -37,6 +37,8 @@ public class HostVolumeInfo { @SerializedName(SERIALIZED_NAME_READ_ONLY) private Boolean readOnly; + public HostVolumeInfo() { + } public HostVolumeInfo path(String path) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/Job.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/Job.java index 6cf0977a..dc74410f 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/Job.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/Job.java @@ -37,6 +37,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; /** * Job @@ -191,6 +192,8 @@ public class Job { @SerializedName(SERIALIZED_NAME_VERSION) private Integer version; + public Job() { + } public Job affinities(List affinities) { @@ -1147,11 +1150,22 @@ public boolean equals(Object o) { Objects.equals(this.version, job.version); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(affinities, allAtOnce, constraints, consulNamespace, consulToken, createIndex, datacenters, dispatchIdempotencyToken, dispatched, ID, jobModifyIndex, meta, migrate, modifyIndex, multiregion, name, namespace, nomadTokenID, parameterizedJob, parentID, Arrays.hashCode(payload), periodic, priority, region, reschedule, spreads, stable, status, statusDescription, stop, submitTime, taskGroups, type, update, vaultNamespace, vaultToken, version); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobChildrenSummary.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobChildrenSummary.java index af02e83e..9672fcdf 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobChildrenSummary.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobChildrenSummary.java @@ -41,6 +41,8 @@ public class JobChildrenSummary { @SerializedName(SERIALIZED_NAME_RUNNING) private Long running; + public JobChildrenSummary() { + } public JobChildrenSummary dead(Long dead) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobDeregisterResponse.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobDeregisterResponse.java index d13f3521..68d90672 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobDeregisterResponse.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobDeregisterResponse.java @@ -61,6 +61,8 @@ public class JobDeregisterResponse { @SerializedName(SERIALIZED_NAME_REQUEST_TIME) private Long requestTime; + public JobDeregisterResponse() { + } public JobDeregisterResponse evalCreateIndex(Integer evalCreateIndex) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobDiff.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobDiff.java index 86f8e56d..e643bc7a 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobDiff.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobDiff.java @@ -54,6 +54,8 @@ public class JobDiff { @SerializedName(SERIALIZED_NAME_TYPE) private String type; + public JobDiff() { + } public JobDiff fields(List fields) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobDispatchRequest.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobDispatchRequest.java index b6ba6b0e..ae95aeff 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobDispatchRequest.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobDispatchRequest.java @@ -44,6 +44,8 @@ public class JobDispatchRequest { @SerializedName(SERIALIZED_NAME_PAYLOAD) private byte[] payload; + public JobDispatchRequest() { + } public JobDispatchRequest jobID(String jobID) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobDispatchResponse.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobDispatchResponse.java index 4aabdb6a..4a5871ba 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobDispatchResponse.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobDispatchResponse.java @@ -53,6 +53,8 @@ public class JobDispatchResponse { @SerializedName(SERIALIZED_NAME_REQUEST_TIME) private Long requestTime; + public JobDispatchResponse() { + } public JobDispatchResponse dispatchedJobID(String dispatchedJobID) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobEvaluateRequest.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobEvaluateRequest.java index 8fd49459..72a3d57f 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobEvaluateRequest.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobEvaluateRequest.java @@ -24,6 +24,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; /** * JobEvaluateRequest @@ -50,6 +51,8 @@ public class JobEvaluateRequest { @SerializedName(SERIALIZED_NAME_SECRET_I_D) private String secretID; + public JobEvaluateRequest() { + } public JobEvaluateRequest evalOptions(EvalOptions evalOptions) { @@ -182,11 +185,22 @@ public boolean equals(Object o) { Objects.equals(this.secretID, jobEvaluateRequest.secretID); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(evalOptions, jobID, namespace, region, secretID); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobListStub.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobListStub.java index 9a785439..82fefe26 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobListStub.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobListStub.java @@ -26,6 +26,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import org.openapitools.jackson.nullable.JsonNullable; /** * JobListStub @@ -100,6 +101,8 @@ public class JobListStub { @SerializedName(SERIALIZED_NAME_TYPE) private String type; + public JobListStub() { + } public JobListStub createIndex(Integer createIndex) { @@ -534,11 +537,22 @@ public boolean equals(Object o) { Objects.equals(this.type, jobListStub.type); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(createIndex, datacenters, ID, jobModifyIndex, jobSummary, modifyIndex, name, namespace, parameterizedJob, parentID, periodic, priority, status, statusDescription, stop, submitTime, type); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobPlanRequest.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobPlanRequest.java index b388e5aa..33620360 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobPlanRequest.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobPlanRequest.java @@ -24,6 +24,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; /** * JobPlanRequest @@ -54,6 +55,8 @@ public class JobPlanRequest { @SerializedName(SERIALIZED_NAME_SECRET_I_D) private String secretID; + public JobPlanRequest() { + } public JobPlanRequest diff(Boolean diff) { @@ -210,11 +213,22 @@ public boolean equals(Object o) { Objects.equals(this.secretID, jobPlanRequest.secretID); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(diff, job, namespace, policyOverride, region, secretID); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobPlanResponse.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobPlanResponse.java index 6654e9ba..a1c491a2 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobPlanResponse.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobPlanResponse.java @@ -31,6 +31,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; /** @@ -66,6 +67,8 @@ public class JobPlanResponse { @SerializedName(SERIALIZED_NAME_WARNINGS) private String warnings; + public JobPlanResponse() { + } public JobPlanResponse annotations(PlanAnnotations annotations) { @@ -264,11 +267,22 @@ public boolean equals(Object o) { Objects.equals(this.warnings, jobPlanResponse.warnings); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(annotations, createdEvals, diff, failedTGAllocs, jobModifyIndex, nextPeriodicLaunch, warnings); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobRegisterRequest.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobRegisterRequest.java index f7dfb1d2..369422c0 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobRegisterRequest.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobRegisterRequest.java @@ -24,6 +24,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; /** * JobRegisterRequest @@ -66,6 +67,8 @@ public class JobRegisterRequest { @SerializedName(SERIALIZED_NAME_SECRET_I_D) private String secretID; + public JobRegisterRequest() { + } public JobRegisterRequest enforceIndex(Boolean enforceIndex) { @@ -296,11 +299,22 @@ public boolean equals(Object o) { Objects.equals(this.secretID, jobRegisterRequest.secretID); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(enforceIndex, evalPriority, job, jobModifyIndex, namespace, policyOverride, preserveCounts, region, secretID); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobRegisterResponse.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobRegisterResponse.java index bd7744ce..0f71deb4 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobRegisterResponse.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobRegisterResponse.java @@ -65,6 +65,8 @@ public class JobRegisterResponse { @SerializedName(SERIALIZED_NAME_WARNINGS) private String warnings; + public JobRegisterResponse() { + } public JobRegisterResponse evalCreateIndex(Integer evalCreateIndex) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobRevertRequest.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobRevertRequest.java index 5a0358e4..9e656f98 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobRevertRequest.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobRevertRequest.java @@ -61,6 +61,8 @@ public class JobRevertRequest { @SerializedName(SERIALIZED_NAME_VAULT_TOKEN) private String vaultToken; + public JobRevertRequest() { + } public JobRevertRequest consulToken(String consulToken) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobScaleStatusResponse.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobScaleStatusResponse.java index f7c5e9c7..d4a3f0a3 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobScaleStatusResponse.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobScaleStatusResponse.java @@ -57,6 +57,8 @@ public class JobScaleStatusResponse { @SerializedName(SERIALIZED_NAME_TASK_GROUPS) private Map taskGroups = null; + public JobScaleStatusResponse() { + } public JobScaleStatusResponse jobCreateIndex(Integer jobCreateIndex) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobStabilityRequest.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobStabilityRequest.java index 4a444f73..00b5673e 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobStabilityRequest.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobStabilityRequest.java @@ -53,6 +53,8 @@ public class JobStabilityRequest { @SerializedName(SERIALIZED_NAME_STABLE) private Boolean stable; + public JobStabilityRequest() { + } public JobStabilityRequest jobID(String jobID) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobStabilityResponse.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobStabilityResponse.java index b62d82f3..d2b05c36 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobStabilityResponse.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobStabilityResponse.java @@ -33,6 +33,8 @@ public class JobStabilityResponse { @SerializedName(SERIALIZED_NAME_INDEX) private Integer index; + public JobStabilityResponse() { + } public JobStabilityResponse index(Integer index) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobSummary.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobSummary.java index 0e44081e..455d7ac5 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobSummary.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobSummary.java @@ -28,6 +28,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; /** * JobSummary @@ -58,6 +59,8 @@ public class JobSummary { @SerializedName(SERIALIZED_NAME_SUMMARY) private Map summary = null; + public JobSummary() { + } public JobSummary children(JobChildrenSummary children) { @@ -226,11 +229,22 @@ public boolean equals(Object o) { Objects.equals(this.summary, jobSummary.summary); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(children, createIndex, jobID, modifyIndex, namespace, summary); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobValidateRequest.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobValidateRequest.java index 8d29d333..fb7dbfee 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobValidateRequest.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobValidateRequest.java @@ -24,6 +24,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; /** * JobValidateRequest @@ -46,6 +47,8 @@ public class JobValidateRequest { @SerializedName(SERIALIZED_NAME_SECRET_I_D) private String secretID; + public JobValidateRequest() { + } public JobValidateRequest job(Job job) { @@ -154,11 +157,22 @@ public boolean equals(Object o) { Objects.equals(this.secretID, jobValidateRequest.secretID); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(job, namespace, region, secretID); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobValidateResponse.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobValidateResponse.java index e7ded70e..40da8894 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobValidateResponse.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobValidateResponse.java @@ -47,6 +47,8 @@ public class JobValidateResponse { @SerializedName(SERIALIZED_NAME_WARNINGS) private String warnings; + public JobValidateResponse() { + } public JobValidateResponse driverConfigValidated(Boolean driverConfigValidated) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobVersionsResponse.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobVersionsResponse.java index 93e50e5d..e64a90f9 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobVersionsResponse.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobVersionsResponse.java @@ -61,6 +61,8 @@ public class JobVersionsResponse { @SerializedName(SERIALIZED_NAME_VERSIONS) private List versions = null; + public JobVersionsResponse() { + } public JobVersionsResponse diffs(List diffs) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobsParseRequest.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobsParseRequest.java index fec7dfd6..63de3083 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/JobsParseRequest.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/JobsParseRequest.java @@ -41,6 +41,8 @@ public class JobsParseRequest { @SerializedName(SERIALIZED_NAME_HCLV1) private Boolean hclv1; + public JobsParseRequest() { + } public JobsParseRequest canonicalize(Boolean canonicalize) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/LogConfig.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/LogConfig.java index 13e58af2..602ead3b 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/LogConfig.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/LogConfig.java @@ -37,6 +37,8 @@ public class LogConfig { @SerializedName(SERIALIZED_NAME_MAX_FILES) private Integer maxFiles; + public LogConfig() { + } public LogConfig maxFileSizeMB(Integer maxFileSizeMB) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/MetricsSummary.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/MetricsSummary.java index 72436bc3..ace7c301 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/MetricsSummary.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/MetricsSummary.java @@ -54,6 +54,8 @@ public class MetricsSummary { @SerializedName(SERIALIZED_NAME_TIMESTAMP) private String timestamp; + public MetricsSummary() { + } public MetricsSummary counters(List counters) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/MigrateStrategy.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/MigrateStrategy.java index f3c0d9e4..0f341079 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/MigrateStrategy.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/MigrateStrategy.java @@ -45,6 +45,8 @@ public class MigrateStrategy { @SerializedName(SERIALIZED_NAME_MIN_HEALTHY_TIME) private Long minHealthyTime; + public MigrateStrategy() { + } public MigrateStrategy healthCheck(String healthCheck) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/Multiregion.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/Multiregion.java index 39d36611..5ec28e03 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/Multiregion.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/Multiregion.java @@ -41,6 +41,8 @@ public class Multiregion { @SerializedName(SERIALIZED_NAME_STRATEGY) private MultiregionStrategy strategy; + public Multiregion() { + } public Multiregion regions(List regions) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/MultiregionRegion.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/MultiregionRegion.java index 3d43a1a3..de0da24c 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/MultiregionRegion.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/MultiregionRegion.java @@ -49,6 +49,8 @@ public class MultiregionRegion { @SerializedName(SERIALIZED_NAME_NAME) private String name; + public MultiregionRegion() { + } public MultiregionRegion count(Integer count) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/MultiregionStrategy.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/MultiregionStrategy.java index 59dc5560..1f40ec59 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/MultiregionStrategy.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/MultiregionStrategy.java @@ -37,6 +37,8 @@ public class MultiregionStrategy { @SerializedName(SERIALIZED_NAME_ON_FAILURE) private String onFailure; + public MultiregionStrategy() { + } public MultiregionStrategy maxParallel(Integer maxParallel) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/Namespace.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/Namespace.java index 36726f90..d47de372 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/Namespace.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/Namespace.java @@ -27,6 +27,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; /** * Namespace @@ -61,6 +62,8 @@ public class Namespace { @SerializedName(SERIALIZED_NAME_QUOTA) private String quota; + public Namespace() { + } public Namespace capabilities(NamespaceCapabilities capabilities) { @@ -253,11 +256,22 @@ public boolean equals(Object o) { Objects.equals(this.quota, namespace.quota); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(capabilities, createIndex, description, meta, modifyIndex, name, quota); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/NamespaceCapabilities.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/NamespaceCapabilities.java index 5ffacb73..273dce2e 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/NamespaceCapabilities.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/NamespaceCapabilities.java @@ -39,6 +39,8 @@ public class NamespaceCapabilities { @SerializedName(SERIALIZED_NAME_ENABLED_TASK_DRIVERS) private List enabledTaskDrivers = null; + public NamespaceCapabilities() { + } public NamespaceCapabilities disabledTaskDrivers(List disabledTaskDrivers) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/NetworkResource.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/NetworkResource.java index d264692f..52e839f9 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/NetworkResource.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/NetworkResource.java @@ -27,6 +27,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import org.openapitools.jackson.nullable.JsonNullable; /** * NetworkResource @@ -69,6 +70,8 @@ public class NetworkResource { @SerializedName(SERIALIZED_NAME_RESERVED_PORTS) private List reservedPorts = null; + public NetworkResource() { + } public NetworkResource CIDR(String CIDR) { @@ -313,11 +316,22 @@ public boolean equals(Object o) { Objects.equals(this.reservedPorts, networkResource.reservedPorts); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(CIDR, DNS, device, dynamicPorts, hostname, IP, mbits, mode, reservedPorts); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/Node.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/Node.java index 1d306930..cc512736 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/Node.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/Node.java @@ -37,6 +37,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; /** * Node @@ -159,6 +160,8 @@ public class Node { @SerializedName(SERIALIZED_NAME_TL_S_ENABLED) private Boolean tlSEnabled; + public Node() { + } public Node attributes(Map attributes) { @@ -943,11 +946,22 @@ public boolean equals(Object o) { Objects.equals(this.tlSEnabled, node.tlSEnabled); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(attributes, csIControllerPlugins, csINodePlugins, cgroupParent, createIndex, datacenter, drain, drainStrategy, drivers, events, htTPAddr, hostNetworks, hostVolumes, ID, lastDrain, links, meta, modifyIndex, name, nodeClass, nodeResources, reserved, reservedResources, resources, schedulingEligibility, status, statusDescription, statusUpdatedAt, tlSEnabled); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeCpuResources.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeCpuResources.java index a53d519f..eaad1027 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeCpuResources.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeCpuResources.java @@ -43,6 +43,8 @@ public class NodeCpuResources { @SerializedName(SERIALIZED_NAME_TOTAL_CPU_CORES) private Integer totalCpuCores; + public NodeCpuResources() { + } public NodeCpuResources cpuShares(Long cpuShares) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeDevice.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeDevice.java index 75823de5..ee64bf8c 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeDevice.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeDevice.java @@ -24,6 +24,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; /** * NodeDevice @@ -46,6 +47,8 @@ public class NodeDevice { @SerializedName(SERIALIZED_NAME_LOCALITY) private NodeDeviceLocality locality; + public NodeDevice() { + } public NodeDevice healthDescription(String healthDescription) { @@ -154,11 +157,22 @@ public boolean equals(Object o) { Objects.equals(this.locality, nodeDevice.locality); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(healthDescription, healthy, ID, locality); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeDeviceLocality.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeDeviceLocality.java index f4983e5f..6f9efa33 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeDeviceLocality.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeDeviceLocality.java @@ -33,6 +33,8 @@ public class NodeDeviceLocality { @SerializedName(SERIALIZED_NAME_PCI_BUS_I_D) private String pciBusID; + public NodeDeviceLocality() { + } public NodeDeviceLocality pciBusID(String pciBusID) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeDeviceResource.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeDeviceResource.java index 3981cb13..db9873b1 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeDeviceResource.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeDeviceResource.java @@ -55,6 +55,8 @@ public class NodeDeviceResource { @SerializedName(SERIALIZED_NAME_VENDOR) private String vendor; + public NodeDeviceResource() { + } public NodeDeviceResource attributes(Map attributes) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeDiskResources.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeDiskResources.java index 5a78f8be..7530b1de 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeDiskResources.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeDiskResources.java @@ -33,6 +33,8 @@ public class NodeDiskResources { @SerializedName(SERIALIZED_NAME_DISK_M_B) private Long diskMB; + public NodeDiskResources() { + } public NodeDiskResources diskMB(Long diskMB) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeDrainUpdateResponse.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeDrainUpdateResponse.java index c5058e30..3ada75ab 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeDrainUpdateResponse.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeDrainUpdateResponse.java @@ -51,6 +51,8 @@ public class NodeDrainUpdateResponse { @SerializedName(SERIALIZED_NAME_REQUEST_TIME) private Long requestTime; + public NodeDrainUpdateResponse() { + } public NodeDrainUpdateResponse evalCreateIndex(Integer evalCreateIndex) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeEligibilityUpdateResponse.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeEligibilityUpdateResponse.java index 2bac1088..92a51329 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeEligibilityUpdateResponse.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeEligibilityUpdateResponse.java @@ -51,6 +51,8 @@ public class NodeEligibilityUpdateResponse { @SerializedName(SERIALIZED_NAME_REQUEST_TIME) private Long requestTime; + public NodeEligibilityUpdateResponse() { + } public NodeEligibilityUpdateResponse evalCreateIndex(Integer evalCreateIndex) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeEvent.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeEvent.java index 19c8b26b..74138757 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeEvent.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeEvent.java @@ -26,6 +26,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; /** @@ -53,6 +54,8 @@ public class NodeEvent { @SerializedName(SERIALIZED_NAME_TIMESTAMP) private OffsetDateTime timestamp; + public NodeEvent() { + } public NodeEvent createIndex(Integer createIndex) { @@ -195,11 +198,22 @@ public boolean equals(Object o) { Objects.equals(this.timestamp, nodeEvent.timestamp); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(createIndex, details, message, subsystem, timestamp); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeListStub.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeListStub.java index f1995e19..18634057 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeListStub.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeListStub.java @@ -30,6 +30,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; /** * NodeListStub @@ -104,6 +105,8 @@ public class NodeListStub { @SerializedName(SERIALIZED_NAME_VERSION) private String version; + public NodeListStub() { + } public NodeListStub address(String address) { @@ -544,11 +547,22 @@ public boolean equals(Object o) { Objects.equals(this.version, nodeListStub.version); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(address, attributes, createIndex, datacenter, drain, drivers, ID, lastDrain, modifyIndex, name, nodeClass, nodeResources, reservedResources, schedulingEligibility, status, statusDescription, version); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeMemoryResources.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeMemoryResources.java index 4d5db37b..58ce4394 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeMemoryResources.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeMemoryResources.java @@ -33,6 +33,8 @@ public class NodeMemoryResources { @SerializedName(SERIALIZED_NAME_MEMORY_M_B) private Long memoryMB; + public NodeMemoryResources() { + } public NodeMemoryResources memoryMB(Long memoryMB) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodePurgeResponse.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodePurgeResponse.java index 75d7578b..d8a2ae98 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodePurgeResponse.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodePurgeResponse.java @@ -43,6 +43,8 @@ public class NodePurgeResponse { @SerializedName(SERIALIZED_NAME_NODE_MODIFY_INDEX) private Integer nodeModifyIndex; + public NodePurgeResponse() { + } public NodePurgeResponse evalCreateIndex(Integer evalCreateIndex) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeReservedCpuResources.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeReservedCpuResources.java index 38448675..319c12a7 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeReservedCpuResources.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeReservedCpuResources.java @@ -33,6 +33,8 @@ public class NodeReservedCpuResources { @SerializedName(SERIALIZED_NAME_CPU_SHARES) private Integer cpuShares; + public NodeReservedCpuResources() { + } public NodeReservedCpuResources cpuShares(Integer cpuShares) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeReservedDiskResources.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeReservedDiskResources.java index 469a4d6b..1833e7c9 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeReservedDiskResources.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeReservedDiskResources.java @@ -33,6 +33,8 @@ public class NodeReservedDiskResources { @SerializedName(SERIALIZED_NAME_DISK_M_B) private Integer diskMB; + public NodeReservedDiskResources() { + } public NodeReservedDiskResources diskMB(Integer diskMB) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeReservedMemoryResources.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeReservedMemoryResources.java index 942f5aa1..d9f0e9e4 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeReservedMemoryResources.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeReservedMemoryResources.java @@ -33,6 +33,8 @@ public class NodeReservedMemoryResources { @SerializedName(SERIALIZED_NAME_MEMORY_M_B) private Integer memoryMB; + public NodeReservedMemoryResources() { + } public NodeReservedMemoryResources memoryMB(Integer memoryMB) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeReservedNetworkResources.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeReservedNetworkResources.java index 51a22682..244c9011 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeReservedNetworkResources.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeReservedNetworkResources.java @@ -33,6 +33,8 @@ public class NodeReservedNetworkResources { @SerializedName(SERIALIZED_NAME_RESERVED_HOST_PORTS) private String reservedHostPorts; + public NodeReservedNetworkResources() { + } public NodeReservedNetworkResources reservedHostPorts(String reservedHostPorts) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeReservedResources.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeReservedResources.java index 4ab6a112..affa83c5 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeReservedResources.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeReservedResources.java @@ -27,6 +27,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; /** * NodeReservedResources @@ -49,6 +50,8 @@ public class NodeReservedResources { @SerializedName(SERIALIZED_NAME_NETWORKS) private NodeReservedNetworkResources networks; + public NodeReservedResources() { + } public NodeReservedResources cpu(NodeReservedCpuResources cpu) { @@ -157,11 +160,22 @@ public boolean equals(Object o) { Objects.equals(this.networks, nodeReservedResources.networks); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(cpu, disk, memory, networks); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeResources.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeResources.java index f0ee7b7a..686b358d 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeResources.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeResources.java @@ -30,6 +30,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import org.openapitools.jackson.nullable.JsonNullable; /** * NodeResources @@ -64,6 +65,8 @@ public class NodeResources { @SerializedName(SERIALIZED_NAME_NETWORKS) private List networks = null; + public NodeResources() { + } public NodeResources cpu(NodeCpuResources cpu) { @@ -260,11 +263,22 @@ public boolean equals(Object o) { Objects.equals(this.networks, nodeResources.networks); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(cpu, devices, disk, maxDynamicPort, memory, minDynamicPort, networks); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeScoreMeta.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeScoreMeta.java index 9b44c377..d3dfc341 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeScoreMeta.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeScoreMeta.java @@ -44,6 +44,8 @@ public class NodeScoreMeta { @SerializedName(SERIALIZED_NAME_SCORES) private Map scores = null; + public NodeScoreMeta() { + } public NodeScoreMeta nodeID(String nodeID) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeUpdateDrainRequest.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeUpdateDrainRequest.java index 8d194c0d..4cd82bbd 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeUpdateDrainRequest.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeUpdateDrainRequest.java @@ -27,6 +27,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; /** * NodeUpdateDrainRequest @@ -49,6 +50,8 @@ public class NodeUpdateDrainRequest { @SerializedName(SERIALIZED_NAME_NODE_I_D) private String nodeID; + public NodeUpdateDrainRequest() { + } public NodeUpdateDrainRequest drainSpec(DrainSpec drainSpec) { @@ -165,11 +168,22 @@ public boolean equals(Object o) { Objects.equals(this.nodeID, nodeUpdateDrainRequest.nodeID); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(drainSpec, markEligible, meta, nodeID); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeUpdateEligibilityRequest.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeUpdateEligibilityRequest.java index d51f079f..8bad4fbb 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeUpdateEligibilityRequest.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/NodeUpdateEligibilityRequest.java @@ -37,6 +37,8 @@ public class NodeUpdateEligibilityRequest { @SerializedName(SERIALIZED_NAME_NODE_I_D) private String nodeID; + public NodeUpdateEligibilityRequest() { + } public NodeUpdateEligibilityRequest eligibility(String eligibility) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/ObjectDiff.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/ObjectDiff.java index f0d76e24..5c4beeb8 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/ObjectDiff.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/ObjectDiff.java @@ -48,6 +48,8 @@ public class ObjectDiff { @SerializedName(SERIALIZED_NAME_TYPE) private String type; + public ObjectDiff() { + } public ObjectDiff fields(List fields) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/OneTimeToken.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/OneTimeToken.java index d8fba8cb..778c7e3c 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/OneTimeToken.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/OneTimeToken.java @@ -23,6 +23,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; /** @@ -50,6 +51,8 @@ public class OneTimeToken { @SerializedName(SERIALIZED_NAME_ONE_TIME_SECRET_I_D) private String oneTimeSecretID; + public OneTimeToken() { + } public OneTimeToken accessorID(String accessorID) { @@ -186,11 +189,22 @@ public boolean equals(Object o) { Objects.equals(this.oneTimeSecretID, oneTimeToken.oneTimeSecretID); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(accessorID, createIndex, expiresAt, modifyIndex, oneTimeSecretID); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/OneTimeTokenExchangeRequest.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/OneTimeTokenExchangeRequest.java index f6e47929..cc1bb8fa 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/OneTimeTokenExchangeRequest.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/OneTimeTokenExchangeRequest.java @@ -33,6 +33,8 @@ public class OneTimeTokenExchangeRequest { @SerializedName(SERIALIZED_NAME_ONE_TIME_SECRET_I_D) private String oneTimeSecretID; + public OneTimeTokenExchangeRequest() { + } public OneTimeTokenExchangeRequest oneTimeSecretID(String oneTimeSecretID) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/OperatorHealthReply.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/OperatorHealthReply.java index 09c8577d..7ff4eab6 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/OperatorHealthReply.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/OperatorHealthReply.java @@ -44,6 +44,8 @@ public class OperatorHealthReply { @SerializedName(SERIALIZED_NAME_SERVERS) private List servers = null; + public OperatorHealthReply() { + } public OperatorHealthReply failureTolerance(Integer failureTolerance) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/ParameterizedJobConfig.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/ParameterizedJobConfig.java index 3c8c57a7..98b38011 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/ParameterizedJobConfig.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/ParameterizedJobConfig.java @@ -43,6 +43,8 @@ public class ParameterizedJobConfig { @SerializedName(SERIALIZED_NAME_PAYLOAD) private String payload; + public ParameterizedJobConfig() { + } public ParameterizedJobConfig metaOptional(List metaOptional) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/PeriodicConfig.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/PeriodicConfig.java index 6d257bf6..4434e841 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/PeriodicConfig.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/PeriodicConfig.java @@ -49,6 +49,8 @@ public class PeriodicConfig { @SerializedName(SERIALIZED_NAME_TIME_ZONE) private String timeZone; + public PeriodicConfig() { + } public PeriodicConfig enabled(Boolean enabled) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/PeriodicForceResponse.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/PeriodicForceResponse.java index 62e374ef..65b0a870 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/PeriodicForceResponse.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/PeriodicForceResponse.java @@ -41,6 +41,8 @@ public class PeriodicForceResponse { @SerializedName(SERIALIZED_NAME_INDEX) private Integer index; + public PeriodicForceResponse() { + } public PeriodicForceResponse evalCreateIndex(Integer evalCreateIndex) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/PlanAnnotations.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/PlanAnnotations.java index 08b95d3b..c008b82f 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/PlanAnnotations.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/PlanAnnotations.java @@ -43,6 +43,8 @@ public class PlanAnnotations { @SerializedName(SERIALIZED_NAME_PREEMPTED_ALLOCS) private List preemptedAllocs = null; + public PlanAnnotations() { + } public PlanAnnotations desiredTGUpdates(Map desiredTGUpdates) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/PointValue.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/PointValue.java index 90705d1a..cb692a96 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/PointValue.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/PointValue.java @@ -39,6 +39,8 @@ public class PointValue { @SerializedName(SERIALIZED_NAME_POINTS) private List points = null; + public PointValue() { + } public PointValue name(String name) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/Port.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/Port.java index 4d78e01e..70ff1a97 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/Port.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/Port.java @@ -45,6 +45,8 @@ public class Port { @SerializedName(SERIALIZED_NAME_VALUE) private Integer value; + public Port() { + } public Port hostNetwork(String hostNetwork) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/PortMapping.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/PortMapping.java index 45cf2530..b550801b 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/PortMapping.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/PortMapping.java @@ -45,6 +45,8 @@ public class PortMapping { @SerializedName(SERIALIZED_NAME_VALUE) private Integer value; + public PortMapping() { + } public PortMapping hostIP(String hostIP) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/PreemptionConfig.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/PreemptionConfig.java index 72e541f6..18fd42a3 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/PreemptionConfig.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/PreemptionConfig.java @@ -45,6 +45,8 @@ public class PreemptionConfig { @SerializedName(SERIALIZED_NAME_SYSTEM_SCHEDULER_ENABLED) private Boolean systemSchedulerEnabled; + public PreemptionConfig() { + } public PreemptionConfig batchSchedulerEnabled(Boolean batchSchedulerEnabled) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/QuotaLimit.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/QuotaLimit.java index 90ef721d..e24bfd68 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/QuotaLimit.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/QuotaLimit.java @@ -24,6 +24,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; /** * QuotaLimit @@ -42,6 +43,8 @@ public class QuotaLimit { @SerializedName(SERIALIZED_NAME_REGION_LIMIT) private Resources regionLimit; + public QuotaLimit() { + } public QuotaLimit hash(byte[] hash) { @@ -126,11 +129,22 @@ public boolean equals(Object o) { Objects.equals(this.regionLimit, quotaLimit.regionLimit); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(Arrays.hashCode(hash), region, regionLimit); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/QuotaSpec.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/QuotaSpec.java index f0549f08..899c55fd 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/QuotaSpec.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/QuotaSpec.java @@ -52,6 +52,8 @@ public class QuotaSpec { @SerializedName(SERIALIZED_NAME_NAME) private String name; + public QuotaSpec() { + } public QuotaSpec createIndex(Integer createIndex) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/RaftConfiguration.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/RaftConfiguration.java index d64cc6e2..7f4ac29e 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/RaftConfiguration.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/RaftConfiguration.java @@ -40,6 +40,8 @@ public class RaftConfiguration { @SerializedName(SERIALIZED_NAME_SERVERS) private List servers = null; + public RaftConfiguration() { + } public RaftConfiguration index(Integer index) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/RaftServer.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/RaftServer.java index ae19dd65..c0e489b2 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/RaftServer.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/RaftServer.java @@ -53,6 +53,8 @@ public class RaftServer { @SerializedName(SERIALIZED_NAME_VOTER) private Boolean voter; + public RaftServer() { + } public RaftServer address(String address) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/RequestedDevice.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/RequestedDevice.java index 7cbc45ee..d75b6432 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/RequestedDevice.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/RequestedDevice.java @@ -49,6 +49,8 @@ public class RequestedDevice { @SerializedName(SERIALIZED_NAME_NAME) private String name; + public RequestedDevice() { + } public RequestedDevice affinities(List affinities) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/RescheduleEvent.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/RescheduleEvent.java index b0c6d350..3c031abd 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/RescheduleEvent.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/RescheduleEvent.java @@ -41,6 +41,8 @@ public class RescheduleEvent { @SerializedName(SERIALIZED_NAME_RESCHEDULE_TIME) private Long rescheduleTime; + public RescheduleEvent() { + } public RescheduleEvent prevAllocID(String prevAllocID) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/ReschedulePolicy.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/ReschedulePolicy.java index 45a23b73..98f2c7a9 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/ReschedulePolicy.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/ReschedulePolicy.java @@ -53,6 +53,8 @@ public class ReschedulePolicy { @SerializedName(SERIALIZED_NAME_UNLIMITED) private Boolean unlimited; + public ReschedulePolicy() { + } public ReschedulePolicy attempts(Integer attempts) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/RescheduleTracker.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/RescheduleTracker.java index 70b2e371..a467b3f0 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/RescheduleTracker.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/RescheduleTracker.java @@ -36,6 +36,8 @@ public class RescheduleTracker { @SerializedName(SERIALIZED_NAME_EVENTS) private List events = null; + public RescheduleTracker() { + } public RescheduleTracker events(List events) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/Resources.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/Resources.java index a22feffd..bea8b772 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/Resources.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/Resources.java @@ -65,6 +65,8 @@ public class Resources { @SerializedName(SERIALIZED_NAME_NETWORKS) private List networks = null; + public Resources() { + } public Resources CPU(Integer CPU) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/RestartPolicy.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/RestartPolicy.java index 62992f62..c24d5e88 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/RestartPolicy.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/RestartPolicy.java @@ -45,6 +45,8 @@ public class RestartPolicy { @SerializedName(SERIALIZED_NAME_MODE) private String mode; + public RestartPolicy() { + } public RestartPolicy attempts(Integer attempts) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/SampledValue.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/SampledValue.java index 0da2f353..c134d0b9 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/SampledValue.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/SampledValue.java @@ -68,6 +68,8 @@ public class SampledValue { @SerializedName(SERIALIZED_NAME_SUM) private Double sum; + public SampledValue() { + } public SampledValue count(Integer count) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/ScalingEvent.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/ScalingEvent.java index b3b99741..b16741fc 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/ScalingEvent.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/ScalingEvent.java @@ -64,6 +64,8 @@ public class ScalingEvent { @SerializedName(SERIALIZED_NAME_TIME) private Integer time; + public ScalingEvent() { + } public ScalingEvent count(Long count) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/ScalingPolicy.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/ScalingPolicy.java index c314374d..479c2cc3 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/ScalingPolicy.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/ScalingPolicy.java @@ -72,6 +72,8 @@ public class ScalingPolicy { @SerializedName(SERIALIZED_NAME_TYPE) private String type; + public ScalingPolicy() { + } public ScalingPolicy createIndex(Integer createIndex) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/ScalingPolicyListStub.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/ScalingPolicyListStub.java index b09984e6..7a09270d 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/ScalingPolicyListStub.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/ScalingPolicyListStub.java @@ -56,6 +56,8 @@ public class ScalingPolicyListStub { @SerializedName(SERIALIZED_NAME_TYPE) private String type; + public ScalingPolicyListStub() { + } public ScalingPolicyListStub createIndex(Integer createIndex) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/ScalingRequest.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/ScalingRequest.java index ad8340f3..4ba8bf89 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/ScalingRequest.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/ScalingRequest.java @@ -68,6 +68,8 @@ public class ScalingRequest { @SerializedName(SERIALIZED_NAME_TARGET) private Map target = null; + public ScalingRequest() { + } public ScalingRequest count(Long count) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/SchedulerConfiguration.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/SchedulerConfiguration.java index 4aaa9ea3..2cdece74 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/SchedulerConfiguration.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/SchedulerConfiguration.java @@ -24,6 +24,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; /** * SchedulerConfiguration @@ -58,6 +59,8 @@ public class SchedulerConfiguration { @SerializedName(SERIALIZED_NAME_SCHEDULER_ALGORITHM) private String schedulerAlgorithm; + public SchedulerConfiguration() { + } public SchedulerConfiguration createIndex(Integer createIndex) { @@ -242,11 +245,22 @@ public boolean equals(Object o) { Objects.equals(this.schedulerAlgorithm, schedulerConfiguration.schedulerAlgorithm); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(createIndex, memoryOversubscriptionEnabled, modifyIndex, pauseEvalBroker, preemptionConfig, rejectJobRegistration, schedulerAlgorithm); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/SchedulerConfigurationResponse.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/SchedulerConfigurationResponse.java index 9cdee256..a4424ed9 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/SchedulerConfigurationResponse.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/SchedulerConfigurationResponse.java @@ -24,6 +24,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; /** * SchedulerConfigurationResponse @@ -54,6 +55,8 @@ public class SchedulerConfigurationResponse { @SerializedName(SERIALIZED_NAME_SCHEDULER_CONFIG) private SchedulerConfiguration schedulerConfig; + public SchedulerConfigurationResponse() { + } public SchedulerConfigurationResponse knownLeader(Boolean knownLeader) { @@ -212,11 +215,22 @@ public boolean equals(Object o) { Objects.equals(this.schedulerConfig, schedulerConfigurationResponse.schedulerConfig); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(knownLeader, lastContact, lastIndex, nextToken, requestTime, schedulerConfig); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/SchedulerSetConfigurationResponse.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/SchedulerSetConfigurationResponse.java index 018888cf..7fcad829 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/SchedulerSetConfigurationResponse.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/SchedulerSetConfigurationResponse.java @@ -41,6 +41,8 @@ public class SchedulerSetConfigurationResponse { @SerializedName(SERIALIZED_NAME_UPDATED) private Boolean updated; + public SchedulerSetConfigurationResponse() { + } public SchedulerSetConfigurationResponse lastIndex(Integer lastIndex) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/SearchRequest.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/SearchRequest.java index 51a6fd1d..9d60ed32 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/SearchRequest.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/SearchRequest.java @@ -88,6 +88,8 @@ public class SearchRequest { @SerializedName(SERIALIZED_NAME_WAIT_TIME) private Long waitTime; + public SearchRequest() { + } public SearchRequest allowStale(Boolean allowStale) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/SearchResponse.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/SearchResponse.java index b2018e37..8dd072c2 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/SearchResponse.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/SearchResponse.java @@ -60,6 +60,8 @@ public class SearchResponse { @SerializedName(SERIALIZED_NAME_TRUNCATIONS) private Map truncations = null; + public SearchResponse() { + } public SearchResponse knownLeader(Boolean knownLeader) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/ServerHealth.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/ServerHealth.java index 1a9d3216..714492ca 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/ServerHealth.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/ServerHealth.java @@ -23,6 +23,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; /** @@ -78,6 +79,8 @@ public class ServerHealth { @SerializedName(SERIALIZED_NAME_VOTER) private Boolean voter; + public ServerHealth() { + } public ServerHealth address(String address) { @@ -382,11 +385,22 @@ public boolean equals(Object o) { Objects.equals(this.voter, serverHealth.voter); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(address, healthy, ID, lastContact, lastIndex, lastTerm, leader, name, serfStatus, stableSince, version, voter); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/Service.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/Service.java index e996d37a..0b58785a 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/Service.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/Service.java @@ -30,6 +30,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; /** * Service @@ -100,6 +101,8 @@ public class Service { @SerializedName(SERIALIZED_NAME_TASK_NAME) private String taskName; + public Service() { + } public Service address(String address) { @@ -544,11 +547,22 @@ public boolean equals(Object o) { Objects.equals(this.taskName, service.taskName); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(address, addressMode, canaryMeta, canaryTags, checkRestart, checks, connect, enableTagOverride, meta, name, onUpdate, portLabel, provider, taggedAddresses, tags, taskName); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/ServiceCheck.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/ServiceCheck.java index 2921a44f..46db48bd 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/ServiceCheck.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/ServiceCheck.java @@ -28,6 +28,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; /** * ServiceCheck @@ -130,6 +131,8 @@ public class ServiceCheck { @SerializedName(SERIALIZED_NAME_TYPE) private String type; + public ServiceCheck() { + } public ServiceCheck addressMode(String addressMode) { @@ -734,11 +737,22 @@ public boolean equals(Object o) { Objects.equals(this.type, serviceCheck.type); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(addressMode, advertise, args, body, checkRestart, command, expose, failuresBeforeCritical, grPCService, grPCUseTLS, header, initialStatus, interval, method, name, onUpdate, path, portLabel, protocol, successBeforePassing, tlSSkipVerify, taskName, timeout, type); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/ServiceRegistration.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/ServiceRegistration.java index 3d97e5ef..461fb854 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/ServiceRegistration.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/ServiceRegistration.java @@ -79,6 +79,8 @@ public class ServiceRegistration { @SerializedName(SERIALIZED_NAME_TAGS) private List tags = null; + public ServiceRegistration() { + } public ServiceRegistration address(String address) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/SidecarTask.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/SidecarTask.java index dcaa14ae..573c208e 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/SidecarTask.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/SidecarTask.java @@ -28,6 +28,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; /** * SidecarTask @@ -78,6 +79,8 @@ public class SidecarTask { @SerializedName(SERIALIZED_NAME_USER) private String user; + public SidecarTask() { + } public SidecarTask config(Map config) { @@ -378,11 +381,22 @@ public boolean equals(Object o) { Objects.equals(this.user, sidecarTask.user); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(config, driver, env, killSignal, killTimeout, logConfig, meta, name, resources, shutdownDelay, user); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/Spread.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/Spread.java index 009d060d..2c6dd373 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/Spread.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/Spread.java @@ -44,6 +44,8 @@ public class Spread { @SerializedName(SERIALIZED_NAME_WEIGHT) private Integer weight; + public Spread() { + } public Spread attribute(String attribute) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/SpreadTarget.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/SpreadTarget.java index 1236ec23..42d4604c 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/SpreadTarget.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/SpreadTarget.java @@ -37,6 +37,8 @@ public class SpreadTarget { @SerializedName(SERIALIZED_NAME_VALUE) private String value; + public SpreadTarget() { + } public SpreadTarget percent(Integer percent) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/Task.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/Task.java index 69fcb886..626d8874 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/Task.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/Task.java @@ -41,6 +41,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; /** * Task @@ -147,6 +148,8 @@ public class Task { @SerializedName(SERIALIZED_NAME_VOLUME_MOUNTS) private List volumeMounts = null; + public Task() { + } public Task affinities(List affinities) { @@ -839,11 +842,22 @@ public boolean equals(Object o) { Objects.equals(this.volumeMounts, task.volumeMounts); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(affinities, artifacts, csIPluginConfig, config, constraints, dispatchPayload, driver, env, killSignal, killTimeout, kind, leader, lifecycle, logConfig, meta, name, resources, restartPolicy, scalingPolicies, services, shutdownDelay, templates, user, vault, volumeMounts); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskArtifact.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskArtifact.java index 1bce781a..4e5aac61 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskArtifact.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskArtifact.java @@ -52,6 +52,8 @@ public class TaskArtifact { @SerializedName(SERIALIZED_NAME_RELATIVE_DEST) private String relativeDest; + public TaskArtifact() { + } public TaskArtifact getterHeaders(Map getterHeaders) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskCSIPluginConfig.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskCSIPluginConfig.java index 29e4bcf2..bfec16f2 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskCSIPluginConfig.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskCSIPluginConfig.java @@ -45,6 +45,8 @@ public class TaskCSIPluginConfig { @SerializedName(SERIALIZED_NAME_TYPE) private String type; + public TaskCSIPluginConfig() { + } public TaskCSIPluginConfig healthTimeout(Long healthTimeout) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskDiff.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskDiff.java index b331d2df..866c90a9 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskDiff.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskDiff.java @@ -53,6 +53,8 @@ public class TaskDiff { @SerializedName(SERIALIZED_NAME_TYPE) private String type; + public TaskDiff() { + } public TaskDiff annotations(List annotations) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskEvent.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskEvent.java index b9fba9f0..ba3b3ac5 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskEvent.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskEvent.java @@ -132,6 +132,8 @@ public class TaskEvent { @SerializedName(SERIALIZED_NAME_VAULT_ERROR) private String vaultError; + public TaskEvent() { + } public TaskEvent details(Map details) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskGroup.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskGroup.java index 7563fb4f..e6ec1876 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskGroup.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskGroup.java @@ -41,6 +41,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; /** * TaskGroup @@ -127,6 +128,8 @@ public class TaskGroup { @SerializedName(SERIALIZED_NAME_VOLUMES) private Map volumes = null; + public TaskGroup() { + } public TaskGroup affinities(List affinities) { @@ -683,11 +686,22 @@ public boolean equals(Object o) { Objects.equals(this.volumes, taskGroup.volumes); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(affinities, constraints, consul, count, ephemeralDisk, maxClientDisconnect, meta, migrate, name, networks, reschedulePolicy, restartPolicy, scaling, services, shutdownDelay, spreads, stopAfterClientDisconnect, tasks, update, volumes); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskGroupDiff.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskGroupDiff.java index a7bdf59e..c9181fc1 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskGroupDiff.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskGroupDiff.java @@ -60,6 +60,8 @@ public class TaskGroupDiff { @SerializedName(SERIALIZED_NAME_UPDATES) private Map updates = null; + public TaskGroupDiff() { + } public TaskGroupDiff fields(List fields) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskGroupScaleStatus.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskGroupScaleStatus.java index 3e2015aa..01088eb9 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskGroupScaleStatus.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskGroupScaleStatus.java @@ -56,6 +56,8 @@ public class TaskGroupScaleStatus { @SerializedName(SERIALIZED_NAME_UNHEALTHY) private Integer unhealthy; + public TaskGroupScaleStatus() { + } public TaskGroupScaleStatus desired(Integer desired) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskGroupSummary.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskGroupSummary.java index fbf35566..5fb5e044 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskGroupSummary.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskGroupSummary.java @@ -57,6 +57,8 @@ public class TaskGroupSummary { @SerializedName(SERIALIZED_NAME_UNKNOWN) private Integer unknown; + public TaskGroupSummary() { + } public TaskGroupSummary complete(Integer complete) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskHandle.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskHandle.java index 85913619..2cdd7ea6 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskHandle.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskHandle.java @@ -37,6 +37,8 @@ public class TaskHandle { @SerializedName(SERIALIZED_NAME_VERSION) private Integer version; + public TaskHandle() { + } public TaskHandle driverState(byte[] driverState) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskLifecycle.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskLifecycle.java index 1c883edc..8366bf3a 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskLifecycle.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskLifecycle.java @@ -37,6 +37,8 @@ public class TaskLifecycle { @SerializedName(SERIALIZED_NAME_SIDECAR) private Boolean sidecar; + public TaskLifecycle() { + } public TaskLifecycle hook(String hook) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskState.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskState.java index a6c77294..a0837d4a 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskState.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/TaskState.java @@ -27,6 +27,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; /** @@ -66,6 +67,8 @@ public class TaskState { @SerializedName(SERIALIZED_NAME_TASK_HANDLE) private TaskHandle taskHandle; + public TaskState() { + } public TaskState events(List events) { @@ -280,11 +283,22 @@ public boolean equals(Object o) { Objects.equals(this.taskHandle, taskState.taskHandle); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(events, failed, finishedAt, lastRestart, restarts, startedAt, state, taskHandle); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/Template.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/Template.java index 5dbec867..98d94c03 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/Template.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/Template.java @@ -78,6 +78,8 @@ public class Template { @SerializedName(SERIALIZED_NAME_WAIT) private WaitConfig wait; + public Template() { + } public Template changeMode(String changeMode) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/UpdateStrategy.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/UpdateStrategy.java index f02b3752..90460cb0 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/UpdateStrategy.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/UpdateStrategy.java @@ -65,6 +65,8 @@ public class UpdateStrategy { @SerializedName(SERIALIZED_NAME_STAGGER) private Long stagger; + public UpdateStrategy() { + } public UpdateStrategy autoPromote(Boolean autoPromote) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/Vault.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/Vault.java index d999d169..af7a51f8 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/Vault.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/Vault.java @@ -51,6 +51,8 @@ public class Vault { @SerializedName(SERIALIZED_NAME_POLICIES) private List policies = null; + public Vault() { + } public Vault changeMode(String changeMode) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/VolumeMount.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/VolumeMount.java index 944dd39a..b05b0a64 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/VolumeMount.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/VolumeMount.java @@ -45,6 +45,8 @@ public class VolumeMount { @SerializedName(SERIALIZED_NAME_VOLUME) private String volume; + public VolumeMount() { + } public VolumeMount destination(String destination) { diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/VolumeRequest.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/VolumeRequest.java index f69c5701..5d56d225 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/VolumeRequest.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/VolumeRequest.java @@ -24,6 +24,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; /** * VolumeRequest @@ -62,6 +63,8 @@ public class VolumeRequest { @SerializedName(SERIALIZED_NAME_TYPE) private String type; + public VolumeRequest() { + } public VolumeRequest accessMode(String accessMode) { @@ -266,11 +269,22 @@ public boolean equals(Object o) { Objects.equals(this.type, volumeRequest.type); } + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); + } + @Override public int hashCode() { return Objects.hash(accessMode, attachmentMode, mountOptions, name, perAlloc, readOnly, source, type); } + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); diff --git a/clients/java/v1/src/main/java/io/nomadproject/client/models/WaitConfig.java b/clients/java/v1/src/main/java/io/nomadproject/client/models/WaitConfig.java index e45bb105..cf98464d 100644 --- a/clients/java/v1/src/main/java/io/nomadproject/client/models/WaitConfig.java +++ b/clients/java/v1/src/main/java/io/nomadproject/client/models/WaitConfig.java @@ -37,6 +37,8 @@ public class WaitConfig { @SerializedName(SERIALIZED_NAME_MIN) private Long min; + public WaitConfig() { + } public WaitConfig max(Long max) { diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/api/AclApiTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/api/AclApiTest.java index 9ba38cf5..0865401d 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/api/AclApiTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/api/AclApiTest.java @@ -52,8 +52,7 @@ public void deleteACLPolicyTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - api.deleteACLPolicy(policyName, region, namespace, xNomadToken, idempotencyToken); - + api.deleteACLPolicy(policyName, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } @@ -72,8 +71,7 @@ public void deleteACLTokenTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - api.deleteACLToken(tokenAccessor, region, namespace, xNomadToken, idempotencyToken); - + api.deleteACLToken(tokenAccessor, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } @@ -96,8 +94,7 @@ public void getACLPoliciesTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - List response = api.getACLPolicies(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + List response = api.getACLPolicies(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -121,8 +118,7 @@ public void getACLPolicyTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - ACLPolicy response = api.getACLPolicy(policyName, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + ACLPolicy response = api.getACLPolicy(policyName, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -146,8 +142,7 @@ public void getACLTokenTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - ACLToken response = api.getACLToken(tokenAccessor, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + ACLToken response = api.getACLToken(tokenAccessor, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -170,8 +165,7 @@ public void getACLTokenSelfTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - ACLToken response = api.getACLTokenSelf(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + ACLToken response = api.getACLTokenSelf(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -194,8 +188,7 @@ public void getACLTokensTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - List response = api.getACLTokens(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + List response = api.getACLTokens(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -213,8 +206,7 @@ public void postACLBootstrapTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - ACLToken response = api.postACLBootstrap(region, namespace, xNomadToken, idempotencyToken); - + ACLToken response = api.postACLBootstrap(region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } @@ -234,8 +226,7 @@ public void postACLPolicyTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - api.postACLPolicy(policyName, acLPolicy, region, namespace, xNomadToken, idempotencyToken); - + api.postACLPolicy(policyName, acLPolicy, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } @@ -255,8 +246,7 @@ public void postACLTokenTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - ACLToken response = api.postACLToken(tokenAccessor, acLToken, region, namespace, xNomadToken, idempotencyToken); - + ACLToken response = api.postACLToken(tokenAccessor, acLToken, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } @@ -274,8 +264,7 @@ public void postACLTokenOnetimeTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - OneTimeToken response = api.postACLTokenOnetime(region, namespace, xNomadToken, idempotencyToken); - + OneTimeToken response = api.postACLTokenOnetime(region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } @@ -294,8 +283,7 @@ public void postACLTokenOnetimeExchangeTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - ACLToken response = api.postACLTokenOnetimeExchange(oneTimeTokenExchangeRequest, region, namespace, xNomadToken, idempotencyToken); - + ACLToken response = api.postACLTokenOnetimeExchange(oneTimeTokenExchangeRequest, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/api/AllocationsApiTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/api/AllocationsApiTest.java index 49f312e9..4f90a963 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/api/AllocationsApiTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/api/AllocationsApiTest.java @@ -55,8 +55,7 @@ public void getAllocationTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - Allocation response = api.getAllocation(allocID, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + Allocation response = api.getAllocation(allocID, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -80,8 +79,7 @@ public void getAllocationServicesTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - List response = api.getAllocationServices(allocID, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + List response = api.getAllocationServices(allocID, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -106,8 +104,7 @@ public void getAllocationsTest() throws ApiException { String nextToken = null; Boolean resources = null; Boolean taskStates = null; - List response = api.getAllocations(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken, resources, taskStates); - + List response = api.getAllocations(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken, resources, taskStates); // TODO: test validations } @@ -132,8 +129,7 @@ public void postAllocationStopTest() throws ApiException { Integer perPage = null; String nextToken = null; Boolean noShutdownDelay = null; - AllocStopResponse response = api.postAllocationStop(allocID, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken, noShutdownDelay); - + AllocStopResponse response = api.postAllocationStop(allocID, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken, noShutdownDelay); // TODO: test validations } diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/api/DeploymentsApiTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/api/DeploymentsApiTest.java index 0a5528d0..77e07448 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/api/DeploymentsApiTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/api/DeploymentsApiTest.java @@ -58,8 +58,7 @@ public void getDeploymentTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - Deployment response = api.getDeployment(deploymentID, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + Deployment response = api.getDeployment(deploymentID, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -83,8 +82,7 @@ public void getDeploymentAllocationsTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - List response = api.getDeploymentAllocations(deploymentID, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + List response = api.getDeploymentAllocations(deploymentID, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -107,8 +105,7 @@ public void getDeploymentsTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - List response = api.getDeployments(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + List response = api.getDeployments(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -128,8 +125,7 @@ public void postDeploymentAllocationHealthTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - DeploymentUpdateResponse response = api.postDeploymentAllocationHealth(deploymentID, deploymentAllocHealthRequest, region, namespace, xNomadToken, idempotencyToken); - + DeploymentUpdateResponse response = api.postDeploymentAllocationHealth(deploymentID, deploymentAllocHealthRequest, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } @@ -148,8 +144,7 @@ public void postDeploymentFailTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - DeploymentUpdateResponse response = api.postDeploymentFail(deploymentID, region, namespace, xNomadToken, idempotencyToken); - + DeploymentUpdateResponse response = api.postDeploymentFail(deploymentID, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } @@ -169,8 +164,7 @@ public void postDeploymentPauseTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - DeploymentUpdateResponse response = api.postDeploymentPause(deploymentID, deploymentPauseRequest, region, namespace, xNomadToken, idempotencyToken); - + DeploymentUpdateResponse response = api.postDeploymentPause(deploymentID, deploymentPauseRequest, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } @@ -190,8 +184,7 @@ public void postDeploymentPromoteTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - DeploymentUpdateResponse response = api.postDeploymentPromote(deploymentID, deploymentPromoteRequest, region, namespace, xNomadToken, idempotencyToken); - + DeploymentUpdateResponse response = api.postDeploymentPromote(deploymentID, deploymentPromoteRequest, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } @@ -211,8 +204,7 @@ public void postDeploymentUnblockTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - DeploymentUpdateResponse response = api.postDeploymentUnblock(deploymentID, deploymentUnblockRequest, region, namespace, xNomadToken, idempotencyToken); - + DeploymentUpdateResponse response = api.postDeploymentUnblock(deploymentID, deploymentUnblockRequest, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/api/EnterpriseApiTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/api/EnterpriseApiTest.java index c779b3e9..71c79e26 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/api/EnterpriseApiTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/api/EnterpriseApiTest.java @@ -47,8 +47,7 @@ public void createQuotaSpecTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - api.createQuotaSpec(quotaSpec, region, namespace, xNomadToken, idempotencyToken); - + api.createQuotaSpec(quotaSpec, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } @@ -67,8 +66,7 @@ public void deleteQuotaSpecTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - api.deleteQuotaSpec(specName, region, namespace, xNomadToken, idempotencyToken); - + api.deleteQuotaSpec(specName, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } @@ -92,8 +90,7 @@ public void getQuotaSpecTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - QuotaSpec response = api.getQuotaSpec(specName, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + QuotaSpec response = api.getQuotaSpec(specName, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -116,8 +113,7 @@ public void getQuotasTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - List response = api.getQuotas(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + List response = api.getQuotas(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -137,8 +133,7 @@ public void postQuotaSpecTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - api.postQuotaSpec(specName, quotaSpec, region, namespace, xNomadToken, idempotencyToken); - + api.postQuotaSpec(specName, quotaSpec, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/api/EvaluationsApiTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/api/EvaluationsApiTest.java index e78f4a31..97aa930b 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/api/EvaluationsApiTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/api/EvaluationsApiTest.java @@ -53,8 +53,7 @@ public void getEvaluationTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - Evaluation response = api.getEvaluation(evalID, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + Evaluation response = api.getEvaluation(evalID, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -78,8 +77,7 @@ public void getEvaluationAllocationsTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - List response = api.getEvaluationAllocations(evalID, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + List response = api.getEvaluationAllocations(evalID, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -102,8 +100,7 @@ public void getEvaluationsTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - List response = api.getEvaluations(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + List response = api.getEvaluations(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/api/JobsApiTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/api/JobsApiTest.java index 8218d466..719c5f24 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/api/JobsApiTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/api/JobsApiTest.java @@ -72,8 +72,7 @@ public void deleteJobTest() throws ApiException { String idempotencyToken = null; Boolean purge = null; Boolean global = null; - JobDeregisterResponse response = api.deleteJob(jobName, region, namespace, xNomadToken, idempotencyToken, purge, global); - + JobDeregisterResponse response = api.deleteJob(jobName, region, namespace, xNomadToken, idempotencyToken, purge, global); // TODO: test validations } @@ -97,8 +96,7 @@ public void getJobTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - Job response = api.getJob(jobName, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + Job response = api.getJob(jobName, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -123,8 +121,7 @@ public void getJobAllocationsTest() throws ApiException { Integer perPage = null; String nextToken = null; Boolean all = null; - List response = api.getJobAllocations(jobName, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken, all); - + List response = api.getJobAllocations(jobName, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken, all); // TODO: test validations } @@ -148,8 +145,7 @@ public void getJobDeploymentTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - Deployment response = api.getJobDeployment(jobName, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + Deployment response = api.getJobDeployment(jobName, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -174,8 +170,7 @@ public void getJobDeploymentsTest() throws ApiException { Integer perPage = null; String nextToken = null; Integer all = null; - List response = api.getJobDeployments(jobName, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken, all); - + List response = api.getJobDeployments(jobName, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken, all); // TODO: test validations } @@ -199,8 +194,7 @@ public void getJobEvaluationsTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - List response = api.getJobEvaluations(jobName, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + List response = api.getJobEvaluations(jobName, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -224,8 +218,7 @@ public void getJobScaleStatusTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - JobScaleStatusResponse response = api.getJobScaleStatus(jobName, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + JobScaleStatusResponse response = api.getJobScaleStatus(jobName, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -249,8 +242,7 @@ public void getJobSummaryTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - JobSummary response = api.getJobSummary(jobName, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + JobSummary response = api.getJobSummary(jobName, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -275,8 +267,7 @@ public void getJobVersionsTest() throws ApiException { Integer perPage = null; String nextToken = null; Boolean diffs = null; - JobVersionsResponse response = api.getJobVersions(jobName, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken, diffs); - + JobVersionsResponse response = api.getJobVersions(jobName, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken, diffs); // TODO: test validations } @@ -299,8 +290,7 @@ public void getJobsTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - List response = api.getJobs(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + List response = api.getJobs(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -320,8 +310,7 @@ public void postJobTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - JobRegisterResponse response = api.postJob(jobName, jobRegisterRequest, region, namespace, xNomadToken, idempotencyToken); - + JobRegisterResponse response = api.postJob(jobName, jobRegisterRequest, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } @@ -341,8 +330,7 @@ public void postJobDispatchTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - JobDispatchResponse response = api.postJobDispatch(jobName, jobDispatchRequest, region, namespace, xNomadToken, idempotencyToken); - + JobDispatchResponse response = api.postJobDispatch(jobName, jobDispatchRequest, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } @@ -362,8 +350,7 @@ public void postJobEvaluateTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - JobRegisterResponse response = api.postJobEvaluate(jobName, jobEvaluateRequest, region, namespace, xNomadToken, idempotencyToken); - + JobRegisterResponse response = api.postJobEvaluate(jobName, jobEvaluateRequest, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } @@ -378,8 +365,7 @@ public void postJobEvaluateTest() throws ApiException { @Test public void postJobParseTest() throws ApiException { JobsParseRequest jobsParseRequest = null; - Job response = api.postJobParse(jobsParseRequest); - + Job response = api.postJobParse(jobsParseRequest); // TODO: test validations } @@ -398,8 +384,7 @@ public void postJobPeriodicForceTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - PeriodicForceResponse response = api.postJobPeriodicForce(jobName, region, namespace, xNomadToken, idempotencyToken); - + PeriodicForceResponse response = api.postJobPeriodicForce(jobName, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } @@ -419,8 +404,7 @@ public void postJobPlanTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - JobPlanResponse response = api.postJobPlan(jobName, jobPlanRequest, region, namespace, xNomadToken, idempotencyToken); - + JobPlanResponse response = api.postJobPlan(jobName, jobPlanRequest, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } @@ -440,8 +424,7 @@ public void postJobRevertTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - JobRegisterResponse response = api.postJobRevert(jobName, jobRevertRequest, region, namespace, xNomadToken, idempotencyToken); - + JobRegisterResponse response = api.postJobRevert(jobName, jobRevertRequest, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } @@ -461,8 +444,7 @@ public void postJobScalingRequestTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - JobRegisterResponse response = api.postJobScalingRequest(jobName, scalingRequest, region, namespace, xNomadToken, idempotencyToken); - + JobRegisterResponse response = api.postJobScalingRequest(jobName, scalingRequest, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } @@ -482,8 +464,7 @@ public void postJobStabilityTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - JobStabilityResponse response = api.postJobStability(jobName, jobStabilityRequest, region, namespace, xNomadToken, idempotencyToken); - + JobStabilityResponse response = api.postJobStability(jobName, jobStabilityRequest, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } @@ -502,8 +483,7 @@ public void postJobValidateRequestTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - JobValidateResponse response = api.postJobValidateRequest(jobValidateRequest, region, namespace, xNomadToken, idempotencyToken); - + JobValidateResponse response = api.postJobValidateRequest(jobValidateRequest, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } @@ -522,8 +502,7 @@ public void registerJobTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - JobRegisterResponse response = api.registerJob(jobRegisterRequest, region, namespace, xNomadToken, idempotencyToken); - + JobRegisterResponse response = api.registerJob(jobRegisterRequest, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/api/MetricsApiTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/api/MetricsApiTest.java index 6435549e..69d18349 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/api/MetricsApiTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/api/MetricsApiTest.java @@ -43,8 +43,7 @@ public class MetricsApiTest { @Test public void getMetricsSummaryTest() throws ApiException { String format = null; - MetricsSummary response = api.getMetricsSummary(format); - + MetricsSummary response = api.getMetricsSummary(format); // TODO: test validations } diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/api/NamespacesApiTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/api/NamespacesApiTest.java index 757e84b6..ba4edd43 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/api/NamespacesApiTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/api/NamespacesApiTest.java @@ -46,8 +46,7 @@ public void createNamespaceTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - api.createNamespace(region, namespace, xNomadToken, idempotencyToken); - + api.createNamespace(region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } @@ -66,8 +65,7 @@ public void deleteNamespaceTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - api.deleteNamespace(namespaceName, region, namespace, xNomadToken, idempotencyToken); - + api.deleteNamespace(namespaceName, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } @@ -91,8 +89,7 @@ public void getNamespaceTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - Namespace response = api.getNamespace(namespaceName, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + Namespace response = api.getNamespace(namespaceName, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -115,8 +112,7 @@ public void getNamespacesTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - List response = api.getNamespaces(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + List response = api.getNamespaces(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -136,8 +132,7 @@ public void postNamespaceTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - api.postNamespace(namespaceName, namespace2, region, namespace, xNomadToken, idempotencyToken); - + api.postNamespace(namespaceName, namespace2, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/api/NodesApiTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/api/NodesApiTest.java index 635e83fa..cb7007c1 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/api/NodesApiTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/api/NodesApiTest.java @@ -59,8 +59,7 @@ public void getNodeTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - Node response = api.getNode(nodeId, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + Node response = api.getNode(nodeId, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -84,8 +83,7 @@ public void getNodeAllocationsTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - List response = api.getNodeAllocations(nodeId, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + List response = api.getNodeAllocations(nodeId, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -109,8 +107,7 @@ public void getNodesTest() throws ApiException { Integer perPage = null; String nextToken = null; Boolean resources = null; - List response = api.getNodes(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken, resources); - + List response = api.getNodes(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken, resources); // TODO: test validations } @@ -135,8 +132,7 @@ public void updateNodeDrainTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - NodeDrainUpdateResponse response = api.updateNodeDrain(nodeId, nodeUpdateDrainRequest, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + NodeDrainUpdateResponse response = api.updateNodeDrain(nodeId, nodeUpdateDrainRequest, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -161,8 +157,7 @@ public void updateNodeEligibilityTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - NodeEligibilityUpdateResponse response = api.updateNodeEligibility(nodeId, nodeUpdateEligibilityRequest, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + NodeEligibilityUpdateResponse response = api.updateNodeEligibility(nodeId, nodeUpdateEligibilityRequest, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -186,8 +181,7 @@ public void updateNodePurgeTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - NodePurgeResponse response = api.updateNodePurge(nodeId, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + NodePurgeResponse response = api.updateNodePurge(nodeId, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/api/OperatorApiTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/api/OperatorApiTest.java index 762235e9..86096fa5 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/api/OperatorApiTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/api/OperatorApiTest.java @@ -51,8 +51,7 @@ public void deleteOperatorRaftPeerTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - api.deleteOperatorRaftPeer(region, namespace, xNomadToken, idempotencyToken); - + api.deleteOperatorRaftPeer(region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } @@ -75,8 +74,7 @@ public void getOperatorAutopilotConfigurationTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - AutopilotConfiguration response = api.getOperatorAutopilotConfiguration(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + AutopilotConfiguration response = api.getOperatorAutopilotConfiguration(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -99,8 +97,7 @@ public void getOperatorAutopilotHealthTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - OperatorHealthReply response = api.getOperatorAutopilotHealth(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + OperatorHealthReply response = api.getOperatorAutopilotHealth(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -123,8 +120,7 @@ public void getOperatorRaftConfigurationTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - RaftConfiguration response = api.getOperatorRaftConfiguration(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + RaftConfiguration response = api.getOperatorRaftConfiguration(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -147,8 +143,7 @@ public void getOperatorSchedulerConfigurationTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - SchedulerConfigurationResponse response = api.getOperatorSchedulerConfiguration(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + SchedulerConfigurationResponse response = api.getOperatorSchedulerConfiguration(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -167,8 +162,7 @@ public void postOperatorSchedulerConfigurationTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - SchedulerSetConfigurationResponse response = api.postOperatorSchedulerConfiguration(schedulerConfiguration, region, namespace, xNomadToken, idempotencyToken); - + SchedulerSetConfigurationResponse response = api.postOperatorSchedulerConfiguration(schedulerConfiguration, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } @@ -187,8 +181,7 @@ public void putOperatorAutopilotConfigurationTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - Boolean response = api.putOperatorAutopilotConfiguration(autopilotConfiguration, region, namespace, xNomadToken, idempotencyToken); - + Boolean response = api.putOperatorAutopilotConfiguration(autopilotConfiguration, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/api/PluginsApiTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/api/PluginsApiTest.java index bd9ea562..c9366a0b 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/api/PluginsApiTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/api/PluginsApiTest.java @@ -53,8 +53,7 @@ public void getPluginCSITest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - List response = api.getPluginCSI(pluginID, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + List response = api.getPluginCSI(pluginID, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -77,8 +76,7 @@ public void getPluginsTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - List response = api.getPlugins(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + List response = api.getPlugins(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/api/RegionsApiTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/api/RegionsApiTest.java index b9fd5398..6f7a1225 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/api/RegionsApiTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/api/RegionsApiTest.java @@ -41,8 +41,7 @@ public class RegionsApiTest { */ @Test public void getRegionsTest() throws ApiException { - List response = api.getRegions(); - + List response = api.getRegions(); // TODO: test validations } diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/api/ScalingApiTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/api/ScalingApiTest.java index d4b024f4..81e548b8 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/api/ScalingApiTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/api/ScalingApiTest.java @@ -52,8 +52,7 @@ public void getScalingPoliciesTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - List response = api.getScalingPolicies(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + List response = api.getScalingPolicies(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -77,8 +76,7 @@ public void getScalingPolicyTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - ScalingPolicy response = api.getScalingPolicy(policyID, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + ScalingPolicy response = api.getScalingPolicy(policyID, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/api/SearchApiTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/api/SearchApiTest.java index df9a5ec3..90c0a9b2 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/api/SearchApiTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/api/SearchApiTest.java @@ -55,8 +55,7 @@ public void getFuzzySearchTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - FuzzySearchResponse response = api.getFuzzySearch(fuzzySearchRequest, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + FuzzySearchResponse response = api.getFuzzySearch(fuzzySearchRequest, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -80,8 +79,7 @@ public void getSearchTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - SearchResponse response = api.getSearch(searchRequest, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + SearchResponse response = api.getSearch(searchRequest, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/api/StatusApiTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/api/StatusApiTest.java index c89adfde..0ccfe723 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/api/StatusApiTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/api/StatusApiTest.java @@ -50,8 +50,7 @@ public void getStatusLeaderTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - String response = api.getStatusLeader(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + String response = api.getStatusLeader(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -74,8 +73,7 @@ public void getStatusPeersTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - List response = api.getStatusPeers(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + List response = api.getStatusPeers(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/api/SystemApiTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/api/SystemApiTest.java index 9a22ac38..74239200 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/api/SystemApiTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/api/SystemApiTest.java @@ -45,8 +45,7 @@ public void putSystemGCTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - api.putSystemGC(region, namespace, xNomadToken, idempotencyToken); - + api.putSystemGC(region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } @@ -64,8 +63,7 @@ public void putSystemReconcileSummariesTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - api.putSystemReconcileSummaries(region, namespace, xNomadToken, idempotencyToken); - + api.putSystemReconcileSummaries(region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/api/VolumesApiTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/api/VolumesApiTest.java index 3909506f..a0b2fa12 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/api/VolumesApiTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/api/VolumesApiTest.java @@ -56,8 +56,7 @@ public void createVolumeTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - api.createVolume(volumeId, action, csIVolumeCreateRequest, region, namespace, xNomadToken, idempotencyToken); - + api.createVolume(volumeId, action, csIVolumeCreateRequest, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } @@ -77,8 +76,7 @@ public void deleteSnapshotTest() throws ApiException { String idempotencyToken = null; String pluginId = null; String snapshotId = null; - api.deleteSnapshot(region, namespace, xNomadToken, idempotencyToken, pluginId, snapshotId); - + api.deleteSnapshot(region, namespace, xNomadToken, idempotencyToken, pluginId, snapshotId); // TODO: test validations } @@ -98,8 +96,7 @@ public void deleteVolumeRegistrationTest() throws ApiException { String xNomadToken = null; String idempotencyToken = null; String force = null; - api.deleteVolumeRegistration(volumeId, region, namespace, xNomadToken, idempotencyToken, force); - + api.deleteVolumeRegistration(volumeId, region, namespace, xNomadToken, idempotencyToken, force); // TODO: test validations } @@ -120,8 +117,7 @@ public void detachOrDeleteVolumeTest() throws ApiException { String xNomadToken = null; String idempotencyToken = null; String node = null; - api.detachOrDeleteVolume(volumeId, action, region, namespace, xNomadToken, idempotencyToken, node); - + api.detachOrDeleteVolume(volumeId, action, region, namespace, xNomadToken, idempotencyToken, node); // TODO: test validations } @@ -145,8 +141,7 @@ public void getExternalVolumesTest() throws ApiException { Integer perPage = null; String nextToken = null; String pluginId = null; - CSIVolumeListExternalResponse response = api.getExternalVolumes(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken, pluginId); - + CSIVolumeListExternalResponse response = api.getExternalVolumes(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken, pluginId); // TODO: test validations } @@ -170,8 +165,7 @@ public void getSnapshotsTest() throws ApiException { Integer perPage = null; String nextToken = null; String pluginId = null; - CSISnapshotListResponse response = api.getSnapshots(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken, pluginId); - + CSISnapshotListResponse response = api.getSnapshots(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken, pluginId); // TODO: test validations } @@ -195,8 +189,7 @@ public void getVolumeTest() throws ApiException { String xNomadToken = null; Integer perPage = null; String nextToken = null; - CSIVolume response = api.getVolume(volumeId, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); - + CSIVolume response = api.getVolume(volumeId, region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken); // TODO: test validations } @@ -222,8 +215,7 @@ public void getVolumesTest() throws ApiException { String nodeId = null; String pluginId = null; String type = null; - List response = api.getVolumes(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken, nodeId, pluginId, type); - + List response = api.getVolumes(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken, nodeId, pluginId, type); // TODO: test validations } @@ -242,8 +234,7 @@ public void postSnapshotTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - CSISnapshotCreateResponse response = api.postSnapshot(csISnapshotCreateRequest, region, namespace, xNomadToken, idempotencyToken); - + CSISnapshotCreateResponse response = api.postSnapshot(csISnapshotCreateRequest, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } @@ -262,8 +253,7 @@ public void postVolumeTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - api.postVolume(csIVolumeRegisterRequest, region, namespace, xNomadToken, idempotencyToken); - + api.postVolume(csIVolumeRegisterRequest, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } @@ -283,8 +273,7 @@ public void postVolumeRegistrationTest() throws ApiException { String namespace = null; String xNomadToken = null; String idempotencyToken = null; - api.postVolumeRegistration(volumeId, csIVolumeRegisterRequest, region, namespace, xNomadToken, idempotencyToken); - + api.postVolumeRegistration(volumeId, csIVolumeRegisterRequest, region, namespace, xNomadToken, idempotencyToken); // TODO: test validations } diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/AllocDeploymentStatusTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/AllocDeploymentStatusTest.java index 60f10c2a..77ebbb5f 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/AllocDeploymentStatusTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/AllocDeploymentStatusTest.java @@ -21,6 +21,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; import org.junit.Assert; import org.junit.Ignore; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/AllocatedResourcesTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/AllocatedResourcesTest.java index 2e009674..b43dba45 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/AllocatedResourcesTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/AllocatedResourcesTest.java @@ -26,6 +26,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/AllocatedTaskResourcesTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/AllocatedTaskResourcesTest.java index 07241fe2..b76212ab 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/AllocatedTaskResourcesTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/AllocatedTaskResourcesTest.java @@ -27,6 +27,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/AllocationListStubTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/AllocationListStubTest.java index 8f770dfa..e76b9c5a 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/AllocationListStubTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/AllocationListStubTest.java @@ -29,6 +29,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/AllocationTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/AllocationTest.java index 7aed918a..5343717c 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/AllocationTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/AllocationTest.java @@ -33,6 +33,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/CSIInfoTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/CSIInfoTest.java index e672405e..a5c18bba 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/CSIInfoTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/CSIInfoTest.java @@ -23,6 +23,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; import org.junit.Assert; import org.junit.Ignore; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/CSINodeInfoTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/CSINodeInfoTest.java index 957a1cf7..8b43bb52 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/CSINodeInfoTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/CSINodeInfoTest.java @@ -22,6 +22,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/CSIVolumeListStubTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/CSIVolumeListStubTest.java index 6280813c..7b9029be 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/CSIVolumeListStubTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/CSIVolumeListStubTest.java @@ -24,6 +24,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; import org.junit.Assert; import org.junit.Ignore; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/CSIVolumeTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/CSIVolumeTest.java index f21a7572..beef8852 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/CSIVolumeTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/CSIVolumeTest.java @@ -31,6 +31,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; import org.junit.Assert; import org.junit.Ignore; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/ConsulConnectTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/ConsulConnectTest.java index a239e881..215e6f77 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/ConsulConnectTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/ConsulConnectTest.java @@ -24,6 +24,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/ConsulGatewayTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/ConsulGatewayTest.java index a92ce4a7..e89b3dbf 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/ConsulGatewayTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/ConsulGatewayTest.java @@ -24,6 +24,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/ConsulIngressConfigEntryTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/ConsulIngressConfigEntryTest.java index 3b915d02..cf6fe386 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/ConsulIngressConfigEntryTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/ConsulIngressConfigEntryTest.java @@ -25,6 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/ConsulProxyTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/ConsulProxyTest.java index 7fbe2c2f..967a81f0 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/ConsulProxyTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/ConsulProxyTest.java @@ -27,6 +27,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/ConsulSidecarServiceTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/ConsulSidecarServiceTest.java index 6ce6da7c..cb8db2dd 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/ConsulSidecarServiceTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/ConsulSidecarServiceTest.java @@ -24,6 +24,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/ConsulUpstreamTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/ConsulUpstreamTest.java index 73869d60..0d3b97fb 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/ConsulUpstreamTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/ConsulUpstreamTest.java @@ -22,6 +22,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/DeploymentStateTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/DeploymentStateTest.java index 0809d15b..031e2a22 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/DeploymentStateTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/DeploymentStateTest.java @@ -23,6 +23,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; import org.junit.Assert; import org.junit.Ignore; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/DispatchPayloadConfigTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/DispatchPayloadConfigTest.java index 3af6515f..3473a0b2 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/DispatchPayloadConfigTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/DispatchPayloadConfigTest.java @@ -41,11 +41,11 @@ public void testDispatchPayloadConfig() { } /** - * Test the property 'file' + * Test the property '_file' */ @Test - public void fileTest() { - // TODO: test file + public void _fileTest() { + // TODO: test _file } } diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/DrainMetadataTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/DrainMetadataTest.java index 39c438ae..446157fd 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/DrainMetadataTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/DrainMetadataTest.java @@ -24,6 +24,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; import org.junit.Assert; import org.junit.Ignore; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/DrainStrategyTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/DrainStrategyTest.java index 96f1447a..63e14fef 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/DrainStrategyTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/DrainStrategyTest.java @@ -21,6 +21,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; import org.junit.Assert; import org.junit.Ignore; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/DriverInfoTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/DriverInfoTest.java index de82e8c6..9e972bc4 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/DriverInfoTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/DriverInfoTest.java @@ -24,6 +24,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; import org.junit.Assert; import org.junit.Ignore; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/EvaluationStubTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/EvaluationStubTest.java index 31c463c0..1f7207c7 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/EvaluationStubTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/EvaluationStubTest.java @@ -21,6 +21,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; import org.junit.Assert; import org.junit.Ignore; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/EvaluationTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/EvaluationTest.java index 06d028bd..7ab124bf 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/EvaluationTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/EvaluationTest.java @@ -27,6 +27,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; import org.junit.Assert; import org.junit.Ignore; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/JobEvaluateRequestTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/JobEvaluateRequestTest.java index 53cd4ddf..a9f18b16 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/JobEvaluateRequestTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/JobEvaluateRequestTest.java @@ -22,6 +22,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/JobListStubTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/JobListStubTest.java index f72e883b..3277b64a 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/JobListStubTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/JobListStubTest.java @@ -24,6 +24,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/JobPlanRequestTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/JobPlanRequestTest.java index c878fbb7..913c1f0a 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/JobPlanRequestTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/JobPlanRequestTest.java @@ -22,6 +22,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/JobPlanResponseTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/JobPlanResponseTest.java index 85ba826b..0ce85944 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/JobPlanResponseTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/JobPlanResponseTest.java @@ -29,6 +29,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; import org.junit.Assert; import org.junit.Ignore; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/JobRegisterRequestTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/JobRegisterRequestTest.java index 9d4451d8..c326175e 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/JobRegisterRequestTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/JobRegisterRequestTest.java @@ -22,6 +22,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/JobSummaryTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/JobSummaryTest.java index df0ed8ba..087c2502 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/JobSummaryTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/JobSummaryTest.java @@ -26,6 +26,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/JobTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/JobTest.java index e44c8eb6..30d1d022 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/JobTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/JobTest.java @@ -35,6 +35,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/JobValidateRequestTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/JobValidateRequestTest.java index bdd01ac3..f4727d67 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/JobValidateRequestTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/JobValidateRequestTest.java @@ -22,6 +22,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/NamespaceTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/NamespaceTest.java index a159ca19..f5d1c1f2 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/NamespaceTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/NamespaceTest.java @@ -25,6 +25,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/NetworkResourceTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/NetworkResourceTest.java index a8959c09..27f11bd8 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/NetworkResourceTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/NetworkResourceTest.java @@ -25,6 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/NodeDeviceTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/NodeDeviceTest.java index 3385e91a..99054b41 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/NodeDeviceTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/NodeDeviceTest.java @@ -22,6 +22,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/NodeEventTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/NodeEventTest.java index a49b96f2..678edee5 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/NodeEventTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/NodeEventTest.java @@ -24,6 +24,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; import org.junit.Assert; import org.junit.Ignore; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/NodeListStubTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/NodeListStubTest.java index a4593718..e09791ee 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/NodeListStubTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/NodeListStubTest.java @@ -28,6 +28,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/NodeReservedResourcesTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/NodeReservedResourcesTest.java index 68ac60e6..dfde9352 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/NodeReservedResourcesTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/NodeReservedResourcesTest.java @@ -25,6 +25,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/NodeResourcesTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/NodeResourcesTest.java index f05c92fb..1527067f 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/NodeResourcesTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/NodeResourcesTest.java @@ -28,6 +28,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/NodeTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/NodeTest.java index cd08247b..d01196d1 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/NodeTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/NodeTest.java @@ -35,6 +35,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/NodeUpdateDrainRequestTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/NodeUpdateDrainRequestTest.java index 1cb91f2b..ca076d85 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/NodeUpdateDrainRequestTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/NodeUpdateDrainRequestTest.java @@ -25,6 +25,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/OneTimeTokenTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/OneTimeTokenTest.java index 482bc864..bce982f2 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/OneTimeTokenTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/OneTimeTokenTest.java @@ -21,6 +21,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; import org.junit.Assert; import org.junit.Ignore; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/QuotaLimitTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/QuotaLimitTest.java index 9202af6c..77677693 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/QuotaLimitTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/QuotaLimitTest.java @@ -22,6 +22,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/SchedulerConfigurationResponseTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/SchedulerConfigurationResponseTest.java index 665d1861..fe466245 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/SchedulerConfigurationResponseTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/SchedulerConfigurationResponseTest.java @@ -22,6 +22,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/SchedulerConfigurationTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/SchedulerConfigurationTest.java index 3429a54a..398bcb7d 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/SchedulerConfigurationTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/SchedulerConfigurationTest.java @@ -22,6 +22,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/ServerHealthTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/ServerHealthTest.java index bf7e9b97..e62e5223 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/ServerHealthTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/ServerHealthTest.java @@ -21,6 +21,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; import org.junit.Assert; import org.junit.Ignore; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/ServiceCheckTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/ServiceCheckTest.java index 989273d1..afe2b207 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/ServiceCheckTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/ServiceCheckTest.java @@ -26,6 +26,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/ServiceTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/ServiceTest.java index b7ece201..fcc428ba 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/ServiceTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/ServiceTest.java @@ -28,6 +28,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/SidecarTaskTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/SidecarTaskTest.java index d8846278..5a475a74 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/SidecarTaskTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/SidecarTaskTest.java @@ -26,6 +26,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/TaskGroupTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/TaskGroupTest.java index fa2b8bed..cd067d81 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/TaskGroupTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/TaskGroupTest.java @@ -39,6 +39,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/TaskStateTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/TaskStateTest.java index 67198a6e..46020e3d 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/TaskStateTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/TaskStateTest.java @@ -25,6 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import org.openapitools.jackson.nullable.JsonNullable; import org.threeten.bp.OffsetDateTime; import org.junit.Assert; import org.junit.Ignore; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/TaskTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/TaskTest.java index 20459ba8..dfc7dbf1 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/TaskTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/TaskTest.java @@ -39,6 +39,7 @@ import java.util.HashMap; import java.util.List; import java.util.Map; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/java/v1/src/test/java/io/nomadproject/client/models/VolumeRequestTest.java b/clients/java/v1/src/test/java/io/nomadproject/client/models/VolumeRequestTest.java index 834dbf01..3140bc17 100644 --- a/clients/java/v1/src/test/java/io/nomadproject/client/models/VolumeRequestTest.java +++ b/clients/java/v1/src/test/java/io/nomadproject/client/models/VolumeRequestTest.java @@ -22,6 +22,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.io.IOException; +import org.openapitools.jackson.nullable.JsonNullable; import org.junit.Assert; import org.junit.Ignore; import org.junit.Test; diff --git a/clients/javascript/v1/.openapi-generator/VERSION b/clients/javascript/v1/.openapi-generator/VERSION index 7cbea073..1e20ec35 100644 --- a/clients/javascript/v1/.openapi-generator/VERSION +++ b/clients/javascript/v1/.openapi-generator/VERSION @@ -1 +1 @@ -5.2.0 \ No newline at end of file +5.4.0 \ No newline at end of file diff --git a/clients/javascript/v1/src/ApiClient.js b/clients/javascript/v1/src/ApiClient.js index 2777bd26..a7ea723b 100644 --- a/clients/javascript/v1/src/ApiClient.js +++ b/clients/javascript/v1/src/ApiClient.js @@ -28,13 +28,18 @@ import querystring from "querystring"; * @class */ class ApiClient { - constructor() { + /** + * The base URL against which to resolve every API call's (relative) path. + * Overrides the default value set in spec file if present + * @param {String} basePath + */ + constructor(basePath = 'https://127.0.0.1:4646/v1') { /** * The base URL against which to resolve every API call's (relative) path. * @type {String} * @default https://127.0.0.1:4646/v1 */ - this.basePath = 'https://127.0.0.1:4646/v1'.replace(/\/+$/, ''); + this.basePath = basePath.replace(/\/+$/, ''); /** * The authentication methods to be included for all API calls. diff --git a/clients/javascript/v1/test/model/AllocStopResponse.spec.js b/clients/javascript/v1/test/model/AllocStopResponse.spec.js index f07f47a4..d7627ab8 100644 --- a/clients/javascript/v1/test/model/AllocStopResponse.spec.js +++ b/clients/javascript/v1/test/model/AllocStopResponse.spec.js @@ -50,7 +50,7 @@ describe('AllocStopResponse', function() { it('should create an instance of AllocStopResponse', function() { // uncomment below and update the code to test AllocStopResponse - //var instane = new nomad-client.AllocStopResponse(); + //var instance = new nomad-client.AllocStopResponse(); //expect(instance).to.be.a(nomad-client.AllocStopResponse); }); diff --git a/clients/javascript/v1/test/model/AutopilotConfiguration.spec.js b/clients/javascript/v1/test/model/AutopilotConfiguration.spec.js index 1460aa43..3106857d 100644 --- a/clients/javascript/v1/test/model/AutopilotConfiguration.spec.js +++ b/clients/javascript/v1/test/model/AutopilotConfiguration.spec.js @@ -50,7 +50,7 @@ describe('AutopilotConfiguration', function() { it('should create an instance of AutopilotConfiguration', function() { // uncomment below and update the code to test AutopilotConfiguration - //var instane = new nomad-client.AutopilotConfiguration(); + //var instance = new nomad-client.AutopilotConfiguration(); //expect(instance).to.be.a(nomad-client.AutopilotConfiguration); }); diff --git a/clients/javascript/v1/test/model/CSIControllerInfo.spec.js b/clients/javascript/v1/test/model/CSIControllerInfo.spec.js index 752c3eed..de34c8b7 100644 --- a/clients/javascript/v1/test/model/CSIControllerInfo.spec.js +++ b/clients/javascript/v1/test/model/CSIControllerInfo.spec.js @@ -50,7 +50,7 @@ describe('CSIControllerInfo', function() { it('should create an instance of CSIControllerInfo', function() { // uncomment below and update the code to test CSIControllerInfo - //var instane = new nomad-client.CSIControllerInfo(); + //var instance = new nomad-client.CSIControllerInfo(); //expect(instance).to.be.a(nomad-client.CSIControllerInfo); }); diff --git a/clients/javascript/v1/test/model/CSIInfo.spec.js b/clients/javascript/v1/test/model/CSIInfo.spec.js index ee901625..c6c65d41 100644 --- a/clients/javascript/v1/test/model/CSIInfo.spec.js +++ b/clients/javascript/v1/test/model/CSIInfo.spec.js @@ -50,7 +50,7 @@ describe('CSIInfo', function() { it('should create an instance of CSIInfo', function() { // uncomment below and update the code to test CSIInfo - //var instane = new nomad-client.CSIInfo(); + //var instance = new nomad-client.CSIInfo(); //expect(instance).to.be.a(nomad-client.CSIInfo); }); diff --git a/clients/javascript/v1/test/model/CSINodeInfo.spec.js b/clients/javascript/v1/test/model/CSINodeInfo.spec.js index c53b07cf..0c994219 100644 --- a/clients/javascript/v1/test/model/CSINodeInfo.spec.js +++ b/clients/javascript/v1/test/model/CSINodeInfo.spec.js @@ -50,7 +50,7 @@ describe('CSINodeInfo', function() { it('should create an instance of CSINodeInfo', function() { // uncomment below and update the code to test CSINodeInfo - //var instane = new nomad-client.CSINodeInfo(); + //var instance = new nomad-client.CSINodeInfo(); //expect(instance).to.be.a(nomad-client.CSINodeInfo); }); diff --git a/clients/javascript/v1/test/model/CSIPlugin.spec.js b/clients/javascript/v1/test/model/CSIPlugin.spec.js index cdfa05e4..72649f5c 100644 --- a/clients/javascript/v1/test/model/CSIPlugin.spec.js +++ b/clients/javascript/v1/test/model/CSIPlugin.spec.js @@ -50,7 +50,7 @@ describe('CSIPlugin', function() { it('should create an instance of CSIPlugin', function() { // uncomment below and update the code to test CSIPlugin - //var instane = new nomad-client.CSIPlugin(); + //var instance = new nomad-client.CSIPlugin(); //expect(instance).to.be.a(nomad-client.CSIPlugin); }); diff --git a/clients/javascript/v1/test/model/CSIPluginListStub.spec.js b/clients/javascript/v1/test/model/CSIPluginListStub.spec.js index 34a44a40..bcdf7113 100644 --- a/clients/javascript/v1/test/model/CSIPluginListStub.spec.js +++ b/clients/javascript/v1/test/model/CSIPluginListStub.spec.js @@ -50,7 +50,7 @@ describe('CSIPluginListStub', function() { it('should create an instance of CSIPluginListStub', function() { // uncomment below and update the code to test CSIPluginListStub - //var instane = new nomad-client.CSIPluginListStub(); + //var instance = new nomad-client.CSIPluginListStub(); //expect(instance).to.be.a(nomad-client.CSIPluginListStub); }); diff --git a/clients/javascript/v1/test/model/CSITopologyRequest.spec.js b/clients/javascript/v1/test/model/CSITopologyRequest.spec.js index 377947bb..6538bb16 100644 --- a/clients/javascript/v1/test/model/CSITopologyRequest.spec.js +++ b/clients/javascript/v1/test/model/CSITopologyRequest.spec.js @@ -50,7 +50,7 @@ describe('CSITopologyRequest', function() { it('should create an instance of CSITopologyRequest', function() { // uncomment below and update the code to test CSITopologyRequest - //var instane = new nomad-client.CSITopologyRequest(); + //var instance = new nomad-client.CSITopologyRequest(); //expect(instance).to.be.a(nomad-client.CSITopologyRequest); }); diff --git a/clients/javascript/v1/test/model/DeploymentAllocHealthRequest.spec.js b/clients/javascript/v1/test/model/DeploymentAllocHealthRequest.spec.js index 49dc5f1f..c443b484 100644 --- a/clients/javascript/v1/test/model/DeploymentAllocHealthRequest.spec.js +++ b/clients/javascript/v1/test/model/DeploymentAllocHealthRequest.spec.js @@ -50,7 +50,7 @@ describe('DeploymentAllocHealthRequest', function() { it('should create an instance of DeploymentAllocHealthRequest', function() { // uncomment below and update the code to test DeploymentAllocHealthRequest - //var instane = new nomad-client.DeploymentAllocHealthRequest(); + //var instance = new nomad-client.DeploymentAllocHealthRequest(); //expect(instance).to.be.a(nomad-client.DeploymentAllocHealthRequest); }); diff --git a/clients/javascript/v1/test/model/DeploymentPauseRequest.spec.js b/clients/javascript/v1/test/model/DeploymentPauseRequest.spec.js index 9babfa84..8cfdad53 100644 --- a/clients/javascript/v1/test/model/DeploymentPauseRequest.spec.js +++ b/clients/javascript/v1/test/model/DeploymentPauseRequest.spec.js @@ -50,7 +50,7 @@ describe('DeploymentPauseRequest', function() { it('should create an instance of DeploymentPauseRequest', function() { // uncomment below and update the code to test DeploymentPauseRequest - //var instane = new nomad-client.DeploymentPauseRequest(); + //var instance = new nomad-client.DeploymentPauseRequest(); //expect(instance).to.be.a(nomad-client.DeploymentPauseRequest); }); diff --git a/clients/javascript/v1/test/model/DeploymentPromoteRequest.spec.js b/clients/javascript/v1/test/model/DeploymentPromoteRequest.spec.js index f2d68f24..f335a53a 100644 --- a/clients/javascript/v1/test/model/DeploymentPromoteRequest.spec.js +++ b/clients/javascript/v1/test/model/DeploymentPromoteRequest.spec.js @@ -50,7 +50,7 @@ describe('DeploymentPromoteRequest', function() { it('should create an instance of DeploymentPromoteRequest', function() { // uncomment below and update the code to test DeploymentPromoteRequest - //var instane = new nomad-client.DeploymentPromoteRequest(); + //var instance = new nomad-client.DeploymentPromoteRequest(); //expect(instance).to.be.a(nomad-client.DeploymentPromoteRequest); }); diff --git a/clients/javascript/v1/test/model/DeploymentUnblockRequest.spec.js b/clients/javascript/v1/test/model/DeploymentUnblockRequest.spec.js index 42465fa9..50501671 100644 --- a/clients/javascript/v1/test/model/DeploymentUnblockRequest.spec.js +++ b/clients/javascript/v1/test/model/DeploymentUnblockRequest.spec.js @@ -50,7 +50,7 @@ describe('DeploymentUnblockRequest', function() { it('should create an instance of DeploymentUnblockRequest', function() { // uncomment below and update the code to test DeploymentUnblockRequest - //var instane = new nomad-client.DeploymentUnblockRequest(); + //var instance = new nomad-client.DeploymentUnblockRequest(); //expect(instance).to.be.a(nomad-client.DeploymentUnblockRequest); }); diff --git a/clients/javascript/v1/test/model/DeploymentUpdateResponse.spec.js b/clients/javascript/v1/test/model/DeploymentUpdateResponse.spec.js index f8b5ce1e..71fc01f1 100644 --- a/clients/javascript/v1/test/model/DeploymentUpdateResponse.spec.js +++ b/clients/javascript/v1/test/model/DeploymentUpdateResponse.spec.js @@ -50,7 +50,7 @@ describe('DeploymentUpdateResponse', function() { it('should create an instance of DeploymentUpdateResponse', function() { // uncomment below and update the code to test DeploymentUpdateResponse - //var instane = new nomad-client.DeploymentUpdateResponse(); + //var instance = new nomad-client.DeploymentUpdateResponse(); //expect(instance).to.be.a(nomad-client.DeploymentUpdateResponse); }); diff --git a/clients/javascript/v1/test/model/EvaluationStub.spec.js b/clients/javascript/v1/test/model/EvaluationStub.spec.js index 1f5cf0f9..69141fb3 100644 --- a/clients/javascript/v1/test/model/EvaluationStub.spec.js +++ b/clients/javascript/v1/test/model/EvaluationStub.spec.js @@ -50,7 +50,7 @@ describe('EvaluationStub', function() { it('should create an instance of EvaluationStub', function() { // uncomment below and update the code to test EvaluationStub - //var instane = new nomad-client.EvaluationStub(); + //var instance = new nomad-client.EvaluationStub(); //expect(instance).to.be.a(nomad-client.EvaluationStub); }); diff --git a/clients/javascript/v1/test/model/HostNetworkInfo.spec.js b/clients/javascript/v1/test/model/HostNetworkInfo.spec.js index fb914855..6b46e0ba 100644 --- a/clients/javascript/v1/test/model/HostNetworkInfo.spec.js +++ b/clients/javascript/v1/test/model/HostNetworkInfo.spec.js @@ -50,7 +50,7 @@ describe('HostNetworkInfo', function() { it('should create an instance of HostNetworkInfo', function() { // uncomment below and update the code to test HostNetworkInfo - //var instane = new nomad-client.HostNetworkInfo(); + //var instance = new nomad-client.HostNetworkInfo(); //expect(instance).to.be.a(nomad-client.HostNetworkInfo); }); diff --git a/clients/javascript/v1/test/model/NamespaceCapabilities.spec.js b/clients/javascript/v1/test/model/NamespaceCapabilities.spec.js index 6616342b..c15ba176 100644 --- a/clients/javascript/v1/test/model/NamespaceCapabilities.spec.js +++ b/clients/javascript/v1/test/model/NamespaceCapabilities.spec.js @@ -50,7 +50,7 @@ describe('NamespaceCapabilities', function() { it('should create an instance of NamespaceCapabilities', function() { // uncomment below and update the code to test NamespaceCapabilities - //var instane = new nomad-client.NamespaceCapabilities(); + //var instance = new nomad-client.NamespaceCapabilities(); //expect(instance).to.be.a(nomad-client.NamespaceCapabilities); }); diff --git a/clients/javascript/v1/test/model/OneTimeToken.spec.js b/clients/javascript/v1/test/model/OneTimeToken.spec.js index b02dbe64..40e9d5e6 100644 --- a/clients/javascript/v1/test/model/OneTimeToken.spec.js +++ b/clients/javascript/v1/test/model/OneTimeToken.spec.js @@ -50,7 +50,7 @@ describe('OneTimeToken', function() { it('should create an instance of OneTimeToken', function() { // uncomment below and update the code to test OneTimeToken - //var instane = new nomad-client.OneTimeToken(); + //var instance = new nomad-client.OneTimeToken(); //expect(instance).to.be.a(nomad-client.OneTimeToken); }); diff --git a/clients/javascript/v1/test/model/OneTimeTokenExchangeRequest.spec.js b/clients/javascript/v1/test/model/OneTimeTokenExchangeRequest.spec.js index a1e5c8a3..3883a51b 100644 --- a/clients/javascript/v1/test/model/OneTimeTokenExchangeRequest.spec.js +++ b/clients/javascript/v1/test/model/OneTimeTokenExchangeRequest.spec.js @@ -50,7 +50,7 @@ describe('OneTimeTokenExchangeRequest', function() { it('should create an instance of OneTimeTokenExchangeRequest', function() { // uncomment below and update the code to test OneTimeTokenExchangeRequest - //var instane = new nomad-client.OneTimeTokenExchangeRequest(); + //var instance = new nomad-client.OneTimeTokenExchangeRequest(); //expect(instance).to.be.a(nomad-client.OneTimeTokenExchangeRequest); }); diff --git a/clients/javascript/v1/test/model/OperatorHealthReply.spec.js b/clients/javascript/v1/test/model/OperatorHealthReply.spec.js index 58d082e3..e00a6513 100644 --- a/clients/javascript/v1/test/model/OperatorHealthReply.spec.js +++ b/clients/javascript/v1/test/model/OperatorHealthReply.spec.js @@ -50,7 +50,7 @@ describe('OperatorHealthReply', function() { it('should create an instance of OperatorHealthReply', function() { // uncomment below and update the code to test OperatorHealthReply - //var instane = new nomad-client.OperatorHealthReply(); + //var instance = new nomad-client.OperatorHealthReply(); //expect(instance).to.be.a(nomad-client.OperatorHealthReply); }); diff --git a/clients/javascript/v1/test/model/PreemptionConfig.spec.js b/clients/javascript/v1/test/model/PreemptionConfig.spec.js index 77eed725..cc0aa105 100644 --- a/clients/javascript/v1/test/model/PreemptionConfig.spec.js +++ b/clients/javascript/v1/test/model/PreemptionConfig.spec.js @@ -50,7 +50,7 @@ describe('PreemptionConfig', function() { it('should create an instance of PreemptionConfig', function() { // uncomment below and update the code to test PreemptionConfig - //var instane = new nomad-client.PreemptionConfig(); + //var instance = new nomad-client.PreemptionConfig(); //expect(instance).to.be.a(nomad-client.PreemptionConfig); }); diff --git a/clients/javascript/v1/test/model/RaftConfiguration.spec.js b/clients/javascript/v1/test/model/RaftConfiguration.spec.js index 901d6ba3..89c38226 100644 --- a/clients/javascript/v1/test/model/RaftConfiguration.spec.js +++ b/clients/javascript/v1/test/model/RaftConfiguration.spec.js @@ -50,7 +50,7 @@ describe('RaftConfiguration', function() { it('should create an instance of RaftConfiguration', function() { // uncomment below and update the code to test RaftConfiguration - //var instane = new nomad-client.RaftConfiguration(); + //var instance = new nomad-client.RaftConfiguration(); //expect(instance).to.be.a(nomad-client.RaftConfiguration); }); diff --git a/clients/javascript/v1/test/model/RaftServer.spec.js b/clients/javascript/v1/test/model/RaftServer.spec.js index e26b7cd4..8a5f48cd 100644 --- a/clients/javascript/v1/test/model/RaftServer.spec.js +++ b/clients/javascript/v1/test/model/RaftServer.spec.js @@ -50,7 +50,7 @@ describe('RaftServer', function() { it('should create an instance of RaftServer', function() { // uncomment below and update the code to test RaftServer - //var instane = new nomad-client.RaftServer(); + //var instance = new nomad-client.RaftServer(); //expect(instance).to.be.a(nomad-client.RaftServer); }); diff --git a/clients/javascript/v1/test/model/ScalingPolicyListStub.spec.js b/clients/javascript/v1/test/model/ScalingPolicyListStub.spec.js index 2bd46b1d..031622be 100644 --- a/clients/javascript/v1/test/model/ScalingPolicyListStub.spec.js +++ b/clients/javascript/v1/test/model/ScalingPolicyListStub.spec.js @@ -50,7 +50,7 @@ describe('ScalingPolicyListStub', function() { it('should create an instance of ScalingPolicyListStub', function() { // uncomment below and update the code to test ScalingPolicyListStub - //var instane = new nomad-client.ScalingPolicyListStub(); + //var instance = new nomad-client.ScalingPolicyListStub(); //expect(instance).to.be.a(nomad-client.ScalingPolicyListStub); }); diff --git a/clients/javascript/v1/test/model/SchedulerConfiguration.spec.js b/clients/javascript/v1/test/model/SchedulerConfiguration.spec.js index 48fe20d9..005ff4ff 100644 --- a/clients/javascript/v1/test/model/SchedulerConfiguration.spec.js +++ b/clients/javascript/v1/test/model/SchedulerConfiguration.spec.js @@ -50,7 +50,7 @@ describe('SchedulerConfiguration', function() { it('should create an instance of SchedulerConfiguration', function() { // uncomment below and update the code to test SchedulerConfiguration - //var instane = new nomad-client.SchedulerConfiguration(); + //var instance = new nomad-client.SchedulerConfiguration(); //expect(instance).to.be.a(nomad-client.SchedulerConfiguration); }); diff --git a/clients/javascript/v1/test/model/SchedulerConfigurationResponse.spec.js b/clients/javascript/v1/test/model/SchedulerConfigurationResponse.spec.js index be42cdc5..8396c737 100644 --- a/clients/javascript/v1/test/model/SchedulerConfigurationResponse.spec.js +++ b/clients/javascript/v1/test/model/SchedulerConfigurationResponse.spec.js @@ -50,7 +50,7 @@ describe('SchedulerConfigurationResponse', function() { it('should create an instance of SchedulerConfigurationResponse', function() { // uncomment below and update the code to test SchedulerConfigurationResponse - //var instane = new nomad-client.SchedulerConfigurationResponse(); + //var instance = new nomad-client.SchedulerConfigurationResponse(); //expect(instance).to.be.a(nomad-client.SchedulerConfigurationResponse); }); diff --git a/clients/javascript/v1/test/model/SchedulerSetConfigurationResponse.spec.js b/clients/javascript/v1/test/model/SchedulerSetConfigurationResponse.spec.js index d8f1feba..c15a4859 100644 --- a/clients/javascript/v1/test/model/SchedulerSetConfigurationResponse.spec.js +++ b/clients/javascript/v1/test/model/SchedulerSetConfigurationResponse.spec.js @@ -50,7 +50,7 @@ describe('SchedulerSetConfigurationResponse', function() { it('should create an instance of SchedulerSetConfigurationResponse', function() { // uncomment below and update the code to test SchedulerSetConfigurationResponse - //var instane = new nomad-client.SchedulerSetConfigurationResponse(); + //var instance = new nomad-client.SchedulerSetConfigurationResponse(); //expect(instance).to.be.a(nomad-client.SchedulerSetConfigurationResponse); }); diff --git a/clients/javascript/v1/test/model/ServerHealth.spec.js b/clients/javascript/v1/test/model/ServerHealth.spec.js index a473f386..c7f780e9 100644 --- a/clients/javascript/v1/test/model/ServerHealth.spec.js +++ b/clients/javascript/v1/test/model/ServerHealth.spec.js @@ -50,7 +50,7 @@ describe('ServerHealth', function() { it('should create an instance of ServerHealth', function() { // uncomment below and update the code to test ServerHealth - //var instane = new nomad-client.ServerHealth(); + //var instance = new nomad-client.ServerHealth(); //expect(instance).to.be.a(nomad-client.ServerHealth); }); diff --git a/clients/javascript/v1/test/model/ServiceRegistration.spec.js b/clients/javascript/v1/test/model/ServiceRegistration.spec.js index 9d495448..c0b1567f 100644 --- a/clients/javascript/v1/test/model/ServiceRegistration.spec.js +++ b/clients/javascript/v1/test/model/ServiceRegistration.spec.js @@ -50,7 +50,7 @@ describe('ServiceRegistration', function() { it('should create an instance of ServiceRegistration', function() { // uncomment below and update the code to test ServiceRegistration - //var instane = new nomad-client.ServiceRegistration(); + //var instance = new nomad-client.ServiceRegistration(); //expect(instance).to.be.a(nomad-client.ServiceRegistration); }); diff --git a/clients/javascript/v1/test/model/WaitConfig.spec.js b/clients/javascript/v1/test/model/WaitConfig.spec.js index f03c0eb3..e7014073 100644 --- a/clients/javascript/v1/test/model/WaitConfig.spec.js +++ b/clients/javascript/v1/test/model/WaitConfig.spec.js @@ -50,7 +50,7 @@ describe('WaitConfig', function() { it('should create an instance of WaitConfig', function() { // uncomment below and update the code to test WaitConfig - //var instane = new nomad-client.WaitConfig(); + //var instance = new nomad-client.WaitConfig(); //expect(instance).to.be.a(nomad-client.WaitConfig); }); diff --git a/clients/python/jobs_list.py b/clients/python/jobs_list.py new file mode 100644 index 00000000..356d9f27 --- /dev/null +++ b/clients/python/jobs_list.py @@ -0,0 +1,21 @@ +import nomad_client +import nomad_client.apis +from pprint import pprint + + +nc_config = nomad_client.Configuration( + host="http://127.0.0.1:4646/v1" +) + +nc = nomad_client.ApiClient(configuration=nc_config) +jobsApi = nomad_client.apis.JobsApi(nc) + +try: + jobs = jobsApi.get_jobs() + pprint(jobs) + + job = jobsApi.get_job(job_name="example") + pprint(job) +except nomad_client.ApiException as e: + print("Exception when calling JobsApi.get_jobs: %s\n" % e) + diff --git a/clients/python/v1/.openapi-generator/VERSION b/clients/python/v1/.openapi-generator/VERSION index 7cbea073..1e20ec35 100644 --- a/clients/python/v1/.openapi-generator/VERSION +++ b/clients/python/v1/.openapi-generator/VERSION @@ -1 +1 @@ -5.2.0 \ No newline at end of file +5.4.0 \ No newline at end of file diff --git a/clients/python/v1/README.md b/clients/python/v1/README.md index d3c7c60b..e010a139 100644 --- a/clients/python/v1/README.md +++ b/clients/python/v1/README.md @@ -9,7 +9,7 @@ This Python package is automatically generated by the [OpenAPI Generator](https: ## Requirements. -Python >= 3.6 +Python >=3.6 ## Installation & Usage ### pip install diff --git a/clients/python/v1/docs/ACLApi.md b/clients/python/v1/docs/ACLApi.md index 0115f601..4b436765 100644 --- a/clients/python/v1/docs/ACLApi.md +++ b/clients/python/v1/docs/ACLApi.md @@ -26,6 +26,7 @@ Method | HTTP request | Description ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -98,6 +99,7 @@ void (empty response body) ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| @@ -116,6 +118,7 @@ void (empty response body) ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -188,6 +191,7 @@ void (empty response body) ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| @@ -206,6 +210,7 @@ void (empty response body) ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -282,6 +287,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -300,6 +306,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -385,6 +392,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -403,6 +411,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -488,6 +497,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -506,6 +516,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -582,6 +593,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -600,6 +612,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -676,6 +689,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -694,6 +708,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -760,6 +775,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| @@ -778,6 +794,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -859,6 +876,7 @@ void (empty response body) ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| @@ -877,6 +895,7 @@ void (empty response body) ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -966,6 +985,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| @@ -984,6 +1004,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -1050,6 +1071,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| @@ -1068,6 +1090,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -1146,6 +1169,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| diff --git a/clients/python/v1/docs/ACLToken.md b/clients/python/v1/docs/ACLToken.md index 7e6a7ba6..85ad8f39 100644 --- a/clients/python/v1/docs/ACLToken.md +++ b/clients/python/v1/docs/ACLToken.md @@ -6,7 +6,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **accessor_id** | **str** | | [optional] **create_index** | **int** | | [optional] -**create_time** | **datetime** | | [optional] +**create_time** | **datetime, none_type** | | [optional] **_global** | **bool** | | [optional] **modify_index** | **int** | | [optional] **name** | **str** | | [optional] diff --git a/clients/python/v1/docs/ACLTokenListStub.md b/clients/python/v1/docs/ACLTokenListStub.md index 309bffbc..6d8791b9 100644 --- a/clients/python/v1/docs/ACLTokenListStub.md +++ b/clients/python/v1/docs/ACLTokenListStub.md @@ -6,7 +6,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **accessor_id** | **str** | | [optional] **create_index** | **int** | | [optional] -**create_time** | **datetime** | | [optional] +**create_time** | **datetime, none_type** | | [optional] **_global** | **bool** | | [optional] **modify_index** | **int** | | [optional] **name** | **str** | | [optional] diff --git a/clients/python/v1/docs/AllocDeploymentStatus.md b/clients/python/v1/docs/AllocDeploymentStatus.md index d9f7f399..3aa183a0 100644 --- a/clients/python/v1/docs/AllocDeploymentStatus.md +++ b/clients/python/v1/docs/AllocDeploymentStatus.md @@ -7,7 +7,7 @@ Name | Type | Description | Notes **canary** | **bool** | | [optional] **healthy** | **bool** | | [optional] **modify_index** | **int** | | [optional] -**timestamp** | **datetime** | | [optional] +**timestamp** | **datetime, none_type** | | [optional] **any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional] [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/python/v1/docs/AllocationsApi.md b/clients/python/v1/docs/AllocationsApi.md index 8d80f03c..ee431617 100644 --- a/clients/python/v1/docs/AllocationsApi.md +++ b/clients/python/v1/docs/AllocationsApi.md @@ -18,6 +18,7 @@ Method | HTTP request | Description ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -103,6 +104,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -121,6 +123,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -206,6 +209,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -224,6 +228,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -304,6 +309,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -322,6 +328,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -409,6 +416,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| diff --git a/clients/python/v1/docs/CSIInfo.md b/clients/python/v1/docs/CSIInfo.md index be8c0c94..ac106ace 100644 --- a/clients/python/v1/docs/CSIInfo.md +++ b/clients/python/v1/docs/CSIInfo.md @@ -12,7 +12,7 @@ Name | Type | Description | Notes **plugin_id** | **str** | | [optional] **requires_controller_plugin** | **bool** | | [optional] **requires_topologies** | **bool** | | [optional] -**update_time** | **datetime** | | [optional] +**update_time** | **datetime, none_type** | | [optional] **any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional] [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/python/v1/docs/CSIVolume.md b/clients/python/v1/docs/CSIVolume.md index 1af904c9..fc961fdd 100644 --- a/clients/python/v1/docs/CSIVolume.md +++ b/clients/python/v1/docs/CSIVolume.md @@ -31,7 +31,7 @@ Name | Type | Description | Notes **requested_capacity_max** | **int** | | [optional] **requested_capacity_min** | **int** | | [optional] **requested_topologies** | [**CSITopologyRequest**](CSITopologyRequest.md) | | [optional] -**resource_exhausted** | **datetime** | | [optional] +**resource_exhausted** | **datetime, none_type** | | [optional] **schedulable** | **bool** | | [optional] **secrets** | [**CSISecrets**](CSISecrets.md) | | [optional] **snapshot_id** | **str** | | [optional] diff --git a/clients/python/v1/docs/CSIVolumeListStub.md b/clients/python/v1/docs/CSIVolumeListStub.md index 6c73f627..23da9c2c 100644 --- a/clients/python/v1/docs/CSIVolumeListStub.md +++ b/clients/python/v1/docs/CSIVolumeListStub.md @@ -19,7 +19,7 @@ Name | Type | Description | Notes **nodes_healthy** | **int** | | [optional] **plugin_id** | **str** | | [optional] **provider** | **str** | | [optional] -**resource_exhausted** | **datetime** | | [optional] +**resource_exhausted** | **datetime, none_type** | | [optional] **schedulable** | **bool** | | [optional] **topologies** | [**[CSITopology]**](CSITopology.md) | | [optional] **any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional] diff --git a/clients/python/v1/docs/DeploymentState.md b/clients/python/v1/docs/DeploymentState.md index a634f3ee..8755e844 100644 --- a/clients/python/v1/docs/DeploymentState.md +++ b/clients/python/v1/docs/DeploymentState.md @@ -12,7 +12,7 @@ Name | Type | Description | Notes **placed_canaries** | **[str]** | | [optional] **progress_deadline** | **int** | | [optional] **promoted** | **bool** | | [optional] -**require_progress_by** | **datetime** | | [optional] +**require_progress_by** | **datetime, none_type** | | [optional] **unhealthy_allocs** | **int** | | [optional] **any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional] diff --git a/clients/python/v1/docs/DeploymentsApi.md b/clients/python/v1/docs/DeploymentsApi.md index 0183d288..7fbd2125 100644 --- a/clients/python/v1/docs/DeploymentsApi.md +++ b/clients/python/v1/docs/DeploymentsApi.md @@ -22,6 +22,7 @@ Method | HTTP request | Description ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -107,6 +108,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -125,6 +127,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -210,6 +213,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -228,6 +232,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -304,6 +309,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -322,6 +328,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -411,6 +418,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | - | @@ -429,6 +437,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -504,6 +513,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | - | @@ -522,6 +532,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -606,6 +617,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | - | @@ -624,6 +636,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -711,6 +724,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | - | @@ -729,6 +743,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -812,6 +827,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | - | diff --git a/clients/python/v1/docs/DrainMetadata.md b/clients/python/v1/docs/DrainMetadata.md index 19d0d147..272de9d9 100644 --- a/clients/python/v1/docs/DrainMetadata.md +++ b/clients/python/v1/docs/DrainMetadata.md @@ -6,9 +6,9 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **accessor_id** | **str** | | [optional] **meta** | **{str: (str,)}** | | [optional] -**started_at** | **datetime** | | [optional] +**started_at** | **datetime, none_type** | | [optional] **status** | **str** | | [optional] -**updated_at** | **datetime** | | [optional] +**updated_at** | **datetime, none_type** | | [optional] **any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional] [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/python/v1/docs/DrainStrategy.md b/clients/python/v1/docs/DrainStrategy.md index 47c421bc..480ae920 100644 --- a/clients/python/v1/docs/DrainStrategy.md +++ b/clients/python/v1/docs/DrainStrategy.md @@ -5,9 +5,9 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **deadline** | **int** | | [optional] -**force_deadline** | **datetime** | | [optional] +**force_deadline** | **datetime, none_type** | | [optional] **ignore_system_jobs** | **bool** | | [optional] -**started_at** | **datetime** | | [optional] +**started_at** | **datetime, none_type** | | [optional] **any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional] [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/python/v1/docs/DriverInfo.md b/clients/python/v1/docs/DriverInfo.md index e5e02afb..d220ed65 100644 --- a/clients/python/v1/docs/DriverInfo.md +++ b/clients/python/v1/docs/DriverInfo.md @@ -8,7 +8,7 @@ Name | Type | Description | Notes **detected** | **bool** | | [optional] **health_description** | **str** | | [optional] **healthy** | **bool** | | [optional] -**update_time** | **datetime** | | [optional] +**update_time** | **datetime, none_type** | | [optional] **any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional] [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/python/v1/docs/EnterpriseApi.md b/clients/python/v1/docs/EnterpriseApi.md index fa54a08c..2abe792c 100644 --- a/clients/python/v1/docs/EnterpriseApi.md +++ b/clients/python/v1/docs/EnterpriseApi.md @@ -19,6 +19,7 @@ Method | HTTP request | Description ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -169,6 +170,7 @@ void (empty response body) ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| @@ -187,6 +189,7 @@ void (empty response body) ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -259,6 +262,7 @@ void (empty response body) ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| @@ -277,6 +281,7 @@ void (empty response body) ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -362,6 +367,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -373,13 +379,14 @@ Name | Type | Description | Notes [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) # **get_quotas** -> [bool, date, datetime, dict, float, int, list, str, none_type] get_quotas() +> [object] get_quotas() ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -442,7 +449,7 @@ Name | Type | Description | Notes ### Return type -**[bool, date, datetime, dict, float, int, list, str, none_type]** +**[object]** ### Authorization @@ -455,6 +462,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -473,6 +481,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -625,6 +634,7 @@ void (empty response body) ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| diff --git a/clients/python/v1/docs/Evaluation.md b/clients/python/v1/docs/Evaluation.md index 4a77a929..fc4b00a5 100644 --- a/clients/python/v1/docs/Evaluation.md +++ b/clients/python/v1/docs/Evaluation.md @@ -32,7 +32,7 @@ Name | Type | Description | Notes **triggered_by** | **str** | | [optional] **type** | **str** | | [optional] **wait** | **int** | | [optional] -**wait_until** | **datetime** | | [optional] +**wait_until** | **datetime, none_type** | | [optional] **any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional] [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/python/v1/docs/EvaluationStub.md b/clients/python/v1/docs/EvaluationStub.md index c10f3732..12134e93 100644 --- a/clients/python/v1/docs/EvaluationStub.md +++ b/clients/python/v1/docs/EvaluationStub.md @@ -21,7 +21,7 @@ Name | Type | Description | Notes **status_description** | **str** | | [optional] **triggered_by** | **str** | | [optional] **type** | **str** | | [optional] -**wait_until** | **datetime** | | [optional] +**wait_until** | **datetime, none_type** | | [optional] **any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional] [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/python/v1/docs/EvaluationsApi.md b/clients/python/v1/docs/EvaluationsApi.md index 73ce5779..6dc3874e 100644 --- a/clients/python/v1/docs/EvaluationsApi.md +++ b/clients/python/v1/docs/EvaluationsApi.md @@ -17,6 +17,7 @@ Method | HTTP request | Description ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -102,6 +103,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -120,6 +122,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -205,6 +208,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -223,6 +227,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -299,6 +304,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| diff --git a/clients/python/v1/docs/Int8.md b/clients/python/v1/docs/Int8.md index 69c88a54..abb520da 100644 --- a/clients/python/v1/docs/Int8.md +++ b/clients/python/v1/docs/Int8.md @@ -5,7 +5,6 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **value** | **int** | | -**any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional] [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/python/v1/docs/JobPlanResponse.md b/clients/python/v1/docs/JobPlanResponse.md index 9aea459d..784d1cb1 100644 --- a/clients/python/v1/docs/JobPlanResponse.md +++ b/clients/python/v1/docs/JobPlanResponse.md @@ -9,7 +9,7 @@ Name | Type | Description | Notes **diff** | [**JobDiff**](JobDiff.md) | | [optional] **failed_tg_allocs** | [**{str: (AllocationMetric,)}**](AllocationMetric.md) | | [optional] **job_modify_index** | **int** | | [optional] -**next_periodic_launch** | **datetime** | | [optional] +**next_periodic_launch** | **datetime, none_type** | | [optional] **warnings** | **str** | | [optional] **any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional] diff --git a/clients/python/v1/docs/JobsApi.md b/clients/python/v1/docs/JobsApi.md index 1f63cac6..fb89366a 100644 --- a/clients/python/v1/docs/JobsApi.md +++ b/clients/python/v1/docs/JobsApi.md @@ -35,6 +35,7 @@ Method | HTTP request | Description ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -114,6 +115,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| @@ -132,6 +134,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -217,6 +220,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -235,6 +239,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -322,6 +327,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -340,6 +346,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -425,6 +432,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -443,6 +451,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -530,6 +539,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -548,6 +558,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -633,6 +644,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -651,6 +663,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -736,6 +749,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -754,6 +768,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -839,6 +854,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -857,6 +873,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -944,6 +961,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -962,6 +980,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -1038,6 +1057,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -1056,6 +1076,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -2102,6 +2123,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -2120,6 +2142,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -2204,6 +2227,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| @@ -2222,6 +2246,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -2308,6 +2333,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| @@ -2326,6 +2352,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -2390,6 +2417,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | - | @@ -2408,6 +2436,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -2483,6 +2512,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| @@ -2501,6 +2531,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -3544,6 +3575,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| @@ -3562,6 +3594,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -3649,6 +3682,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| @@ -3667,6 +3701,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -3759,6 +3794,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| @@ -3777,6 +3813,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -3862,6 +3899,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| @@ -3880,6 +3918,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -4919,6 +4958,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| @@ -4937,6 +4977,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -5981,6 +6022,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| diff --git a/clients/python/v1/docs/MetricsApi.md b/clients/python/v1/docs/MetricsApi.md index 650bd0bc..3f1da4ce 100644 --- a/clients/python/v1/docs/MetricsApi.md +++ b/clients/python/v1/docs/MetricsApi.md @@ -15,6 +15,7 @@ Method | HTTP request | Description ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -75,6 +76,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | - | diff --git a/clients/python/v1/docs/NamespacesApi.md b/clients/python/v1/docs/NamespacesApi.md index d97542a6..f7b037b3 100644 --- a/clients/python/v1/docs/NamespacesApi.md +++ b/clients/python/v1/docs/NamespacesApi.md @@ -19,6 +19,7 @@ Method | HTTP request | Description ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -83,6 +84,7 @@ void (empty response body) ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| @@ -101,6 +103,7 @@ void (empty response body) ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -173,6 +176,7 @@ void (empty response body) ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| @@ -191,6 +195,7 @@ void (empty response body) ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -276,6 +281,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -294,6 +300,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -370,6 +377,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -388,6 +396,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -480,6 +489,7 @@ void (empty response body) ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| diff --git a/clients/python/v1/docs/NodeEvent.md b/clients/python/v1/docs/NodeEvent.md index 44d1692e..8b08b74c 100644 --- a/clients/python/v1/docs/NodeEvent.md +++ b/clients/python/v1/docs/NodeEvent.md @@ -8,7 +8,7 @@ Name | Type | Description | Notes **details** | **{str: (str,)}** | | [optional] **message** | **str** | | [optional] **subsystem** | **str** | | [optional] -**timestamp** | **datetime** | | [optional] +**timestamp** | **datetime, none_type** | | [optional] **any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional] [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/python/v1/docs/NodesApi.md b/clients/python/v1/docs/NodesApi.md index 8dbb7b74..e240e22f 100644 --- a/clients/python/v1/docs/NodesApi.md +++ b/clients/python/v1/docs/NodesApi.md @@ -20,6 +20,7 @@ Method | HTTP request | Description ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -105,6 +106,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -123,6 +125,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -208,6 +211,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -226,6 +230,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -304,6 +309,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -322,6 +328,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -420,6 +427,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| @@ -438,6 +446,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -529,6 +538,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| @@ -547,6 +557,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -632,6 +643,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| diff --git a/clients/python/v1/docs/OneTimeToken.md b/clients/python/v1/docs/OneTimeToken.md index 2771eeed..0f690a52 100644 --- a/clients/python/v1/docs/OneTimeToken.md +++ b/clients/python/v1/docs/OneTimeToken.md @@ -6,7 +6,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **accessor_id** | **str** | | [optional] **create_index** | **int** | | [optional] -**expires_at** | **datetime** | | [optional] +**expires_at** | **datetime, none_type** | | [optional] **modify_index** | **int** | | [optional] **one_time_secret_id** | **str** | | [optional] **any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional] diff --git a/clients/python/v1/docs/OperatorApi.md b/clients/python/v1/docs/OperatorApi.md index f0f2631d..d339f352 100644 --- a/clients/python/v1/docs/OperatorApi.md +++ b/clients/python/v1/docs/OperatorApi.md @@ -21,6 +21,7 @@ Method | HTTP request | Description ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -85,6 +86,7 @@ void (empty response body) ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | - | @@ -103,6 +105,7 @@ void (empty response body) ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -179,6 +182,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | - | @@ -197,6 +201,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -273,6 +278,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | - | @@ -291,6 +297,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -367,6 +374,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | - | @@ -385,6 +393,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -461,6 +470,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -479,6 +489,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -568,6 +579,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| @@ -586,6 +598,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -672,6 +685,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | - | diff --git a/clients/python/v1/docs/PluginsApi.md b/clients/python/v1/docs/PluginsApi.md index 5ba02a93..6b905c9d 100644 --- a/clients/python/v1/docs/PluginsApi.md +++ b/clients/python/v1/docs/PluginsApi.md @@ -16,6 +16,7 @@ Method | HTTP request | Description ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -101,6 +102,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -119,6 +121,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -195,6 +198,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | - | diff --git a/clients/python/v1/docs/RegionsApi.md b/clients/python/v1/docs/RegionsApi.md index d1ef5e23..c2a67c34 100644 --- a/clients/python/v1/docs/RegionsApi.md +++ b/clients/python/v1/docs/RegionsApi.md @@ -15,6 +15,7 @@ Method | HTTP request | Description ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -69,6 +70,7 @@ This endpoint does not need any parameter. ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | - | diff --git a/clients/python/v1/docs/ScalingApi.md b/clients/python/v1/docs/ScalingApi.md index 50121b53..2cc309e4 100644 --- a/clients/python/v1/docs/ScalingApi.md +++ b/clients/python/v1/docs/ScalingApi.md @@ -16,6 +16,7 @@ Method | HTTP request | Description ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -92,6 +93,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -110,6 +112,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -195,6 +198,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| diff --git a/clients/python/v1/docs/SearchApi.md b/clients/python/v1/docs/SearchApi.md index 9c794de2..2dd4ace2 100644 --- a/clients/python/v1/docs/SearchApi.md +++ b/clients/python/v1/docs/SearchApi.md @@ -16,6 +16,7 @@ Method | HTTP request | Description ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -122,6 +123,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -140,6 +142,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -245,6 +248,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| diff --git a/clients/python/v1/docs/ServerHealth.md b/clients/python/v1/docs/ServerHealth.md index c9259c02..488a8743 100644 --- a/clients/python/v1/docs/ServerHealth.md +++ b/clients/python/v1/docs/ServerHealth.md @@ -13,7 +13,7 @@ Name | Type | Description | Notes **leader** | **bool** | | [optional] **name** | **str** | | [optional] **serf_status** | **str** | | [optional] -**stable_since** | **datetime** | | [optional] +**stable_since** | **datetime, none_type** | | [optional] **version** | **str** | | [optional] **voter** | **bool** | | [optional] **any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional] diff --git a/clients/python/v1/docs/StatusApi.md b/clients/python/v1/docs/StatusApi.md index bebdf7b2..3c65118b 100644 --- a/clients/python/v1/docs/StatusApi.md +++ b/clients/python/v1/docs/StatusApi.md @@ -16,6 +16,7 @@ Method | HTTP request | Description ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -91,6 +92,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | - | @@ -109,6 +111,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -184,6 +187,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | - | diff --git a/clients/python/v1/docs/SystemApi.md b/clients/python/v1/docs/SystemApi.md index 6d2ddf9c..3a2e235a 100644 --- a/clients/python/v1/docs/SystemApi.md +++ b/clients/python/v1/docs/SystemApi.md @@ -16,6 +16,7 @@ Method | HTTP request | Description ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -80,6 +81,7 @@ void (empty response body) ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | - | @@ -98,6 +100,7 @@ void (empty response body) ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -162,6 +165,7 @@ void (empty response body) ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | - | diff --git a/clients/python/v1/docs/TaskGroupDiff.md b/clients/python/v1/docs/TaskGroupDiff.md index 53d8e76f..fe1f2fac 100644 --- a/clients/python/v1/docs/TaskGroupDiff.md +++ b/clients/python/v1/docs/TaskGroupDiff.md @@ -9,7 +9,7 @@ Name | Type | Description | Notes **objects** | [**[ObjectDiff]**](ObjectDiff.md) | | [optional] **tasks** | [**[TaskDiff]**](TaskDiff.md) | | [optional] **type** | **str** | | [optional] -**updates** | **{str: (int,)}** | | [optional] +**updates** | **{str: (Uint64,)}** | | [optional] **any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional] [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/python/v1/docs/TaskState.md b/clients/python/v1/docs/TaskState.md index 964b5477..0726614f 100644 --- a/clients/python/v1/docs/TaskState.md +++ b/clients/python/v1/docs/TaskState.md @@ -6,10 +6,10 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **events** | [**[TaskEvent]**](TaskEvent.md) | | [optional] **failed** | **bool** | | [optional] -**finished_at** | **datetime** | | [optional] -**last_restart** | **datetime** | | [optional] +**finished_at** | **datetime, none_type** | | [optional] +**last_restart** | **datetime, none_type** | | [optional] **restarts** | **int** | | [optional] -**started_at** | **datetime** | | [optional] +**started_at** | **datetime, none_type** | | [optional] **state** | **str** | | [optional] **task_handle** | [**TaskHandle**](TaskHandle.md) | | [optional] **any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional] diff --git a/clients/python/v1/docs/Uint.md b/clients/python/v1/docs/Uint.md index 715b9226..7eed0deb 100644 --- a/clients/python/v1/docs/Uint.md +++ b/clients/python/v1/docs/Uint.md @@ -5,7 +5,6 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **value** | **int** | | -**any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional] [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/python/v1/docs/Uint16.md b/clients/python/v1/docs/Uint16.md index 727539e8..fdc94dd4 100644 --- a/clients/python/v1/docs/Uint16.md +++ b/clients/python/v1/docs/Uint16.md @@ -5,7 +5,6 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **value** | **int** | | -**any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional] [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/python/v1/docs/Uint64.md b/clients/python/v1/docs/Uint64.md index 48138387..6cb5c1f1 100644 --- a/clients/python/v1/docs/Uint64.md +++ b/clients/python/v1/docs/Uint64.md @@ -5,7 +5,6 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **value** | **int** | | -**any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional] [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/python/v1/docs/Uint8.md b/clients/python/v1/docs/Uint8.md index 4c6ea374..b56fdb1b 100644 --- a/clients/python/v1/docs/Uint8.md +++ b/clients/python/v1/docs/Uint8.md @@ -5,7 +5,6 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **value** | **int** | | -**any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional] [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/clients/python/v1/docs/VolumesApi.md b/clients/python/v1/docs/VolumesApi.md index 1536601d..ee70ff7c 100644 --- a/clients/python/v1/docs/VolumesApi.md +++ b/clients/python/v1/docs/VolumesApi.md @@ -25,6 +25,7 @@ Method | HTTP request | Description ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -3176,6 +3177,7 @@ void (empty response body) ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -3194,6 +3196,7 @@ void (empty response body) ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -3262,6 +3265,7 @@ void (empty response body) ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| @@ -3280,6 +3284,7 @@ void (empty response body) ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -3354,6 +3359,7 @@ void (empty response body) ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| @@ -3372,6 +3378,7 @@ void (empty response body) ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -3448,6 +3455,7 @@ void (empty response body) ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -3466,6 +3474,7 @@ void (empty response body) ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -3544,6 +3553,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -3562,6 +3572,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -3640,6 +3651,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -3658,6 +3670,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -3743,6 +3756,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -3761,6 +3775,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -3843,6 +3858,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -3861,6 +3877,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -3959,6 +3976,7 @@ Name | Type | Description | Notes ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| @@ -3977,6 +3995,7 @@ Name | Type | Description | Notes ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -7124,6 +7143,7 @@ void (empty response body) ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| @@ -7142,6 +7162,7 @@ void (empty response body) ### Example * Api Key Authentication (X-Nomad-Token): + ```python import time import nomad_client @@ -10291,6 +10312,7 @@ void (empty response body) ### HTTP response details + | Status code | Description | Response headers | |-------------|-------------|------------------| **200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| diff --git a/clients/python/v1/nomad_client/api/acl_api.py b/clients/python/v1/nomad_client/api/acl_api.py index f05378da..e0290875 100644 --- a/clients/python/v1/nomad_client/api/acl_api.py +++ b/clients/python/v1/nomad_client/api/acl_api.py @@ -41,77 +41,7 @@ def __init__(self, api_client=None): if api_client is None: api_client = ApiClient() self.api_client = api_client - - def __delete_acl_policy( - self, - policy_name, - **kwargs - ): - """delete_acl_policy # 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_acl_policy(policy_name, async_req=True) - >>> result = thread.get() - - Args: - policy_name (str): The ACL policy name. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - None - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['policy_name'] = \ - policy_name - return self.call_with_http_info(**kwargs) - - self.delete_acl_policy = _Endpoint( + self.delete_acl_policy_endpoint = _Endpoint( settings={ 'response_type': None, 'auth': [ @@ -178,80 +108,9 @@ def __delete_acl_policy( 'accept': [], 'content_type': [], }, - api_client=api_client, - callable=__delete_acl_policy - ) - - def __delete_acl_token( - self, - token_accessor, - **kwargs - ): - """delete_acl_token # 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_acl_token(token_accessor, async_req=True) - >>> result = thread.get() - - Args: - token_accessor (str): The token accessor ID. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - None - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['token_accessor'] = \ - token_accessor - return self.call_with_http_info(**kwargs) - - self.delete_acl_token = _Endpoint( + api_client=api_client + ) + self.delete_acl_token_endpoint = _Endpoint( settings={ 'response_type': None, 'auth': [ @@ -318,80 +177,9 @@ def __delete_acl_token( 'accept': [], 'content_type': [], }, - api_client=api_client, - callable=__delete_acl_token - ) - - def __get_acl_policies( - self, - **kwargs - ): - """get_acl_policies # 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_acl_policies(async_req=True) - >>> result = thread.get() - - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - [ACLPolicyListStub] - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - return self.call_with_http_info(**kwargs) - - self.get_acl_policies = _Endpoint( + api_client=api_client + ) + self.get_acl_policies_endpoint = _Endpoint( settings={ 'response_type': ([ACLPolicyListStub],), 'auth': [ @@ -478,85 +266,9 @@ def __get_acl_policies( ], 'content_type': [], }, - api_client=api_client, - callable=__get_acl_policies - ) - - def __get_acl_policy( - self, - policy_name, - **kwargs - ): - """get_acl_policy # 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_acl_policy(policy_name, async_req=True) - >>> result = thread.get() - - Args: - policy_name (str): The ACL policy name. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - ACLPolicy - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['policy_name'] = \ - policy_name - return self.call_with_http_info(**kwargs) - - self.get_acl_policy = _Endpoint( + api_client=api_client + ) + self.get_acl_policy_endpoint = _Endpoint( settings={ 'response_type': (ACLPolicy,), 'auth': [ @@ -650,85 +362,9 @@ def __get_acl_policy( ], 'content_type': [], }, - api_client=api_client, - callable=__get_acl_policy - ) - - def __get_acl_token( - self, - token_accessor, - **kwargs - ): - """get_acl_token # 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_acl_token(token_accessor, async_req=True) - >>> result = thread.get() - - Args: - token_accessor (str): The token accessor ID. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - ACLToken - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['token_accessor'] = \ - token_accessor - return self.call_with_http_info(**kwargs) - - self.get_acl_token = _Endpoint( + api_client=api_client + ) + self.get_acl_token_endpoint = _Endpoint( settings={ 'response_type': (ACLToken,), 'auth': [ @@ -822,80 +458,9 @@ def __get_acl_token( ], 'content_type': [], }, - api_client=api_client, - callable=__get_acl_token - ) - - def __get_acl_token_self( - self, - **kwargs - ): - """get_acl_token_self # 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_acl_token_self(async_req=True) - >>> result = thread.get() - - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - ACLToken - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - return self.call_with_http_info(**kwargs) - - self.get_acl_token_self = _Endpoint( + api_client=api_client + ) + self.get_acl_token_self_endpoint = _Endpoint( settings={ 'response_type': (ACLToken,), 'auth': [ @@ -982,80 +547,9 @@ def __get_acl_token_self( ], 'content_type': [], }, - api_client=api_client, - callable=__get_acl_token_self - ) - - def __get_acl_tokens( - self, - **kwargs - ): - """get_acl_tokens # 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_acl_tokens(async_req=True) - >>> result = thread.get() - - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - [ACLTokenListStub] - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - return self.call_with_http_info(**kwargs) - - self.get_acl_tokens = _Endpoint( + api_client=api_client + ) + self.get_acl_tokens_endpoint = _Endpoint( settings={ 'response_type': ([ACLTokenListStub],), 'auth': [ @@ -1142,75 +636,9 @@ def __get_acl_tokens( ], 'content_type': [], }, - api_client=api_client, - callable=__get_acl_tokens - ) - - def __post_acl_bootstrap( - self, - **kwargs - ): - """post_acl_bootstrap # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.post_acl_bootstrap(async_req=True) - >>> result = thread.get() - - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - ACLToken - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - return self.call_with_http_info(**kwargs) - - self.post_acl_bootstrap = _Endpoint( + api_client=api_client + ) + self.post_acl_bootstrap_endpoint = _Endpoint( settings={ 'response_type': (ACLToken,), 'auth': [ @@ -1272,84 +700,9 @@ def __post_acl_bootstrap( ], 'content_type': [], }, - api_client=api_client, - callable=__post_acl_bootstrap - ) - - def __post_acl_policy( - self, - policy_name, - acl_policy, - **kwargs - ): - """post_acl_policy # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.post_acl_policy(policy_name, acl_policy, async_req=True) - >>> result = thread.get() - - Args: - policy_name (str): The ACL policy name. - acl_policy (ACLPolicy): - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - None - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['policy_name'] = \ - policy_name - kwargs['acl_policy'] = \ - acl_policy - return self.call_with_http_info(**kwargs) - - self.post_acl_policy = _Endpoint( + api_client=api_client + ) + self.post_acl_policy_endpoint = _Endpoint( settings={ 'response_type': None, 'auth': [ @@ -1374,6 +727,7 @@ def __post_acl_policy( 'acl_policy', ], 'nullable': [ + 'acl_policy', ], 'enum': [ ], @@ -1423,84 +777,9 @@ def __post_acl_policy( 'application/json' ] }, - api_client=api_client, - callable=__post_acl_policy - ) - - def __post_acl_token( - self, - token_accessor, - acl_token, - **kwargs - ): - """post_acl_token # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.post_acl_token(token_accessor, acl_token, async_req=True) - >>> result = thread.get() - - Args: - token_accessor (str): The token accessor ID. - acl_token (ACLToken): - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - ACLToken - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['token_accessor'] = \ - token_accessor - kwargs['acl_token'] = \ - acl_token - return self.call_with_http_info(**kwargs) - - self.post_acl_token = _Endpoint( + api_client=api_client + ) + self.post_acl_token_endpoint = _Endpoint( settings={ 'response_type': (ACLToken,), 'auth': [ @@ -1525,6 +804,7 @@ def __post_acl_token( 'acl_token', ], 'nullable': [ + 'acl_token', ], 'enum': [ ], @@ -1576,75 +856,9 @@ def __post_acl_token( 'application/json' ] }, - api_client=api_client, - callable=__post_acl_token - ) - - def __post_acl_token_onetime( - self, - **kwargs - ): - """post_acl_token_onetime # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.post_acl_token_onetime(async_req=True) - >>> result = thread.get() - - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - OneTimeToken - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - return self.call_with_http_info(**kwargs) - - self.post_acl_token_onetime = _Endpoint( + api_client=api_client + ) + self.post_acl_token_onetime_endpoint = _Endpoint( settings={ 'response_type': (OneTimeToken,), 'auth': [ @@ -1706,80 +920,9 @@ def __post_acl_token_onetime( ], 'content_type': [], }, - api_client=api_client, - callable=__post_acl_token_onetime - ) - - def __post_acl_token_onetime_exchange( - self, - one_time_token_exchange_request, - **kwargs - ): - """post_acl_token_onetime_exchange # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.post_acl_token_onetime_exchange(one_time_token_exchange_request, async_req=True) - >>> result = thread.get() - - Args: - one_time_token_exchange_request (OneTimeTokenExchangeRequest): - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - ACLToken - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['one_time_token_exchange_request'] = \ - one_time_token_exchange_request - return self.call_with_http_info(**kwargs) - - self.post_acl_token_onetime_exchange = _Endpoint( + api_client=api_client + ) + self.post_acl_token_onetime_exchange_endpoint = _Endpoint( settings={ 'response_type': (ACLToken,), 'auth': [ @@ -1802,6 +945,7 @@ def __post_acl_token_onetime_exchange( 'one_time_token_exchange_request', ], 'nullable': [ + 'one_time_token_exchange_request', ], 'enum': [ ], @@ -1849,6 +993,986 @@ def __post_acl_token_onetime_exchange( 'application/json' ] }, - api_client=api_client, - callable=__post_acl_token_onetime_exchange + api_client=api_client + ) + + def delete_acl_policy( + self, + policy_name, + **kwargs + ): + """delete_acl_policy # 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_acl_policy(policy_name, async_req=True) + >>> result = thread.get() + + Args: + policy_name (str): The ACL policy name. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + None + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['policy_name'] = \ + policy_name + return self.delete_acl_policy_endpoint.call_with_http_info(**kwargs) + + def delete_acl_token( + self, + token_accessor, + **kwargs + ): + """delete_acl_token # 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_acl_token(token_accessor, async_req=True) + >>> result = thread.get() + + Args: + token_accessor (str): The token accessor ID. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + None + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['token_accessor'] = \ + token_accessor + return self.delete_acl_token_endpoint.call_with_http_info(**kwargs) + + def get_acl_policies( + self, + **kwargs + ): + """get_acl_policies # 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_acl_policies(async_req=True) + >>> result = thread.get() + + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + [ACLPolicyListStub] + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + return self.get_acl_policies_endpoint.call_with_http_info(**kwargs) + + def get_acl_policy( + self, + policy_name, + **kwargs + ): + """get_acl_policy # 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_acl_policy(policy_name, async_req=True) + >>> result = thread.get() + + Args: + policy_name (str): The ACL policy name. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + ACLPolicy + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['policy_name'] = \ + policy_name + return self.get_acl_policy_endpoint.call_with_http_info(**kwargs) + + def get_acl_token( + self, + token_accessor, + **kwargs + ): + """get_acl_token # 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_acl_token(token_accessor, async_req=True) + >>> result = thread.get() + + Args: + token_accessor (str): The token accessor ID. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + ACLToken + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['token_accessor'] = \ + token_accessor + return self.get_acl_token_endpoint.call_with_http_info(**kwargs) + + def get_acl_token_self( + self, + **kwargs + ): + """get_acl_token_self # 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_acl_token_self(async_req=True) + >>> result = thread.get() + + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + ACLToken + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + return self.get_acl_token_self_endpoint.call_with_http_info(**kwargs) + + def get_acl_tokens( + self, + **kwargs + ): + """get_acl_tokens # 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_acl_tokens(async_req=True) + >>> result = thread.get() + + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + [ACLTokenListStub] + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + return self.get_acl_tokens_endpoint.call_with_http_info(**kwargs) + + def post_acl_bootstrap( + self, + **kwargs + ): + """post_acl_bootstrap # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.post_acl_bootstrap(async_req=True) + >>> result = thread.get() + + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + ACLToken + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + return self.post_acl_bootstrap_endpoint.call_with_http_info(**kwargs) + + def post_acl_policy( + self, + policy_name, + acl_policy, + **kwargs + ): + """post_acl_policy # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.post_acl_policy(policy_name, acl_policy, async_req=True) + >>> result = thread.get() + + Args: + policy_name (str): The ACL policy name. + acl_policy (ACLPolicy): + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + None + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['policy_name'] = \ + policy_name + kwargs['acl_policy'] = \ + acl_policy + return self.post_acl_policy_endpoint.call_with_http_info(**kwargs) + + def post_acl_token( + self, + token_accessor, + acl_token, + **kwargs + ): + """post_acl_token # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.post_acl_token(token_accessor, acl_token, async_req=True) + >>> result = thread.get() + + Args: + token_accessor (str): The token accessor ID. + acl_token (ACLToken): + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + ACLToken + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['token_accessor'] = \ + token_accessor + kwargs['acl_token'] = \ + acl_token + return self.post_acl_token_endpoint.call_with_http_info(**kwargs) + + def post_acl_token_onetime( + self, + **kwargs + ): + """post_acl_token_onetime # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.post_acl_token_onetime(async_req=True) + >>> result = thread.get() + + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + OneTimeToken + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + return self.post_acl_token_onetime_endpoint.call_with_http_info(**kwargs) + + def post_acl_token_onetime_exchange( + self, + one_time_token_exchange_request, + **kwargs + ): + """post_acl_token_onetime_exchange # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.post_acl_token_onetime_exchange(one_time_token_exchange_request, async_req=True) + >>> result = thread.get() + + Args: + one_time_token_exchange_request (OneTimeTokenExchangeRequest): + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + ACLToken + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['one_time_token_exchange_request'] = \ + one_time_token_exchange_request + return self.post_acl_token_onetime_exchange_endpoint.call_with_http_info(**kwargs) + diff --git a/clients/python/v1/nomad_client/api/allocations_api.py b/clients/python/v1/nomad_client/api/allocations_api.py index 363d9aba..7a453bbf 100644 --- a/clients/python/v1/nomad_client/api/allocations_api.py +++ b/clients/python/v1/nomad_client/api/allocations_api.py @@ -39,82 +39,7 @@ def __init__(self, api_client=None): if api_client is None: api_client = ApiClient() self.api_client = api_client - - def __get_allocation( - self, - alloc_id, - **kwargs - ): - """get_allocation # 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_allocation(alloc_id, async_req=True) - >>> result = thread.get() - - Args: - alloc_id (str): Allocation ID. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - Allocation - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['alloc_id'] = \ - alloc_id - return self.call_with_http_info(**kwargs) - - self.get_allocation = _Endpoint( + self.get_allocation_endpoint = _Endpoint( settings={ 'response_type': (Allocation,), 'auth': [ @@ -208,85 +133,9 @@ def __get_allocation( ], 'content_type': [], }, - api_client=api_client, - callable=__get_allocation - ) - - def __get_allocation_services( - self, - alloc_id, - **kwargs - ): - """get_allocation_services # 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_allocation_services(alloc_id, async_req=True) - >>> result = thread.get() - - Args: - alloc_id (str): Allocation ID. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - [ServiceRegistration] - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['alloc_id'] = \ - alloc_id - return self.call_with_http_info(**kwargs) - - self.get_allocation_services = _Endpoint( + api_client=api_client + ) + self.get_allocation_services_endpoint = _Endpoint( settings={ 'response_type': ([ServiceRegistration],), 'auth': [ @@ -380,82 +229,9 @@ def __get_allocation_services( ], 'content_type': [], }, - api_client=api_client, - callable=__get_allocation_services - ) - - def __get_allocations( - self, - **kwargs - ): - """get_allocations # 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_allocations(async_req=True) - >>> result = thread.get() - - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - resources (bool): Flag indicating whether to include resources in response.. [optional] - task_states (bool): Flag indicating whether to include task states in response.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - [AllocationListStub] - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - return self.call_with_http_info(**kwargs) - - self.get_allocations = _Endpoint( + api_client=api_client + ) + self.get_allocations_endpoint = _Endpoint( settings={ 'response_type': ([AllocationListStub],), 'auth': [ @@ -552,86 +328,9 @@ def __get_allocations( ], 'content_type': [], }, - api_client=api_client, - callable=__get_allocations - ) - - def __post_allocation_stop( - self, - alloc_id, - **kwargs - ): - """post_allocation_stop # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.post_allocation_stop(alloc_id, async_req=True) - >>> result = thread.get() - - Args: - alloc_id (str): Allocation ID. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - no_shutdown_delay (bool): Flag indicating whether to delay shutdown when requesting an allocation stop.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - AllocStopResponse - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['alloc_id'] = \ - alloc_id - return self.call_with_http_info(**kwargs) - - self.post_allocation_stop = _Endpoint( + api_client=api_client + ) + self.post_allocation_stop_endpoint = _Endpoint( settings={ 'response_type': (AllocStopResponse,), 'auth': [ @@ -730,6 +429,348 @@ def __post_allocation_stop( ], 'content_type': [], }, - api_client=api_client, - callable=__post_allocation_stop + api_client=api_client + ) + + def get_allocation( + self, + alloc_id, + **kwargs + ): + """get_allocation # 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_allocation(alloc_id, async_req=True) + >>> result = thread.get() + + Args: + alloc_id (str): Allocation ID. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + Allocation + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['alloc_id'] = \ + alloc_id + return self.get_allocation_endpoint.call_with_http_info(**kwargs) + + def get_allocation_services( + self, + alloc_id, + **kwargs + ): + """get_allocation_services # 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_allocation_services(alloc_id, async_req=True) + >>> result = thread.get() + + Args: + alloc_id (str): Allocation ID. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + [ServiceRegistration] + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['alloc_id'] = \ + alloc_id + return self.get_allocation_services_endpoint.call_with_http_info(**kwargs) + + def get_allocations( + self, + **kwargs + ): + """get_allocations # 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_allocations(async_req=True) + >>> result = thread.get() + + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + resources (bool): Flag indicating whether to include resources in response.. [optional] + task_states (bool): Flag indicating whether to include task states in response.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + [AllocationListStub] + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + return self.get_allocations_endpoint.call_with_http_info(**kwargs) + + def post_allocation_stop( + self, + alloc_id, + **kwargs + ): + """post_allocation_stop # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.post_allocation_stop(alloc_id, async_req=True) + >>> result = thread.get() + + Args: + alloc_id (str): Allocation ID. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + no_shutdown_delay (bool): Flag indicating whether to delay shutdown when requesting an allocation stop.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + AllocStopResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['alloc_id'] = \ + alloc_id + return self.post_allocation_stop_endpoint.call_with_http_info(**kwargs) + diff --git a/clients/python/v1/nomad_client/api/deployments_api.py b/clients/python/v1/nomad_client/api/deployments_api.py index fb16e90f..13bcf169 100644 --- a/clients/python/v1/nomad_client/api/deployments_api.py +++ b/clients/python/v1/nomad_client/api/deployments_api.py @@ -42,82 +42,7 @@ def __init__(self, api_client=None): if api_client is None: api_client = ApiClient() self.api_client = api_client - - def __get_deployment( - self, - deployment_id, - **kwargs - ): - """get_deployment # 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_deployment(deployment_id, async_req=True) - >>> result = thread.get() - - Args: - deployment_id (str): Deployment ID. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - Deployment - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['deployment_id'] = \ - deployment_id - return self.call_with_http_info(**kwargs) - - self.get_deployment = _Endpoint( + self.get_deployment_endpoint = _Endpoint( settings={ 'response_type': (Deployment,), 'auth': [ @@ -211,85 +136,9 @@ def __get_deployment( ], 'content_type': [], }, - api_client=api_client, - callable=__get_deployment + api_client=api_client ) - - def __get_deployment_allocations( - self, - deployment_id, - **kwargs - ): - """get_deployment_allocations # 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_deployment_allocations(deployment_id, async_req=True) - >>> result = thread.get() - - Args: - deployment_id (str): Deployment ID. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - [AllocationListStub] - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['deployment_id'] = \ - deployment_id - return self.call_with_http_info(**kwargs) - - self.get_deployment_allocations = _Endpoint( + self.get_deployment_allocations_endpoint = _Endpoint( settings={ 'response_type': ([AllocationListStub],), 'auth': [ @@ -383,80 +232,9 @@ def __get_deployment_allocations( ], 'content_type': [], }, - api_client=api_client, - callable=__get_deployment_allocations + api_client=api_client ) - - def __get_deployments( - self, - **kwargs - ): - """get_deployments # 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_deployments(async_req=True) - >>> result = thread.get() - - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - [Deployment] - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - return self.call_with_http_info(**kwargs) - - self.get_deployments = _Endpoint( + self.get_deployments_endpoint = _Endpoint( settings={ 'response_type': ([Deployment],), 'auth': [ @@ -543,84 +321,9 @@ def __get_deployments( ], 'content_type': [], }, - api_client=api_client, - callable=__get_deployments + api_client=api_client ) - - def __post_deployment_allocation_health( - self, - deployment_id, - deployment_alloc_health_request, - **kwargs - ): - """post_deployment_allocation_health # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.post_deployment_allocation_health(deployment_id, deployment_alloc_health_request, async_req=True) - >>> result = thread.get() - - Args: - deployment_id (str): Deployment ID. - deployment_alloc_health_request (DeploymentAllocHealthRequest): - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - DeploymentUpdateResponse - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['deployment_id'] = \ - deployment_id - kwargs['deployment_alloc_health_request'] = \ - deployment_alloc_health_request - return self.call_with_http_info(**kwargs) - - self.post_deployment_allocation_health = _Endpoint( + self.post_deployment_allocation_health_endpoint = _Endpoint( settings={ 'response_type': (DeploymentUpdateResponse,), 'auth': [ @@ -645,6 +348,7 @@ def __post_deployment_allocation_health( 'deployment_alloc_health_request', ], 'nullable': [ + 'deployment_alloc_health_request', ], 'enum': [ ], @@ -696,80 +400,9 @@ def __post_deployment_allocation_health( 'application/json' ] }, - api_client=api_client, - callable=__post_deployment_allocation_health + api_client=api_client ) - - def __post_deployment_fail( - self, - deployment_id, - **kwargs - ): - """post_deployment_fail # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.post_deployment_fail(deployment_id, async_req=True) - >>> result = thread.get() - - Args: - deployment_id (str): Deployment ID. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - DeploymentUpdateResponse - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['deployment_id'] = \ - deployment_id - return self.call_with_http_info(**kwargs) - - self.post_deployment_fail = _Endpoint( + self.post_deployment_fail_endpoint = _Endpoint( settings={ 'response_type': (DeploymentUpdateResponse,), 'auth': [ @@ -838,84 +471,9 @@ def __post_deployment_fail( ], 'content_type': [], }, - api_client=api_client, - callable=__post_deployment_fail + api_client=api_client ) - - def __post_deployment_pause( - self, - deployment_id, - deployment_pause_request, - **kwargs - ): - """post_deployment_pause # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.post_deployment_pause(deployment_id, deployment_pause_request, async_req=True) - >>> result = thread.get() - - Args: - deployment_id (str): Deployment ID. - deployment_pause_request (DeploymentPauseRequest): - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - DeploymentUpdateResponse - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['deployment_id'] = \ - deployment_id - kwargs['deployment_pause_request'] = \ - deployment_pause_request - return self.call_with_http_info(**kwargs) - - self.post_deployment_pause = _Endpoint( + self.post_deployment_pause_endpoint = _Endpoint( settings={ 'response_type': (DeploymentUpdateResponse,), 'auth': [ @@ -940,6 +498,7 @@ def __post_deployment_pause( 'deployment_pause_request', ], 'nullable': [ + 'deployment_pause_request', ], 'enum': [ ], @@ -991,84 +550,9 @@ def __post_deployment_pause( 'application/json' ] }, - api_client=api_client, - callable=__post_deployment_pause + api_client=api_client ) - - def __post_deployment_promote( - self, - deployment_id, - deployment_promote_request, - **kwargs - ): - """post_deployment_promote # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.post_deployment_promote(deployment_id, deployment_promote_request, async_req=True) - >>> result = thread.get() - - Args: - deployment_id (str): Deployment ID. - deployment_promote_request (DeploymentPromoteRequest): - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - DeploymentUpdateResponse - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['deployment_id'] = \ - deployment_id - kwargs['deployment_promote_request'] = \ - deployment_promote_request - return self.call_with_http_info(**kwargs) - - self.post_deployment_promote = _Endpoint( + self.post_deployment_promote_endpoint = _Endpoint( settings={ 'response_type': (DeploymentUpdateResponse,), 'auth': [ @@ -1093,6 +577,7 @@ def __post_deployment_promote( 'deployment_promote_request', ], 'nullable': [ + 'deployment_promote_request', ], 'enum': [ ], @@ -1144,84 +629,9 @@ def __post_deployment_promote( 'application/json' ] }, - api_client=api_client, - callable=__post_deployment_promote + api_client=api_client ) - - def __post_deployment_unblock( - self, - deployment_id, - deployment_unblock_request, - **kwargs - ): - """post_deployment_unblock # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.post_deployment_unblock(deployment_id, deployment_unblock_request, async_req=True) - >>> result = thread.get() - - Args: - deployment_id (str): Deployment ID. - deployment_unblock_request (DeploymentUnblockRequest): - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - DeploymentUpdateResponse - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['deployment_id'] = \ - deployment_id - kwargs['deployment_unblock_request'] = \ - deployment_unblock_request - return self.call_with_http_info(**kwargs) - - self.post_deployment_unblock = _Endpoint( + self.post_deployment_unblock_endpoint = _Endpoint( settings={ 'response_type': (DeploymentUpdateResponse,), 'auth': [ @@ -1246,6 +656,7 @@ def __post_deployment_unblock( 'deployment_unblock_request', ], 'nullable': [ + 'deployment_unblock_request', ], 'enum': [ ], @@ -1297,6 +708,680 @@ def __post_deployment_unblock( 'application/json' ] }, - api_client=api_client, - callable=__post_deployment_unblock + api_client=api_client + ) + + def get_deployment( + self, + deployment_id, + **kwargs + ): + """get_deployment # 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_deployment(deployment_id, async_req=True) + >>> result = thread.get() + + Args: + deployment_id (str): Deployment ID. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + Deployment + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['deployment_id'] = \ + deployment_id + return self.get_deployment_endpoint.call_with_http_info(**kwargs) + + def get_deployment_allocations( + self, + deployment_id, + **kwargs + ): + """get_deployment_allocations # 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_deployment_allocations(deployment_id, async_req=True) + >>> result = thread.get() + + Args: + deployment_id (str): Deployment ID. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + [AllocationListStub] + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['deployment_id'] = \ + deployment_id + return self.get_deployment_allocations_endpoint.call_with_http_info(**kwargs) + + def get_deployments( + self, + **kwargs + ): + """get_deployments # 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_deployments(async_req=True) + >>> result = thread.get() + + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + [Deployment] + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + return self.get_deployments_endpoint.call_with_http_info(**kwargs) + + def post_deployment_allocation_health( + self, + deployment_id, + deployment_alloc_health_request, + **kwargs + ): + """post_deployment_allocation_health # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.post_deployment_allocation_health(deployment_id, deployment_alloc_health_request, async_req=True) + >>> result = thread.get() + + Args: + deployment_id (str): Deployment ID. + deployment_alloc_health_request (DeploymentAllocHealthRequest): + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + DeploymentUpdateResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['deployment_id'] = \ + deployment_id + kwargs['deployment_alloc_health_request'] = \ + deployment_alloc_health_request + return self.post_deployment_allocation_health_endpoint.call_with_http_info(**kwargs) + + def post_deployment_fail( + self, + deployment_id, + **kwargs + ): + """post_deployment_fail # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.post_deployment_fail(deployment_id, async_req=True) + >>> result = thread.get() + + Args: + deployment_id (str): Deployment ID. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + DeploymentUpdateResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['deployment_id'] = \ + deployment_id + return self.post_deployment_fail_endpoint.call_with_http_info(**kwargs) + + def post_deployment_pause( + self, + deployment_id, + deployment_pause_request, + **kwargs + ): + """post_deployment_pause # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.post_deployment_pause(deployment_id, deployment_pause_request, async_req=True) + >>> result = thread.get() + + Args: + deployment_id (str): Deployment ID. + deployment_pause_request (DeploymentPauseRequest): + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + DeploymentUpdateResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['deployment_id'] = \ + deployment_id + kwargs['deployment_pause_request'] = \ + deployment_pause_request + return self.post_deployment_pause_endpoint.call_with_http_info(**kwargs) + + def post_deployment_promote( + self, + deployment_id, + deployment_promote_request, + **kwargs + ): + """post_deployment_promote # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.post_deployment_promote(deployment_id, deployment_promote_request, async_req=True) + >>> result = thread.get() + + Args: + deployment_id (str): Deployment ID. + deployment_promote_request (DeploymentPromoteRequest): + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + DeploymentUpdateResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['deployment_id'] = \ + deployment_id + kwargs['deployment_promote_request'] = \ + deployment_promote_request + return self.post_deployment_promote_endpoint.call_with_http_info(**kwargs) + + def post_deployment_unblock( + self, + deployment_id, + deployment_unblock_request, + **kwargs + ): + """post_deployment_unblock # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.post_deployment_unblock(deployment_id, deployment_unblock_request, async_req=True) + >>> result = thread.get() + + Args: + deployment_id (str): Deployment ID. + deployment_unblock_request (DeploymentUnblockRequest): + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + DeploymentUpdateResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['deployment_id'] = \ + deployment_id + kwargs['deployment_unblock_request'] = \ + deployment_unblock_request + return self.post_deployment_unblock_endpoint.call_with_http_info(**kwargs) + diff --git a/clients/python/v1/nomad_client/api/enterprise_api.py b/clients/python/v1/nomad_client/api/enterprise_api.py index c1d5ab96..7a46f17c 100644 --- a/clients/python/v1/nomad_client/api/enterprise_api.py +++ b/clients/python/v1/nomad_client/api/enterprise_api.py @@ -36,77 +36,7 @@ def __init__(self, api_client=None): if api_client is None: api_client = ApiClient() self.api_client = api_client - - def __create_quota_spec( - self, - quota_spec, - **kwargs - ): - """create_quota_spec # 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_quota_spec(quota_spec, async_req=True) - >>> result = thread.get() - - Args: - quota_spec (QuotaSpec): - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - None - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['quota_spec'] = \ - quota_spec - return self.call_with_http_info(**kwargs) - - self.create_quota_spec = _Endpoint( + self.create_quota_spec_endpoint = _Endpoint( settings={ 'response_type': None, 'auth': [ @@ -129,6 +59,7 @@ def __create_quota_spec( 'quota_spec', ], 'nullable': [ + 'quota_spec', ], 'enum': [ ], @@ -174,80 +105,9 @@ def __create_quota_spec( 'application/json' ] }, - api_client=api_client, - callable=__create_quota_spec - ) - - def __delete_quota_spec( - self, - spec_name, - **kwargs - ): - """delete_quota_spec # 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_quota_spec(spec_name, async_req=True) - >>> result = thread.get() - - Args: - spec_name (str): The quota spec identifier. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - None - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['spec_name'] = \ - spec_name - return self.call_with_http_info(**kwargs) - - self.delete_quota_spec = _Endpoint( + api_client=api_client + ) + self.delete_quota_spec_endpoint = _Endpoint( settings={ 'response_type': None, 'auth': [ @@ -314,85 +174,9 @@ def __delete_quota_spec( 'accept': [], 'content_type': [], }, - api_client=api_client, - callable=__delete_quota_spec - ) - - def __get_quota_spec( - self, - spec_name, - **kwargs - ): - """get_quota_spec # 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_quota_spec(spec_name, async_req=True) - >>> result = thread.get() - - Args: - spec_name (str): The quota spec identifier. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - QuotaSpec - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['spec_name'] = \ - spec_name - return self.call_with_http_info(**kwargs) - - self.get_quota_spec = _Endpoint( + api_client=api_client + ) + self.get_quota_spec_endpoint = _Endpoint( settings={ 'response_type': (QuotaSpec,), 'auth': [ @@ -486,82 +270,11 @@ def __get_quota_spec( ], 'content_type': [], }, - api_client=api_client, - callable=__get_quota_spec - ) - - def __get_quotas( - self, - **kwargs - ): - """get_quotas # 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_quotas(async_req=True) - >>> result = thread.get() - - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - [bool, date, datetime, dict, float, int, list, str, none_type] - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - return self.call_with_http_info(**kwargs) - - self.get_quotas = _Endpoint( + api_client=api_client + ) + self.get_quotas_endpoint = _Endpoint( settings={ - 'response_type': ([bool, date, datetime, dict, float, int, list, str, none_type],), + 'response_type': ([object],), 'auth': [ 'X-Nomad-Token' ], @@ -646,84 +359,9 @@ def __get_quotas( ], 'content_type': [], }, - api_client=api_client, - callable=__get_quotas - ) - - def __post_quota_spec( - self, - spec_name, - quota_spec, - **kwargs - ): - """post_quota_spec # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.post_quota_spec(spec_name, quota_spec, async_req=True) - >>> result = thread.get() - - Args: - spec_name (str): The quota spec identifier. - quota_spec (QuotaSpec): - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - None - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['spec_name'] = \ - spec_name - kwargs['quota_spec'] = \ - quota_spec - return self.call_with_http_info(**kwargs) - - self.post_quota_spec = _Endpoint( + api_client=api_client + ) + self.post_quota_spec_endpoint = _Endpoint( settings={ 'response_type': None, 'auth': [ @@ -748,6 +386,7 @@ def __post_quota_spec( 'quota_spec', ], 'nullable': [ + 'quota_spec', ], 'enum': [ ], @@ -797,6 +436,420 @@ def __post_quota_spec( 'application/json' ] }, - api_client=api_client, - callable=__post_quota_spec + api_client=api_client + ) + + def create_quota_spec( + self, + quota_spec, + **kwargs + ): + """create_quota_spec # 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_quota_spec(quota_spec, async_req=True) + >>> result = thread.get() + + Args: + quota_spec (QuotaSpec): + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + None + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['quota_spec'] = \ + quota_spec + return self.create_quota_spec_endpoint.call_with_http_info(**kwargs) + + def delete_quota_spec( + self, + spec_name, + **kwargs + ): + """delete_quota_spec # 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_quota_spec(spec_name, async_req=True) + >>> result = thread.get() + + Args: + spec_name (str): The quota spec identifier. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + None + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['spec_name'] = \ + spec_name + return self.delete_quota_spec_endpoint.call_with_http_info(**kwargs) + + def get_quota_spec( + self, + spec_name, + **kwargs + ): + """get_quota_spec # 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_quota_spec(spec_name, async_req=True) + >>> result = thread.get() + + Args: + spec_name (str): The quota spec identifier. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + QuotaSpec + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['spec_name'] = \ + spec_name + return self.get_quota_spec_endpoint.call_with_http_info(**kwargs) + + def get_quotas( + self, + **kwargs + ): + """get_quotas # 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_quotas(async_req=True) + >>> result = thread.get() + + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + [object] + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + return self.get_quotas_endpoint.call_with_http_info(**kwargs) + + def post_quota_spec( + self, + spec_name, + quota_spec, + **kwargs + ): + """post_quota_spec # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.post_quota_spec(spec_name, quota_spec, async_req=True) + >>> result = thread.get() + + Args: + spec_name (str): The quota spec identifier. + quota_spec (QuotaSpec): + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + None + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['spec_name'] = \ + spec_name + kwargs['quota_spec'] = \ + quota_spec + return self.post_quota_spec_endpoint.call_with_http_info(**kwargs) + diff --git a/clients/python/v1/nomad_client/api/evaluations_api.py b/clients/python/v1/nomad_client/api/evaluations_api.py index 3a431c2c..6ef8f2ef 100644 --- a/clients/python/v1/nomad_client/api/evaluations_api.py +++ b/clients/python/v1/nomad_client/api/evaluations_api.py @@ -37,82 +37,7 @@ def __init__(self, api_client=None): if api_client is None: api_client = ApiClient() self.api_client = api_client - - def __get_evaluation( - self, - eval_id, - **kwargs - ): - """get_evaluation # 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_evaluation(eval_id, async_req=True) - >>> result = thread.get() - - Args: - eval_id (str): Evaluation ID. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - Evaluation - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['eval_id'] = \ - eval_id - return self.call_with_http_info(**kwargs) - - self.get_evaluation = _Endpoint( + self.get_evaluation_endpoint = _Endpoint( settings={ 'response_type': (Evaluation,), 'auth': [ @@ -206,85 +131,9 @@ def __get_evaluation( ], 'content_type': [], }, - api_client=api_client, - callable=__get_evaluation + api_client=api_client ) - - def __get_evaluation_allocations( - self, - eval_id, - **kwargs - ): - """get_evaluation_allocations # 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_evaluation_allocations(eval_id, async_req=True) - >>> result = thread.get() - - Args: - eval_id (str): Evaluation ID. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - [AllocationListStub] - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['eval_id'] = \ - eval_id - return self.call_with_http_info(**kwargs) - - self.get_evaluation_allocations = _Endpoint( + self.get_evaluation_allocations_endpoint = _Endpoint( settings={ 'response_type': ([AllocationListStub],), 'auth': [ @@ -378,80 +227,9 @@ def __get_evaluation_allocations( ], 'content_type': [], }, - api_client=api_client, - callable=__get_evaluation_allocations + api_client=api_client ) - - def __get_evaluations( - self, - **kwargs - ): - """get_evaluations # 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_evaluations(async_req=True) - >>> result = thread.get() - - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - [Evaluation] - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - return self.call_with_http_info(**kwargs) - - self.get_evaluations = _Endpoint( + self.get_evaluations_endpoint = _Endpoint( settings={ 'response_type': ([Evaluation],), 'auth': [ @@ -538,6 +316,259 @@ def __get_evaluations( ], 'content_type': [], }, - api_client=api_client, - callable=__get_evaluations + api_client=api_client + ) + + def get_evaluation( + self, + eval_id, + **kwargs + ): + """get_evaluation # 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_evaluation(eval_id, async_req=True) + >>> result = thread.get() + + Args: + eval_id (str): Evaluation ID. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + Evaluation + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['eval_id'] = \ + eval_id + return self.get_evaluation_endpoint.call_with_http_info(**kwargs) + + def get_evaluation_allocations( + self, + eval_id, + **kwargs + ): + """get_evaluation_allocations # 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_evaluation_allocations(eval_id, async_req=True) + >>> result = thread.get() + + Args: + eval_id (str): Evaluation ID. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + [AllocationListStub] + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['eval_id'] = \ + eval_id + return self.get_evaluation_allocations_endpoint.call_with_http_info(**kwargs) + + def get_evaluations( + self, + **kwargs + ): + """get_evaluations # 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_evaluations(async_req=True) + >>> result = thread.get() + + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + [Evaluation] + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + return self.get_evaluations_endpoint.call_with_http_info(**kwargs) + diff --git a/clients/python/v1/nomad_client/api/jobs_api.py b/clients/python/v1/nomad_client/api/jobs_api.py index 00c14370..b0471258 100644 --- a/clients/python/v1/nomad_client/api/jobs_api.py +++ b/clients/python/v1/nomad_client/api/jobs_api.py @@ -59,79 +59,7 @@ def __init__(self, api_client=None): if api_client is None: api_client = ApiClient() self.api_client = api_client - - def __delete_job( - self, - job_name, - **kwargs - ): - """delete_job # 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_job(job_name, async_req=True) - >>> result = thread.get() - - Args: - job_name (str): The job identifier. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - purge (bool): Boolean flag indicating whether to purge allocations of the job after deleting.. [optional] - _global (bool): Boolean flag indicating whether the operation should apply to all instances of the job globally.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - JobDeregisterResponse - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['job_name'] = \ - job_name - return self.call_with_http_info(**kwargs) - - self.delete_job = _Endpoint( + self.delete_job_endpoint = _Endpoint( settings={ 'response_type': (JobDeregisterResponse,), 'auth': [ @@ -210,85 +138,9 @@ def __delete_job( ], 'content_type': [], }, - api_client=api_client, - callable=__delete_job - ) - - def __get_job( - self, - job_name, - **kwargs - ): - """get_job # 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_job(job_name, async_req=True) - >>> result = thread.get() - - Args: - job_name (str): The job identifier. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - Job - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['job_name'] = \ - job_name - return self.call_with_http_info(**kwargs) - - self.get_job = _Endpoint( + api_client=api_client + ) + self.get_job_endpoint = _Endpoint( settings={ 'response_type': (Job,), 'auth': [ @@ -382,86 +234,9 @@ def __get_job( ], 'content_type': [], }, - api_client=api_client, - callable=__get_job - ) - - def __get_job_allocations( - self, - job_name, - **kwargs - ): - """get_job_allocations # 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_job_allocations(job_name, async_req=True) - >>> result = thread.get() - - Args: - job_name (str): The job identifier. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - all (bool): Specifies whether the list of allocations should include allocations from a previously registered job with the same ID. This is possible if the job is deregistered and reregistered.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - [AllocationListStub] - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['job_name'] = \ - job_name - return self.call_with_http_info(**kwargs) - - self.get_job_allocations = _Endpoint( + api_client=api_client + ) + self.get_job_allocations_endpoint = _Endpoint( settings={ 'response_type': ([AllocationListStub],), 'auth': [ @@ -560,85 +335,9 @@ def __get_job_allocations( ], 'content_type': [], }, - api_client=api_client, - callable=__get_job_allocations - ) - - def __get_job_deployment( - self, - job_name, - **kwargs - ): - """get_job_deployment # 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_job_deployment(job_name, async_req=True) - >>> result = thread.get() - - Args: - job_name (str): The job identifier. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - Deployment - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['job_name'] = \ - job_name - return self.call_with_http_info(**kwargs) - - self.get_job_deployment = _Endpoint( + api_client=api_client + ) + self.get_job_deployment_endpoint = _Endpoint( settings={ 'response_type': (Deployment,), 'auth': [ @@ -732,86 +431,9 @@ def __get_job_deployment( ], 'content_type': [], }, - api_client=api_client, - callable=__get_job_deployment - ) - - def __get_job_deployments( - self, - job_name, - **kwargs - ): - """get_job_deployments # 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_job_deployments(job_name, async_req=True) - >>> result = thread.get() - - Args: - job_name (str): The job identifier. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - all (int): Flag indicating whether to constrain by job creation index or not.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - [Deployment] - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['job_name'] = \ - job_name - return self.call_with_http_info(**kwargs) - - self.get_job_deployments = _Endpoint( + api_client=api_client + ) + self.get_job_deployments_endpoint = _Endpoint( settings={ 'response_type': ([Deployment],), 'auth': [ @@ -910,85 +532,9 @@ def __get_job_deployments( ], 'content_type': [], }, - api_client=api_client, - callable=__get_job_deployments - ) - - def __get_job_evaluations( - self, - job_name, - **kwargs - ): - """get_job_evaluations # 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_job_evaluations(job_name, async_req=True) - >>> result = thread.get() - - Args: - job_name (str): The job identifier. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - [Evaluation] - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['job_name'] = \ - job_name - return self.call_with_http_info(**kwargs) - - self.get_job_evaluations = _Endpoint( + api_client=api_client + ) + self.get_job_evaluations_endpoint = _Endpoint( settings={ 'response_type': ([Evaluation],), 'auth': [ @@ -1082,85 +628,9 @@ def __get_job_evaluations( ], 'content_type': [], }, - api_client=api_client, - callable=__get_job_evaluations - ) - - def __get_job_scale_status( - self, - job_name, - **kwargs - ): - """get_job_scale_status # 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_job_scale_status(job_name, async_req=True) - >>> result = thread.get() - - Args: - job_name (str): The job identifier. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - JobScaleStatusResponse - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['job_name'] = \ - job_name - return self.call_with_http_info(**kwargs) - - self.get_job_scale_status = _Endpoint( + api_client=api_client + ) + self.get_job_scale_status_endpoint = _Endpoint( settings={ 'response_type': (JobScaleStatusResponse,), 'auth': [ @@ -1254,85 +724,9 @@ def __get_job_scale_status( ], 'content_type': [], }, - api_client=api_client, - callable=__get_job_scale_status - ) - - def __get_job_summary( - self, - job_name, - **kwargs - ): - """get_job_summary # 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_job_summary(job_name, async_req=True) - >>> result = thread.get() - - Args: - job_name (str): The job identifier. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - JobSummary - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['job_name'] = \ - job_name - return self.call_with_http_info(**kwargs) - - self.get_job_summary = _Endpoint( + api_client=api_client + ) + self.get_job_summary_endpoint = _Endpoint( settings={ 'response_type': (JobSummary,), 'auth': [ @@ -1426,86 +820,9 @@ def __get_job_summary( ], 'content_type': [], }, - api_client=api_client, - callable=__get_job_summary - ) - - def __get_job_versions( - self, - job_name, - **kwargs - ): - """get_job_versions # 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_job_versions(job_name, async_req=True) - >>> result = thread.get() - - Args: - job_name (str): The job identifier. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - diffs (bool): Boolean flag indicating whether to compute job diffs.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - JobVersionsResponse - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['job_name'] = \ - job_name - return self.call_with_http_info(**kwargs) - - self.get_job_versions = _Endpoint( + api_client=api_client + ) + self.get_job_versions_endpoint = _Endpoint( settings={ 'response_type': (JobVersionsResponse,), 'auth': [ @@ -1604,80 +921,9 @@ def __get_job_versions( ], 'content_type': [], }, - api_client=api_client, - callable=__get_job_versions - ) - - def __get_jobs( - self, - **kwargs - ): - """get_jobs # 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_jobs(async_req=True) - >>> result = thread.get() - - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - [JobListStub] - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - return self.call_with_http_info(**kwargs) - - self.get_jobs = _Endpoint( + api_client=api_client + ) + self.get_jobs_endpoint = _Endpoint( settings={ 'response_type': ([JobListStub],), 'auth': [ @@ -1764,84 +1010,9 @@ def __get_jobs( ], 'content_type': [], }, - api_client=api_client, - callable=__get_jobs - ) - - def __post_job( - self, - job_name, - job_register_request, - **kwargs - ): - """post_job # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.post_job(job_name, job_register_request, async_req=True) - >>> result = thread.get() - - Args: - job_name (str): The job identifier. - job_register_request (JobRegisterRequest): - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - JobRegisterResponse - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['job_name'] = \ - job_name - kwargs['job_register_request'] = \ - job_register_request - return self.call_with_http_info(**kwargs) - - self.post_job = _Endpoint( + api_client=api_client + ) + self.post_job_endpoint = _Endpoint( settings={ 'response_type': (JobRegisterResponse,), 'auth': [ @@ -1866,6 +1037,7 @@ def __post_job( 'job_register_request', ], 'nullable': [ + 'job_register_request', ], 'enum': [ ], @@ -1917,84 +1089,9 @@ def __post_job( 'application/json' ] }, - api_client=api_client, - callable=__post_job - ) - - def __post_job_dispatch( - self, - job_name, - job_dispatch_request, - **kwargs - ): - """post_job_dispatch # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.post_job_dispatch(job_name, job_dispatch_request, async_req=True) - >>> result = thread.get() - - Args: - job_name (str): The job identifier. - job_dispatch_request (JobDispatchRequest): - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - JobDispatchResponse - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['job_name'] = \ - job_name - kwargs['job_dispatch_request'] = \ - job_dispatch_request - return self.call_with_http_info(**kwargs) - - self.post_job_dispatch = _Endpoint( + api_client=api_client + ) + self.post_job_dispatch_endpoint = _Endpoint( settings={ 'response_type': (JobDispatchResponse,), 'auth': [ @@ -2019,6 +1116,7 @@ def __post_job_dispatch( 'job_dispatch_request', ], 'nullable': [ + 'job_dispatch_request', ], 'enum': [ ], @@ -2070,84 +1168,9 @@ def __post_job_dispatch( 'application/json' ] }, - api_client=api_client, - callable=__post_job_dispatch - ) - - def __post_job_evaluate( - self, - job_name, - job_evaluate_request, - **kwargs - ): - """post_job_evaluate # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.post_job_evaluate(job_name, job_evaluate_request, async_req=True) - >>> result = thread.get() - - Args: - job_name (str): The job identifier. - job_evaluate_request (JobEvaluateRequest): - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - JobRegisterResponse - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['job_name'] = \ - job_name - kwargs['job_evaluate_request'] = \ - job_evaluate_request - return self.call_with_http_info(**kwargs) - - self.post_job_evaluate = _Endpoint( + api_client=api_client + ) + self.post_job_evaluate_endpoint = _Endpoint( settings={ 'response_type': (JobRegisterResponse,), 'auth': [ @@ -2172,6 +1195,7 @@ def __post_job_evaluate( 'job_evaluate_request', ], 'nullable': [ + 'job_evaluate_request', ], 'enum': [ ], @@ -2223,76 +1247,9 @@ def __post_job_evaluate( 'application/json' ] }, - api_client=api_client, - callable=__post_job_evaluate - ) - - def __post_job_parse( - self, - jobs_parse_request, - **kwargs - ): - """post_job_parse # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.post_job_parse(jobs_parse_request, async_req=True) - >>> result = thread.get() - - Args: - jobs_parse_request (JobsParseRequest): - - Keyword Args: - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - Job - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['jobs_parse_request'] = \ - jobs_parse_request - return self.call_with_http_info(**kwargs) - - self.post_job_parse = _Endpoint( + api_client=api_client + ) + self.post_job_parse_endpoint = _Endpoint( settings={ 'response_type': (Job,), 'auth': [ @@ -2311,6 +1268,7 @@ def __post_job_parse( 'jobs_parse_request', ], 'nullable': [ + 'jobs_parse_request', ], 'enum': [ ], @@ -2342,80 +1300,9 @@ def __post_job_parse( 'application/json' ] }, - api_client=api_client, - callable=__post_job_parse - ) - - def __post_job_periodic_force( - self, - job_name, - **kwargs - ): - """post_job_periodic_force # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.post_job_periodic_force(job_name, async_req=True) - >>> result = thread.get() - - Args: - job_name (str): The job identifier. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - PeriodicForceResponse - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['job_name'] = \ - job_name - return self.call_with_http_info(**kwargs) - - self.post_job_periodic_force = _Endpoint( + api_client=api_client + ) + self.post_job_periodic_force_endpoint = _Endpoint( settings={ 'response_type': (PeriodicForceResponse,), 'auth': [ @@ -2484,84 +1371,9 @@ def __post_job_periodic_force( ], 'content_type': [], }, - api_client=api_client, - callable=__post_job_periodic_force - ) - - def __post_job_plan( - self, - job_name, - job_plan_request, - **kwargs - ): - """post_job_plan # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.post_job_plan(job_name, job_plan_request, async_req=True) - >>> result = thread.get() - - Args: - job_name (str): The job identifier. - job_plan_request (JobPlanRequest): - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - JobPlanResponse - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['job_name'] = \ - job_name - kwargs['job_plan_request'] = \ - job_plan_request - return self.call_with_http_info(**kwargs) - - self.post_job_plan = _Endpoint( + api_client=api_client + ) + self.post_job_plan_endpoint = _Endpoint( settings={ 'response_type': (JobPlanResponse,), 'auth': [ @@ -2586,6 +1398,7 @@ def __post_job_plan( 'job_plan_request', ], 'nullable': [ + 'job_plan_request', ], 'enum': [ ], @@ -2637,84 +1450,9 @@ def __post_job_plan( 'application/json' ] }, - api_client=api_client, - callable=__post_job_plan - ) - - def __post_job_revert( - self, - job_name, - job_revert_request, - **kwargs - ): - """post_job_revert # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.post_job_revert(job_name, job_revert_request, async_req=True) - >>> result = thread.get() - - Args: - job_name (str): The job identifier. - job_revert_request (JobRevertRequest): - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - JobRegisterResponse - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['job_name'] = \ - job_name - kwargs['job_revert_request'] = \ - job_revert_request - return self.call_with_http_info(**kwargs) - - self.post_job_revert = _Endpoint( + api_client=api_client + ) + self.post_job_revert_endpoint = _Endpoint( settings={ 'response_type': (JobRegisterResponse,), 'auth': [ @@ -2739,6 +1477,7 @@ def __post_job_revert( 'job_revert_request', ], 'nullable': [ + 'job_revert_request', ], 'enum': [ ], @@ -2790,84 +1529,9 @@ def __post_job_revert( 'application/json' ] }, - api_client=api_client, - callable=__post_job_revert - ) - - def __post_job_scaling_request( - self, - job_name, - scaling_request, - **kwargs - ): - """post_job_scaling_request # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.post_job_scaling_request(job_name, scaling_request, async_req=True) - >>> result = thread.get() - - Args: - job_name (str): The job identifier. - scaling_request (ScalingRequest): - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - JobRegisterResponse - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['job_name'] = \ - job_name - kwargs['scaling_request'] = \ - scaling_request - return self.call_with_http_info(**kwargs) - - self.post_job_scaling_request = _Endpoint( + api_client=api_client + ) + self.post_job_scaling_request_endpoint = _Endpoint( settings={ 'response_type': (JobRegisterResponse,), 'auth': [ @@ -2892,6 +1556,7 @@ def __post_job_scaling_request( 'scaling_request', ], 'nullable': [ + 'scaling_request', ], 'enum': [ ], @@ -2943,84 +1608,9 @@ def __post_job_scaling_request( 'application/json' ] }, - api_client=api_client, - callable=__post_job_scaling_request - ) - - def __post_job_stability( - self, - job_name, - job_stability_request, - **kwargs - ): - """post_job_stability # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.post_job_stability(job_name, job_stability_request, async_req=True) - >>> result = thread.get() - - Args: - job_name (str): The job identifier. - job_stability_request (JobStabilityRequest): - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - JobStabilityResponse - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['job_name'] = \ - job_name - kwargs['job_stability_request'] = \ - job_stability_request - return self.call_with_http_info(**kwargs) - - self.post_job_stability = _Endpoint( + api_client=api_client + ) + self.post_job_stability_endpoint = _Endpoint( settings={ 'response_type': (JobStabilityResponse,), 'auth': [ @@ -3045,6 +1635,7 @@ def __post_job_stability( 'job_stability_request', ], 'nullable': [ + 'job_stability_request', ], 'enum': [ ], @@ -3096,80 +1687,9 @@ def __post_job_stability( 'application/json' ] }, - api_client=api_client, - callable=__post_job_stability - ) - - def __post_job_validate_request( - self, - job_validate_request, - **kwargs - ): - """post_job_validate_request # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.post_job_validate_request(job_validate_request, async_req=True) - >>> result = thread.get() - - Args: - job_validate_request (JobValidateRequest): - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - JobValidateResponse - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['job_validate_request'] = \ - job_validate_request - return self.call_with_http_info(**kwargs) - - self.post_job_validate_request = _Endpoint( + api_client=api_client + ) + self.post_job_validate_request_endpoint = _Endpoint( settings={ 'response_type': (JobValidateResponse,), 'auth': [ @@ -3192,6 +1712,7 @@ def __post_job_validate_request( 'job_validate_request', ], 'nullable': [ + 'job_validate_request', ], 'enum': [ ], @@ -3239,80 +1760,9 @@ def __post_job_validate_request( 'application/json' ] }, - api_client=api_client, - callable=__post_job_validate_request - ) - - def __register_job( - self, - job_register_request, - **kwargs - ): - """register_job # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.register_job(job_register_request, async_req=True) - >>> result = thread.get() - - Args: - job_register_request (JobRegisterRequest): - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - JobRegisterResponse - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['job_register_request'] = \ - job_register_request - return self.call_with_http_info(**kwargs) - - self.register_job = _Endpoint( + api_client=api_client + ) + self.register_job_endpoint = _Endpoint( settings={ 'response_type': (JobRegisterResponse,), 'auth': [ @@ -3335,6 +1785,7 @@ def __register_job( 'job_register_request', ], 'nullable': [ + 'job_register_request', ], 'enum': [ ], @@ -3382,6 +1833,1776 @@ def __register_job( 'application/json' ] }, - api_client=api_client, - callable=__register_job + api_client=api_client + ) + + def delete_job( + self, + job_name, + **kwargs + ): + """delete_job # 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_job(job_name, async_req=True) + >>> result = thread.get() + + Args: + job_name (str): The job identifier. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + purge (bool): Boolean flag indicating whether to purge allocations of the job after deleting.. [optional] + _global (bool): Boolean flag indicating whether the operation should apply to all instances of the job globally.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + JobDeregisterResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['job_name'] = \ + job_name + return self.delete_job_endpoint.call_with_http_info(**kwargs) + + def get_job( + self, + job_name, + **kwargs + ): + """get_job # 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_job(job_name, async_req=True) + >>> result = thread.get() + + Args: + job_name (str): The job identifier. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + Job + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['job_name'] = \ + job_name + return self.get_job_endpoint.call_with_http_info(**kwargs) + + def get_job_allocations( + self, + job_name, + **kwargs + ): + """get_job_allocations # 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_job_allocations(job_name, async_req=True) + >>> result = thread.get() + + Args: + job_name (str): The job identifier. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + all (bool): Specifies whether the list of allocations should include allocations from a previously registered job with the same ID. This is possible if the job is deregistered and reregistered.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + [AllocationListStub] + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['job_name'] = \ + job_name + return self.get_job_allocations_endpoint.call_with_http_info(**kwargs) + + def get_job_deployment( + self, + job_name, + **kwargs + ): + """get_job_deployment # 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_job_deployment(job_name, async_req=True) + >>> result = thread.get() + + Args: + job_name (str): The job identifier. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + Deployment + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['job_name'] = \ + job_name + return self.get_job_deployment_endpoint.call_with_http_info(**kwargs) + + def get_job_deployments( + self, + job_name, + **kwargs + ): + """get_job_deployments # 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_job_deployments(job_name, async_req=True) + >>> result = thread.get() + + Args: + job_name (str): The job identifier. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + all (int): Flag indicating whether to constrain by job creation index or not.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + [Deployment] + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['job_name'] = \ + job_name + return self.get_job_deployments_endpoint.call_with_http_info(**kwargs) + + def get_job_evaluations( + self, + job_name, + **kwargs + ): + """get_job_evaluations # 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_job_evaluations(job_name, async_req=True) + >>> result = thread.get() + + Args: + job_name (str): The job identifier. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + [Evaluation] + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['job_name'] = \ + job_name + return self.get_job_evaluations_endpoint.call_with_http_info(**kwargs) + + def get_job_scale_status( + self, + job_name, + **kwargs + ): + """get_job_scale_status # 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_job_scale_status(job_name, async_req=True) + >>> result = thread.get() + + Args: + job_name (str): The job identifier. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + JobScaleStatusResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['job_name'] = \ + job_name + return self.get_job_scale_status_endpoint.call_with_http_info(**kwargs) + + def get_job_summary( + self, + job_name, + **kwargs + ): + """get_job_summary # 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_job_summary(job_name, async_req=True) + >>> result = thread.get() + + Args: + job_name (str): The job identifier. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + JobSummary + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['job_name'] = \ + job_name + return self.get_job_summary_endpoint.call_with_http_info(**kwargs) + + def get_job_versions( + self, + job_name, + **kwargs + ): + """get_job_versions # 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_job_versions(job_name, async_req=True) + >>> result = thread.get() + + Args: + job_name (str): The job identifier. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + diffs (bool): Boolean flag indicating whether to compute job diffs.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + JobVersionsResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['job_name'] = \ + job_name + return self.get_job_versions_endpoint.call_with_http_info(**kwargs) + + def get_jobs( + self, + **kwargs + ): + """get_jobs # 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_jobs(async_req=True) + >>> result = thread.get() + + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + [JobListStub] + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + return self.get_jobs_endpoint.call_with_http_info(**kwargs) + + def post_job( + self, + job_name, + job_register_request, + **kwargs + ): + """post_job # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.post_job(job_name, job_register_request, async_req=True) + >>> result = thread.get() + + Args: + job_name (str): The job identifier. + job_register_request (JobRegisterRequest): + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + JobRegisterResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['job_name'] = \ + job_name + kwargs['job_register_request'] = \ + job_register_request + return self.post_job_endpoint.call_with_http_info(**kwargs) + + def post_job_dispatch( + self, + job_name, + job_dispatch_request, + **kwargs + ): + """post_job_dispatch # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.post_job_dispatch(job_name, job_dispatch_request, async_req=True) + >>> result = thread.get() + + Args: + job_name (str): The job identifier. + job_dispatch_request (JobDispatchRequest): + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + JobDispatchResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['job_name'] = \ + job_name + kwargs['job_dispatch_request'] = \ + job_dispatch_request + return self.post_job_dispatch_endpoint.call_with_http_info(**kwargs) + + def post_job_evaluate( + self, + job_name, + job_evaluate_request, + **kwargs + ): + """post_job_evaluate # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.post_job_evaluate(job_name, job_evaluate_request, async_req=True) + >>> result = thread.get() + + Args: + job_name (str): The job identifier. + job_evaluate_request (JobEvaluateRequest): + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + JobRegisterResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['job_name'] = \ + job_name + kwargs['job_evaluate_request'] = \ + job_evaluate_request + return self.post_job_evaluate_endpoint.call_with_http_info(**kwargs) + + def post_job_parse( + self, + jobs_parse_request, + **kwargs + ): + """post_job_parse # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.post_job_parse(jobs_parse_request, async_req=True) + >>> result = thread.get() + + Args: + jobs_parse_request (JobsParseRequest): + + Keyword Args: + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + Job + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['jobs_parse_request'] = \ + jobs_parse_request + return self.post_job_parse_endpoint.call_with_http_info(**kwargs) + + def post_job_periodic_force( + self, + job_name, + **kwargs + ): + """post_job_periodic_force # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.post_job_periodic_force(job_name, async_req=True) + >>> result = thread.get() + + Args: + job_name (str): The job identifier. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + PeriodicForceResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['job_name'] = \ + job_name + return self.post_job_periodic_force_endpoint.call_with_http_info(**kwargs) + + def post_job_plan( + self, + job_name, + job_plan_request, + **kwargs + ): + """post_job_plan # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.post_job_plan(job_name, job_plan_request, async_req=True) + >>> result = thread.get() + + Args: + job_name (str): The job identifier. + job_plan_request (JobPlanRequest): + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + JobPlanResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['job_name'] = \ + job_name + kwargs['job_plan_request'] = \ + job_plan_request + return self.post_job_plan_endpoint.call_with_http_info(**kwargs) + + def post_job_revert( + self, + job_name, + job_revert_request, + **kwargs + ): + """post_job_revert # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.post_job_revert(job_name, job_revert_request, async_req=True) + >>> result = thread.get() + + Args: + job_name (str): The job identifier. + job_revert_request (JobRevertRequest): + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + JobRegisterResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['job_name'] = \ + job_name + kwargs['job_revert_request'] = \ + job_revert_request + return self.post_job_revert_endpoint.call_with_http_info(**kwargs) + + def post_job_scaling_request( + self, + job_name, + scaling_request, + **kwargs + ): + """post_job_scaling_request # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.post_job_scaling_request(job_name, scaling_request, async_req=True) + >>> result = thread.get() + + Args: + job_name (str): The job identifier. + scaling_request (ScalingRequest): + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + JobRegisterResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['job_name'] = \ + job_name + kwargs['scaling_request'] = \ + scaling_request + return self.post_job_scaling_request_endpoint.call_with_http_info(**kwargs) + + def post_job_stability( + self, + job_name, + job_stability_request, + **kwargs + ): + """post_job_stability # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.post_job_stability(job_name, job_stability_request, async_req=True) + >>> result = thread.get() + + Args: + job_name (str): The job identifier. + job_stability_request (JobStabilityRequest): + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + JobStabilityResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['job_name'] = \ + job_name + kwargs['job_stability_request'] = \ + job_stability_request + return self.post_job_stability_endpoint.call_with_http_info(**kwargs) + + def post_job_validate_request( + self, + job_validate_request, + **kwargs + ): + """post_job_validate_request # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.post_job_validate_request(job_validate_request, async_req=True) + >>> result = thread.get() + + Args: + job_validate_request (JobValidateRequest): + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + JobValidateResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['job_validate_request'] = \ + job_validate_request + return self.post_job_validate_request_endpoint.call_with_http_info(**kwargs) + + def register_job( + self, + job_register_request, + **kwargs + ): + """register_job # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.register_job(job_register_request, async_req=True) + >>> result = thread.get() + + Args: + job_register_request (JobRegisterRequest): + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + JobRegisterResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['job_register_request'] = \ + job_register_request + return self.register_job_endpoint.call_with_http_info(**kwargs) + diff --git a/clients/python/v1/nomad_client/api/metrics_api.py b/clients/python/v1/nomad_client/api/metrics_api.py index af56ee05..7c085559 100644 --- a/clients/python/v1/nomad_client/api/metrics_api.py +++ b/clients/python/v1/nomad_client/api/metrics_api.py @@ -36,69 +36,7 @@ def __init__(self, api_client=None): if api_client is None: api_client = ApiClient() self.api_client = api_client - - def __get_metrics_summary( - self, - **kwargs - ): - """get_metrics_summary # 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_metrics_summary(async_req=True) - >>> result = thread.get() - - - Keyword Args: - format (str): The format the user requested for the metrics summary (e.g. prometheus). [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - MetricsSummary - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - return self.call_with_http_info(**kwargs) - - self.get_metrics_summary = _Endpoint( + self.get_metrics_summary_endpoint = _Endpoint( settings={ 'response_type': (MetricsSummary,), 'auth': [ @@ -145,6 +83,79 @@ def __get_metrics_summary( ], 'content_type': [], }, - api_client=api_client, - callable=__get_metrics_summary + api_client=api_client + ) + + def get_metrics_summary( + self, + **kwargs + ): + """get_metrics_summary # 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_metrics_summary(async_req=True) + >>> result = thread.get() + + + Keyword Args: + format (str): The format the user requested for the metrics summary (e.g. prometheus). [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + MetricsSummary + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + return self.get_metrics_summary_endpoint.call_with_http_info(**kwargs) + diff --git a/clients/python/v1/nomad_client/api/namespaces_api.py b/clients/python/v1/nomad_client/api/namespaces_api.py index 1ebd589c..2f6f1d20 100644 --- a/clients/python/v1/nomad_client/api/namespaces_api.py +++ b/clients/python/v1/nomad_client/api/namespaces_api.py @@ -36,72 +36,7 @@ def __init__(self, api_client=None): if api_client is None: api_client = ApiClient() self.api_client = api_client - - def __create_namespace( - self, - **kwargs - ): - """create_namespace # 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_namespace(async_req=True) - >>> result = thread.get() - - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - None - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - return self.call_with_http_info(**kwargs) - - self.create_namespace = _Endpoint( + self.create_namespace_endpoint = _Endpoint( settings={ 'response_type': None, 'auth': [ @@ -161,80 +96,9 @@ def __create_namespace( 'accept': [], 'content_type': [], }, - api_client=api_client, - callable=__create_namespace - ) - - def __delete_namespace( - self, - namespace_name, - **kwargs - ): - """delete_namespace # 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_namespace(namespace_name, async_req=True) - >>> result = thread.get() - - Args: - namespace_name (str): The namespace identifier. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - None - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['namespace_name'] = \ - namespace_name - return self.call_with_http_info(**kwargs) - - self.delete_namespace = _Endpoint( + api_client=api_client + ) + self.delete_namespace_endpoint = _Endpoint( settings={ 'response_type': None, 'auth': [ @@ -301,85 +165,9 @@ def __delete_namespace( 'accept': [], 'content_type': [], }, - api_client=api_client, - callable=__delete_namespace - ) - - def __get_namespace( - self, - namespace_name, - **kwargs - ): - """get_namespace # 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_namespace(namespace_name, async_req=True) - >>> result = thread.get() - - Args: - namespace_name (str): The namespace identifier. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - Namespace - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['namespace_name'] = \ - namespace_name - return self.call_with_http_info(**kwargs) - - self.get_namespace = _Endpoint( + api_client=api_client + ) + self.get_namespace_endpoint = _Endpoint( settings={ 'response_type': (Namespace,), 'auth': [ @@ -473,80 +261,9 @@ def __get_namespace( ], 'content_type': [], }, - api_client=api_client, - callable=__get_namespace - ) - - def __get_namespaces( - self, - **kwargs - ): - """get_namespaces # 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_namespaces(async_req=True) - >>> result = thread.get() - - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - [Namespace] - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - return self.call_with_http_info(**kwargs) - - self.get_namespaces = _Endpoint( + api_client=api_client + ) + self.get_namespaces_endpoint = _Endpoint( settings={ 'response_type': ([Namespace],), 'auth': [ @@ -633,84 +350,9 @@ def __get_namespaces( ], 'content_type': [], }, - api_client=api_client, - callable=__get_namespaces - ) - - def __post_namespace( - self, - namespace_name, - namespace2, - **kwargs - ): - """post_namespace # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.post_namespace(namespace_name, namespace2, async_req=True) - >>> result = thread.get() - - Args: - namespace_name (str): The namespace identifier. - namespace2 (Namespace): - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - None - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['namespace_name'] = \ - namespace_name - kwargs['namespace2'] = \ - namespace2 - return self.call_with_http_info(**kwargs) - - self.post_namespace = _Endpoint( + api_client=api_client + ) + self.post_namespace_endpoint = _Endpoint( settings={ 'response_type': None, 'auth': [ @@ -735,6 +377,7 @@ def __post_namespace( 'namespace2', ], 'nullable': [ + 'namespace2', ], 'enum': [ ], @@ -784,6 +427,415 @@ def __post_namespace( 'application/json' ] }, - api_client=api_client, - callable=__post_namespace + api_client=api_client + ) + + def create_namespace( + self, + **kwargs + ): + """create_namespace # 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_namespace(async_req=True) + >>> result = thread.get() + + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + None + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + return self.create_namespace_endpoint.call_with_http_info(**kwargs) + + def delete_namespace( + self, + namespace_name, + **kwargs + ): + """delete_namespace # 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_namespace(namespace_name, async_req=True) + >>> result = thread.get() + + Args: + namespace_name (str): The namespace identifier. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + None + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['namespace_name'] = \ + namespace_name + return self.delete_namespace_endpoint.call_with_http_info(**kwargs) + + def get_namespace( + self, + namespace_name, + **kwargs + ): + """get_namespace # 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_namespace(namespace_name, async_req=True) + >>> result = thread.get() + + Args: + namespace_name (str): The namespace identifier. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + Namespace + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['namespace_name'] = \ + namespace_name + return self.get_namespace_endpoint.call_with_http_info(**kwargs) + + def get_namespaces( + self, + **kwargs + ): + """get_namespaces # 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_namespaces(async_req=True) + >>> result = thread.get() + + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + [Namespace] + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + return self.get_namespaces_endpoint.call_with_http_info(**kwargs) + + def post_namespace( + self, + namespace_name, + namespace2, + **kwargs + ): + """post_namespace # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.post_namespace(namespace_name, namespace2, async_req=True) + >>> result = thread.get() + + Args: + namespace_name (str): The namespace identifier. + namespace2 (Namespace): + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + None + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['namespace_name'] = \ + namespace_name + kwargs['namespace2'] = \ + namespace2 + return self.post_namespace_endpoint.call_with_http_info(**kwargs) + diff --git a/clients/python/v1/nomad_client/api/nodes_api.py b/clients/python/v1/nomad_client/api/nodes_api.py index bdf39cdc..9e30fe83 100644 --- a/clients/python/v1/nomad_client/api/nodes_api.py +++ b/clients/python/v1/nomad_client/api/nodes_api.py @@ -43,82 +43,7 @@ def __init__(self, api_client=None): if api_client is None: api_client = ApiClient() self.api_client = api_client - - def __get_node( - self, - node_id, - **kwargs - ): - """get_node # 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_node(node_id, async_req=True) - >>> result = thread.get() - - Args: - node_id (str): The ID of the node. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - Node - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['node_id'] = \ - node_id - return self.call_with_http_info(**kwargs) - - self.get_node = _Endpoint( + self.get_node_endpoint = _Endpoint( settings={ 'response_type': (Node,), 'auth': [ @@ -212,85 +137,9 @@ def __get_node( ], 'content_type': [], }, - api_client=api_client, - callable=__get_node + api_client=api_client ) - - def __get_node_allocations( - self, - node_id, - **kwargs - ): - """get_node_allocations # 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_node_allocations(node_id, async_req=True) - >>> result = thread.get() - - Args: - node_id (str): The ID of the node. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - [AllocationListStub] - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['node_id'] = \ - node_id - return self.call_with_http_info(**kwargs) - - self.get_node_allocations = _Endpoint( + self.get_node_allocations_endpoint = _Endpoint( settings={ 'response_type': ([AllocationListStub],), 'auth': [ @@ -384,81 +233,9 @@ def __get_node_allocations( ], 'content_type': [], }, - api_client=api_client, - callable=__get_node_allocations + api_client=api_client ) - - def __get_nodes( - self, - **kwargs - ): - """get_nodes # 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_nodes(async_req=True) - >>> result = thread.get() - - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - resources (bool): Whether or not to include the NodeResources and ReservedResources fields in the response.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - [NodeListStub] - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - return self.call_with_http_info(**kwargs) - - self.get_nodes = _Endpoint( + self.get_nodes_endpoint = _Endpoint( settings={ 'response_type': ([NodeListStub],), 'auth': [ @@ -550,89 +327,9 @@ def __get_nodes( ], 'content_type': [], }, - api_client=api_client, - callable=__get_nodes + api_client=api_client ) - - def __update_node_drain( - self, - node_id, - node_update_drain_request, - **kwargs - ): - """update_node_drain # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.update_node_drain(node_id, node_update_drain_request, async_req=True) - >>> result = thread.get() - - Args: - node_id (str): The ID of the node. - node_update_drain_request (NodeUpdateDrainRequest): - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - NodeDrainUpdateResponse - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['node_id'] = \ - node_id - kwargs['node_update_drain_request'] = \ - node_update_drain_request - return self.call_with_http_info(**kwargs) - - self.update_node_drain = _Endpoint( + self.update_node_drain_endpoint = _Endpoint( settings={ 'response_type': (NodeDrainUpdateResponse,), 'auth': [ @@ -662,6 +359,7 @@ def __update_node_drain( 'node_update_drain_request', ], 'nullable': [ + 'node_update_drain_request', ], 'enum': [ ], @@ -733,89 +431,9 @@ def __update_node_drain( 'application/json' ] }, - api_client=api_client, - callable=__update_node_drain + api_client=api_client ) - - def __update_node_eligibility( - self, - node_id, - node_update_eligibility_request, - **kwargs - ): - """update_node_eligibility # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.update_node_eligibility(node_id, node_update_eligibility_request, async_req=True) - >>> result = thread.get() - - Args: - node_id (str): The ID of the node. - node_update_eligibility_request (NodeUpdateEligibilityRequest): - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - NodeEligibilityUpdateResponse - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['node_id'] = \ - node_id - kwargs['node_update_eligibility_request'] = \ - node_update_eligibility_request - return self.call_with_http_info(**kwargs) - - self.update_node_eligibility = _Endpoint( + self.update_node_eligibility_endpoint = _Endpoint( settings={ 'response_type': (NodeEligibilityUpdateResponse,), 'auth': [ @@ -845,6 +463,7 @@ def __update_node_eligibility( 'node_update_eligibility_request', ], 'nullable': [ + 'node_update_eligibility_request', ], 'enum': [ ], @@ -916,85 +535,9 @@ def __update_node_eligibility( 'application/json' ] }, - api_client=api_client, - callable=__update_node_eligibility + api_client=api_client ) - - def __update_node_purge( - self, - node_id, - **kwargs - ): - """update_node_purge # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.update_node_purge(node_id, async_req=True) - >>> result = thread.get() - - Args: - node_id (str): The ID of the node. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - NodePurgeResponse - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['node_id'] = \ - node_id - return self.call_with_http_info(**kwargs) - - self.update_node_purge = _Endpoint( + self.update_node_purge_endpoint = _Endpoint( settings={ 'response_type': (NodePurgeResponse,), 'auth': [ @@ -1088,6 +631,526 @@ def __update_node_purge( ], 'content_type': [], }, - api_client=api_client, - callable=__update_node_purge + api_client=api_client ) + + def get_node( + self, + node_id, + **kwargs + ): + """get_node # 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_node(node_id, async_req=True) + >>> result = thread.get() + + Args: + node_id (str): The ID of the node. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + Node + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['node_id'] = \ + node_id + return self.get_node_endpoint.call_with_http_info(**kwargs) + + def get_node_allocations( + self, + node_id, + **kwargs + ): + """get_node_allocations # 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_node_allocations(node_id, async_req=True) + >>> result = thread.get() + + Args: + node_id (str): The ID of the node. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + [AllocationListStub] + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['node_id'] = \ + node_id + return self.get_node_allocations_endpoint.call_with_http_info(**kwargs) + + def get_nodes( + self, + **kwargs + ): + """get_nodes # 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_nodes(async_req=True) + >>> result = thread.get() + + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + resources (bool): Whether or not to include the NodeResources and ReservedResources fields in the response.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + [NodeListStub] + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + return self.get_nodes_endpoint.call_with_http_info(**kwargs) + + def update_node_drain( + self, + node_id, + node_update_drain_request, + **kwargs + ): + """update_node_drain # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.update_node_drain(node_id, node_update_drain_request, async_req=True) + >>> result = thread.get() + + Args: + node_id (str): The ID of the node. + node_update_drain_request (NodeUpdateDrainRequest): + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + NodeDrainUpdateResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['node_id'] = \ + node_id + kwargs['node_update_drain_request'] = \ + node_update_drain_request + return self.update_node_drain_endpoint.call_with_http_info(**kwargs) + + def update_node_eligibility( + self, + node_id, + node_update_eligibility_request, + **kwargs + ): + """update_node_eligibility # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.update_node_eligibility(node_id, node_update_eligibility_request, async_req=True) + >>> result = thread.get() + + Args: + node_id (str): The ID of the node. + node_update_eligibility_request (NodeUpdateEligibilityRequest): + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + NodeEligibilityUpdateResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['node_id'] = \ + node_id + kwargs['node_update_eligibility_request'] = \ + node_update_eligibility_request + return self.update_node_eligibility_endpoint.call_with_http_info(**kwargs) + + def update_node_purge( + self, + node_id, + **kwargs + ): + """update_node_purge # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.update_node_purge(node_id, async_req=True) + >>> result = thread.get() + + Args: + node_id (str): The ID of the node. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + NodePurgeResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['node_id'] = \ + node_id + return self.update_node_purge_endpoint.call_with_http_info(**kwargs) + diff --git a/clients/python/v1/nomad_client/api/operator_api.py b/clients/python/v1/nomad_client/api/operator_api.py index 03996548..64b8d638 100644 --- a/clients/python/v1/nomad_client/api/operator_api.py +++ b/clients/python/v1/nomad_client/api/operator_api.py @@ -41,72 +41,7 @@ def __init__(self, api_client=None): if api_client is None: api_client = ApiClient() self.api_client = api_client - - def __delete_operator_raft_peer( - self, - **kwargs - ): - """delete_operator_raft_peer # 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_operator_raft_peer(async_req=True) - >>> result = thread.get() - - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - None - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - return self.call_with_http_info(**kwargs) - - self.delete_operator_raft_peer = _Endpoint( + self.delete_operator_raft_peer_endpoint = _Endpoint( settings={ 'response_type': None, 'auth': [ @@ -166,80 +101,9 @@ def __delete_operator_raft_peer( 'accept': [], 'content_type': [], }, - api_client=api_client, - callable=__delete_operator_raft_peer + api_client=api_client ) - - def __get_operator_autopilot_configuration( - self, - **kwargs - ): - """get_operator_autopilot_configuration # 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_operator_autopilot_configuration(async_req=True) - >>> result = thread.get() - - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - AutopilotConfiguration - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - return self.call_with_http_info(**kwargs) - - self.get_operator_autopilot_configuration = _Endpoint( + self.get_operator_autopilot_configuration_endpoint = _Endpoint( settings={ 'response_type': (AutopilotConfiguration,), 'auth': [ @@ -326,80 +190,9 @@ def __get_operator_autopilot_configuration( ], 'content_type': [], }, - api_client=api_client, - callable=__get_operator_autopilot_configuration + api_client=api_client ) - - def __get_operator_autopilot_health( - self, - **kwargs - ): - """get_operator_autopilot_health # 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_operator_autopilot_health(async_req=True) - >>> result = thread.get() - - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - OperatorHealthReply - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - return self.call_with_http_info(**kwargs) - - self.get_operator_autopilot_health = _Endpoint( + self.get_operator_autopilot_health_endpoint = _Endpoint( settings={ 'response_type': (OperatorHealthReply,), 'auth': [ @@ -486,80 +279,9 @@ def __get_operator_autopilot_health( ], 'content_type': [], }, - api_client=api_client, - callable=__get_operator_autopilot_health + api_client=api_client ) - - def __get_operator_raft_configuration( - self, - **kwargs - ): - """get_operator_raft_configuration # 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_operator_raft_configuration(async_req=True) - >>> result = thread.get() - - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - RaftConfiguration - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - return self.call_with_http_info(**kwargs) - - self.get_operator_raft_configuration = _Endpoint( + self.get_operator_raft_configuration_endpoint = _Endpoint( settings={ 'response_type': (RaftConfiguration,), 'auth': [ @@ -646,80 +368,9 @@ def __get_operator_raft_configuration( ], 'content_type': [], }, - api_client=api_client, - callable=__get_operator_raft_configuration + api_client=api_client ) - - def __get_operator_scheduler_configuration( - self, - **kwargs - ): - """get_operator_scheduler_configuration # 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_operator_scheduler_configuration(async_req=True) - >>> result = thread.get() - - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - SchedulerConfigurationResponse - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - return self.call_with_http_info(**kwargs) - - self.get_operator_scheduler_configuration = _Endpoint( + self.get_operator_scheduler_configuration_endpoint = _Endpoint( settings={ 'response_type': (SchedulerConfigurationResponse,), 'auth': [ @@ -806,80 +457,9 @@ def __get_operator_scheduler_configuration( ], 'content_type': [], }, - api_client=api_client, - callable=__get_operator_scheduler_configuration + api_client=api_client ) - - def __post_operator_scheduler_configuration( - self, - scheduler_configuration, - **kwargs - ): - """post_operator_scheduler_configuration # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.post_operator_scheduler_configuration(scheduler_configuration, async_req=True) - >>> result = thread.get() - - Args: - scheduler_configuration (SchedulerConfiguration): - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - SchedulerSetConfigurationResponse - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['scheduler_configuration'] = \ - scheduler_configuration - return self.call_with_http_info(**kwargs) - - self.post_operator_scheduler_configuration = _Endpoint( + self.post_operator_scheduler_configuration_endpoint = _Endpoint( settings={ 'response_type': (SchedulerSetConfigurationResponse,), 'auth': [ @@ -902,6 +482,7 @@ def __post_operator_scheduler_configuration( 'scheduler_configuration', ], 'nullable': [ + 'scheduler_configuration', ], 'enum': [ ], @@ -949,80 +530,9 @@ def __post_operator_scheduler_configuration( 'application/json' ] }, - api_client=api_client, - callable=__post_operator_scheduler_configuration + api_client=api_client ) - - def __put_operator_autopilot_configuration( - self, - autopilot_configuration, - **kwargs - ): - """put_operator_autopilot_configuration # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.put_operator_autopilot_configuration(autopilot_configuration, async_req=True) - >>> result = thread.get() - - Args: - autopilot_configuration (AutopilotConfiguration): - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - bool - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['autopilot_configuration'] = \ - autopilot_configuration - return self.call_with_http_info(**kwargs) - - self.put_operator_autopilot_configuration = _Endpoint( + self.put_operator_autopilot_configuration_endpoint = _Endpoint( settings={ 'response_type': (bool,), 'auth': [ @@ -1045,6 +555,7 @@ def __put_operator_autopilot_configuration( 'autopilot_configuration', ], 'nullable': [ + 'autopilot_configuration', ], 'enum': [ ], @@ -1092,6 +603,568 @@ def __put_operator_autopilot_configuration( 'application/json' ] }, - api_client=api_client, - callable=__put_operator_autopilot_configuration + api_client=api_client + ) + + def delete_operator_raft_peer( + self, + **kwargs + ): + """delete_operator_raft_peer # 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_operator_raft_peer(async_req=True) + >>> result = thread.get() + + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + None + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + return self.delete_operator_raft_peer_endpoint.call_with_http_info(**kwargs) + + def get_operator_autopilot_configuration( + self, + **kwargs + ): + """get_operator_autopilot_configuration # 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_operator_autopilot_configuration(async_req=True) + >>> result = thread.get() + + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + AutopilotConfiguration + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + return self.get_operator_autopilot_configuration_endpoint.call_with_http_info(**kwargs) + + def get_operator_autopilot_health( + self, + **kwargs + ): + """get_operator_autopilot_health # 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_operator_autopilot_health(async_req=True) + >>> result = thread.get() + + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + OperatorHealthReply + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + return self.get_operator_autopilot_health_endpoint.call_with_http_info(**kwargs) + + def get_operator_raft_configuration( + self, + **kwargs + ): + """get_operator_raft_configuration # 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_operator_raft_configuration(async_req=True) + >>> result = thread.get() + + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + RaftConfiguration + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + return self.get_operator_raft_configuration_endpoint.call_with_http_info(**kwargs) + + def get_operator_scheduler_configuration( + self, + **kwargs + ): + """get_operator_scheduler_configuration # 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_operator_scheduler_configuration(async_req=True) + >>> result = thread.get() + + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + SchedulerConfigurationResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + return self.get_operator_scheduler_configuration_endpoint.call_with_http_info(**kwargs) + + def post_operator_scheduler_configuration( + self, + scheduler_configuration, + **kwargs + ): + """post_operator_scheduler_configuration # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.post_operator_scheduler_configuration(scheduler_configuration, async_req=True) + >>> result = thread.get() + + Args: + scheduler_configuration (SchedulerConfiguration): + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + SchedulerSetConfigurationResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['scheduler_configuration'] = \ + scheduler_configuration + return self.post_operator_scheduler_configuration_endpoint.call_with_http_info(**kwargs) + + def put_operator_autopilot_configuration( + self, + autopilot_configuration, + **kwargs + ): + """put_operator_autopilot_configuration # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.put_operator_autopilot_configuration(autopilot_configuration, async_req=True) + >>> result = thread.get() + + Args: + autopilot_configuration (AutopilotConfiguration): + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + bool + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['autopilot_configuration'] = \ + autopilot_configuration + return self.put_operator_autopilot_configuration_endpoint.call_with_http_info(**kwargs) + diff --git a/clients/python/v1/nomad_client/api/plugins_api.py b/clients/python/v1/nomad_client/api/plugins_api.py index a494cbf4..cc0abb70 100644 --- a/clients/python/v1/nomad_client/api/plugins_api.py +++ b/clients/python/v1/nomad_client/api/plugins_api.py @@ -37,82 +37,7 @@ def __init__(self, api_client=None): if api_client is None: api_client = ApiClient() self.api_client = api_client - - def __get_plugin_csi( - self, - plugin_id, - **kwargs - ): - """get_plugin_csi # 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_plugin_csi(plugin_id, async_req=True) - >>> result = thread.get() - - Args: - plugin_id (str): The CSI plugin identifier. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - [CSIPlugin] - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['plugin_id'] = \ - plugin_id - return self.call_with_http_info(**kwargs) - - self.get_plugin_csi = _Endpoint( + self.get_plugin_csi_endpoint = _Endpoint( settings={ 'response_type': ([CSIPlugin],), 'auth': [ @@ -206,80 +131,9 @@ def __get_plugin_csi( ], 'content_type': [], }, - api_client=api_client, - callable=__get_plugin_csi + api_client=api_client ) - - def __get_plugins( - self, - **kwargs - ): - """get_plugins # 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_plugins(async_req=True) - >>> result = thread.get() - - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - [CSIPluginListStub] - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - return self.call_with_http_info(**kwargs) - - self.get_plugins = _Endpoint( + self.get_plugins_endpoint = _Endpoint( settings={ 'response_type': ([CSIPluginListStub],), 'auth': [ @@ -366,6 +220,173 @@ def __get_plugins( ], 'content_type': [], }, - api_client=api_client, - callable=__get_plugins + api_client=api_client + ) + + def get_plugin_csi( + self, + plugin_id, + **kwargs + ): + """get_plugin_csi # 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_plugin_csi(plugin_id, async_req=True) + >>> result = thread.get() + + Args: + plugin_id (str): The CSI plugin identifier. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + [CSIPlugin] + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['plugin_id'] = \ + plugin_id + return self.get_plugin_csi_endpoint.call_with_http_info(**kwargs) + + def get_plugins( + self, + **kwargs + ): + """get_plugins # 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_plugins(async_req=True) + >>> result = thread.get() + + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + [CSIPluginListStub] + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + return self.get_plugins_endpoint.call_with_http_info(**kwargs) + diff --git a/clients/python/v1/nomad_client/api/regions_api.py b/clients/python/v1/nomad_client/api/regions_api.py index 21f4314c..96c07e84 100644 --- a/clients/python/v1/nomad_client/api/regions_api.py +++ b/clients/python/v1/nomad_client/api/regions_api.py @@ -35,68 +35,7 @@ def __init__(self, api_client=None): if api_client is None: api_client = ApiClient() self.api_client = api_client - - def __get_regions( - self, - **kwargs - ): - """get_regions # 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_regions(async_req=True) - >>> result = thread.get() - - - Keyword Args: - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - [str] - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - return self.call_with_http_info(**kwargs) - - self.get_regions = _Endpoint( + self.get_regions_endpoint = _Endpoint( settings={ 'response_type': ([str],), 'auth': [ @@ -138,6 +77,78 @@ def __get_regions( ], 'content_type': [], }, - api_client=api_client, - callable=__get_regions + api_client=api_client + ) + + def get_regions( + self, + **kwargs + ): + """get_regions # 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_regions(async_req=True) + >>> result = thread.get() + + + Keyword Args: + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + [str] + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + return self.get_regions_endpoint.call_with_http_info(**kwargs) + diff --git a/clients/python/v1/nomad_client/api/scaling_api.py b/clients/python/v1/nomad_client/api/scaling_api.py index cec68b0d..9a9ee302 100644 --- a/clients/python/v1/nomad_client/api/scaling_api.py +++ b/clients/python/v1/nomad_client/api/scaling_api.py @@ -37,77 +37,7 @@ def __init__(self, api_client=None): if api_client is None: api_client = ApiClient() self.api_client = api_client - - def __get_scaling_policies( - self, - **kwargs - ): - """get_scaling_policies # 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_scaling_policies(async_req=True) - >>> result = thread.get() - - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - [ScalingPolicyListStub] - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - return self.call_with_http_info(**kwargs) - - self.get_scaling_policies = _Endpoint( + self.get_scaling_policies_endpoint = _Endpoint( settings={ 'response_type': ([ScalingPolicyListStub],), 'auth': [ @@ -194,85 +124,9 @@ def __get_scaling_policies( ], 'content_type': [], }, - api_client=api_client, - callable=__get_scaling_policies + api_client=api_client ) - - def __get_scaling_policy( - self, - policy_id, - **kwargs - ): - """get_scaling_policy # 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_scaling_policy(policy_id, async_req=True) - >>> result = thread.get() - - Args: - policy_id (str): The scaling policy identifier. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - ScalingPolicy - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['policy_id'] = \ - policy_id - return self.call_with_http_info(**kwargs) - - self.get_scaling_policy = _Endpoint( + self.get_scaling_policy_endpoint = _Endpoint( settings={ 'response_type': (ScalingPolicy,), 'auth': [ @@ -366,6 +220,173 @@ def __get_scaling_policy( ], 'content_type': [], }, - api_client=api_client, - callable=__get_scaling_policy + api_client=api_client + ) + + def get_scaling_policies( + self, + **kwargs + ): + """get_scaling_policies # 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_scaling_policies(async_req=True) + >>> result = thread.get() + + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + [ScalingPolicyListStub] + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + return self.get_scaling_policies_endpoint.call_with_http_info(**kwargs) + + def get_scaling_policy( + self, + policy_id, + **kwargs + ): + """get_scaling_policy # 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_scaling_policy(policy_id, async_req=True) + >>> result = thread.get() + + Args: + policy_id (str): The scaling policy identifier. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + ScalingPolicy + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['policy_id'] = \ + policy_id + return self.get_scaling_policy_endpoint.call_with_http_info(**kwargs) + diff --git a/clients/python/v1/nomad_client/api/search_api.py b/clients/python/v1/nomad_client/api/search_api.py index 8771e0c5..3c85fde2 100644 --- a/clients/python/v1/nomad_client/api/search_api.py +++ b/clients/python/v1/nomad_client/api/search_api.py @@ -39,82 +39,7 @@ def __init__(self, api_client=None): if api_client is None: api_client = ApiClient() self.api_client = api_client - - def __get_fuzzy_search( - self, - fuzzy_search_request, - **kwargs - ): - """get_fuzzy_search # 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_fuzzy_search(fuzzy_search_request, async_req=True) - >>> result = thread.get() - - Args: - fuzzy_search_request (FuzzySearchRequest): - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - FuzzySearchResponse - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['fuzzy_search_request'] = \ - fuzzy_search_request - return self.call_with_http_info(**kwargs) - - self.get_fuzzy_search = _Endpoint( + self.get_fuzzy_search_endpoint = _Endpoint( settings={ 'response_type': (FuzzySearchResponse,), 'auth': [ @@ -142,6 +67,7 @@ def __get_fuzzy_search( 'fuzzy_search_request', ], 'nullable': [ + 'fuzzy_search_request', ], 'enum': [ ], @@ -209,85 +135,9 @@ def __get_fuzzy_search( 'application/json' ] }, - api_client=api_client, - callable=__get_fuzzy_search + api_client=api_client ) - - def __get_search( - self, - search_request, - **kwargs - ): - """get_search # 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_search(search_request, async_req=True) - >>> result = thread.get() - - Args: - search_request (SearchRequest): - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - SearchResponse - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['search_request'] = \ - search_request - return self.call_with_http_info(**kwargs) - - self.get_search = _Endpoint( + self.get_search_endpoint = _Endpoint( settings={ 'response_type': (SearchResponse,), 'auth': [ @@ -315,6 +165,7 @@ def __get_search( 'search_request', ], 'nullable': [ + 'search_request', ], 'enum': [ ], @@ -382,6 +233,178 @@ def __get_search( 'application/json' ] }, - api_client=api_client, - callable=__get_search + api_client=api_client ) + + def get_fuzzy_search( + self, + fuzzy_search_request, + **kwargs + ): + """get_fuzzy_search # 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_fuzzy_search(fuzzy_search_request, async_req=True) + >>> result = thread.get() + + Args: + fuzzy_search_request (FuzzySearchRequest): + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + FuzzySearchResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['fuzzy_search_request'] = \ + fuzzy_search_request + return self.get_fuzzy_search_endpoint.call_with_http_info(**kwargs) + + def get_search( + self, + search_request, + **kwargs + ): + """get_search # 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_search(search_request, async_req=True) + >>> result = thread.get() + + Args: + search_request (SearchRequest): + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + SearchResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['search_request'] = \ + search_request + return self.get_search_endpoint.call_with_http_info(**kwargs) + diff --git a/clients/python/v1/nomad_client/api/status_api.py b/clients/python/v1/nomad_client/api/status_api.py index 9551d534..06e1fe1a 100644 --- a/clients/python/v1/nomad_client/api/status_api.py +++ b/clients/python/v1/nomad_client/api/status_api.py @@ -35,77 +35,7 @@ def __init__(self, api_client=None): if api_client is None: api_client = ApiClient() self.api_client = api_client - - def __get_status_leader( - self, - **kwargs - ): - """get_status_leader # 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_status_leader(async_req=True) - >>> result = thread.get() - - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - str - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - return self.call_with_http_info(**kwargs) - - self.get_status_leader = _Endpoint( + self.get_status_leader_endpoint = _Endpoint( settings={ 'response_type': (str,), 'auth': [ @@ -192,80 +122,9 @@ def __get_status_leader( ], 'content_type': [], }, - api_client=api_client, - callable=__get_status_leader + api_client=api_client ) - - def __get_status_peers( - self, - **kwargs - ): - """get_status_peers # 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_status_peers(async_req=True) - >>> result = thread.get() - - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - [str] - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - return self.call_with_http_info(**kwargs) - - self.get_status_peers = _Endpoint( + self.get_status_peers_endpoint = _Endpoint( settings={ 'response_type': ([str],), 'auth': [ @@ -352,6 +211,168 @@ def __get_status_peers( ], 'content_type': [], }, - api_client=api_client, - callable=__get_status_peers + api_client=api_client + ) + + def get_status_leader( + self, + **kwargs + ): + """get_status_leader # 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_status_leader(async_req=True) + >>> result = thread.get() + + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + str + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + return self.get_status_leader_endpoint.call_with_http_info(**kwargs) + + def get_status_peers( + self, + **kwargs + ): + """get_status_peers # 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_status_peers(async_req=True) + >>> result = thread.get() + + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + [str] + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + return self.get_status_peers_endpoint.call_with_http_info(**kwargs) + diff --git a/clients/python/v1/nomad_client/api/system_api.py b/clients/python/v1/nomad_client/api/system_api.py index 99607d63..4fd88572 100644 --- a/clients/python/v1/nomad_client/api/system_api.py +++ b/clients/python/v1/nomad_client/api/system_api.py @@ -35,72 +35,7 @@ def __init__(self, api_client=None): if api_client is None: api_client = ApiClient() self.api_client = api_client - - def __put_system_gc( - self, - **kwargs - ): - """put_system_gc # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.put_system_gc(async_req=True) - >>> result = thread.get() - - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - None - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - return self.call_with_http_info(**kwargs) - - self.put_system_gc = _Endpoint( + self.put_system_gc_endpoint = _Endpoint( settings={ 'response_type': None, 'auth': [ @@ -160,75 +95,9 @@ def __put_system_gc( 'accept': [], 'content_type': [], }, - api_client=api_client, - callable=__put_system_gc + api_client=api_client ) - - def __put_system_reconcile_summaries( - self, - **kwargs - ): - """put_system_reconcile_summaries # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.put_system_reconcile_summaries(async_req=True) - >>> result = thread.get() - - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - None - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - return self.call_with_http_info(**kwargs) - - self.put_system_reconcile_summaries = _Endpoint( + self.put_system_reconcile_summaries_endpoint = _Endpoint( settings={ 'response_type': None, 'auth': [ @@ -288,6 +157,158 @@ def __put_system_reconcile_summaries( 'accept': [], 'content_type': [], }, - api_client=api_client, - callable=__put_system_reconcile_summaries + api_client=api_client + ) + + def put_system_gc( + self, + **kwargs + ): + """put_system_gc # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.put_system_gc(async_req=True) + >>> result = thread.get() + + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + None + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + return self.put_system_gc_endpoint.call_with_http_info(**kwargs) + + def put_system_reconcile_summaries( + self, + **kwargs + ): + """put_system_reconcile_summaries # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.put_system_reconcile_summaries(async_req=True) + >>> result = thread.get() + + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + None + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + return self.put_system_reconcile_summaries_endpoint.call_with_http_info(**kwargs) + diff --git a/clients/python/v1/nomad_client/api/volumes_api.py b/clients/python/v1/nomad_client/api/volumes_api.py index 66b40dad..baf03761 100644 --- a/clients/python/v1/nomad_client/api/volumes_api.py +++ b/clients/python/v1/nomad_client/api/volumes_api.py @@ -43,85 +43,7 @@ def __init__(self, api_client=None): if api_client is None: api_client = ApiClient() self.api_client = api_client - - def __create_volume( - self, - volume_id, - action, - csi_volume_create_request, - **kwargs - ): - """create_volume # 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_volume(volume_id, action, csi_volume_create_request, async_req=True) - >>> result = thread.get() - - Args: - volume_id (str): Volume unique identifier. - action (str): The action to perform on the Volume (create, detach, delete). - csi_volume_create_request (CSIVolumeCreateRequest): - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - None - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['volume_id'] = \ - volume_id - kwargs['action'] = \ - action - kwargs['csi_volume_create_request'] = \ - csi_volume_create_request - return self.call_with_http_info(**kwargs) - - self.create_volume = _Endpoint( + self.create_volume_endpoint = _Endpoint( settings={ 'response_type': None, 'auth': [ @@ -148,6 +70,7 @@ def __create_volume( 'csi_volume_create_request', ], 'nullable': [ + 'csi_volume_create_request', ], 'enum': [ ], @@ -201,77 +124,9 @@ def __create_volume( 'application/json' ] }, - api_client=api_client, - callable=__create_volume - ) - - def __delete_snapshot( - self, - **kwargs - ): - """delete_snapshot # 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_snapshot(async_req=True) - >>> result = thread.get() - - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - plugin_id (str): Filters volume lists by plugin ID.. [optional] - snapshot_id (str): The ID of the snapshot to target.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - None - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - return self.call_with_http_info(**kwargs) - - self.delete_snapshot = _Endpoint( + api_client=api_client + ) + self.delete_snapshot_endpoint = _Endpoint( settings={ 'response_type': None, 'auth': [ @@ -341,81 +196,9 @@ def __delete_snapshot( 'accept': [], 'content_type': [], }, - api_client=api_client, - callable=__delete_snapshot - ) - - def __delete_volume_registration( - self, - volume_id, - **kwargs - ): - """delete_volume_registration # 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_volume_registration(volume_id, async_req=True) - >>> result = thread.get() - - Args: - volume_id (str): Volume unique identifier. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - force (str): Used to force the de-registration of a volume.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - None - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['volume_id'] = \ - volume_id - return self.call_with_http_info(**kwargs) - - self.delete_volume_registration = _Endpoint( + api_client=api_client + ) + self.delete_volume_registration_endpoint = _Endpoint( settings={ 'response_type': None, 'auth': [ @@ -487,85 +270,9 @@ def __delete_volume_registration( 'accept': [], 'content_type': [], }, - api_client=api_client, - callable=__delete_volume_registration - ) - - def __detach_or_delete_volume( - self, - volume_id, - action, - **kwargs - ): - """detach_or_delete_volume # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.detach_or_delete_volume(volume_id, action, async_req=True) - >>> result = thread.get() - - Args: - volume_id (str): Volume unique identifier. - action (str): The action to perform on the Volume (create, detach, delete). - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - node (str): Specifies node to target volume operation for.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - None - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['volume_id'] = \ - volume_id - kwargs['action'] = \ - action - return self.call_with_http_info(**kwargs) - - self.detach_or_delete_volume = _Endpoint( + api_client=api_client + ) + self.detach_or_delete_volume_endpoint = _Endpoint( settings={ 'response_type': None, 'auth': [ @@ -643,81 +350,9 @@ def __detach_or_delete_volume( 'accept': [], 'content_type': [], }, - api_client=api_client, - callable=__detach_or_delete_volume - ) - - def __get_external_volumes( - self, - **kwargs - ): - """get_external_volumes # 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_external_volumes(async_req=True) - >>> result = thread.get() - - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - plugin_id (str): Filters volume lists by plugin ID.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - CSIVolumeListExternalResponse - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - return self.call_with_http_info(**kwargs) - - self.get_external_volumes = _Endpoint( + api_client=api_client + ) + self.get_external_volumes_endpoint = _Endpoint( settings={ 'response_type': (CSIVolumeListExternalResponse,), 'auth': [ @@ -809,81 +444,9 @@ def __get_external_volumes( ], 'content_type': [], }, - api_client=api_client, - callable=__get_external_volumes - ) - - def __get_snapshots( - self, - **kwargs - ): - """get_snapshots # 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_snapshots(async_req=True) - >>> result = thread.get() - - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - plugin_id (str): Filters volume lists by plugin ID.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - CSISnapshotListResponse - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - return self.call_with_http_info(**kwargs) - - self.get_snapshots = _Endpoint( + api_client=api_client + ) + self.get_snapshots_endpoint = _Endpoint( settings={ 'response_type': (CSISnapshotListResponse,), 'auth': [ @@ -975,85 +538,9 @@ def __get_snapshots( ], 'content_type': [], }, - api_client=api_client, - callable=__get_snapshots - ) - - def __get_volume( - self, - volume_id, - **kwargs - ): - """get_volume # 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_volume(volume_id, async_req=True) - >>> result = thread.get() - - Args: - volume_id (str): Volume unique identifier. - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - CSIVolume - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['volume_id'] = \ - volume_id - return self.call_with_http_info(**kwargs) - - self.get_volume = _Endpoint( + api_client=api_client + ) + self.get_volume_endpoint = _Endpoint( settings={ 'response_type': (CSIVolume,), 'auth': [ @@ -1147,83 +634,9 @@ def __get_volume( ], 'content_type': [], }, - api_client=api_client, - callable=__get_volume - ) - - def __get_volumes( - self, - **kwargs - ): - """get_volumes # 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_volumes(async_req=True) - >>> result = thread.get() - - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] - wait (str): Provided with IndexParam to wait for change.. [optional] - stale (str): If present, results will include stale reads.. [optional] - prefix (str): Constrains results to jobs that start with the defined prefix. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - per_page (int): Maximum number of results to return.. [optional] - next_token (str): Indicates where to start paging for queries that support pagination.. [optional] - node_id (str): Filters volume lists by node ID.. [optional] - plugin_id (str): Filters volume lists by plugin ID.. [optional] - type (str): Filters volume lists to a specific type.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - [CSIVolumeListStub] - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - return self.call_with_http_info(**kwargs) - - self.get_volumes = _Endpoint( + api_client=api_client + ) + self.get_volumes_endpoint = _Endpoint( settings={ 'response_type': ([CSIVolumeListStub],), 'auth': [ @@ -1325,80 +738,9 @@ def __get_volumes( ], 'content_type': [], }, - api_client=api_client, - callable=__get_volumes - ) - - def __post_snapshot( - self, - csi_snapshot_create_request, - **kwargs - ): - """post_snapshot # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.post_snapshot(csi_snapshot_create_request, async_req=True) - >>> result = thread.get() - - Args: - csi_snapshot_create_request (CSISnapshotCreateRequest): - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - CSISnapshotCreateResponse - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['csi_snapshot_create_request'] = \ - csi_snapshot_create_request - return self.call_with_http_info(**kwargs) - - self.post_snapshot = _Endpoint( + api_client=api_client + ) + self.post_snapshot_endpoint = _Endpoint( settings={ 'response_type': (CSISnapshotCreateResponse,), 'auth': [ @@ -1421,6 +763,7 @@ def __post_snapshot( 'csi_snapshot_create_request', ], 'nullable': [ + 'csi_snapshot_create_request', ], 'enum': [ ], @@ -1468,80 +811,9 @@ def __post_snapshot( 'application/json' ] }, - api_client=api_client, - callable=__post_snapshot - ) - - def __post_volume( - self, - csi_volume_register_request, - **kwargs - ): - """post_volume # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.post_volume(csi_volume_register_request, async_req=True) - >>> result = thread.get() - - Args: - csi_volume_register_request (CSIVolumeRegisterRequest): - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - None - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['csi_volume_register_request'] = \ - csi_volume_register_request - return self.call_with_http_info(**kwargs) - - self.post_volume = _Endpoint( + api_client=api_client + ) + self.post_volume_endpoint = _Endpoint( settings={ 'response_type': None, 'auth': [ @@ -1564,6 +836,7 @@ def __post_volume( 'csi_volume_register_request', ], 'nullable': [ + 'csi_volume_register_request', ], 'enum': [ ], @@ -1609,84 +882,9 @@ def __post_volume( 'application/json' ] }, - api_client=api_client, - callable=__post_volume - ) - - def __post_volume_registration( - self, - volume_id, - csi_volume_register_request, - **kwargs - ): - """post_volume_registration # noqa: E501 - - This method makes a synchronous HTTP request by default. To make an - asynchronous HTTP request, please pass async_req=True - - >>> thread = api.post_volume_registration(volume_id, csi_volume_register_request, async_req=True) - >>> result = thread.get() - - Args: - volume_id (str): Volume unique identifier. - csi_volume_register_request (CSIVolumeRegisterRequest): - - Keyword Args: - region (str): Filters results based on the specified region.. [optional] - namespace (str): Filters results based on the specified namespace.. [optional] - x_nomad_token (str): A Nomad ACL token.. [optional] - idempotency_token (str): Can be used to ensure operations are only run once.. [optional] - _return_http_data_only (bool): response data without head status - code and headers. Default is True. - _preload_content (bool): if False, the urllib3.HTTPResponse object - will be returned without reading/decoding response data. - Default is True. - _request_timeout (int/float/tuple): 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. - Default is None. - _check_input_type (bool): specifies if type checking - should be done one the data sent to the server. - Default is True. - _check_return_type (bool): specifies if type checking - should be done one the data received from the server. - Default is True. - _host_index (int/None): specifies the index of the server - that we want to use. - Default is read from the configuration. - async_req (bool): execute request asynchronously - - Returns: - None - If the method is called asynchronously, returns the request - thread. - """ - kwargs['async_req'] = kwargs.get( - 'async_req', False - ) - kwargs['_return_http_data_only'] = kwargs.get( - '_return_http_data_only', True - ) - kwargs['_preload_content'] = kwargs.get( - '_preload_content', True - ) - kwargs['_request_timeout'] = kwargs.get( - '_request_timeout', None - ) - kwargs['_check_input_type'] = kwargs.get( - '_check_input_type', True - ) - kwargs['_check_return_type'] = kwargs.get( - '_check_return_type', True - ) - kwargs['_host_index'] = kwargs.get('_host_index') - kwargs['volume_id'] = \ - volume_id - kwargs['csi_volume_register_request'] = \ - csi_volume_register_request - return self.call_with_http_info(**kwargs) - - self.post_volume_registration = _Endpoint( + api_client=api_client + ) + self.post_volume_registration_endpoint = _Endpoint( settings={ 'response_type': None, 'auth': [ @@ -1711,6 +909,7 @@ def __post_volume_registration( 'csi_volume_register_request', ], 'nullable': [ + 'csi_volume_register_request', ], 'enum': [ ], @@ -1760,6 +959,922 @@ def __post_volume_registration( 'application/json' ] }, - api_client=api_client, - callable=__post_volume_registration + api_client=api_client + ) + + def create_volume( + self, + volume_id, + action, + csi_volume_create_request, + **kwargs + ): + """create_volume # 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_volume(volume_id, action, csi_volume_create_request, async_req=True) + >>> result = thread.get() + + Args: + volume_id (str): Volume unique identifier. + action (str): The action to perform on the Volume (create, detach, delete). + csi_volume_create_request (CSIVolumeCreateRequest): + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + None + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['volume_id'] = \ + volume_id + kwargs['action'] = \ + action + kwargs['csi_volume_create_request'] = \ + csi_volume_create_request + return self.create_volume_endpoint.call_with_http_info(**kwargs) + + def delete_snapshot( + self, + **kwargs + ): + """delete_snapshot # 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_snapshot(async_req=True) + >>> result = thread.get() + + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + plugin_id (str): Filters volume lists by plugin ID.. [optional] + snapshot_id (str): The ID of the snapshot to target.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + None + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + return self.delete_snapshot_endpoint.call_with_http_info(**kwargs) + + def delete_volume_registration( + self, + volume_id, + **kwargs + ): + """delete_volume_registration # 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_volume_registration(volume_id, async_req=True) + >>> result = thread.get() + + Args: + volume_id (str): Volume unique identifier. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + force (str): Used to force the de-registration of a volume.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + None + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['volume_id'] = \ + volume_id + return self.delete_volume_registration_endpoint.call_with_http_info(**kwargs) + + def detach_or_delete_volume( + self, + volume_id, + action, + **kwargs + ): + """detach_or_delete_volume # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.detach_or_delete_volume(volume_id, action, async_req=True) + >>> result = thread.get() + + Args: + volume_id (str): Volume unique identifier. + action (str): The action to perform on the Volume (create, detach, delete). + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + node (str): Specifies node to target volume operation for.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + None + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['volume_id'] = \ + volume_id + kwargs['action'] = \ + action + return self.detach_or_delete_volume_endpoint.call_with_http_info(**kwargs) + + def get_external_volumes( + self, + **kwargs + ): + """get_external_volumes # 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_external_volumes(async_req=True) + >>> result = thread.get() + + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + plugin_id (str): Filters volume lists by plugin ID.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + CSIVolumeListExternalResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + return self.get_external_volumes_endpoint.call_with_http_info(**kwargs) + + def get_snapshots( + self, + **kwargs + ): + """get_snapshots # 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_snapshots(async_req=True) + >>> result = thread.get() + + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + plugin_id (str): Filters volume lists by plugin ID.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + CSISnapshotListResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + return self.get_snapshots_endpoint.call_with_http_info(**kwargs) + + def get_volume( + self, + volume_id, + **kwargs + ): + """get_volume # 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_volume(volume_id, async_req=True) + >>> result = thread.get() + + Args: + volume_id (str): Volume unique identifier. + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + CSIVolume + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['volume_id'] = \ + volume_id + return self.get_volume_endpoint.call_with_http_info(**kwargs) + + def get_volumes( + self, + **kwargs + ): + """get_volumes # 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_volumes(async_req=True) + >>> result = thread.get() + + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + index (int): If set, wait until query exceeds given index. Must be provided with WaitParam.. [optional] + wait (str): Provided with IndexParam to wait for change.. [optional] + stale (str): If present, results will include stale reads.. [optional] + prefix (str): Constrains results to jobs that start with the defined prefix. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + per_page (int): Maximum number of results to return.. [optional] + next_token (str): Indicates where to start paging for queries that support pagination.. [optional] + node_id (str): Filters volume lists by node ID.. [optional] + plugin_id (str): Filters volume lists by plugin ID.. [optional] + type (str): Filters volume lists to a specific type.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + [CSIVolumeListStub] + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + return self.get_volumes_endpoint.call_with_http_info(**kwargs) + + def post_snapshot( + self, + csi_snapshot_create_request, + **kwargs + ): + """post_snapshot # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.post_snapshot(csi_snapshot_create_request, async_req=True) + >>> result = thread.get() + + Args: + csi_snapshot_create_request (CSISnapshotCreateRequest): + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + CSISnapshotCreateResponse + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['csi_snapshot_create_request'] = \ + csi_snapshot_create_request + return self.post_snapshot_endpoint.call_with_http_info(**kwargs) + + def post_volume( + self, + csi_volume_register_request, + **kwargs + ): + """post_volume # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.post_volume(csi_volume_register_request, async_req=True) + >>> result = thread.get() + + Args: + csi_volume_register_request (CSIVolumeRegisterRequest): + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + None + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['csi_volume_register_request'] = \ + csi_volume_register_request + return self.post_volume_endpoint.call_with_http_info(**kwargs) + + def post_volume_registration( + self, + volume_id, + csi_volume_register_request, + **kwargs + ): + """post_volume_registration # noqa: E501 + + This method makes a synchronous HTTP request by default. To make an + asynchronous HTTP request, please pass async_req=True + + >>> thread = api.post_volume_registration(volume_id, csi_volume_register_request, async_req=True) + >>> result = thread.get() + + Args: + volume_id (str): Volume unique identifier. + csi_volume_register_request (CSIVolumeRegisterRequest): + + Keyword Args: + region (str): Filters results based on the specified region.. [optional] + namespace (str): Filters results based on the specified namespace.. [optional] + x_nomad_token (str): A Nomad ACL token.. [optional] + idempotency_token (str): Can be used to ensure operations are only run once.. [optional] + _return_http_data_only (bool): response data without head status + code and headers. Default is True. + _preload_content (bool): if False, the urllib3.HTTPResponse object + will be returned without reading/decoding response data. + Default is True. + _request_timeout (int/float/tuple): 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. + Default is None. + _check_input_type (bool): specifies if type checking + should be done one the data sent to the server. + Default is True. + _check_return_type (bool): specifies if type checking + should be done one the data received from the server. + Default is True. + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _content_type (str/None): force body content-type. + Default is None and content-type will be predicted by allowed + content-types and body. + _host_index (int/None): specifies the index of the server + that we want to use. + Default is read from the configuration. + async_req (bool): execute request asynchronously + + Returns: + None + If the method is called asynchronously, returns the request + thread. + """ + kwargs['async_req'] = kwargs.get( + 'async_req', False + ) + kwargs['_return_http_data_only'] = kwargs.get( + '_return_http_data_only', True + ) + kwargs['_preload_content'] = kwargs.get( + '_preload_content', True + ) + kwargs['_request_timeout'] = kwargs.get( + '_request_timeout', None + ) + kwargs['_check_input_type'] = kwargs.get( + '_check_input_type', True + ) + kwargs['_check_return_type'] = kwargs.get( + '_check_return_type', True + ) + kwargs['_spec_property_naming'] = kwargs.get( + '_spec_property_naming', False + ) + kwargs['_content_type'] = kwargs.get( + '_content_type') + kwargs['_host_index'] = kwargs.get('_host_index') + kwargs['volume_id'] = \ + volume_id + kwargs['csi_volume_register_request'] = \ + csi_volume_register_request + return self.post_volume_registration_endpoint.call_with_http_info(**kwargs) + diff --git a/clients/python/v1/nomad_client/api_client.py b/clients/python/v1/nomad_client/api_client.py index e7990a88..3f22fd0b 100644 --- a/clients/python/v1/nomad_client/api_client.py +++ b/clients/python/v1/nomad_client/api_client.py @@ -132,7 +132,8 @@ def __call_api( _preload_content: bool = True, _request_timeout: typing.Optional[typing.Union[int, float, typing.Tuple]] = None, _host: typing.Optional[str] = None, - _check_type: typing.Optional[bool] = None + _check_type: typing.Optional[bool] = None, + _content_type: typing.Optional[str] = None ): config = self.configuration @@ -573,10 +574,12 @@ def select_header_accept(self, accepts): else: return ', '.join(accepts) - def select_header_content_type(self, content_types): + def select_header_content_type(self, content_types, method=None, body=None): """Returns `Content-Type` based on an array of content_types provided. :param content_types: List of content-types. + :param method: http method (e.g. POST, PATCH). + :param body: http body to send. :return: Content-Type (e.g. application/json). """ if not content_types: @@ -584,17 +587,22 @@ def select_header_content_type(self, content_types): content_types = [x.lower() for x in content_types] + if (method == 'PATCH' and + 'application/json-patch+json' in content_types and + isinstance(body, list)): + return 'application/json-patch+json' + if 'application/json' in content_types or '*/*' in content_types: return 'application/json' else: return content_types[0] - def update_params_for_auth(self, headers, querys, auth_settings, + def update_params_for_auth(self, headers, queries, auth_settings, resource_path, method, body): """Updates header and query params based on authentication setting. :param headers: Header parameters dict to be updated. - :param querys: Query parameters tuple list to be updated. + :param queries: Query parameters tuple list to be updated. :param auth_settings: Authentication setting identifiers list. :param resource_path: A string representation of the HTTP request resource path. :param method: A string representation of the HTTP request method. @@ -613,7 +621,7 @@ def update_params_for_auth(self, headers, querys, auth_settings, if auth_setting['type'] != 'http-signature': headers[auth_setting['key']] = auth_setting['value'] elif auth_setting['in'] == 'query': - querys.append((auth_setting['key'], auth_setting['value'])) + queries.append((auth_setting['key'], auth_setting['value'])) else: raise ApiValueError( 'Authentication token must be in `query` or `header`' @@ -665,7 +673,9 @@ def __init__(self, settings=None, params_map=None, root_map=None, '_request_timeout', '_return_http_data_only', '_check_input_type', - '_check_return_type' + '_check_return_type', + '_content_type', + '_spec_property_naming' ]) self.params_map['nullable'].extend(['_request_timeout']) self.validations = root_map['validations'] @@ -678,7 +688,9 @@ def __init__(self, settings=None, params_map=None, root_map=None, '_request_timeout': (none_type, float, (float,), [float], int, (int,), [int]), '_return_http_data_only': (bool,), '_check_input_type': (bool,), - '_check_return_type': (bool,) + '_check_return_type': (bool,), + '_spec_property_naming': (bool,), + '_content_type': (none_type, str) } self.openapi_types.update(extra_types) self.attribute_map = root_map['attribute_map'] @@ -714,7 +726,7 @@ def __validate_inputs(self, kwargs): value, self.openapi_types[key], [key], - False, + kwargs['_spec_property_naming'], kwargs['_check_input_type'], configuration=self.api_client.configuration ) @@ -742,11 +754,11 @@ def __gather_params(self, kwargs): base_name = self.attribute_map[param_name] if (param_location == 'form' and self.openapi_types[param_name] == (file_type,)): - params['file'][param_name] = [param_value] + params['file'][base_name] = [param_value] elif (param_location == 'form' and self.openapi_types[param_name] == ([file_type],)): # param_value is already a list - params['file'][param_name] = param_value + params['file'][base_name] = param_value elif param_location in {'form', 'query'}: param_value_full = (base_name, param_value) params[param_location].append(param_value_full) @@ -825,11 +837,16 @@ def call_with_http_info(self, **kwargs): params['header']['Accept'] = self.api_client.select_header_accept( accept_headers_list) - content_type_headers_list = self.headers_map['content_type'] - if content_type_headers_list: - header_list = self.api_client.select_header_content_type( - content_type_headers_list) - params['header']['Content-Type'] = header_list + if kwargs.get('_content_type'): + params['header']['Content-Type'] = kwargs['_content_type'] + else: + content_type_headers_list = self.headers_map['content_type'] + if content_type_headers_list: + if params['body'] != "": + header_list = self.api_client.select_header_content_type( + content_type_headers_list, self.settings['http_method'], + params['body']) + params['header']['Content-Type'] = header_list return self.api_client.call_api( self.settings['endpoint_path'], self.settings['http_method'], diff --git a/clients/python/v1/nomad_client/configuration.py b/clients/python/v1/nomad_client/configuration.py index 342939f5..25e7df19 100644 --- a/clients/python/v1/nomad_client/configuration.py +++ b/clients/python/v1/nomad_client/configuration.py @@ -74,7 +74,7 @@ class Configuration(object): :param server_operation_variables: Mapping from operation ID to a mapping with string values to replace variables in templated server configuration. The validation of enums is performed for variables with defined enum values before. - :param ssl_ca_cert: str - the path to a file of concatenated CA certificates + :param ssl_ca_cert: str - the path to a file of concatenated CA certificates in PEM format :Example: @@ -200,6 +200,9 @@ def __init__(self, host=None, self.proxy = None """Proxy URL """ + self.no_proxy = None + """bypass proxy for host in the no_proxy list. + """ self.proxy_headers = None """Proxy headers """ diff --git a/clients/python/v1/nomad_client/model/acl_policy.py b/clients/python/v1/nomad_client/model/acl_policy.py index 303d3852..005883ee 100644 --- a/clients/python/v1/nomad_client/model/acl_policy.py +++ b/clients/python/v1/nomad_client/model/acl_policy.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -77,7 +77,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/acl_policy_list_stub.py b/clients/python/v1/nomad_client/model/acl_policy_list_stub.py index 6a3c2f84..520df315 100644 --- a/clients/python/v1/nomad_client/model/acl_policy_list_stub.py +++ b/clients/python/v1/nomad_client/model/acl_policy_list_stub.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -77,7 +77,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/acl_token.py b/clients/python/v1/nomad_client/model/acl_token.py index 363daef8..88ae11a9 100644 --- a/clients/python/v1/nomad_client/model/acl_token.py +++ b/clients/python/v1/nomad_client/model/acl_token.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -77,7 +77,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): @@ -92,7 +92,7 @@ def openapi_types(): return { 'accessor_id': (str,), # noqa: E501 'create_index': (int,), # noqa: E501 - 'create_time': (datetime,), # noqa: E501 + 'create_time': (datetime, none_type,), # noqa: E501 '_global': (bool,), # noqa: E501 'modify_index': (int,), # noqa: E501 'name': (str,), # noqa: E501 @@ -161,7 +161,7 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 _visited_composed_classes = (Animal,) accessor_id (str): [optional] # noqa: E501 create_index (int): [optional] # noqa: E501 - create_time (datetime): [optional] # noqa: E501 + create_time (datetime, none_type): [optional] # noqa: E501 _global (bool): [optional] # noqa: E501 modify_index (int): [optional] # noqa: E501 name (str): [optional] # noqa: E501 @@ -251,7 +251,7 @@ def __init__(self, *args, **kwargs): # noqa: E501 _visited_composed_classes = (Animal,) accessor_id (str): [optional] # noqa: E501 create_index (int): [optional] # noqa: E501 - create_time (datetime): [optional] # noqa: E501 + create_time (datetime, none_type): [optional] # noqa: E501 _global (bool): [optional] # noqa: E501 modify_index (int): [optional] # noqa: E501 name (str): [optional] # noqa: E501 diff --git a/clients/python/v1/nomad_client/model/acl_token_list_stub.py b/clients/python/v1/nomad_client/model/acl_token_list_stub.py index e981a7f8..01042940 100644 --- a/clients/python/v1/nomad_client/model/acl_token_list_stub.py +++ b/clients/python/v1/nomad_client/model/acl_token_list_stub.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -77,7 +77,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): @@ -92,7 +92,7 @@ def openapi_types(): return { 'accessor_id': (str,), # noqa: E501 'create_index': (int,), # noqa: E501 - 'create_time': (datetime,), # noqa: E501 + 'create_time': (datetime, none_type,), # noqa: E501 '_global': (bool,), # noqa: E501 'modify_index': (int,), # noqa: E501 'name': (str,), # noqa: E501 @@ -159,7 +159,7 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 _visited_composed_classes = (Animal,) accessor_id (str): [optional] # noqa: E501 create_index (int): [optional] # noqa: E501 - create_time (datetime): [optional] # noqa: E501 + create_time (datetime, none_type): [optional] # noqa: E501 _global (bool): [optional] # noqa: E501 modify_index (int): [optional] # noqa: E501 name (str): [optional] # noqa: E501 @@ -248,7 +248,7 @@ def __init__(self, *args, **kwargs): # noqa: E501 _visited_composed_classes = (Animal,) accessor_id (str): [optional] # noqa: E501 create_index (int): [optional] # noqa: E501 - create_time (datetime): [optional] # noqa: E501 + create_time (datetime, none_type): [optional] # noqa: E501 _global (bool): [optional] # noqa: E501 modify_index (int): [optional] # noqa: E501 name (str): [optional] # noqa: E501 diff --git a/clients/python/v1/nomad_client/model/affinity.py b/clients/python/v1/nomad_client/model/affinity.py index 069baabb..e1888536 100644 --- a/clients/python/v1/nomad_client/model/affinity.py +++ b/clients/python/v1/nomad_client/model/affinity.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -73,7 +73,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/alloc_deployment_status.py b/clients/python/v1/nomad_client/model/alloc_deployment_status.py index 77fc424d..4e9802d1 100644 --- a/clients/python/v1/nomad_client/model/alloc_deployment_status.py +++ b/clients/python/v1/nomad_client/model/alloc_deployment_status.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -73,7 +73,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): @@ -89,7 +89,7 @@ def openapi_types(): 'canary': (bool,), # noqa: E501 'healthy': (bool,), # noqa: E501 'modify_index': (int,), # noqa: E501 - 'timestamp': (datetime,), # noqa: E501 + 'timestamp': (datetime, none_type,), # noqa: E501 } @cached_property @@ -148,7 +148,7 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 canary (bool): [optional] # noqa: E501 healthy (bool): [optional] # noqa: E501 modify_index (int): [optional] # noqa: E501 - timestamp (datetime): [optional] # noqa: E501 + timestamp (datetime, none_type): [optional] # noqa: E501 """ _check_type = kwargs.pop('_check_type', True) @@ -233,7 +233,7 @@ def __init__(self, *args, **kwargs): # noqa: E501 canary (bool): [optional] # noqa: E501 healthy (bool): [optional] # noqa: E501 modify_index (int): [optional] # noqa: E501 - timestamp (datetime): [optional] # noqa: E501 + timestamp (datetime, none_type): [optional] # noqa: E501 """ _check_type = kwargs.pop('_check_type', True) diff --git a/clients/python/v1/nomad_client/model/alloc_stop_response.py b/clients/python/v1/nomad_client/model/alloc_stop_response.py index 166cac60..6b94cb5f 100644 --- a/clients/python/v1/nomad_client/model/alloc_stop_response.py +++ b/clients/python/v1/nomad_client/model/alloc_stop_response.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -73,7 +73,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/allocated_cpu_resources.py b/clients/python/v1/nomad_client/model/allocated_cpu_resources.py index 9d1b2acb..37a8f19e 100644 --- a/clients/python/v1/nomad_client/model/allocated_cpu_resources.py +++ b/clients/python/v1/nomad_client/model/allocated_cpu_resources.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/allocated_device_resource.py b/clients/python/v1/nomad_client/model/allocated_device_resource.py index 1c3274a4..3013b2f2 100644 --- a/clients/python/v1/nomad_client/model/allocated_device_resource.py +++ b/clients/python/v1/nomad_client/model/allocated_device_resource.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/allocated_memory_resources.py b/clients/python/v1/nomad_client/model/allocated_memory_resources.py index 6d7abe27..90f8c5fd 100644 --- a/clients/python/v1/nomad_client/model/allocated_memory_resources.py +++ b/clients/python/v1/nomad_client/model/allocated_memory_resources.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/allocated_resources.py b/clients/python/v1/nomad_client/model/allocated_resources.py index 85570ca3..524b0bdf 100644 --- a/clients/python/v1/nomad_client/model/allocated_resources.py +++ b/clients/python/v1/nomad_client/model/allocated_resources.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -76,7 +76,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/allocated_shared_resources.py b/clients/python/v1/nomad_client/model/allocated_shared_resources.py index bd3d4e4f..57d1a3b0 100644 --- a/clients/python/v1/nomad_client/model/allocated_shared_resources.py +++ b/clients/python/v1/nomad_client/model/allocated_shared_resources.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -76,7 +76,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/allocated_task_resources.py b/clients/python/v1/nomad_client/model/allocated_task_resources.py index e4bfcecb..b350b863 100644 --- a/clients/python/v1/nomad_client/model/allocated_task_resources.py +++ b/clients/python/v1/nomad_client/model/allocated_task_resources.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -80,7 +80,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/allocation.py b/clients/python/v1/nomad_client/model/allocation.py index 05ec44c4..da12bafa 100644 --- a/clients/python/v1/nomad_client/model/allocation.py +++ b/clients/python/v1/nomad_client/model/allocation.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -100,7 +100,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/allocation_list_stub.py b/clients/python/v1/nomad_client/model/allocation_list_stub.py index a30cf7da..fd23014e 100644 --- a/clients/python/v1/nomad_client/model/allocation_list_stub.py +++ b/clients/python/v1/nomad_client/model/allocation_list_stub.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -92,7 +92,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/allocation_metric.py b/clients/python/v1/nomad_client/model/allocation_metric.py index 5487fbf4..dd6d9225 100644 --- a/clients/python/v1/nomad_client/model/allocation_metric.py +++ b/clients/python/v1/nomad_client/model/allocation_metric.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -76,7 +76,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/attribute.py b/clients/python/v1/nomad_client/model/attribute.py index d2046562..ac8f3908 100644 --- a/clients/python/v1/nomad_client/model/attribute.py +++ b/clients/python/v1/nomad_client/model/attribute.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/autopilot_configuration.py b/clients/python/v1/nomad_client/model/autopilot_configuration.py index 2985fec1..d07538d5 100644 --- a/clients/python/v1/nomad_client/model/autopilot_configuration.py +++ b/clients/python/v1/nomad_client/model/autopilot_configuration.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -84,7 +84,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/check_restart.py b/clients/python/v1/nomad_client/model/check_restart.py index 0faa3ee9..12b59acc 100644 --- a/clients/python/v1/nomad_client/model/check_restart.py +++ b/clients/python/v1/nomad_client/model/check_restart.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/constraint.py b/clients/python/v1/nomad_client/model/constraint.py index 984645fa..e8049a16 100644 --- a/clients/python/v1/nomad_client/model/constraint.py +++ b/clients/python/v1/nomad_client/model/constraint.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/consul.py b/clients/python/v1/nomad_client/model/consul.py index 00d6e6d0..43147ced 100644 --- a/clients/python/v1/nomad_client/model/consul.py +++ b/clients/python/v1/nomad_client/model/consul.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/consul_connect.py b/clients/python/v1/nomad_client/model/consul_connect.py index adc683ba..9817d58e 100644 --- a/clients/python/v1/nomad_client/model/consul_connect.py +++ b/clients/python/v1/nomad_client/model/consul_connect.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -78,7 +78,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/consul_expose_config.py b/clients/python/v1/nomad_client/model/consul_expose_config.py index f41c9b41..b0fd3754 100644 --- a/clients/python/v1/nomad_client/model/consul_expose_config.py +++ b/clients/python/v1/nomad_client/model/consul_expose_config.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -74,7 +74,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/consul_expose_path.py b/clients/python/v1/nomad_client/model/consul_expose_path.py index 490ba085..927fdd3d 100644 --- a/clients/python/v1/nomad_client/model/consul_expose_path.py +++ b/clients/python/v1/nomad_client/model/consul_expose_path.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/consul_gateway.py b/clients/python/v1/nomad_client/model/consul_gateway.py index 6e5d5e69..86fae9df 100644 --- a/clients/python/v1/nomad_client/model/consul_gateway.py +++ b/clients/python/v1/nomad_client/model/consul_gateway.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError diff --git a/clients/python/v1/nomad_client/model/consul_gateway_bind_address.py b/clients/python/v1/nomad_client/model/consul_gateway_bind_address.py index 03ebd2a7..b294ef1a 100644 --- a/clients/python/v1/nomad_client/model/consul_gateway_bind_address.py +++ b/clients/python/v1/nomad_client/model/consul_gateway_bind_address.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/consul_gateway_proxy.py b/clients/python/v1/nomad_client/model/consul_gateway_proxy.py index bda05b92..4352af0a 100644 --- a/clients/python/v1/nomad_client/model/consul_gateway_proxy.py +++ b/clients/python/v1/nomad_client/model/consul_gateway_proxy.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -74,7 +74,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/consul_gateway_tls_config.py b/clients/python/v1/nomad_client/model/consul_gateway_tls_config.py index 4ff2eceb..a55dcbfe 100644 --- a/clients/python/v1/nomad_client/model/consul_gateway_tls_config.py +++ b/clients/python/v1/nomad_client/model/consul_gateway_tls_config.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/consul_ingress_config_entry.py b/clients/python/v1/nomad_client/model/consul_ingress_config_entry.py index bea48d27..0c713851 100644 --- a/clients/python/v1/nomad_client/model/consul_ingress_config_entry.py +++ b/clients/python/v1/nomad_client/model/consul_ingress_config_entry.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -76,7 +76,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/consul_ingress_listener.py b/clients/python/v1/nomad_client/model/consul_ingress_listener.py index 9561fb4d..59d14e59 100644 --- a/clients/python/v1/nomad_client/model/consul_ingress_listener.py +++ b/clients/python/v1/nomad_client/model/consul_ingress_listener.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -74,7 +74,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/consul_ingress_service.py b/clients/python/v1/nomad_client/model/consul_ingress_service.py index a9ff29b4..a01e9f72 100644 --- a/clients/python/v1/nomad_client/model/consul_ingress_service.py +++ b/clients/python/v1/nomad_client/model/consul_ingress_service.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/consul_linked_service.py b/clients/python/v1/nomad_client/model/consul_linked_service.py index 40a5ff65..160c9b93 100644 --- a/clients/python/v1/nomad_client/model/consul_linked_service.py +++ b/clients/python/v1/nomad_client/model/consul_linked_service.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/consul_mesh_gateway.py b/clients/python/v1/nomad_client/model/consul_mesh_gateway.py index e223cefb..782e222e 100644 --- a/clients/python/v1/nomad_client/model/consul_mesh_gateway.py +++ b/clients/python/v1/nomad_client/model/consul_mesh_gateway.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/consul_proxy.py b/clients/python/v1/nomad_client/model/consul_proxy.py index 5566e243..534036ad 100644 --- a/clients/python/v1/nomad_client/model/consul_proxy.py +++ b/clients/python/v1/nomad_client/model/consul_proxy.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -76,7 +76,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/consul_sidecar_service.py b/clients/python/v1/nomad_client/model/consul_sidecar_service.py index c53b2991..c16e1667 100644 --- a/clients/python/v1/nomad_client/model/consul_sidecar_service.py +++ b/clients/python/v1/nomad_client/model/consul_sidecar_service.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -74,7 +74,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/consul_terminating_config_entry.py b/clients/python/v1/nomad_client/model/consul_terminating_config_entry.py index ef253566..b350a78a 100644 --- a/clients/python/v1/nomad_client/model/consul_terminating_config_entry.py +++ b/clients/python/v1/nomad_client/model/consul_terminating_config_entry.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -74,7 +74,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/consul_upstream.py b/clients/python/v1/nomad_client/model/consul_upstream.py index b6b73be9..92c2b58b 100644 --- a/clients/python/v1/nomad_client/model/consul_upstream.py +++ b/clients/python/v1/nomad_client/model/consul_upstream.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -74,7 +74,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/csi_controller_info.py b/clients/python/v1/nomad_client/model/csi_controller_info.py index 73142cb0..0c12eeeb 100644 --- a/clients/python/v1/nomad_client/model/csi_controller_info.py +++ b/clients/python/v1/nomad_client/model/csi_controller_info.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/csi_info.py b/clients/python/v1/nomad_client/model/csi_info.py index 17a7b0fa..0c2f81f3 100644 --- a/clients/python/v1/nomad_client/model/csi_info.py +++ b/clients/python/v1/nomad_client/model/csi_info.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -76,7 +76,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): @@ -98,7 +98,7 @@ def openapi_types(): 'plugin_id': (str,), # noqa: E501 'requires_controller_plugin': (bool,), # noqa: E501 'requires_topologies': (bool,), # noqa: E501 - 'update_time': (datetime,), # noqa: E501 + 'update_time': (datetime, none_type,), # noqa: E501 } @cached_property @@ -167,7 +167,7 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 plugin_id (str): [optional] # noqa: E501 requires_controller_plugin (bool): [optional] # noqa: E501 requires_topologies (bool): [optional] # noqa: E501 - update_time (datetime): [optional] # noqa: E501 + update_time (datetime, none_type): [optional] # noqa: E501 """ _check_type = kwargs.pop('_check_type', True) @@ -257,7 +257,7 @@ def __init__(self, *args, **kwargs): # noqa: E501 plugin_id (str): [optional] # noqa: E501 requires_controller_plugin (bool): [optional] # noqa: E501 requires_topologies (bool): [optional] # noqa: E501 - update_time (datetime): [optional] # noqa: E501 + update_time (datetime, none_type): [optional] # noqa: E501 """ _check_type = kwargs.pop('_check_type', True) diff --git a/clients/python/v1/nomad_client/model/csi_mount_options.py b/clients/python/v1/nomad_client/model/csi_mount_options.py index 305e9a71..69e9858d 100644 --- a/clients/python/v1/nomad_client/model/csi_mount_options.py +++ b/clients/python/v1/nomad_client/model/csi_mount_options.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/csi_node_info.py b/clients/python/v1/nomad_client/model/csi_node_info.py index 42bed94e..bcd8c90a 100644 --- a/clients/python/v1/nomad_client/model/csi_node_info.py +++ b/clients/python/v1/nomad_client/model/csi_node_info.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -74,7 +74,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/csi_plugin.py b/clients/python/v1/nomad_client/model/csi_plugin.py index 417be520..e205f743 100644 --- a/clients/python/v1/nomad_client/model/csi_plugin.py +++ b/clients/python/v1/nomad_client/model/csi_plugin.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -84,7 +84,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/csi_plugin_list_stub.py b/clients/python/v1/nomad_client/model/csi_plugin_list_stub.py index d96ff414..041ff61f 100644 --- a/clients/python/v1/nomad_client/model/csi_plugin_list_stub.py +++ b/clients/python/v1/nomad_client/model/csi_plugin_list_stub.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -77,7 +77,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/csi_secrets.py b/clients/python/v1/nomad_client/model/csi_secrets.py index d0501835..21126bdb 100644 --- a/clients/python/v1/nomad_client/model/csi_secrets.py +++ b/clients/python/v1/nomad_client/model/csi_secrets.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError diff --git a/clients/python/v1/nomad_client/model/csi_snapshot.py b/clients/python/v1/nomad_client/model/csi_snapshot.py index e9bf801a..79a90eed 100644 --- a/clients/python/v1/nomad_client/model/csi_snapshot.py +++ b/clients/python/v1/nomad_client/model/csi_snapshot.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -74,7 +74,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/csi_snapshot_create_request.py b/clients/python/v1/nomad_client/model/csi_snapshot_create_request.py index a2b9e457..fcedfbe1 100644 --- a/clients/python/v1/nomad_client/model/csi_snapshot_create_request.py +++ b/clients/python/v1/nomad_client/model/csi_snapshot_create_request.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -74,7 +74,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/csi_snapshot_create_response.py b/clients/python/v1/nomad_client/model/csi_snapshot_create_response.py index a3ba0a3c..b827c3ca 100644 --- a/clients/python/v1/nomad_client/model/csi_snapshot_create_response.py +++ b/clients/python/v1/nomad_client/model/csi_snapshot_create_response.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -78,7 +78,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/csi_snapshot_list_response.py b/clients/python/v1/nomad_client/model/csi_snapshot_list_response.py index 4ba12254..1ccbaa8a 100644 --- a/clients/python/v1/nomad_client/model/csi_snapshot_list_response.py +++ b/clients/python/v1/nomad_client/model/csi_snapshot_list_response.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -78,7 +78,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/csi_topology.py b/clients/python/v1/nomad_client/model/csi_topology.py index 788ad07f..804f32b0 100644 --- a/clients/python/v1/nomad_client/model/csi_topology.py +++ b/clients/python/v1/nomad_client/model/csi_topology.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/csi_topology_request.py b/clients/python/v1/nomad_client/model/csi_topology_request.py index d9a8ac73..8fef070a 100644 --- a/clients/python/v1/nomad_client/model/csi_topology_request.py +++ b/clients/python/v1/nomad_client/model/csi_topology_request.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -74,7 +74,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/csi_volume.py b/clients/python/v1/nomad_client/model/csi_volume.py index d7b68999..cfe1defb 100644 --- a/clients/python/v1/nomad_client/model/csi_volume.py +++ b/clients/python/v1/nomad_client/model/csi_volume.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -94,7 +94,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): @@ -135,7 +135,7 @@ def openapi_types(): 'requested_capacity_max': (int,), # noqa: E501 'requested_capacity_min': (int,), # noqa: E501 'requested_topologies': (CSITopologyRequest,), # noqa: E501 - 'resource_exhausted': (datetime,), # noqa: E501 + 'resource_exhausted': (datetime, none_type,), # noqa: E501 'schedulable': (bool,), # noqa: E501 'secrets': (CSISecrets,), # noqa: E501 'snapshot_id': (str,), # noqa: E501 @@ -252,7 +252,7 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 requested_capacity_max (int): [optional] # noqa: E501 requested_capacity_min (int): [optional] # noqa: E501 requested_topologies (CSITopologyRequest): [optional] # noqa: E501 - resource_exhausted (datetime): [optional] # noqa: E501 + resource_exhausted (datetime, none_type): [optional] # noqa: E501 schedulable (bool): [optional] # noqa: E501 secrets (CSISecrets): [optional] # noqa: E501 snapshot_id (str): [optional] # noqa: E501 @@ -366,7 +366,7 @@ def __init__(self, *args, **kwargs): # noqa: E501 requested_capacity_max (int): [optional] # noqa: E501 requested_capacity_min (int): [optional] # noqa: E501 requested_topologies (CSITopologyRequest): [optional] # noqa: E501 - resource_exhausted (datetime): [optional] # noqa: E501 + resource_exhausted (datetime, none_type): [optional] # noqa: E501 schedulable (bool): [optional] # noqa: E501 secrets (CSISecrets): [optional] # noqa: E501 snapshot_id (str): [optional] # noqa: E501 diff --git a/clients/python/v1/nomad_client/model/csi_volume_capability.py b/clients/python/v1/nomad_client/model/csi_volume_capability.py index 0d5283b0..0ef3dc43 100644 --- a/clients/python/v1/nomad_client/model/csi_volume_capability.py +++ b/clients/python/v1/nomad_client/model/csi_volume_capability.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/csi_volume_create_request.py b/clients/python/v1/nomad_client/model/csi_volume_create_request.py index fe4a3300..96e930c2 100644 --- a/clients/python/v1/nomad_client/model/csi_volume_create_request.py +++ b/clients/python/v1/nomad_client/model/csi_volume_create_request.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -74,7 +74,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/csi_volume_external_stub.py b/clients/python/v1/nomad_client/model/csi_volume_external_stub.py index e65c7451..233eb432 100644 --- a/clients/python/v1/nomad_client/model/csi_volume_external_stub.py +++ b/clients/python/v1/nomad_client/model/csi_volume_external_stub.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/csi_volume_list_external_response.py b/clients/python/v1/nomad_client/model/csi_volume_list_external_response.py index 1c8fd8d2..2793caa3 100644 --- a/clients/python/v1/nomad_client/model/csi_volume_list_external_response.py +++ b/clients/python/v1/nomad_client/model/csi_volume_list_external_response.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -74,7 +74,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/csi_volume_list_stub.py b/clients/python/v1/nomad_client/model/csi_volume_list_stub.py index 0cb3c49d..d423f5d8 100644 --- a/clients/python/v1/nomad_client/model/csi_volume_list_stub.py +++ b/clients/python/v1/nomad_client/model/csi_volume_list_stub.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -82,7 +82,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): @@ -111,7 +111,7 @@ def openapi_types(): 'nodes_healthy': (int,), # noqa: E501 'plugin_id': (str,), # noqa: E501 'provider': (str,), # noqa: E501 - 'resource_exhausted': (datetime,), # noqa: E501 + 'resource_exhausted': (datetime, none_type,), # noqa: E501 'schedulable': (bool,), # noqa: E501 'topologies': ([CSITopology],), # noqa: E501 } @@ -198,7 +198,7 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 nodes_healthy (int): [optional] # noqa: E501 plugin_id (str): [optional] # noqa: E501 provider (str): [optional] # noqa: E501 - resource_exhausted (datetime): [optional] # noqa: E501 + resource_exhausted (datetime, none_type): [optional] # noqa: E501 schedulable (bool): [optional] # noqa: E501 topologies ([CSITopology]): [optional] # noqa: E501 """ @@ -297,7 +297,7 @@ def __init__(self, *args, **kwargs): # noqa: E501 nodes_healthy (int): [optional] # noqa: E501 plugin_id (str): [optional] # noqa: E501 provider (str): [optional] # noqa: E501 - resource_exhausted (datetime): [optional] # noqa: E501 + resource_exhausted (datetime, none_type): [optional] # noqa: E501 schedulable (bool): [optional] # noqa: E501 topologies ([CSITopology]): [optional] # noqa: E501 """ diff --git a/clients/python/v1/nomad_client/model/csi_volume_register_request.py b/clients/python/v1/nomad_client/model/csi_volume_register_request.py index 5dbd1107..563e42f3 100644 --- a/clients/python/v1/nomad_client/model/csi_volume_register_request.py +++ b/clients/python/v1/nomad_client/model/csi_volume_register_request.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -74,7 +74,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/deployment.py b/clients/python/v1/nomad_client/model/deployment.py index b7043d2f..26ed0157 100644 --- a/clients/python/v1/nomad_client/model/deployment.py +++ b/clients/python/v1/nomad_client/model/deployment.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -98,7 +98,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/deployment_alloc_health_request.py b/clients/python/v1/nomad_client/model/deployment_alloc_health_request.py index bd02ec88..9a84ff3d 100644 --- a/clients/python/v1/nomad_client/model/deployment_alloc_health_request.py +++ b/clients/python/v1/nomad_client/model/deployment_alloc_health_request.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/deployment_pause_request.py b/clients/python/v1/nomad_client/model/deployment_pause_request.py index b6ab05ad..368d97ac 100644 --- a/clients/python/v1/nomad_client/model/deployment_pause_request.py +++ b/clients/python/v1/nomad_client/model/deployment_pause_request.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/deployment_promote_request.py b/clients/python/v1/nomad_client/model/deployment_promote_request.py index 64f8a2ca..77dbc312 100644 --- a/clients/python/v1/nomad_client/model/deployment_promote_request.py +++ b/clients/python/v1/nomad_client/model/deployment_promote_request.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/deployment_state.py b/clients/python/v1/nomad_client/model/deployment_state.py index 4067872a..c20d66c2 100644 --- a/clients/python/v1/nomad_client/model/deployment_state.py +++ b/clients/python/v1/nomad_client/model/deployment_state.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): @@ -90,7 +90,7 @@ def openapi_types(): 'placed_canaries': ([str],), # noqa: E501 'progress_deadline': (int,), # noqa: E501 'promoted': (bool,), # noqa: E501 - 'require_progress_by': (datetime,), # noqa: E501 + 'require_progress_by': (datetime, none_type,), # noqa: E501 'unhealthy_allocs': (int,), # noqa: E501 } @@ -161,7 +161,7 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 placed_canaries ([str]): [optional] # noqa: E501 progress_deadline (int): [optional] # noqa: E501 promoted (bool): [optional] # noqa: E501 - require_progress_by (datetime): [optional] # noqa: E501 + require_progress_by (datetime, none_type): [optional] # noqa: E501 unhealthy_allocs (int): [optional] # noqa: E501 """ @@ -252,7 +252,7 @@ def __init__(self, *args, **kwargs): # noqa: E501 placed_canaries ([str]): [optional] # noqa: E501 progress_deadline (int): [optional] # noqa: E501 promoted (bool): [optional] # noqa: E501 - require_progress_by (datetime): [optional] # noqa: E501 + require_progress_by (datetime, none_type): [optional] # noqa: E501 unhealthy_allocs (int): [optional] # noqa: E501 """ diff --git a/clients/python/v1/nomad_client/model/deployment_unblock_request.py b/clients/python/v1/nomad_client/model/deployment_unblock_request.py index ae991b88..f1679dae 100644 --- a/clients/python/v1/nomad_client/model/deployment_unblock_request.py +++ b/clients/python/v1/nomad_client/model/deployment_unblock_request.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/deployment_update_response.py b/clients/python/v1/nomad_client/model/deployment_update_response.py index 5b6f7d70..3b33571f 100644 --- a/clients/python/v1/nomad_client/model/deployment_update_response.py +++ b/clients/python/v1/nomad_client/model/deployment_update_response.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -85,7 +85,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/desired_transition.py b/clients/python/v1/nomad_client/model/desired_transition.py index 78c34482..9edb05a1 100644 --- a/clients/python/v1/nomad_client/model/desired_transition.py +++ b/clients/python/v1/nomad_client/model/desired_transition.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError diff --git a/clients/python/v1/nomad_client/model/desired_updates.py b/clients/python/v1/nomad_client/model/desired_updates.py index 5c76e57f..0dc4a423 100644 --- a/clients/python/v1/nomad_client/model/desired_updates.py +++ b/clients/python/v1/nomad_client/model/desired_updates.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -101,7 +101,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/dispatch_payload_config.py b/clients/python/v1/nomad_client/model/dispatch_payload_config.py index fbafc07f..45bd90d9 100644 --- a/clients/python/v1/nomad_client/model/dispatch_payload_config.py +++ b/clients/python/v1/nomad_client/model/dispatch_payload_config.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/dns_config.py b/clients/python/v1/nomad_client/model/dns_config.py index 3ef33aaf..abf66086 100644 --- a/clients/python/v1/nomad_client/model/dns_config.py +++ b/clients/python/v1/nomad_client/model/dns_config.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/drain_metadata.py b/clients/python/v1/nomad_client/model/drain_metadata.py index 28bccd50..ef3f72f7 100644 --- a/clients/python/v1/nomad_client/model/drain_metadata.py +++ b/clients/python/v1/nomad_client/model/drain_metadata.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): @@ -84,9 +84,9 @@ def openapi_types(): return { 'accessor_id': (str,), # noqa: E501 'meta': ({str: (str,)},), # noqa: E501 - 'started_at': (datetime,), # noqa: E501 + 'started_at': (datetime, none_type,), # noqa: E501 'status': (str,), # noqa: E501 - 'updated_at': (datetime,), # noqa: E501 + 'updated_at': (datetime, none_type,), # noqa: E501 } @cached_property @@ -145,9 +145,9 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 _visited_composed_classes = (Animal,) accessor_id (str): [optional] # noqa: E501 meta ({str: (str,)}): [optional] # noqa: E501 - started_at (datetime): [optional] # noqa: E501 + started_at (datetime, none_type): [optional] # noqa: E501 status (str): [optional] # noqa: E501 - updated_at (datetime): [optional] # noqa: E501 + updated_at (datetime, none_type): [optional] # noqa: E501 """ _check_type = kwargs.pop('_check_type', True) @@ -231,9 +231,9 @@ def __init__(self, *args, **kwargs): # noqa: E501 _visited_composed_classes = (Animal,) accessor_id (str): [optional] # noqa: E501 meta ({str: (str,)}): [optional] # noqa: E501 - started_at (datetime): [optional] # noqa: E501 + started_at (datetime, none_type): [optional] # noqa: E501 status (str): [optional] # noqa: E501 - updated_at (datetime): [optional] # noqa: E501 + updated_at (datetime, none_type): [optional] # noqa: E501 """ _check_type = kwargs.pop('_check_type', True) diff --git a/clients/python/v1/nomad_client/model/drain_spec.py b/clients/python/v1/nomad_client/model/drain_spec.py index 0a0cb0c9..896664ab 100644 --- a/clients/python/v1/nomad_client/model/drain_spec.py +++ b/clients/python/v1/nomad_client/model/drain_spec.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/drain_strategy.py b/clients/python/v1/nomad_client/model/drain_strategy.py index efd34dbe..29ee7692 100644 --- a/clients/python/v1/nomad_client/model/drain_strategy.py +++ b/clients/python/v1/nomad_client/model/drain_strategy.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): @@ -83,9 +83,9 @@ def openapi_types(): """ return { 'deadline': (int,), # noqa: E501 - 'force_deadline': (datetime,), # noqa: E501 + 'force_deadline': (datetime, none_type,), # noqa: E501 'ignore_system_jobs': (bool,), # noqa: E501 - 'started_at': (datetime,), # noqa: E501 + 'started_at': (datetime, none_type,), # noqa: E501 } @cached_property @@ -142,9 +142,9 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 through its discriminator because we passed in _visited_composed_classes = (Animal,) deadline (int): [optional] # noqa: E501 - force_deadline (datetime): [optional] # noqa: E501 + force_deadline (datetime, none_type): [optional] # noqa: E501 ignore_system_jobs (bool): [optional] # noqa: E501 - started_at (datetime): [optional] # noqa: E501 + started_at (datetime, none_type): [optional] # noqa: E501 """ _check_type = kwargs.pop('_check_type', True) @@ -227,9 +227,9 @@ def __init__(self, *args, **kwargs): # noqa: E501 through its discriminator because we passed in _visited_composed_classes = (Animal,) deadline (int): [optional] # noqa: E501 - force_deadline (datetime): [optional] # noqa: E501 + force_deadline (datetime, none_type): [optional] # noqa: E501 ignore_system_jobs (bool): [optional] # noqa: E501 - started_at (datetime): [optional] # noqa: E501 + started_at (datetime, none_type): [optional] # noqa: E501 """ _check_type = kwargs.pop('_check_type', True) diff --git a/clients/python/v1/nomad_client/model/driver_info.py b/clients/python/v1/nomad_client/model/driver_info.py index ffc065a3..5d04c027 100644 --- a/clients/python/v1/nomad_client/model/driver_info.py +++ b/clients/python/v1/nomad_client/model/driver_info.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): @@ -86,7 +86,7 @@ def openapi_types(): 'detected': (bool,), # noqa: E501 'health_description': (str,), # noqa: E501 'healthy': (bool,), # noqa: E501 - 'update_time': (datetime,), # noqa: E501 + 'update_time': (datetime, none_type,), # noqa: E501 } @cached_property @@ -147,7 +147,7 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 detected (bool): [optional] # noqa: E501 health_description (str): [optional] # noqa: E501 healthy (bool): [optional] # noqa: E501 - update_time (datetime): [optional] # noqa: E501 + update_time (datetime, none_type): [optional] # noqa: E501 """ _check_type = kwargs.pop('_check_type', True) @@ -233,7 +233,7 @@ def __init__(self, *args, **kwargs): # noqa: E501 detected (bool): [optional] # noqa: E501 health_description (str): [optional] # noqa: E501 healthy (bool): [optional] # noqa: E501 - update_time (datetime): [optional] # noqa: E501 + update_time (datetime, none_type): [optional] # noqa: E501 """ _check_type = kwargs.pop('_check_type', True) diff --git a/clients/python/v1/nomad_client/model/ephemeral_disk.py b/clients/python/v1/nomad_client/model/ephemeral_disk.py index da2e60d8..ddf2d220 100644 --- a/clients/python/v1/nomad_client/model/ephemeral_disk.py +++ b/clients/python/v1/nomad_client/model/ephemeral_disk.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError diff --git a/clients/python/v1/nomad_client/model/eval_options.py b/clients/python/v1/nomad_client/model/eval_options.py index 5181b14c..3aa2ee44 100644 --- a/clients/python/v1/nomad_client/model/eval_options.py +++ b/clients/python/v1/nomad_client/model/eval_options.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/evaluation.py b/clients/python/v1/nomad_client/model/evaluation.py index ac4f5409..f656ba87 100644 --- a/clients/python/v1/nomad_client/model/evaluation.py +++ b/clients/python/v1/nomad_client/model/evaluation.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -96,7 +96,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): @@ -138,7 +138,7 @@ def openapi_types(): 'triggered_by': (str,), # noqa: E501 'type': (str,), # noqa: E501 'wait': (int,), # noqa: E501 - 'wait_until': (datetime,), # noqa: E501 + 'wait_until': (datetime, none_type,), # noqa: E501 } @cached_property @@ -247,7 +247,7 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 triggered_by (str): [optional] # noqa: E501 type (str): [optional] # noqa: E501 wait (int): [optional] # noqa: E501 - wait_until (datetime): [optional] # noqa: E501 + wait_until (datetime, none_type): [optional] # noqa: E501 """ _check_type = kwargs.pop('_check_type', True) @@ -357,7 +357,7 @@ def __init__(self, *args, **kwargs): # noqa: E501 triggered_by (str): [optional] # noqa: E501 type (str): [optional] # noqa: E501 wait (int): [optional] # noqa: E501 - wait_until (datetime): [optional] # noqa: E501 + wait_until (datetime, none_type): [optional] # noqa: E501 """ _check_type = kwargs.pop('_check_type', True) diff --git a/clients/python/v1/nomad_client/model/evaluation_stub.py b/clients/python/v1/nomad_client/model/evaluation_stub.py index 88790028..82ed049f 100644 --- a/clients/python/v1/nomad_client/model/evaluation_stub.py +++ b/clients/python/v1/nomad_client/model/evaluation_stub.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -77,7 +77,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): @@ -107,7 +107,7 @@ def openapi_types(): 'status_description': (str,), # noqa: E501 'triggered_by': (str,), # noqa: E501 'type': (str,), # noqa: E501 - 'wait_until': (datetime,), # noqa: E501 + 'wait_until': (datetime, none_type,), # noqa: E501 } @cached_property @@ -194,7 +194,7 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 status_description (str): [optional] # noqa: E501 triggered_by (str): [optional] # noqa: E501 type (str): [optional] # noqa: E501 - wait_until (datetime): [optional] # noqa: E501 + wait_until (datetime, none_type): [optional] # noqa: E501 """ _check_type = kwargs.pop('_check_type', True) @@ -293,7 +293,7 @@ def __init__(self, *args, **kwargs): # noqa: E501 status_description (str): [optional] # noqa: E501 triggered_by (str): [optional] # noqa: E501 type (str): [optional] # noqa: E501 - wait_until (datetime): [optional] # noqa: E501 + wait_until (datetime, none_type): [optional] # noqa: E501 """ _check_type = kwargs.pop('_check_type', True) diff --git a/clients/python/v1/nomad_client/model/field_diff.py b/clients/python/v1/nomad_client/model/field_diff.py index c66072bd..68cf0723 100644 --- a/clients/python/v1/nomad_client/model/field_diff.py +++ b/clients/python/v1/nomad_client/model/field_diff.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/fuzzy_match.py b/clients/python/v1/nomad_client/model/fuzzy_match.py index 4ef070fa..f8e91140 100644 --- a/clients/python/v1/nomad_client/model/fuzzy_match.py +++ b/clients/python/v1/nomad_client/model/fuzzy_match.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/fuzzy_search_request.py b/clients/python/v1/nomad_client/model/fuzzy_search_request.py index f26186bf..6d9af255 100644 --- a/clients/python/v1/nomad_client/model/fuzzy_search_request.py +++ b/clients/python/v1/nomad_client/model/fuzzy_search_request.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -73,7 +73,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/fuzzy_search_response.py b/clients/python/v1/nomad_client/model/fuzzy_search_response.py index 9f859651..be23343b 100644 --- a/clients/python/v1/nomad_client/model/fuzzy_search_response.py +++ b/clients/python/v1/nomad_client/model/fuzzy_search_response.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -78,7 +78,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/gauge_value.py b/clients/python/v1/nomad_client/model/gauge_value.py index 165c7305..9c40df11 100644 --- a/clients/python/v1/nomad_client/model/gauge_value.py +++ b/clients/python/v1/nomad_client/model/gauge_value.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/host_network_info.py b/clients/python/v1/nomad_client/model/host_network_info.py index 811cc86d..e5fa5569 100644 --- a/clients/python/v1/nomad_client/model/host_network_info.py +++ b/clients/python/v1/nomad_client/model/host_network_info.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/host_volume_info.py b/clients/python/v1/nomad_client/model/host_volume_info.py index 425b1a77..e06e1e38 100644 --- a/clients/python/v1/nomad_client/model/host_volume_info.py +++ b/clients/python/v1/nomad_client/model/host_volume_info.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/int8.py b/clients/python/v1/nomad_client/model/int8.py index c49ce6e1..b428ec97 100644 --- a/clients/python/v1/nomad_client/model/int8.py +++ b/clients/python/v1/nomad_client/model/int8.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -61,13 +61,7 @@ class Int8(ModelSimple): }, } - @cached_property - def additional_properties_type(): - """ - This must be a method because a model may have properties that are - of type self, this must run after the class is loaded - """ - return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 + additional_properties_type = None _nullable = False diff --git a/clients/python/v1/nomad_client/model/job.py b/clients/python/v1/nomad_client/model/job.py index d0e3dab4..48bda76b 100644 --- a/clients/python/v1/nomad_client/model/job.py +++ b/clients/python/v1/nomad_client/model/job.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -108,7 +108,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/job_children_summary.py b/clients/python/v1/nomad_client/model/job_children_summary.py index b48bc997..3a1709dd 100644 --- a/clients/python/v1/nomad_client/model/job_children_summary.py +++ b/clients/python/v1/nomad_client/model/job_children_summary.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/job_deregister_response.py b/clients/python/v1/nomad_client/model/job_deregister_response.py index d42955c8..42b0882f 100644 --- a/clients/python/v1/nomad_client/model/job_deregister_response.py +++ b/clients/python/v1/nomad_client/model/job_deregister_response.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -81,7 +81,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/job_diff.py b/clients/python/v1/nomad_client/model/job_diff.py index 5cf2bb7a..ad65fe0a 100644 --- a/clients/python/v1/nomad_client/model/job_diff.py +++ b/clients/python/v1/nomad_client/model/job_diff.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -78,7 +78,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/job_dispatch_request.py b/clients/python/v1/nomad_client/model/job_dispatch_request.py index 1d3ab171..d9d373da 100644 --- a/clients/python/v1/nomad_client/model/job_dispatch_request.py +++ b/clients/python/v1/nomad_client/model/job_dispatch_request.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/job_dispatch_response.py b/clients/python/v1/nomad_client/model/job_dispatch_response.py index f5bb5b39..8fafed7b 100644 --- a/clients/python/v1/nomad_client/model/job_dispatch_response.py +++ b/clients/python/v1/nomad_client/model/job_dispatch_response.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -81,7 +81,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/job_evaluate_request.py b/clients/python/v1/nomad_client/model/job_evaluate_request.py index 03afd254..6aafd5fc 100644 --- a/clients/python/v1/nomad_client/model/job_evaluate_request.py +++ b/clients/python/v1/nomad_client/model/job_evaluate_request.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -74,7 +74,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/job_list_stub.py b/clients/python/v1/nomad_client/model/job_list_stub.py index 088ae3db..590bafbd 100644 --- a/clients/python/v1/nomad_client/model/job_list_stub.py +++ b/clients/python/v1/nomad_client/model/job_list_stub.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -86,7 +86,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/job_plan_request.py b/clients/python/v1/nomad_client/model/job_plan_request.py index b2022861..c8aa7448 100644 --- a/clients/python/v1/nomad_client/model/job_plan_request.py +++ b/clients/python/v1/nomad_client/model/job_plan_request.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -74,7 +74,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/job_plan_response.py b/clients/python/v1/nomad_client/model/job_plan_response.py index ac409b00..b0f62f32 100644 --- a/clients/python/v1/nomad_client/model/job_plan_response.py +++ b/clients/python/v1/nomad_client/model/job_plan_response.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -84,7 +84,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): @@ -103,7 +103,7 @@ def openapi_types(): 'diff': (JobDiff,), # noqa: E501 'failed_tg_allocs': ({str: (AllocationMetric,)},), # noqa: E501 'job_modify_index': (int,), # noqa: E501 - 'next_periodic_launch': (datetime,), # noqa: E501 + 'next_periodic_launch': (datetime, none_type,), # noqa: E501 'warnings': (str,), # noqa: E501 } @@ -168,7 +168,7 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 diff (JobDiff): [optional] # noqa: E501 failed_tg_allocs ({str: (AllocationMetric,)}): [optional] # noqa: E501 job_modify_index (int): [optional] # noqa: E501 - next_periodic_launch (datetime): [optional] # noqa: E501 + next_periodic_launch (datetime, none_type): [optional] # noqa: E501 warnings (str): [optional] # noqa: E501 """ @@ -256,7 +256,7 @@ def __init__(self, *args, **kwargs): # noqa: E501 diff (JobDiff): [optional] # noqa: E501 failed_tg_allocs ({str: (AllocationMetric,)}): [optional] # noqa: E501 job_modify_index (int): [optional] # noqa: E501 - next_periodic_launch (datetime): [optional] # noqa: E501 + next_periodic_launch (datetime, none_type): [optional] # noqa: E501 warnings (str): [optional] # noqa: E501 """ diff --git a/clients/python/v1/nomad_client/model/job_register_request.py b/clients/python/v1/nomad_client/model/job_register_request.py index 12ee2abd..a13a5740 100644 --- a/clients/python/v1/nomad_client/model/job_register_request.py +++ b/clients/python/v1/nomad_client/model/job_register_request.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -78,7 +78,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/job_register_response.py b/clients/python/v1/nomad_client/model/job_register_response.py index 5472d138..9fd05e5a 100644 --- a/clients/python/v1/nomad_client/model/job_register_response.py +++ b/clients/python/v1/nomad_client/model/job_register_response.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -81,7 +81,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/job_revert_request.py b/clients/python/v1/nomad_client/model/job_revert_request.py index 608ba3e1..352fe0eb 100644 --- a/clients/python/v1/nomad_client/model/job_revert_request.py +++ b/clients/python/v1/nomad_client/model/job_revert_request.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -77,7 +77,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/job_scale_status_response.py b/clients/python/v1/nomad_client/model/job_scale_status_response.py index f0bb71f2..e23dd3fb 100644 --- a/clients/python/v1/nomad_client/model/job_scale_status_response.py +++ b/clients/python/v1/nomad_client/model/job_scale_status_response.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -82,7 +82,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/job_stability_request.py b/clients/python/v1/nomad_client/model/job_stability_request.py index 501ab15c..5f8e060c 100644 --- a/clients/python/v1/nomad_client/model/job_stability_request.py +++ b/clients/python/v1/nomad_client/model/job_stability_request.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -73,7 +73,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/job_stability_response.py b/clients/python/v1/nomad_client/model/job_stability_response.py index 226dc1ee..4e80df84 100644 --- a/clients/python/v1/nomad_client/model/job_stability_response.py +++ b/clients/python/v1/nomad_client/model/job_stability_response.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -73,7 +73,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/job_summary.py b/clients/python/v1/nomad_client/model/job_summary.py index 857afcc1..9b3aede4 100644 --- a/clients/python/v1/nomad_client/model/job_summary.py +++ b/clients/python/v1/nomad_client/model/job_summary.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -84,7 +84,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/job_validate_request.py b/clients/python/v1/nomad_client/model/job_validate_request.py index 3d3d0b03..1da4a592 100644 --- a/clients/python/v1/nomad_client/model/job_validate_request.py +++ b/clients/python/v1/nomad_client/model/job_validate_request.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -74,7 +74,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/job_validate_response.py b/clients/python/v1/nomad_client/model/job_validate_response.py index df2450be..b71f8b5f 100644 --- a/clients/python/v1/nomad_client/model/job_validate_response.py +++ b/clients/python/v1/nomad_client/model/job_validate_response.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/job_versions_response.py b/clients/python/v1/nomad_client/model/job_versions_response.py index bfe74346..49829c0b 100644 --- a/clients/python/v1/nomad_client/model/job_versions_response.py +++ b/clients/python/v1/nomad_client/model/job_versions_response.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -80,7 +80,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/jobs_parse_request.py b/clients/python/v1/nomad_client/model/jobs_parse_request.py index 1b1a21de..2b2fa58c 100644 --- a/clients/python/v1/nomad_client/model/jobs_parse_request.py +++ b/clients/python/v1/nomad_client/model/jobs_parse_request.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/log_config.py b/clients/python/v1/nomad_client/model/log_config.py index 0ddad177..429d0051 100644 --- a/clients/python/v1/nomad_client/model/log_config.py +++ b/clients/python/v1/nomad_client/model/log_config.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError diff --git a/clients/python/v1/nomad_client/model/metrics_summary.py b/clients/python/v1/nomad_client/model/metrics_summary.py index 657e8c13..d8da21da 100644 --- a/clients/python/v1/nomad_client/model/metrics_summary.py +++ b/clients/python/v1/nomad_client/model/metrics_summary.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -78,7 +78,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/migrate_strategy.py b/clients/python/v1/nomad_client/model/migrate_strategy.py index a7ef9341..aa773707 100644 --- a/clients/python/v1/nomad_client/model/migrate_strategy.py +++ b/clients/python/v1/nomad_client/model/migrate_strategy.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError diff --git a/clients/python/v1/nomad_client/model/multiregion.py b/clients/python/v1/nomad_client/model/multiregion.py index 5221f820..edaa2ef9 100644 --- a/clients/python/v1/nomad_client/model/multiregion.py +++ b/clients/python/v1/nomad_client/model/multiregion.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -76,7 +76,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/multiregion_region.py b/clients/python/v1/nomad_client/model/multiregion_region.py index 47c63940..bbad28fc 100644 --- a/clients/python/v1/nomad_client/model/multiregion_region.py +++ b/clients/python/v1/nomad_client/model/multiregion_region.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/multiregion_strategy.py b/clients/python/v1/nomad_client/model/multiregion_strategy.py index 72d6c096..534b7ee9 100644 --- a/clients/python/v1/nomad_client/model/multiregion_strategy.py +++ b/clients/python/v1/nomad_client/model/multiregion_strategy.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError diff --git a/clients/python/v1/nomad_client/model/namespace.py b/clients/python/v1/nomad_client/model/namespace.py index 7c9ee6cc..3d606fe2 100644 --- a/clients/python/v1/nomad_client/model/namespace.py +++ b/clients/python/v1/nomad_client/model/namespace.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -82,7 +82,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/namespace_capabilities.py b/clients/python/v1/nomad_client/model/namespace_capabilities.py index c5b57f86..54f4a4b5 100644 --- a/clients/python/v1/nomad_client/model/namespace_capabilities.py +++ b/clients/python/v1/nomad_client/model/namespace_capabilities.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/network_resource.py b/clients/python/v1/nomad_client/model/network_resource.py index ba0c9d1b..b9a360c8 100644 --- a/clients/python/v1/nomad_client/model/network_resource.py +++ b/clients/python/v1/nomad_client/model/network_resource.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -76,7 +76,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/node.py b/clients/python/v1/nomad_client/model/node.py index 94053309..bf0140a4 100644 --- a/clients/python/v1/nomad_client/model/node.py +++ b/clients/python/v1/nomad_client/model/node.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -100,7 +100,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/node_cpu_resources.py b/clients/python/v1/nomad_client/model/node_cpu_resources.py index 4849d575..41e4b0e2 100644 --- a/clients/python/v1/nomad_client/model/node_cpu_resources.py +++ b/clients/python/v1/nomad_client/model/node_cpu_resources.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -73,7 +73,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/node_device.py b/clients/python/v1/nomad_client/model/node_device.py index f2210b94..5c164ea5 100644 --- a/clients/python/v1/nomad_client/model/node_device.py +++ b/clients/python/v1/nomad_client/model/node_device.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -74,7 +74,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/node_device_locality.py b/clients/python/v1/nomad_client/model/node_device_locality.py index a77095fd..909f1a6a 100644 --- a/clients/python/v1/nomad_client/model/node_device_locality.py +++ b/clients/python/v1/nomad_client/model/node_device_locality.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/node_device_resource.py b/clients/python/v1/nomad_client/model/node_device_resource.py index 91641ffc..6e3cb909 100644 --- a/clients/python/v1/nomad_client/model/node_device_resource.py +++ b/clients/python/v1/nomad_client/model/node_device_resource.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -76,7 +76,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/node_disk_resources.py b/clients/python/v1/nomad_client/model/node_disk_resources.py index 358a4310..f264a286 100644 --- a/clients/python/v1/nomad_client/model/node_disk_resources.py +++ b/clients/python/v1/nomad_client/model/node_disk_resources.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/node_drain_update_response.py b/clients/python/v1/nomad_client/model/node_drain_update_response.py index 039d2120..4cbeb733 100644 --- a/clients/python/v1/nomad_client/model/node_drain_update_response.py +++ b/clients/python/v1/nomad_client/model/node_drain_update_response.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -81,7 +81,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/node_eligibility_update_response.py b/clients/python/v1/nomad_client/model/node_eligibility_update_response.py index 56eb4efa..ad1139e2 100644 --- a/clients/python/v1/nomad_client/model/node_eligibility_update_response.py +++ b/clients/python/v1/nomad_client/model/node_eligibility_update_response.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -81,7 +81,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/node_event.py b/clients/python/v1/nomad_client/model/node_event.py index 0206d69b..676a1f57 100644 --- a/clients/python/v1/nomad_client/model/node_event.py +++ b/clients/python/v1/nomad_client/model/node_event.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -73,7 +73,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): @@ -90,7 +90,7 @@ def openapi_types(): 'details': ({str: (str,)},), # noqa: E501 'message': (str,), # noqa: E501 'subsystem': (str,), # noqa: E501 - 'timestamp': (datetime,), # noqa: E501 + 'timestamp': (datetime, none_type,), # noqa: E501 } @cached_property @@ -151,7 +151,7 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 details ({str: (str,)}): [optional] # noqa: E501 message (str): [optional] # noqa: E501 subsystem (str): [optional] # noqa: E501 - timestamp (datetime): [optional] # noqa: E501 + timestamp (datetime, none_type): [optional] # noqa: E501 """ _check_type = kwargs.pop('_check_type', True) @@ -237,7 +237,7 @@ def __init__(self, *args, **kwargs): # noqa: E501 details ({str: (str,)}): [optional] # noqa: E501 message (str): [optional] # noqa: E501 subsystem (str): [optional] # noqa: E501 - timestamp (datetime): [optional] # noqa: E501 + timestamp (datetime, none_type): [optional] # noqa: E501 """ _check_type = kwargs.pop('_check_type', True) diff --git a/clients/python/v1/nomad_client/model/node_list_stub.py b/clients/python/v1/nomad_client/model/node_list_stub.py index 4d5944fe..4edc8a99 100644 --- a/clients/python/v1/nomad_client/model/node_list_stub.py +++ b/clients/python/v1/nomad_client/model/node_list_stub.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -88,7 +88,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/node_memory_resources.py b/clients/python/v1/nomad_client/model/node_memory_resources.py index 3291d7ef..733cf831 100644 --- a/clients/python/v1/nomad_client/model/node_memory_resources.py +++ b/clients/python/v1/nomad_client/model/node_memory_resources.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/node_purge_response.py b/clients/python/v1/nomad_client/model/node_purge_response.py index 65609679..345cd83c 100644 --- a/clients/python/v1/nomad_client/model/node_purge_response.py +++ b/clients/python/v1/nomad_client/model/node_purge_response.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -77,7 +77,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/node_reserved_cpu_resources.py b/clients/python/v1/nomad_client/model/node_reserved_cpu_resources.py index a77a68ca..c91687bb 100644 --- a/clients/python/v1/nomad_client/model/node_reserved_cpu_resources.py +++ b/clients/python/v1/nomad_client/model/node_reserved_cpu_resources.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -73,7 +73,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/node_reserved_disk_resources.py b/clients/python/v1/nomad_client/model/node_reserved_disk_resources.py index caabbdb2..2d9c12e2 100644 --- a/clients/python/v1/nomad_client/model/node_reserved_disk_resources.py +++ b/clients/python/v1/nomad_client/model/node_reserved_disk_resources.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -73,7 +73,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/node_reserved_memory_resources.py b/clients/python/v1/nomad_client/model/node_reserved_memory_resources.py index 16b491cd..59336d6c 100644 --- a/clients/python/v1/nomad_client/model/node_reserved_memory_resources.py +++ b/clients/python/v1/nomad_client/model/node_reserved_memory_resources.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -73,7 +73,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/node_reserved_network_resources.py b/clients/python/v1/nomad_client/model/node_reserved_network_resources.py index 0cafa16e..c83a9fd7 100644 --- a/clients/python/v1/nomad_client/model/node_reserved_network_resources.py +++ b/clients/python/v1/nomad_client/model/node_reserved_network_resources.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/node_reserved_resources.py b/clients/python/v1/nomad_client/model/node_reserved_resources.py index 62b878e1..21177f2e 100644 --- a/clients/python/v1/nomad_client/model/node_reserved_resources.py +++ b/clients/python/v1/nomad_client/model/node_reserved_resources.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -80,7 +80,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/node_resources.py b/clients/python/v1/nomad_client/model/node_resources.py index c2630f9b..1cca0863 100644 --- a/clients/python/v1/nomad_client/model/node_resources.py +++ b/clients/python/v1/nomad_client/model/node_resources.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -82,7 +82,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/node_score_meta.py b/clients/python/v1/nomad_client/model/node_score_meta.py index b7be50d7..9202d3ce 100644 --- a/clients/python/v1/nomad_client/model/node_score_meta.py +++ b/clients/python/v1/nomad_client/model/node_score_meta.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/node_update_drain_request.py b/clients/python/v1/nomad_client/model/node_update_drain_request.py index c19fb5e2..16578015 100644 --- a/clients/python/v1/nomad_client/model/node_update_drain_request.py +++ b/clients/python/v1/nomad_client/model/node_update_drain_request.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -74,7 +74,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/node_update_eligibility_request.py b/clients/python/v1/nomad_client/model/node_update_eligibility_request.py index d697f01b..dfed83a6 100644 --- a/clients/python/v1/nomad_client/model/node_update_eligibility_request.py +++ b/clients/python/v1/nomad_client/model/node_update_eligibility_request.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/object_diff.py b/clients/python/v1/nomad_client/model/object_diff.py index f609f966..1f8a5b65 100644 --- a/clients/python/v1/nomad_client/model/object_diff.py +++ b/clients/python/v1/nomad_client/model/object_diff.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -74,7 +74,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/one_time_token.py b/clients/python/v1/nomad_client/model/one_time_token.py index 931fdffb..edd5bd81 100644 --- a/clients/python/v1/nomad_client/model/one_time_token.py +++ b/clients/python/v1/nomad_client/model/one_time_token.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -77,7 +77,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): @@ -92,7 +92,7 @@ def openapi_types(): return { 'accessor_id': (str,), # noqa: E501 'create_index': (int,), # noqa: E501 - 'expires_at': (datetime,), # noqa: E501 + 'expires_at': (datetime, none_type,), # noqa: E501 'modify_index': (int,), # noqa: E501 'one_time_secret_id': (str,), # noqa: E501 } @@ -153,7 +153,7 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 _visited_composed_classes = (Animal,) accessor_id (str): [optional] # noqa: E501 create_index (int): [optional] # noqa: E501 - expires_at (datetime): [optional] # noqa: E501 + expires_at (datetime, none_type): [optional] # noqa: E501 modify_index (int): [optional] # noqa: E501 one_time_secret_id (str): [optional] # noqa: E501 """ @@ -239,7 +239,7 @@ def __init__(self, *args, **kwargs): # noqa: E501 _visited_composed_classes = (Animal,) accessor_id (str): [optional] # noqa: E501 create_index (int): [optional] # noqa: E501 - expires_at (datetime): [optional] # noqa: E501 + expires_at (datetime, none_type): [optional] # noqa: E501 modify_index (int): [optional] # noqa: E501 one_time_secret_id (str): [optional] # noqa: E501 """ diff --git a/clients/python/v1/nomad_client/model/one_time_token_exchange_request.py b/clients/python/v1/nomad_client/model/one_time_token_exchange_request.py index 7ec1b7d2..c0d53a38 100644 --- a/clients/python/v1/nomad_client/model/one_time_token_exchange_request.py +++ b/clients/python/v1/nomad_client/model/one_time_token_exchange_request.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/operator_health_reply.py b/clients/python/v1/nomad_client/model/operator_health_reply.py index e1e17217..f1f54bbd 100644 --- a/clients/python/v1/nomad_client/model/operator_health_reply.py +++ b/clients/python/v1/nomad_client/model/operator_health_reply.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -74,7 +74,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/parameterized_job_config.py b/clients/python/v1/nomad_client/model/parameterized_job_config.py index 556d90ff..0af5639e 100644 --- a/clients/python/v1/nomad_client/model/parameterized_job_config.py +++ b/clients/python/v1/nomad_client/model/parameterized_job_config.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/periodic_config.py b/clients/python/v1/nomad_client/model/periodic_config.py index e7e64f69..30e76fb5 100644 --- a/clients/python/v1/nomad_client/model/periodic_config.py +++ b/clients/python/v1/nomad_client/model/periodic_config.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError diff --git a/clients/python/v1/nomad_client/model/periodic_force_response.py b/clients/python/v1/nomad_client/model/periodic_force_response.py index ac7762a5..5712f0ee 100644 --- a/clients/python/v1/nomad_client/model/periodic_force_response.py +++ b/clients/python/v1/nomad_client/model/periodic_force_response.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -77,7 +77,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/plan_annotations.py b/clients/python/v1/nomad_client/model/plan_annotations.py index 4d4823fe..b06818dd 100644 --- a/clients/python/v1/nomad_client/model/plan_annotations.py +++ b/clients/python/v1/nomad_client/model/plan_annotations.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -76,7 +76,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/point_value.py b/clients/python/v1/nomad_client/model/point_value.py index 6f2bdd75..2369e196 100644 --- a/clients/python/v1/nomad_client/model/point_value.py +++ b/clients/python/v1/nomad_client/model/point_value.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/port.py b/clients/python/v1/nomad_client/model/port.py index 97f8befc..f1bcdf66 100644 --- a/clients/python/v1/nomad_client/model/port.py +++ b/clients/python/v1/nomad_client/model/port.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/port_mapping.py b/clients/python/v1/nomad_client/model/port_mapping.py index 596b51e8..66ba7184 100644 --- a/clients/python/v1/nomad_client/model/port_mapping.py +++ b/clients/python/v1/nomad_client/model/port_mapping.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/preemption_config.py b/clients/python/v1/nomad_client/model/preemption_config.py index 6e4e400e..80cabc2c 100644 --- a/clients/python/v1/nomad_client/model/preemption_config.py +++ b/clients/python/v1/nomad_client/model/preemption_config.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/quota_limit.py b/clients/python/v1/nomad_client/model/quota_limit.py index 507af0c4..9ed278a3 100644 --- a/clients/python/v1/nomad_client/model/quota_limit.py +++ b/clients/python/v1/nomad_client/model/quota_limit.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -74,7 +74,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/quota_spec.py b/clients/python/v1/nomad_client/model/quota_spec.py index 66fc0438..8f12d467 100644 --- a/clients/python/v1/nomad_client/model/quota_spec.py +++ b/clients/python/v1/nomad_client/model/quota_spec.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -82,7 +82,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/raft_configuration.py b/clients/python/v1/nomad_client/model/raft_configuration.py index d99912f2..27f48c3b 100644 --- a/clients/python/v1/nomad_client/model/raft_configuration.py +++ b/clients/python/v1/nomad_client/model/raft_configuration.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -78,7 +78,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/raft_server.py b/clients/python/v1/nomad_client/model/raft_server.py index 171e8e90..b0f03010 100644 --- a/clients/python/v1/nomad_client/model/raft_server.py +++ b/clients/python/v1/nomad_client/model/raft_server.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/requested_device.py b/clients/python/v1/nomad_client/model/requested_device.py index d92605ae..81a7c2dd 100644 --- a/clients/python/v1/nomad_client/model/requested_device.py +++ b/clients/python/v1/nomad_client/model/requested_device.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -80,7 +80,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/reschedule_event.py b/clients/python/v1/nomad_client/model/reschedule_event.py index fa842a32..5df020ee 100644 --- a/clients/python/v1/nomad_client/model/reschedule_event.py +++ b/clients/python/v1/nomad_client/model/reschedule_event.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/reschedule_policy.py b/clients/python/v1/nomad_client/model/reschedule_policy.py index 6eb2647b..fa2c9812 100644 --- a/clients/python/v1/nomad_client/model/reschedule_policy.py +++ b/clients/python/v1/nomad_client/model/reschedule_policy.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError diff --git a/clients/python/v1/nomad_client/model/reschedule_tracker.py b/clients/python/v1/nomad_client/model/reschedule_tracker.py index ed7b231c..0eee3615 100644 --- a/clients/python/v1/nomad_client/model/reschedule_tracker.py +++ b/clients/python/v1/nomad_client/model/reschedule_tracker.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -74,7 +74,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/resources.py b/clients/python/v1/nomad_client/model/resources.py index f0f1ae0e..05ce199c 100644 --- a/clients/python/v1/nomad_client/model/resources.py +++ b/clients/python/v1/nomad_client/model/resources.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -76,7 +76,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/restart_policy.py b/clients/python/v1/nomad_client/model/restart_policy.py index b59f5be4..0b2fd532 100644 --- a/clients/python/v1/nomad_client/model/restart_policy.py +++ b/clients/python/v1/nomad_client/model/restart_policy.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError diff --git a/clients/python/v1/nomad_client/model/sampled_value.py b/clients/python/v1/nomad_client/model/sampled_value.py index 40ec7dda..b7c39571 100644 --- a/clients/python/v1/nomad_client/model/sampled_value.py +++ b/clients/python/v1/nomad_client/model/sampled_value.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/scaling_event.py b/clients/python/v1/nomad_client/model/scaling_event.py index ee4d8569..2df82038 100644 --- a/clients/python/v1/nomad_client/model/scaling_event.py +++ b/clients/python/v1/nomad_client/model/scaling_event.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -77,7 +77,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/scaling_policy.py b/clients/python/v1/nomad_client/model/scaling_policy.py index 8aa2e925..da945fd7 100644 --- a/clients/python/v1/nomad_client/model/scaling_policy.py +++ b/clients/python/v1/nomad_client/model/scaling_policy.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -77,7 +77,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/scaling_policy_list_stub.py b/clients/python/v1/nomad_client/model/scaling_policy_list_stub.py index 77e16ee6..49d36f18 100644 --- a/clients/python/v1/nomad_client/model/scaling_policy_list_stub.py +++ b/clients/python/v1/nomad_client/model/scaling_policy_list_stub.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -77,7 +77,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/scaling_request.py b/clients/python/v1/nomad_client/model/scaling_request.py index e95e61a7..df8170bd 100644 --- a/clients/python/v1/nomad_client/model/scaling_request.py +++ b/clients/python/v1/nomad_client/model/scaling_request.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/scheduler_configuration.py b/clients/python/v1/nomad_client/model/scheduler_configuration.py index 94dd7773..9e7472d9 100644 --- a/clients/python/v1/nomad_client/model/scheduler_configuration.py +++ b/clients/python/v1/nomad_client/model/scheduler_configuration.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -82,7 +82,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/scheduler_configuration_response.py b/clients/python/v1/nomad_client/model/scheduler_configuration_response.py index daa4ce84..88ccd9b1 100644 --- a/clients/python/v1/nomad_client/model/scheduler_configuration_response.py +++ b/clients/python/v1/nomad_client/model/scheduler_configuration_response.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -78,7 +78,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/scheduler_set_configuration_response.py b/clients/python/v1/nomad_client/model/scheduler_set_configuration_response.py index b361d2ae..4ad9f010 100644 --- a/clients/python/v1/nomad_client/model/scheduler_set_configuration_response.py +++ b/clients/python/v1/nomad_client/model/scheduler_set_configuration_response.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -73,7 +73,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/search_request.py b/clients/python/v1/nomad_client/model/search_request.py index b2f46674..e8fe2336 100644 --- a/clients/python/v1/nomad_client/model/search_request.py +++ b/clients/python/v1/nomad_client/model/search_request.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -73,7 +73,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/search_response.py b/clients/python/v1/nomad_client/model/search_response.py index 132bb93e..5f09b379 100644 --- a/clients/python/v1/nomad_client/model/search_response.py +++ b/clients/python/v1/nomad_client/model/search_response.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -73,7 +73,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/server_health.py b/clients/python/v1/nomad_client/model/server_health.py index 40df0cf8..fc59654b 100644 --- a/clients/python/v1/nomad_client/model/server_health.py +++ b/clients/python/v1/nomad_client/model/server_health.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -77,7 +77,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): @@ -99,7 +99,7 @@ def openapi_types(): 'leader': (bool,), # noqa: E501 'name': (str,), # noqa: E501 'serf_status': (str,), # noqa: E501 - 'stable_since': (datetime,), # noqa: E501 + 'stable_since': (datetime, none_type,), # noqa: E501 'version': (str,), # noqa: E501 'voter': (bool,), # noqa: E501 } @@ -174,7 +174,7 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 leader (bool): [optional] # noqa: E501 name (str): [optional] # noqa: E501 serf_status (str): [optional] # noqa: E501 - stable_since (datetime): [optional] # noqa: E501 + stable_since (datetime, none_type): [optional] # noqa: E501 version (str): [optional] # noqa: E501 voter (bool): [optional] # noqa: E501 """ @@ -267,7 +267,7 @@ def __init__(self, *args, **kwargs): # noqa: E501 leader (bool): [optional] # noqa: E501 name (str): [optional] # noqa: E501 serf_status (str): [optional] # noqa: E501 - stable_since (datetime): [optional] # noqa: E501 + stable_since (datetime, none_type): [optional] # noqa: E501 version (str): [optional] # noqa: E501 voter (bool): [optional] # noqa: E501 """ diff --git a/clients/python/v1/nomad_client/model/service.py b/clients/python/v1/nomad_client/model/service.py index 2692ece7..d5f17e82 100644 --- a/clients/python/v1/nomad_client/model/service.py +++ b/clients/python/v1/nomad_client/model/service.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -78,7 +78,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/service_check.py b/clients/python/v1/nomad_client/model/service_check.py index 18b3c37f..30233fb7 100644 --- a/clients/python/v1/nomad_client/model/service_check.py +++ b/clients/python/v1/nomad_client/model/service_check.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -74,7 +74,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/service_registration.py b/clients/python/v1/nomad_client/model/service_registration.py index d8df9e1f..3a72c758 100644 --- a/clients/python/v1/nomad_client/model/service_registration.py +++ b/clients/python/v1/nomad_client/model/service_registration.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -77,7 +77,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/sidecar_task.py b/clients/python/v1/nomad_client/model/sidecar_task.py index 4fe3e4ce..a85b843e 100644 --- a/clients/python/v1/nomad_client/model/sidecar_task.py +++ b/clients/python/v1/nomad_client/model/sidecar_task.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -76,7 +76,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/spread.py b/clients/python/v1/nomad_client/model/spread.py index 5dfce718..bcf55764 100644 --- a/clients/python/v1/nomad_client/model/spread.py +++ b/clients/python/v1/nomad_client/model/spread.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -78,7 +78,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/spread_target.py b/clients/python/v1/nomad_client/model/spread_target.py index f1ae868d..96a2d8f1 100644 --- a/clients/python/v1/nomad_client/model/spread_target.py +++ b/clients/python/v1/nomad_client/model/spread_target.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -73,7 +73,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/task.py b/clients/python/v1/nomad_client/model/task.py index 35a84c74..6608f22f 100644 --- a/clients/python/v1/nomad_client/model/task.py +++ b/clients/python/v1/nomad_client/model/task.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -100,7 +100,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/task_artifact.py b/clients/python/v1/nomad_client/model/task_artifact.py index 6dd3f31b..7c437c99 100644 --- a/clients/python/v1/nomad_client/model/task_artifact.py +++ b/clients/python/v1/nomad_client/model/task_artifact.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/task_csi_plugin_config.py b/clients/python/v1/nomad_client/model/task_csi_plugin_config.py index 589e535e..0f0b64a6 100644 --- a/clients/python/v1/nomad_client/model/task_csi_plugin_config.py +++ b/clients/python/v1/nomad_client/model/task_csi_plugin_config.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/task_diff.py b/clients/python/v1/nomad_client/model/task_diff.py index fdb4314a..c718b2ff 100644 --- a/clients/python/v1/nomad_client/model/task_diff.py +++ b/clients/python/v1/nomad_client/model/task_diff.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -76,7 +76,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/task_event.py b/clients/python/v1/nomad_client/model/task_event.py index 616a6f70..b559ce99 100644 --- a/clients/python/v1/nomad_client/model/task_event.py +++ b/clients/python/v1/nomad_client/model/task_event.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/task_group.py b/clients/python/v1/nomad_client/model/task_group.py index 6c7c34c7..38f3c0f1 100644 --- a/clients/python/v1/nomad_client/model/task_group.py +++ b/clients/python/v1/nomad_client/model/task_group.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -100,7 +100,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/task_group_diff.py b/clients/python/v1/nomad_client/model/task_group_diff.py index 4eb5367c..6d5f7ebb 100644 --- a/clients/python/v1/nomad_client/model/task_group_diff.py +++ b/clients/python/v1/nomad_client/model/task_group_diff.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -34,9 +34,11 @@ def lazy_import(): from nomad_client.model.field_diff import FieldDiff from nomad_client.model.object_diff import ObjectDiff from nomad_client.model.task_diff import TaskDiff + from nomad_client.model.uint64 import Uint64 globals()['FieldDiff'] = FieldDiff globals()['ObjectDiff'] = ObjectDiff globals()['TaskDiff'] = TaskDiff + globals()['Uint64'] = Uint64 class TaskGroupDiff(ModelNormal): @@ -78,7 +80,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): @@ -97,7 +99,7 @@ def openapi_types(): 'objects': ([ObjectDiff],), # noqa: E501 'tasks': ([TaskDiff],), # noqa: E501 'type': (str,), # noqa: E501 - 'updates': ({str: (int,)},), # noqa: E501 + 'updates': ({str: (Uint64,)},), # noqa: E501 } @cached_property @@ -160,7 +162,7 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 objects ([ObjectDiff]): [optional] # noqa: E501 tasks ([TaskDiff]): [optional] # noqa: E501 type (str): [optional] # noqa: E501 - updates ({str: (int,)}): [optional] # noqa: E501 + updates ({str: (Uint64,)}): [optional] # noqa: E501 """ _check_type = kwargs.pop('_check_type', True) @@ -247,7 +249,7 @@ def __init__(self, *args, **kwargs): # noqa: E501 objects ([ObjectDiff]): [optional] # noqa: E501 tasks ([TaskDiff]): [optional] # noqa: E501 type (str): [optional] # noqa: E501 - updates ({str: (int,)}): [optional] # noqa: E501 + updates ({str: (Uint64,)}): [optional] # noqa: E501 """ _check_type = kwargs.pop('_check_type', True) diff --git a/clients/python/v1/nomad_client/model/task_group_scale_status.py b/clients/python/v1/nomad_client/model/task_group_scale_status.py index 87c7371a..0def7da9 100644 --- a/clients/python/v1/nomad_client/model/task_group_scale_status.py +++ b/clients/python/v1/nomad_client/model/task_group_scale_status.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -74,7 +74,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/task_group_summary.py b/clients/python/v1/nomad_client/model/task_group_summary.py index a044a881..8344aa05 100644 --- a/clients/python/v1/nomad_client/model/task_group_summary.py +++ b/clients/python/v1/nomad_client/model/task_group_summary.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/task_handle.py b/clients/python/v1/nomad_client/model/task_handle.py index 734dfaf7..c4acce32 100644 --- a/clients/python/v1/nomad_client/model/task_handle.py +++ b/clients/python/v1/nomad_client/model/task_handle.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/task_lifecycle.py b/clients/python/v1/nomad_client/model/task_lifecycle.py index d9135914..5609911a 100644 --- a/clients/python/v1/nomad_client/model/task_lifecycle.py +++ b/clients/python/v1/nomad_client/model/task_lifecycle.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/task_state.py b/clients/python/v1/nomad_client/model/task_state.py index 8d3968a3..f1e09f07 100644 --- a/clients/python/v1/nomad_client/model/task_state.py +++ b/clients/python/v1/nomad_client/model/task_state.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -80,7 +80,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): @@ -96,10 +96,10 @@ def openapi_types(): return { 'events': ([TaskEvent],), # noqa: E501 'failed': (bool,), # noqa: E501 - 'finished_at': (datetime,), # noqa: E501 - 'last_restart': (datetime,), # noqa: E501 + 'finished_at': (datetime, none_type,), # noqa: E501 + 'last_restart': (datetime, none_type,), # noqa: E501 'restarts': (int,), # noqa: E501 - 'started_at': (datetime,), # noqa: E501 + 'started_at': (datetime, none_type,), # noqa: E501 'state': (str,), # noqa: E501 'task_handle': (TaskHandle,), # noqa: E501 } @@ -163,10 +163,10 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 _visited_composed_classes = (Animal,) events ([TaskEvent]): [optional] # noqa: E501 failed (bool): [optional] # noqa: E501 - finished_at (datetime): [optional] # noqa: E501 - last_restart (datetime): [optional] # noqa: E501 + finished_at (datetime, none_type): [optional] # noqa: E501 + last_restart (datetime, none_type): [optional] # noqa: E501 restarts (int): [optional] # noqa: E501 - started_at (datetime): [optional] # noqa: E501 + started_at (datetime, none_type): [optional] # noqa: E501 state (str): [optional] # noqa: E501 task_handle (TaskHandle): [optional] # noqa: E501 """ @@ -252,10 +252,10 @@ def __init__(self, *args, **kwargs): # noqa: E501 _visited_composed_classes = (Animal,) events ([TaskEvent]): [optional] # noqa: E501 failed (bool): [optional] # noqa: E501 - finished_at (datetime): [optional] # noqa: E501 - last_restart (datetime): [optional] # noqa: E501 + finished_at (datetime, none_type): [optional] # noqa: E501 + last_restart (datetime, none_type): [optional] # noqa: E501 restarts (int): [optional] # noqa: E501 - started_at (datetime): [optional] # noqa: E501 + started_at (datetime, none_type): [optional] # noqa: E501 state (str): [optional] # noqa: E501 task_handle (TaskHandle): [optional] # noqa: E501 """ diff --git a/clients/python/v1/nomad_client/model/template.py b/clients/python/v1/nomad_client/model/template.py index 24a4bb53..ada37b44 100644 --- a/clients/python/v1/nomad_client/model/template.py +++ b/clients/python/v1/nomad_client/model/template.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError diff --git a/clients/python/v1/nomad_client/model/uint.py b/clients/python/v1/nomad_client/model/uint.py index f0b213ba..4c2124c8 100644 --- a/clients/python/v1/nomad_client/model/uint.py +++ b/clients/python/v1/nomad_client/model/uint.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -60,13 +60,7 @@ class Uint(ModelSimple): }, } - @cached_property - def additional_properties_type(): - """ - This must be a method because a model may have properties that are - of type self, this must run after the class is loaded - """ - return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 + additional_properties_type = None _nullable = False diff --git a/clients/python/v1/nomad_client/model/uint16.py b/clients/python/v1/nomad_client/model/uint16.py index fe4c7bcb..4ad8900a 100644 --- a/clients/python/v1/nomad_client/model/uint16.py +++ b/clients/python/v1/nomad_client/model/uint16.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -61,13 +61,7 @@ class Uint16(ModelSimple): }, } - @cached_property - def additional_properties_type(): - """ - This must be a method because a model may have properties that are - of type self, this must run after the class is loaded - """ - return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 + additional_properties_type = None _nullable = False diff --git a/clients/python/v1/nomad_client/model/uint64.py b/clients/python/v1/nomad_client/model/uint64.py index 4bb42002..bc4b0522 100644 --- a/clients/python/v1/nomad_client/model/uint64.py +++ b/clients/python/v1/nomad_client/model/uint64.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -61,13 +61,7 @@ class Uint64(ModelSimple): }, } - @cached_property - def additional_properties_type(): - """ - This must be a method because a model may have properties that are - of type self, this must run after the class is loaded - """ - return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 + additional_properties_type = None _nullable = False diff --git a/clients/python/v1/nomad_client/model/uint8.py b/clients/python/v1/nomad_client/model/uint8.py index 5f9fa336..75a9af47 100644 --- a/clients/python/v1/nomad_client/model/uint8.py +++ b/clients/python/v1/nomad_client/model/uint8.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -61,13 +61,7 @@ class Uint8(ModelSimple): }, } - @cached_property - def additional_properties_type(): - """ - This must be a method because a model may have properties that are - of type self, this must run after the class is loaded - """ - return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 + additional_properties_type = None _nullable = False diff --git a/clients/python/v1/nomad_client/model/update_strategy.py b/clients/python/v1/nomad_client/model/update_strategy.py index 8cbfebe1..fafc157a 100644 --- a/clients/python/v1/nomad_client/model/update_strategy.py +++ b/clients/python/v1/nomad_client/model/update_strategy.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError diff --git a/clients/python/v1/nomad_client/model/vault.py b/clients/python/v1/nomad_client/model/vault.py index c87c7acd..29f5da79 100644 --- a/clients/python/v1/nomad_client/model/vault.py +++ b/clients/python/v1/nomad_client/model/vault.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -69,7 +69,7 @@ def additional_properties_type(): """ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/volume_mount.py b/clients/python/v1/nomad_client/model/volume_mount.py index 6f3c34be..132420a4 100644 --- a/clients/python/v1/nomad_client/model/volume_mount.py +++ b/clients/python/v1/nomad_client/model/volume_mount.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError diff --git a/clients/python/v1/nomad_client/model/volume_request.py b/clients/python/v1/nomad_client/model/volume_request.py index d26e8d4d..6ada171f 100644 --- a/clients/python/v1/nomad_client/model/volume_request.py +++ b/clients/python/v1/nomad_client/model/volume_request.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError @@ -74,7 +74,7 @@ def additional_properties_type(): lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 - _nullable = False + _nullable = True @cached_property def openapi_types(): diff --git a/clients/python/v1/nomad_client/model/wait_config.py b/clients/python/v1/nomad_client/model/wait_config.py index 4526b13b..aa8d0bd2 100644 --- a/clients/python/v1/nomad_client/model/wait_config.py +++ b/clients/python/v1/nomad_client/model/wait_config.py @@ -25,8 +25,8 @@ file_type, none_type, validate_get_composed_info, + OpenApiModel ) -from ..model_utils import OpenApiModel from nomad_client.exceptions import ApiAttributeError diff --git a/clients/python/v1/nomad_client/model_utils.py b/clients/python/v1/nomad_client/model_utils.py index 74723337..beebbca9 100644 --- a/clients/python/v1/nomad_client/model_utils.py +++ b/clients/python/v1/nomad_client/model_utils.py @@ -10,6 +10,7 @@ from datetime import date, datetime # noqa: F401 +from copy import deepcopy import inspect import io import os @@ -187,6 +188,26 @@ def __getattr__(self, attr): """get the value of an attribute using dot notation: `instance.attr`""" return self.__getitem__(attr) + def __copy__(self): + cls = self.__class__ + if self.get("_spec_property_naming", False): + return cls._new_from_openapi_data(**self.__dict__) + else: + return new_cls.__new__(cls, **self.__dict__) + + def __deepcopy__(self, memo): + cls = self.__class__ + + if self.get("_spec_property_naming", False): + new_inst = cls._new_from_openapi_data() + else: + new_inst = cls.__new__(cls) + + for k, v in self.__dict__.items(): + setattr(new_inst, k, deepcopy(v, memo)) + return new_inst + + def __new__(cls, *args, **kwargs): # this function uses the discriminator to # pick a new schema/class to instantiate because a discriminator @@ -296,8 +317,13 @@ def __new__(cls, *args, **kwargs): self_inst = super(OpenApiModel, cls).__new__(cls) self_inst.__init__(*args, **kwargs) - new_inst = new_cls.__new__(new_cls, *args, **kwargs) - new_inst.__init__(*args, **kwargs) + if kwargs.get("_spec_property_naming", False): + # when true, implies new is from deserialization + new_inst = new_cls._new_from_openapi_data(*args, **kwargs) + else: + new_inst = new_cls.__new__(new_cls, *args, **kwargs) + new_inst.__init__(*args, **kwargs) + return new_inst @@ -447,7 +473,7 @@ def __getitem__(self, name): ) def __contains__(self, name): - """used by `in` operator to check if an attrbute value was set in an instance: `'attr' in instance`""" + """used by `in` operator to check if an attribute value was set in an instance: `'attr' in instance`""" if name in self.required_properties: return name in self.__dict__ @@ -502,7 +528,7 @@ def __getitem__(self, name): ) def __contains__(self, name): - """used by `in` operator to check if an attrbute value was set in an instance: `'attr' in instance`""" + """used by `in` operator to check if an attribute value was set in an instance: `'attr' in instance`""" if name in self.required_properties: return name in self.__dict__ @@ -649,7 +675,7 @@ def __getitem__(self, name): return value def __contains__(self, name): - """used by `in` operator to check if an attrbute value was set in an instance: `'attr' in instance`""" + """used by `in` operator to check if an attribute value was set in an instance: `'attr' in instance`""" if name in self.required_properties: return name in self.__dict__ @@ -1480,6 +1506,9 @@ def is_valid_type(input_class_simple, valid_classes): Returns: bool """ + if issubclass(input_class_simple, OpenApiModel) and \ + valid_classes == (bool, date, datetime, dict, float, int, list, str, none_type,): + return True valid_type = input_class_simple in valid_classes if not valid_type and ( issubclass(input_class_simple, OpenApiModel) or @@ -1629,6 +1658,7 @@ def model_to_dict(model_instance, serialize=True): attribute_map """ result = {} + extract_item = lambda item: (item[0], model_to_dict(item[1], serialize=serialize)) if hasattr(item[1], '_data_store') else item model_instances = [model_instance] if model_instance._composed_schemas: @@ -1658,14 +1688,17 @@ def model_to_dict(model_instance, serialize=True): res.append(v) elif isinstance(v, ModelSimple): res.append(v.value) + elif isinstance(v, dict): + res.append(dict(map( + extract_item, + v.items() + ))) else: res.append(model_to_dict(v, serialize=serialize)) result[attr] = res elif isinstance(value, dict): result[attr] = dict(map( - lambda item: (item[0], - model_to_dict(item[1], serialize=serialize)) - if hasattr(item[1], '_data_store') else item, + extract_item, value.items() )) elif isinstance(value, ModelSimple): @@ -1748,7 +1781,10 @@ def get_allof_instances(self, model_args, constant_args): for allof_class in self._composed_schemas['allOf']: try: - allof_instance = allof_class(**model_args, **constant_args) + if constant_args.get('_spec_property_naming'): + allof_instance = allof_class._from_openapi_data(**model_args, **constant_args) + else: + allof_instance = allof_class(**model_args, **constant_args) composed_instances.append(allof_instance) except Exception as ex: raise ApiValueError( @@ -1810,10 +1846,16 @@ def get_oneof_instance(cls, model_kwargs, constant_kwargs, model_arg=None): try: if not single_value_input: - oneof_instance = oneof_class(**model_kwargs, **constant_kwargs) + if constant_kwargs.get('_spec_property_naming'): + oneof_instance = oneof_class._from_openapi_data(**model_kwargs, **constant_kwargs) + else: + oneof_instance = oneof_class(**model_kwargs, **constant_kwargs) else: if issubclass(oneof_class, ModelSimple): - oneof_instance = oneof_class(model_arg, **constant_kwargs) + if constant_kwargs.get('_spec_property_naming'): + oneof_instance = oneof_class._from_openapi_data(model_arg, **constant_kwargs) + else: + oneof_instance = oneof_class(model_arg, **constant_kwargs) elif oneof_class in PRIMITIVE_TYPES: oneof_instance = validate_and_convert_types( model_arg, @@ -1868,7 +1910,10 @@ def get_anyof_instances(self, model_args, constant_args): continue try: - anyof_instance = anyof_class(**model_args, **constant_args) + if constant_args.get('_spec_property_naming'): + anyof_instance = anyof_class._from_openapi_data(**model_args, **constant_args) + else: + anyof_instance = anyof_class(**model_args, **constant_args) anyof_instances.append(anyof_instance) except Exception: pass diff --git a/clients/python/v1/nomad_client/rest.py b/clients/python/v1/nomad_client/rest.py index 009ebb08..5f19d5dc 100644 --- a/clients/python/v1/nomad_client/rest.py +++ b/clients/python/v1/nomad_client/rest.py @@ -15,8 +15,10 @@ import re import ssl from urllib.parse import urlencode - +from urllib.parse import urlparse +from urllib.request import proxy_bypass_environment import urllib3 +import ipaddress from nomad_client.exceptions import ApiException, UnauthorizedException, ForbiddenException, NotFoundException, ServiceException, ApiValueError @@ -73,7 +75,7 @@ def __init__(self, configuration, pools_size=4, maxsize=None): maxsize = 4 # https pool manager - if configuration.proxy: + if configuration.proxy and not should_bypass_proxies(configuration.host, no_proxy=configuration.no_proxy or ''): self.pool_manager = urllib3.ProxyManager( num_pools=pools_size, maxsize=maxsize, @@ -291,3 +293,55 @@ def PATCH(self, url, headers=None, query_params=None, post_params=None, _preload_content=_preload_content, _request_timeout=_request_timeout, body=body) + +# end of class RESTClientObject +def is_ipv4(target): + """ Test if IPv4 address or not + """ + try: + chk = ipaddress.IPv4Address(target) + return True + except ipaddress.AddressValueError: + return False + +def in_ipv4net(target, net): + """ Test if target belongs to given IPv4 network + """ + try: + nw = ipaddress.IPv4Network(net) + ip = ipaddress.IPv4Address(target) + if ip in nw: + return True + return False + except ipaddress.AddressValueError: + return False + except ipaddress.NetmaskValueError: + return False + +def should_bypass_proxies(url, no_proxy=None): + """ Yet another requests.should_bypass_proxies + Test if proxies should not be used for a particular url. + """ + + parsed = urlparse(url) + + # special cases + if parsed.hostname in [None, '']: + return True + + # special cases + if no_proxy in [None , '']: + return False + if no_proxy == '*': + return True + + no_proxy = no_proxy.lower().replace(' ',''); + entries = ( + host for host in no_proxy.split(',') if host + ) + + if is_ipv4(parsed.hostname): + for item in entries: + if in_ipv4net(parsed.hostname, item): + return True + return proxy_bypass_environment(parsed.hostname, {'no': no_proxy} ) diff --git a/clients/ruby/v1/.openapi-generator/VERSION b/clients/ruby/v1/.openapi-generator/VERSION index 7cbea073..1e20ec35 100644 --- a/clients/ruby/v1/.openapi-generator/VERSION +++ b/clients/ruby/v1/.openapi-generator/VERSION @@ -1 +1 @@ -5.2.0 \ No newline at end of file +5.4.0 \ No newline at end of file diff --git a/clients/ruby/v1/docs/ConsulGateway.md b/clients/ruby/v1/docs/ConsulGateway.md index 9879b05b..6a845e70 100644 --- a/clients/ruby/v1/docs/ConsulGateway.md +++ b/clients/ruby/v1/docs/ConsulGateway.md @@ -5,7 +5,7 @@ | Name | Type | Description | Notes | | ---- | ---- | ----------- | ----- | | **ingress** | [**ConsulIngressConfigEntry**](ConsulIngressConfigEntry.md) | | [optional] | -| **mesh** | [**AnyType**](.md) | | [optional] | +| **mesh** | **Object** | | [optional] | | **proxy** | [**ConsulGatewayProxy**](ConsulGatewayProxy.md) | | [optional] | | **terminating** | [**ConsulTerminatingConfigEntry**](ConsulTerminatingConfigEntry.md) | | [optional] | diff --git a/clients/ruby/v1/docs/ConsulGatewayProxy.md b/clients/ruby/v1/docs/ConsulGatewayProxy.md index 40216543..1ad7c26d 100644 --- a/clients/ruby/v1/docs/ConsulGatewayProxy.md +++ b/clients/ruby/v1/docs/ConsulGatewayProxy.md @@ -4,7 +4,7 @@ | Name | Type | Description | Notes | | ---- | ---- | ----------- | ----- | -| **config** | [**Hash<String, AnyType>**](AnyType.md) | | [optional] | +| **config** | **Hash<String, Object>** | | [optional] | | **connect_timeout** | **Integer** | | [optional] | | **envoy_dns_discovery_type** | **String** | | [optional] | | **envoy_gateway_bind_addresses** | [**Hash<String, ConsulGatewayBindAddress>**](ConsulGatewayBindAddress.md) | | [optional] | diff --git a/clients/ruby/v1/docs/ConsulProxy.md b/clients/ruby/v1/docs/ConsulProxy.md index bfebb5fd..23b94988 100644 --- a/clients/ruby/v1/docs/ConsulProxy.md +++ b/clients/ruby/v1/docs/ConsulProxy.md @@ -4,7 +4,7 @@ | Name | Type | Description | Notes | | ---- | ---- | ----------- | ----- | -| **config** | [**Hash<String, AnyType>**](AnyType.md) | | [optional] | +| **config** | **Hash<String, Object>** | | [optional] | | **expose_config** | [**ConsulExposeConfig**](ConsulExposeConfig.md) | | [optional] | | **local_service_address** | **String** | | [optional] | | **local_service_port** | **Integer** | | [optional] | diff --git a/clients/ruby/v1/docs/EnterpriseApi.md b/clients/ruby/v1/docs/EnterpriseApi.md index 9acb4060..5afd6d40 100644 --- a/clients/ruby/v1/docs/EnterpriseApi.md +++ b/clients/ruby/v1/docs/EnterpriseApi.md @@ -258,7 +258,7 @@ end ## get_quotas -> > get_quotas(opts) +> Array<Object> get_quotas(opts) @@ -301,7 +301,7 @@ end This returns an Array which contains the response data, status code and headers. -> >, Integer, Hash)> get_quotas_with_http_info(opts) +> get_quotas_with_http_info(opts) ```ruby begin @@ -309,7 +309,7 @@ begin data, status_code, headers = api_instance.get_quotas_with_http_info(opts) p status_code # => 2xx p headers # => { ... } - p data # => > + p data # => Array<Object> rescue NomadClient::ApiError => e puts "Error when calling EnterpriseApi->get_quotas_with_http_info: #{e}" end @@ -331,7 +331,7 @@ end ### Return type -[**Array<AnyType>**](AnyType.md) +**Array<Object>** ### Authorization diff --git a/clients/ruby/v1/docs/ScalingEvent.md b/clients/ruby/v1/docs/ScalingEvent.md index 7585bba5..b440949e 100644 --- a/clients/ruby/v1/docs/ScalingEvent.md +++ b/clients/ruby/v1/docs/ScalingEvent.md @@ -9,7 +9,7 @@ | **error** | **Boolean** | | [optional] | | **eval_id** | **String** | | [optional] | | **message** | **String** | | [optional] | -| **meta** | [**Hash<String, AnyType>**](AnyType.md) | | [optional] | +| **meta** | **Hash<String, Object>** | | [optional] | | **previous_count** | **Integer** | | [optional] | | **time** | **Integer** | | [optional] | diff --git a/clients/ruby/v1/docs/ScalingPolicy.md b/clients/ruby/v1/docs/ScalingPolicy.md index 532f36f4..3fa979c3 100644 --- a/clients/ruby/v1/docs/ScalingPolicy.md +++ b/clients/ruby/v1/docs/ScalingPolicy.md @@ -11,7 +11,7 @@ | **min** | **Integer** | | [optional] | | **modify_index** | **Integer** | | [optional] | | **namespace** | **String** | | [optional] | -| **policy** | [**Hash<String, AnyType>**](AnyType.md) | | [optional] | +| **policy** | **Hash<String, Object>** | | [optional] | | **target** | **Hash<String, String>** | | [optional] | | **type** | **String** | | [optional] | diff --git a/clients/ruby/v1/docs/ScalingRequest.md b/clients/ruby/v1/docs/ScalingRequest.md index b5af0baf..c96b5b5f 100644 --- a/clients/ruby/v1/docs/ScalingRequest.md +++ b/clients/ruby/v1/docs/ScalingRequest.md @@ -7,7 +7,7 @@ | **count** | **Integer** | | [optional] | | **error** | **Boolean** | | [optional] | | **message** | **String** | | [optional] | -| **meta** | [**Hash<String, AnyType>**](AnyType.md) | | [optional] | +| **meta** | **Hash<String, Object>** | | [optional] | | **namespace** | **String** | | [optional] | | **policy_override** | **Boolean** | | [optional] | | **region** | **String** | | [optional] | diff --git a/clients/ruby/v1/docs/SidecarTask.md b/clients/ruby/v1/docs/SidecarTask.md index a9008d8b..69da3fac 100644 --- a/clients/ruby/v1/docs/SidecarTask.md +++ b/clients/ruby/v1/docs/SidecarTask.md @@ -4,7 +4,7 @@ | Name | Type | Description | Notes | | ---- | ---- | ----------- | ----- | -| **config** | [**Hash<String, AnyType>**](AnyType.md) | | [optional] | +| **config** | **Hash<String, Object>** | | [optional] | | **driver** | **String** | | [optional] | | **env** | **Hash<String, String>** | | [optional] | | **kill_signal** | **String** | | [optional] | diff --git a/clients/ruby/v1/docs/Task.md b/clients/ruby/v1/docs/Task.md index 5a5b56f6..8ed92d9c 100644 --- a/clients/ruby/v1/docs/Task.md +++ b/clients/ruby/v1/docs/Task.md @@ -7,7 +7,7 @@ | **affinities** | [**Array<Affinity>**](Affinity.md) | | [optional] | | **artifacts** | [**Array<TaskArtifact>**](TaskArtifact.md) | | [optional] | | **csi_plugin_config** | [**TaskCSIPluginConfig**](TaskCSIPluginConfig.md) | | [optional] | -| **config** | [**Hash<String, AnyType>**](AnyType.md) | | [optional] | +| **config** | **Hash<String, Object>** | | [optional] | | **constraints** | [**Array<Constraint>**](Constraint.md) | | [optional] | | **dispatch_payload** | [**DispatchPayloadConfig**](DispatchPayloadConfig.md) | | [optional] | | **driver** | **String** | | [optional] | diff --git a/clients/ruby/v1/lib/nomad_client.rb b/clients/ruby/v1/lib/nomad_client.rb index 761187d9..81d82080 100644 --- a/clients/ruby/v1/lib/nomad_client.rb +++ b/clients/ruby/v1/lib/nomad_client.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/api/acl_api.rb b/clients/ruby/v1/lib/nomad_client/api/acl_api.rb index 944727fd..6d049efc 100644 --- a/clients/ruby/v1/lib/nomad_client/api/acl_api.rb +++ b/clients/ruby/v1/lib/nomad_client/api/acl_api.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -663,10 +663,6 @@ def post_acl_policy_with_http_info(policy_name, acl_policy, opts = {}) if @api_client.config.client_side_validation && policy_name.nil? fail ArgumentError, "Missing the required parameter 'policy_name' when calling ACLApi.post_acl_policy" end - # verify the required parameter 'acl_policy' is set - if @api_client.config.client_side_validation && acl_policy.nil? - fail ArgumentError, "Missing the required parameter 'acl_policy' when calling ACLApi.post_acl_policy" - end # resource path local_var_path = '/acl/policy/{policyName}'.sub('{' + 'policyName' + '}', CGI.escape(policy_name.to_s)) @@ -679,7 +675,10 @@ def post_acl_policy_with_http_info(policy_name, acl_policy, opts = {}) # header parameters header_params = opts[:header_params] || {} # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end header_params[:'X-Nomad-Token'] = opts[:'x_nomad_token'] if !opts[:'x_nomad_token'].nil? # form parameters @@ -740,10 +739,6 @@ def post_acl_token_with_http_info(token_accessor, acl_token, opts = {}) if @api_client.config.client_side_validation && token_accessor.nil? fail ArgumentError, "Missing the required parameter 'token_accessor' when calling ACLApi.post_acl_token" end - # verify the required parameter 'acl_token' is set - if @api_client.config.client_side_validation && acl_token.nil? - fail ArgumentError, "Missing the required parameter 'acl_token' when calling ACLApi.post_acl_token" - end # resource path local_var_path = '/acl/token/{tokenAccessor}'.sub('{' + 'tokenAccessor' + '}', CGI.escape(token_accessor.to_s)) @@ -758,7 +753,10 @@ def post_acl_token_with_http_info(token_accessor, acl_token, opts = {}) # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end header_params[:'X-Nomad-Token'] = opts[:'x_nomad_token'] if !opts[:'x_nomad_token'].nil? # form parameters @@ -878,10 +876,6 @@ def post_acl_token_onetime_exchange_with_http_info(one_time_token_exchange_reque if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: ACLApi.post_acl_token_onetime_exchange ...' end - # verify the required parameter 'one_time_token_exchange_request' is set - if @api_client.config.client_side_validation && one_time_token_exchange_request.nil? - fail ArgumentError, "Missing the required parameter 'one_time_token_exchange_request' when calling ACLApi.post_acl_token_onetime_exchange" - end # resource path local_var_path = '/acl/token/onetime/exchange' @@ -896,7 +890,10 @@ def post_acl_token_onetime_exchange_with_http_info(one_time_token_exchange_reque # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end header_params[:'X-Nomad-Token'] = opts[:'x_nomad_token'] if !opts[:'x_nomad_token'].nil? # form parameters diff --git a/clients/ruby/v1/lib/nomad_client/api/allocations_api.rb b/clients/ruby/v1/lib/nomad_client/api/allocations_api.rb index 215ab6ed..f53aa51c 100644 --- a/clients/ruby/v1/lib/nomad_client/api/allocations_api.rb +++ b/clients/ruby/v1/lib/nomad_client/api/allocations_api.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/api/deployments_api.rb b/clients/ruby/v1/lib/nomad_client/api/deployments_api.rb index 2cbeeb6b..a86d73e6 100644 --- a/clients/ruby/v1/lib/nomad_client/api/deployments_api.rb +++ b/clients/ruby/v1/lib/nomad_client/api/deployments_api.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -300,10 +300,6 @@ def post_deployment_allocation_health_with_http_info(deployment_id, deployment_a if @api_client.config.client_side_validation && deployment_id.nil? fail ArgumentError, "Missing the required parameter 'deployment_id' when calling DeploymentsApi.post_deployment_allocation_health" end - # verify the required parameter 'deployment_alloc_health_request' is set - if @api_client.config.client_side_validation && deployment_alloc_health_request.nil? - fail ArgumentError, "Missing the required parameter 'deployment_alloc_health_request' when calling DeploymentsApi.post_deployment_allocation_health" - end # resource path local_var_path = '/deployment/allocation-health/{deploymentID}'.sub('{' + 'deploymentID' + '}', CGI.escape(deployment_id.to_s)) @@ -318,7 +314,10 @@ def post_deployment_allocation_health_with_http_info(deployment_id, deployment_a # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end header_params[:'X-Nomad-Token'] = opts[:'x_nomad_token'] if !opts[:'x_nomad_token'].nil? # form parameters @@ -450,10 +449,6 @@ def post_deployment_pause_with_http_info(deployment_id, deployment_pause_request if @api_client.config.client_side_validation && deployment_id.nil? fail ArgumentError, "Missing the required parameter 'deployment_id' when calling DeploymentsApi.post_deployment_pause" end - # verify the required parameter 'deployment_pause_request' is set - if @api_client.config.client_side_validation && deployment_pause_request.nil? - fail ArgumentError, "Missing the required parameter 'deployment_pause_request' when calling DeploymentsApi.post_deployment_pause" - end # resource path local_var_path = '/deployment/pause/{deploymentID}'.sub('{' + 'deploymentID' + '}', CGI.escape(deployment_id.to_s)) @@ -468,7 +463,10 @@ def post_deployment_pause_with_http_info(deployment_id, deployment_pause_request # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end header_params[:'X-Nomad-Token'] = opts[:'x_nomad_token'] if !opts[:'x_nomad_token'].nil? # form parameters @@ -529,10 +527,6 @@ def post_deployment_promote_with_http_info(deployment_id, deployment_promote_req if @api_client.config.client_side_validation && deployment_id.nil? fail ArgumentError, "Missing the required parameter 'deployment_id' when calling DeploymentsApi.post_deployment_promote" end - # verify the required parameter 'deployment_promote_request' is set - if @api_client.config.client_side_validation && deployment_promote_request.nil? - fail ArgumentError, "Missing the required parameter 'deployment_promote_request' when calling DeploymentsApi.post_deployment_promote" - end # resource path local_var_path = '/deployment/promote/{deploymentID}'.sub('{' + 'deploymentID' + '}', CGI.escape(deployment_id.to_s)) @@ -547,7 +541,10 @@ def post_deployment_promote_with_http_info(deployment_id, deployment_promote_req # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end header_params[:'X-Nomad-Token'] = opts[:'x_nomad_token'] if !opts[:'x_nomad_token'].nil? # form parameters @@ -608,10 +605,6 @@ def post_deployment_unblock_with_http_info(deployment_id, deployment_unblock_req if @api_client.config.client_side_validation && deployment_id.nil? fail ArgumentError, "Missing the required parameter 'deployment_id' when calling DeploymentsApi.post_deployment_unblock" end - # verify the required parameter 'deployment_unblock_request' is set - if @api_client.config.client_side_validation && deployment_unblock_request.nil? - fail ArgumentError, "Missing the required parameter 'deployment_unblock_request' when calling DeploymentsApi.post_deployment_unblock" - end # resource path local_var_path = '/deployment/unblock/{deploymentID}'.sub('{' + 'deploymentID' + '}', CGI.escape(deployment_id.to_s)) @@ -626,7 +619,10 @@ def post_deployment_unblock_with_http_info(deployment_id, deployment_unblock_req # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end header_params[:'X-Nomad-Token'] = opts[:'x_nomad_token'] if !opts[:'x_nomad_token'].nil? # form parameters diff --git a/clients/ruby/v1/lib/nomad_client/api/enterprise_api.rb b/clients/ruby/v1/lib/nomad_client/api/enterprise_api.rb index 50eb79f8..abe8fbf4 100644 --- a/clients/ruby/v1/lib/nomad_client/api/enterprise_api.rb +++ b/clients/ruby/v1/lib/nomad_client/api/enterprise_api.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -42,10 +42,6 @@ def create_quota_spec_with_http_info(quota_spec, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: EnterpriseApi.create_quota_spec ...' end - # verify the required parameter 'quota_spec' is set - if @api_client.config.client_side_validation && quota_spec.nil? - fail ArgumentError, "Missing the required parameter 'quota_spec' when calling EnterpriseApi.create_quota_spec" - end # resource path local_var_path = '/quota' @@ -58,7 +54,10 @@ def create_quota_spec_with_http_info(quota_spec, opts = {}) # header parameters header_params = opts[:header_params] || {} # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end header_params[:'X-Nomad-Token'] = opts[:'x_nomad_token'] if !opts[:'x_nomad_token'].nil? # form parameters @@ -255,7 +254,7 @@ def get_quota_spec_with_http_info(spec_name, opts = {}) # @option opts [String] :x_nomad_token A Nomad ACL token. # @option opts [Integer] :per_page Maximum number of results to return. # @option opts [String] :next_token Indicates where to start paging for queries that support pagination. - # @return [Array] + # @return [Array] def get_quotas(opts = {}) data, _status_code, _headers = get_quotas_with_http_info(opts) data @@ -271,7 +270,7 @@ def get_quotas(opts = {}) # @option opts [String] :x_nomad_token A Nomad ACL token. # @option opts [Integer] :per_page Maximum number of results to return. # @option opts [String] :next_token Indicates where to start paging for queries that support pagination. - # @return [Array<(Array, Integer, Hash)>] Array data, response status code and response headers + # @return [Array<(Array, Integer, Hash)>] Array data, response status code and response headers def get_quotas_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: EnterpriseApi.get_quotas ...' @@ -303,7 +302,7 @@ def get_quotas_with_http_info(opts = {}) post_body = opts[:debug_body] # return_type - return_type = opts[:debug_return_type] || 'Array' + return_type = opts[:debug_return_type] || 'Array' # auth_names auth_names = opts[:debug_auth_names] || ['X-Nomad-Token'] @@ -354,10 +353,6 @@ def post_quota_spec_with_http_info(spec_name, quota_spec, opts = {}) if @api_client.config.client_side_validation && spec_name.nil? fail ArgumentError, "Missing the required parameter 'spec_name' when calling EnterpriseApi.post_quota_spec" end - # verify the required parameter 'quota_spec' is set - if @api_client.config.client_side_validation && quota_spec.nil? - fail ArgumentError, "Missing the required parameter 'quota_spec' when calling EnterpriseApi.post_quota_spec" - end # resource path local_var_path = '/quota/{specName}'.sub('{' + 'specName' + '}', CGI.escape(spec_name.to_s)) @@ -370,7 +365,10 @@ def post_quota_spec_with_http_info(spec_name, quota_spec, opts = {}) # header parameters header_params = opts[:header_params] || {} # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end header_params[:'X-Nomad-Token'] = opts[:'x_nomad_token'] if !opts[:'x_nomad_token'].nil? # form parameters diff --git a/clients/ruby/v1/lib/nomad_client/api/evaluations_api.rb b/clients/ruby/v1/lib/nomad_client/api/evaluations_api.rb index caf85588..280b912d 100644 --- a/clients/ruby/v1/lib/nomad_client/api/evaluations_api.rb +++ b/clients/ruby/v1/lib/nomad_client/api/evaluations_api.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/api/jobs_api.rb b/clients/ruby/v1/lib/nomad_client/api/jobs_api.rb index 764051de..9b26e7e7 100644 --- a/clients/ruby/v1/lib/nomad_client/api/jobs_api.rb +++ b/clients/ruby/v1/lib/nomad_client/api/jobs_api.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -902,10 +902,6 @@ def post_job_with_http_info(job_name, job_register_request, opts = {}) if @api_client.config.client_side_validation && job_name.nil? fail ArgumentError, "Missing the required parameter 'job_name' when calling JobsApi.post_job" end - # verify the required parameter 'job_register_request' is set - if @api_client.config.client_side_validation && job_register_request.nil? - fail ArgumentError, "Missing the required parameter 'job_register_request' when calling JobsApi.post_job" - end # resource path local_var_path = '/job/{jobName}'.sub('{' + 'jobName' + '}', CGI.escape(job_name.to_s)) @@ -920,7 +916,10 @@ def post_job_with_http_info(job_name, job_register_request, opts = {}) # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end header_params[:'X-Nomad-Token'] = opts[:'x_nomad_token'] if !opts[:'x_nomad_token'].nil? # form parameters @@ -981,10 +980,6 @@ def post_job_dispatch_with_http_info(job_name, job_dispatch_request, opts = {}) if @api_client.config.client_side_validation && job_name.nil? fail ArgumentError, "Missing the required parameter 'job_name' when calling JobsApi.post_job_dispatch" end - # verify the required parameter 'job_dispatch_request' is set - if @api_client.config.client_side_validation && job_dispatch_request.nil? - fail ArgumentError, "Missing the required parameter 'job_dispatch_request' when calling JobsApi.post_job_dispatch" - end # resource path local_var_path = '/job/{jobName}/dispatch'.sub('{' + 'jobName' + '}', CGI.escape(job_name.to_s)) @@ -999,7 +994,10 @@ def post_job_dispatch_with_http_info(job_name, job_dispatch_request, opts = {}) # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end header_params[:'X-Nomad-Token'] = opts[:'x_nomad_token'] if !opts[:'x_nomad_token'].nil? # form parameters @@ -1060,10 +1058,6 @@ def post_job_evaluate_with_http_info(job_name, job_evaluate_request, opts = {}) if @api_client.config.client_side_validation && job_name.nil? fail ArgumentError, "Missing the required parameter 'job_name' when calling JobsApi.post_job_evaluate" end - # verify the required parameter 'job_evaluate_request' is set - if @api_client.config.client_side_validation && job_evaluate_request.nil? - fail ArgumentError, "Missing the required parameter 'job_evaluate_request' when calling JobsApi.post_job_evaluate" - end # resource path local_var_path = '/job/{jobName}/evaluate'.sub('{' + 'jobName' + '}', CGI.escape(job_name.to_s)) @@ -1078,7 +1072,10 @@ def post_job_evaluate_with_http_info(job_name, job_evaluate_request, opts = {}) # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end header_params[:'X-Nomad-Token'] = opts[:'x_nomad_token'] if !opts[:'x_nomad_token'].nil? # form parameters @@ -1125,10 +1122,6 @@ def post_job_parse_with_http_info(jobs_parse_request, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: JobsApi.post_job_parse ...' end - # verify the required parameter 'jobs_parse_request' is set - if @api_client.config.client_side_validation && jobs_parse_request.nil? - fail ArgumentError, "Missing the required parameter 'jobs_parse_request' when calling JobsApi.post_job_parse" - end # resource path local_var_path = '/jobs/parse' @@ -1140,7 +1133,10 @@ def post_job_parse_with_http_info(jobs_parse_request, opts = {}) # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end # form parameters form_params = opts[:form_params] || {} @@ -1271,10 +1267,6 @@ def post_job_plan_with_http_info(job_name, job_plan_request, opts = {}) if @api_client.config.client_side_validation && job_name.nil? fail ArgumentError, "Missing the required parameter 'job_name' when calling JobsApi.post_job_plan" end - # verify the required parameter 'job_plan_request' is set - if @api_client.config.client_side_validation && job_plan_request.nil? - fail ArgumentError, "Missing the required parameter 'job_plan_request' when calling JobsApi.post_job_plan" - end # resource path local_var_path = '/job/{jobName}/plan'.sub('{' + 'jobName' + '}', CGI.escape(job_name.to_s)) @@ -1289,7 +1281,10 @@ def post_job_plan_with_http_info(job_name, job_plan_request, opts = {}) # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end header_params[:'X-Nomad-Token'] = opts[:'x_nomad_token'] if !opts[:'x_nomad_token'].nil? # form parameters @@ -1350,10 +1345,6 @@ def post_job_revert_with_http_info(job_name, job_revert_request, opts = {}) if @api_client.config.client_side_validation && job_name.nil? fail ArgumentError, "Missing the required parameter 'job_name' when calling JobsApi.post_job_revert" end - # verify the required parameter 'job_revert_request' is set - if @api_client.config.client_side_validation && job_revert_request.nil? - fail ArgumentError, "Missing the required parameter 'job_revert_request' when calling JobsApi.post_job_revert" - end # resource path local_var_path = '/job/{jobName}/revert'.sub('{' + 'jobName' + '}', CGI.escape(job_name.to_s)) @@ -1368,7 +1359,10 @@ def post_job_revert_with_http_info(job_name, job_revert_request, opts = {}) # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end header_params[:'X-Nomad-Token'] = opts[:'x_nomad_token'] if !opts[:'x_nomad_token'].nil? # form parameters @@ -1429,10 +1423,6 @@ def post_job_scaling_request_with_http_info(job_name, scaling_request, opts = {} if @api_client.config.client_side_validation && job_name.nil? fail ArgumentError, "Missing the required parameter 'job_name' when calling JobsApi.post_job_scaling_request" end - # verify the required parameter 'scaling_request' is set - if @api_client.config.client_side_validation && scaling_request.nil? - fail ArgumentError, "Missing the required parameter 'scaling_request' when calling JobsApi.post_job_scaling_request" - end # resource path local_var_path = '/job/{jobName}/scale'.sub('{' + 'jobName' + '}', CGI.escape(job_name.to_s)) @@ -1447,7 +1437,10 @@ def post_job_scaling_request_with_http_info(job_name, scaling_request, opts = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end header_params[:'X-Nomad-Token'] = opts[:'x_nomad_token'] if !opts[:'x_nomad_token'].nil? # form parameters @@ -1508,10 +1501,6 @@ def post_job_stability_with_http_info(job_name, job_stability_request, opts = {} if @api_client.config.client_side_validation && job_name.nil? fail ArgumentError, "Missing the required parameter 'job_name' when calling JobsApi.post_job_stability" end - # verify the required parameter 'job_stability_request' is set - if @api_client.config.client_side_validation && job_stability_request.nil? - fail ArgumentError, "Missing the required parameter 'job_stability_request' when calling JobsApi.post_job_stability" - end # resource path local_var_path = '/job/{jobName}/stable'.sub('{' + 'jobName' + '}', CGI.escape(job_name.to_s)) @@ -1526,7 +1515,10 @@ def post_job_stability_with_http_info(job_name, job_stability_request, opts = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end header_params[:'X-Nomad-Token'] = opts[:'x_nomad_token'] if !opts[:'x_nomad_token'].nil? # form parameters @@ -1581,10 +1573,6 @@ def post_job_validate_request_with_http_info(job_validate_request, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: JobsApi.post_job_validate_request ...' end - # verify the required parameter 'job_validate_request' is set - if @api_client.config.client_side_validation && job_validate_request.nil? - fail ArgumentError, "Missing the required parameter 'job_validate_request' when calling JobsApi.post_job_validate_request" - end # resource path local_var_path = '/validate/job' @@ -1599,7 +1587,10 @@ def post_job_validate_request_with_http_info(job_validate_request, opts = {}) # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end header_params[:'X-Nomad-Token'] = opts[:'x_nomad_token'] if !opts[:'x_nomad_token'].nil? # form parameters @@ -1654,10 +1645,6 @@ def register_job_with_http_info(job_register_request, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: JobsApi.register_job ...' end - # verify the required parameter 'job_register_request' is set - if @api_client.config.client_side_validation && job_register_request.nil? - fail ArgumentError, "Missing the required parameter 'job_register_request' when calling JobsApi.register_job" - end # resource path local_var_path = '/jobs' @@ -1672,7 +1659,10 @@ def register_job_with_http_info(job_register_request, opts = {}) # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end header_params[:'X-Nomad-Token'] = opts[:'x_nomad_token'] if !opts[:'x_nomad_token'].nil? # form parameters diff --git a/clients/ruby/v1/lib/nomad_client/api/metrics_api.rb b/clients/ruby/v1/lib/nomad_client/api/metrics_api.rb index 0c3238d0..96744fe2 100644 --- a/clients/ruby/v1/lib/nomad_client/api/metrics_api.rb +++ b/clients/ruby/v1/lib/nomad_client/api/metrics_api.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/api/namespaces_api.rb b/clients/ruby/v1/lib/nomad_client/api/namespaces_api.rb index 165ce96e..de0bf52f 100644 --- a/clients/ruby/v1/lib/nomad_client/api/namespaces_api.rb +++ b/clients/ruby/v1/lib/nomad_client/api/namespaces_api.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -346,10 +346,6 @@ def post_namespace_with_http_info(namespace_name, namespace2, opts = {}) if @api_client.config.client_side_validation && namespace_name.nil? fail ArgumentError, "Missing the required parameter 'namespace_name' when calling NamespacesApi.post_namespace" end - # verify the required parameter 'namespace2' is set - if @api_client.config.client_side_validation && namespace2.nil? - fail ArgumentError, "Missing the required parameter 'namespace2' when calling NamespacesApi.post_namespace" - end # resource path local_var_path = '/namespace/{namespaceName}'.sub('{' + 'namespaceName' + '}', CGI.escape(namespace_name.to_s)) @@ -362,7 +358,10 @@ def post_namespace_with_http_info(namespace_name, namespace2, opts = {}) # header parameters header_params = opts[:header_params] || {} # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end header_params[:'X-Nomad-Token'] = opts[:'x_nomad_token'] if !opts[:'x_nomad_token'].nil? # form parameters diff --git a/clients/ruby/v1/lib/nomad_client/api/nodes_api.rb b/clients/ruby/v1/lib/nomad_client/api/nodes_api.rb index d43e2a5e..bf9baff5 100644 --- a/clients/ruby/v1/lib/nomad_client/api/nodes_api.rb +++ b/clients/ruby/v1/lib/nomad_client/api/nodes_api.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -313,10 +313,6 @@ def update_node_drain_with_http_info(node_id, node_update_drain_request, opts = if @api_client.config.client_side_validation && node_id.nil? fail ArgumentError, "Missing the required parameter 'node_id' when calling NodesApi.update_node_drain" end - # verify the required parameter 'node_update_drain_request' is set - if @api_client.config.client_side_validation && node_update_drain_request.nil? - fail ArgumentError, "Missing the required parameter 'node_update_drain_request' when calling NodesApi.update_node_drain" - end # resource path local_var_path = '/node/{nodeId}/drain'.sub('{' + 'nodeId' + '}', CGI.escape(node_id.to_s)) @@ -335,7 +331,10 @@ def update_node_drain_with_http_info(node_id, node_update_drain_request, opts = # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end header_params[:'index'] = opts[:'index'] if !opts[:'index'].nil? header_params[:'X-Nomad-Token'] = opts[:'x_nomad_token'] if !opts[:'x_nomad_token'].nil? @@ -407,10 +406,6 @@ def update_node_eligibility_with_http_info(node_id, node_update_eligibility_requ if @api_client.config.client_side_validation && node_id.nil? fail ArgumentError, "Missing the required parameter 'node_id' when calling NodesApi.update_node_eligibility" end - # verify the required parameter 'node_update_eligibility_request' is set - if @api_client.config.client_side_validation && node_update_eligibility_request.nil? - fail ArgumentError, "Missing the required parameter 'node_update_eligibility_request' when calling NodesApi.update_node_eligibility" - end # resource path local_var_path = '/node/{nodeId}/eligibility'.sub('{' + 'nodeId' + '}', CGI.escape(node_id.to_s)) @@ -429,7 +424,10 @@ def update_node_eligibility_with_http_info(node_id, node_update_eligibility_requ # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end header_params[:'index'] = opts[:'index'] if !opts[:'index'].nil? header_params[:'X-Nomad-Token'] = opts[:'x_nomad_token'] if !opts[:'x_nomad_token'].nil? diff --git a/clients/ruby/v1/lib/nomad_client/api/operator_api.rb b/clients/ruby/v1/lib/nomad_client/api/operator_api.rb index 688905dc..a37849f7 100644 --- a/clients/ruby/v1/lib/nomad_client/api/operator_api.rb +++ b/clients/ruby/v1/lib/nomad_client/api/operator_api.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -425,10 +425,6 @@ def post_operator_scheduler_configuration_with_http_info(scheduler_configuration if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: OperatorApi.post_operator_scheduler_configuration ...' end - # verify the required parameter 'scheduler_configuration' is set - if @api_client.config.client_side_validation && scheduler_configuration.nil? - fail ArgumentError, "Missing the required parameter 'scheduler_configuration' when calling OperatorApi.post_operator_scheduler_configuration" - end # resource path local_var_path = '/operator/scheduler/configuration' @@ -443,7 +439,10 @@ def post_operator_scheduler_configuration_with_http_info(scheduler_configuration # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end header_params[:'X-Nomad-Token'] = opts[:'x_nomad_token'] if !opts[:'x_nomad_token'].nil? # form parameters @@ -498,10 +497,6 @@ def put_operator_autopilot_configuration_with_http_info(autopilot_configuration, if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: OperatorApi.put_operator_autopilot_configuration ...' end - # verify the required parameter 'autopilot_configuration' is set - if @api_client.config.client_side_validation && autopilot_configuration.nil? - fail ArgumentError, "Missing the required parameter 'autopilot_configuration' when calling OperatorApi.put_operator_autopilot_configuration" - end # resource path local_var_path = '/operator/autopilot/configuration' @@ -516,7 +511,10 @@ def put_operator_autopilot_configuration_with_http_info(autopilot_configuration, # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end header_params[:'X-Nomad-Token'] = opts[:'x_nomad_token'] if !opts[:'x_nomad_token'].nil? # form parameters diff --git a/clients/ruby/v1/lib/nomad_client/api/plugins_api.rb b/clients/ruby/v1/lib/nomad_client/api/plugins_api.rb index f64d335c..2d89228e 100644 --- a/clients/ruby/v1/lib/nomad_client/api/plugins_api.rb +++ b/clients/ruby/v1/lib/nomad_client/api/plugins_api.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/api/regions_api.rb b/clients/ruby/v1/lib/nomad_client/api/regions_api.rb index b37d834e..bbe6d3bd 100644 --- a/clients/ruby/v1/lib/nomad_client/api/regions_api.rb +++ b/clients/ruby/v1/lib/nomad_client/api/regions_api.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/api/scaling_api.rb b/clients/ruby/v1/lib/nomad_client/api/scaling_api.rb index c4e0c5b0..102f163d 100644 --- a/clients/ruby/v1/lib/nomad_client/api/scaling_api.rb +++ b/clients/ruby/v1/lib/nomad_client/api/scaling_api.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/api/search_api.rb b/clients/ruby/v1/lib/nomad_client/api/search_api.rb index a4316ba9..a35afa9a 100644 --- a/clients/ruby/v1/lib/nomad_client/api/search_api.rb +++ b/clients/ruby/v1/lib/nomad_client/api/search_api.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -52,10 +52,6 @@ def get_fuzzy_search_with_http_info(fuzzy_search_request, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: SearchApi.get_fuzzy_search ...' end - # verify the required parameter 'fuzzy_search_request' is set - if @api_client.config.client_side_validation && fuzzy_search_request.nil? - fail ArgumentError, "Missing the required parameter 'fuzzy_search_request' when calling SearchApi.get_fuzzy_search" - end # resource path local_var_path = '/search/fuzzy' @@ -74,7 +70,10 @@ def get_fuzzy_search_with_http_info(fuzzy_search_request, opts = {}) # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end header_params[:'index'] = opts[:'index'] if !opts[:'index'].nil? header_params[:'X-Nomad-Token'] = opts[:'x_nomad_token'] if !opts[:'x_nomad_token'].nil? @@ -140,10 +139,6 @@ def get_search_with_http_info(search_request, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: SearchApi.get_search ...' end - # verify the required parameter 'search_request' is set - if @api_client.config.client_side_validation && search_request.nil? - fail ArgumentError, "Missing the required parameter 'search_request' when calling SearchApi.get_search" - end # resource path local_var_path = '/search' @@ -162,7 +157,10 @@ def get_search_with_http_info(search_request, opts = {}) # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end header_params[:'index'] = opts[:'index'] if !opts[:'index'].nil? header_params[:'X-Nomad-Token'] = opts[:'x_nomad_token'] if !opts[:'x_nomad_token'].nil? diff --git a/clients/ruby/v1/lib/nomad_client/api/status_api.rb b/clients/ruby/v1/lib/nomad_client/api/status_api.rb index 08715fbd..236fd8a6 100644 --- a/clients/ruby/v1/lib/nomad_client/api/status_api.rb +++ b/clients/ruby/v1/lib/nomad_client/api/status_api.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/api/system_api.rb b/clients/ruby/v1/lib/nomad_client/api/system_api.rb index bc0a6631..dc68f3b0 100644 --- a/clients/ruby/v1/lib/nomad_client/api/system_api.rb +++ b/clients/ruby/v1/lib/nomad_client/api/system_api.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/api/volumes_api.rb b/clients/ruby/v1/lib/nomad_client/api/volumes_api.rb index ebda5eac..93f45d1a 100644 --- a/clients/ruby/v1/lib/nomad_client/api/volumes_api.rb +++ b/clients/ruby/v1/lib/nomad_client/api/volumes_api.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -54,10 +54,6 @@ def create_volume_with_http_info(volume_id, action, csi_volume_create_request, o if @api_client.config.client_side_validation && action.nil? fail ArgumentError, "Missing the required parameter 'action' when calling VolumesApi.create_volume" end - # verify the required parameter 'csi_volume_create_request' is set - if @api_client.config.client_side_validation && csi_volume_create_request.nil? - fail ArgumentError, "Missing the required parameter 'csi_volume_create_request' when calling VolumesApi.create_volume" - end # resource path local_var_path = '/volume/csi/{volumeId}/{action}'.sub('{' + 'volumeId' + '}', CGI.escape(volume_id.to_s)).sub('{' + 'action' + '}', CGI.escape(action.to_s)) @@ -70,7 +66,10 @@ def create_volume_with_http_info(volume_id, action, csi_volume_create_request, o # header parameters header_params = opts[:header_params] || {} # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end header_params[:'X-Nomad-Token'] = opts[:'x_nomad_token'] if !opts[:'x_nomad_token'].nil? # form parameters @@ -685,10 +684,6 @@ def post_snapshot_with_http_info(csi_snapshot_create_request, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: VolumesApi.post_snapshot ...' end - # verify the required parameter 'csi_snapshot_create_request' is set - if @api_client.config.client_side_validation && csi_snapshot_create_request.nil? - fail ArgumentError, "Missing the required parameter 'csi_snapshot_create_request' when calling VolumesApi.post_snapshot" - end # resource path local_var_path = '/volumes/snapshot' @@ -703,7 +698,10 @@ def post_snapshot_with_http_info(csi_snapshot_create_request, opts = {}) # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end header_params[:'X-Nomad-Token'] = opts[:'x_nomad_token'] if !opts[:'x_nomad_token'].nil? # form parameters @@ -758,10 +756,6 @@ def post_volume_with_http_info(csi_volume_register_request, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: VolumesApi.post_volume ...' end - # verify the required parameter 'csi_volume_register_request' is set - if @api_client.config.client_side_validation && csi_volume_register_request.nil? - fail ArgumentError, "Missing the required parameter 'csi_volume_register_request' when calling VolumesApi.post_volume" - end # resource path local_var_path = '/volumes' @@ -774,7 +768,10 @@ def post_volume_with_http_info(csi_volume_register_request, opts = {}) # header parameters header_params = opts[:header_params] || {} # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end header_params[:'X-Nomad-Token'] = opts[:'x_nomad_token'] if !opts[:'x_nomad_token'].nil? # form parameters @@ -835,10 +832,6 @@ def post_volume_registration_with_http_info(volume_id, csi_volume_register_reque if @api_client.config.client_side_validation && volume_id.nil? fail ArgumentError, "Missing the required parameter 'volume_id' when calling VolumesApi.post_volume_registration" end - # verify the required parameter 'csi_volume_register_request' is set - if @api_client.config.client_side_validation && csi_volume_register_request.nil? - fail ArgumentError, "Missing the required parameter 'csi_volume_register_request' when calling VolumesApi.post_volume_registration" - end # resource path local_var_path = '/volume/csi/{volumeId}'.sub('{' + 'volumeId' + '}', CGI.escape(volume_id.to_s)) @@ -851,7 +844,10 @@ def post_volume_registration_with_http_info(volume_id, csi_volume_register_reque # header parameters header_params = opts[:header_params] || {} # HTTP header 'Content-Type' - header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) + content_type = @api_client.select_header_content_type(['application/json']) + if !content_type.nil? + header_params['Content-Type'] = content_type + end header_params[:'X-Nomad-Token'] = opts[:'x_nomad_token'] if !opts[:'x_nomad_token'].nil? # form parameters diff --git a/clients/ruby/v1/lib/nomad_client/api_client.rb b/clients/ruby/v1/lib/nomad_client/api_client.rb index 2284bcd2..9a29b61e 100644 --- a/clients/ruby/v1/lib/nomad_client/api_client.rb +++ b/clients/ruby/v1/lib/nomad_client/api_client.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -296,7 +296,7 @@ def build_request_url(path, opts = {}) @config.base_url(opts[:operation]) + path end - # Update hearder and query params based on authentication settings. + # Update header and query params based on authentication settings. # # @param [Hash] header_params Header parameters # @param [Hash] query_params Query parameters @@ -335,8 +335,8 @@ def select_header_accept(accepts) # @param [Array] content_types array for Content-Type # @return [String] the Content-Type header (e.g. application/json) def select_header_content_type(content_types) - # use application/json by default - return 'application/json' if content_types.nil? || content_types.empty? + # return nil by default + return if content_types.nil? || content_types.empty? # use JSON when present, otherwise use the first one json_content_type = content_types.find { |s| json_mime?(s) } json_content_type || content_types.first diff --git a/clients/ruby/v1/lib/nomad_client/api_error.rb b/clients/ruby/v1/lib/nomad_client/api_error.rb index d63a124e..59afc6dd 100644 --- a/clients/ruby/v1/lib/nomad_client/api_error.rb +++ b/clients/ruby/v1/lib/nomad_client/api_error.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/configuration.rb b/clients/ruby/v1/lib/nomad_client/configuration.rb index 1cf9ced8..a7296501 100644 --- a/clients/ruby/v1/lib/nomad_client/configuration.rb +++ b/clients/ruby/v1/lib/nomad_client/configuration.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -147,13 +147,13 @@ def initialize @server_operation_variables = {} @api_key = {} @api_key_prefix = {} - @timeout = 0 @client_side_validation = true @verify_ssl = true @verify_ssl_host = true @params_encoding = nil @cert_file = nil @key_file = nil + @timeout = 0 @debugging = false @inject_format = false @force_ending_format = false @@ -313,5 +313,6 @@ def server_url(index, variables = {}, servers = nil) url end + end end diff --git a/clients/ruby/v1/lib/nomad_client/models/acl_policy.rb b/clients/ruby/v1/lib/nomad_client/models/acl_policy.rb index 160b3dfd..48dbdece 100644 --- a/clients/ruby/v1/lib/nomad_client/models/acl_policy.rb +++ b/clients/ruby/v1/lib/nomad_client/models/acl_policy.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/acl_policy_list_stub.rb b/clients/ruby/v1/lib/nomad_client/models/acl_policy_list_stub.rb index b904bd0c..d77c8145 100644 --- a/clients/ruby/v1/lib/nomad_client/models/acl_policy_list_stub.rb +++ b/clients/ruby/v1/lib/nomad_client/models/acl_policy_list_stub.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/acl_token.rb b/clients/ruby/v1/lib/nomad_client/models/acl_token.rb index e8171863..b38973b5 100644 --- a/clients/ruby/v1/lib/nomad_client/models/acl_token.rb +++ b/clients/ruby/v1/lib/nomad_client/models/acl_token.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -71,6 +71,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'create_time', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/acl_token_list_stub.rb b/clients/ruby/v1/lib/nomad_client/models/acl_token_list_stub.rb index 78b5b982..683ecacd 100644 --- a/clients/ruby/v1/lib/nomad_client/models/acl_token_list_stub.rb +++ b/clients/ruby/v1/lib/nomad_client/models/acl_token_list_stub.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -67,6 +67,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'create_time', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/affinity.rb b/clients/ruby/v1/lib/nomad_client/models/affinity.rb index 39ec3697..13760887 100644 --- a/clients/ruby/v1/lib/nomad_client/models/affinity.rb +++ b/clients/ruby/v1/lib/nomad_client/models/affinity.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/alloc_deployment_status.rb b/clients/ruby/v1/lib/nomad_client/models/alloc_deployment_status.rb index 1b1dc394..e47a3f5d 100644 --- a/clients/ruby/v1/lib/nomad_client/models/alloc_deployment_status.rb +++ b/clients/ruby/v1/lib/nomad_client/models/alloc_deployment_status.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -51,6 +51,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'timestamp' ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/alloc_stop_response.rb b/clients/ruby/v1/lib/nomad_client/models/alloc_stop_response.rb index 0559f66e..6c745478 100644 --- a/clients/ruby/v1/lib/nomad_client/models/alloc_stop_response.rb +++ b/clients/ruby/v1/lib/nomad_client/models/alloc_stop_response.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/allocated_cpu_resources.rb b/clients/ruby/v1/lib/nomad_client/models/allocated_cpu_resources.rb index c41b7623..57bbf504 100644 --- a/clients/ruby/v1/lib/nomad_client/models/allocated_cpu_resources.rb +++ b/clients/ruby/v1/lib/nomad_client/models/allocated_cpu_resources.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/allocated_device_resource.rb b/clients/ruby/v1/lib/nomad_client/models/allocated_device_resource.rb index f363edee..2f414b9e 100644 --- a/clients/ruby/v1/lib/nomad_client/models/allocated_device_resource.rb +++ b/clients/ruby/v1/lib/nomad_client/models/allocated_device_resource.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/allocated_memory_resources.rb b/clients/ruby/v1/lib/nomad_client/models/allocated_memory_resources.rb index 563811a6..b8a84a8e 100644 --- a/clients/ruby/v1/lib/nomad_client/models/allocated_memory_resources.rb +++ b/clients/ruby/v1/lib/nomad_client/models/allocated_memory_resources.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/allocated_resources.rb b/clients/ruby/v1/lib/nomad_client/models/allocated_resources.rb index a457dd5e..5a399eee 100644 --- a/clients/ruby/v1/lib/nomad_client/models/allocated_resources.rb +++ b/clients/ruby/v1/lib/nomad_client/models/allocated_resources.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -43,6 +43,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'shared', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/allocated_shared_resources.rb b/clients/ruby/v1/lib/nomad_client/models/allocated_shared_resources.rb index 40e55d81..e2a9bac5 100644 --- a/clients/ruby/v1/lib/nomad_client/models/allocated_shared_resources.rb +++ b/clients/ruby/v1/lib/nomad_client/models/allocated_shared_resources.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/allocated_task_resources.rb b/clients/ruby/v1/lib/nomad_client/models/allocated_task_resources.rb index ff458d8b..755348e0 100644 --- a/clients/ruby/v1/lib/nomad_client/models/allocated_task_resources.rb +++ b/clients/ruby/v1/lib/nomad_client/models/allocated_task_resources.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -51,6 +51,8 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'cpu', + :'memory', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/allocation.rb b/clients/ruby/v1/lib/nomad_client/models/allocation.rb index b5620539..1bd3be5f 100644 --- a/clients/ruby/v1/lib/nomad_client/models/allocation.rb +++ b/clients/ruby/v1/lib/nomad_client/models/allocation.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -167,6 +167,12 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'allocated_resources', + :'deployment_status', + :'job', + :'metrics', + :'reschedule_tracker', + :'resources', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/allocation_list_stub.rb b/clients/ruby/v1/lib/nomad_client/models/allocation_list_stub.rb index cdb7bdec..70f03a67 100644 --- a/clients/ruby/v1/lib/nomad_client/models/allocation_list_stub.rb +++ b/clients/ruby/v1/lib/nomad_client/models/allocation_list_stub.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -135,6 +135,9 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'allocated_resources', + :'deployment_status', + :'reschedule_tracker', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/allocation_metric.rb b/clients/ruby/v1/lib/nomad_client/models/allocation_metric.rb index 2a43824e..7141a176 100644 --- a/clients/ruby/v1/lib/nomad_client/models/allocation_metric.rb +++ b/clients/ruby/v1/lib/nomad_client/models/allocation_metric.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/attribute.rb b/clients/ruby/v1/lib/nomad_client/models/attribute.rb index 2ab0515c..0850e02d 100644 --- a/clients/ruby/v1/lib/nomad_client/models/attribute.rb +++ b/clients/ruby/v1/lib/nomad_client/models/attribute.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/autopilot_configuration.rb b/clients/ruby/v1/lib/nomad_client/models/autopilot_configuration.rb index 86d1c784..8d80f76b 100644 --- a/clients/ruby/v1/lib/nomad_client/models/autopilot_configuration.rb +++ b/clients/ruby/v1/lib/nomad_client/models/autopilot_configuration.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/check_restart.rb b/clients/ruby/v1/lib/nomad_client/models/check_restart.rb index ba99ebf1..0cf73cc5 100644 --- a/clients/ruby/v1/lib/nomad_client/models/check_restart.rb +++ b/clients/ruby/v1/lib/nomad_client/models/check_restart.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/constraint.rb b/clients/ruby/v1/lib/nomad_client/models/constraint.rb index d5f3d02d..74d9efb3 100644 --- a/clients/ruby/v1/lib/nomad_client/models/constraint.rb +++ b/clients/ruby/v1/lib/nomad_client/models/constraint.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/consul.rb b/clients/ruby/v1/lib/nomad_client/models/consul.rb index 840407a7..9671a747 100644 --- a/clients/ruby/v1/lib/nomad_client/models/consul.rb +++ b/clients/ruby/v1/lib/nomad_client/models/consul.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/consul_connect.rb b/clients/ruby/v1/lib/nomad_client/models/consul_connect.rb index 71312d5c..466a0244 100644 --- a/clients/ruby/v1/lib/nomad_client/models/consul_connect.rb +++ b/clients/ruby/v1/lib/nomad_client/models/consul_connect.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -51,6 +51,8 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'sidecar_service', + :'sidecar_task' ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/consul_expose_config.rb b/clients/ruby/v1/lib/nomad_client/models/consul_expose_config.rb index 2a2ed0ec..8bee5a92 100644 --- a/clients/ruby/v1/lib/nomad_client/models/consul_expose_config.rb +++ b/clients/ruby/v1/lib/nomad_client/models/consul_expose_config.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/consul_expose_path.rb b/clients/ruby/v1/lib/nomad_client/models/consul_expose_path.rb index f55f9ad0..5443306d 100644 --- a/clients/ruby/v1/lib/nomad_client/models/consul_expose_path.rb +++ b/clients/ruby/v1/lib/nomad_client/models/consul_expose_path.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/consul_gateway.rb b/clients/ruby/v1/lib/nomad_client/models/consul_gateway.rb index e62ea052..028f5f45 100644 --- a/clients/ruby/v1/lib/nomad_client/models/consul_gateway.rb +++ b/clients/ruby/v1/lib/nomad_client/models/consul_gateway.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -42,7 +42,7 @@ def self.acceptable_attributes def self.openapi_types { :'ingress' => :'ConsulIngressConfigEntry', - :'mesh' => :'AnyType', + :'mesh' => :'Object', :'proxy' => :'ConsulGatewayProxy', :'terminating' => :'ConsulTerminatingConfigEntry' } @@ -51,7 +51,10 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'ingress', :'mesh', + :'proxy', + :'terminating' ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/consul_gateway_bind_address.rb b/clients/ruby/v1/lib/nomad_client/models/consul_gateway_bind_address.rb index 1875669f..2b63dfbc 100644 --- a/clients/ruby/v1/lib/nomad_client/models/consul_gateway_bind_address.rb +++ b/clients/ruby/v1/lib/nomad_client/models/consul_gateway_bind_address.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/consul_gateway_proxy.rb b/clients/ruby/v1/lib/nomad_client/models/consul_gateway_proxy.rb index 4c548da0..96d9b5e5 100644 --- a/clients/ruby/v1/lib/nomad_client/models/consul_gateway_proxy.rb +++ b/clients/ruby/v1/lib/nomad_client/models/consul_gateway_proxy.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -47,7 +47,7 @@ def self.acceptable_attributes # Attribute type mapping. def self.openapi_types { - :'config' => :'Hash', + :'config' => :'Hash', :'connect_timeout' => :'Integer', :'envoy_dns_discovery_type' => :'String', :'envoy_gateway_bind_addresses' => :'Hash', diff --git a/clients/ruby/v1/lib/nomad_client/models/consul_gateway_tls_config.rb b/clients/ruby/v1/lib/nomad_client/models/consul_gateway_tls_config.rb index 1a826d33..200462be 100644 --- a/clients/ruby/v1/lib/nomad_client/models/consul_gateway_tls_config.rb +++ b/clients/ruby/v1/lib/nomad_client/models/consul_gateway_tls_config.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/consul_ingress_config_entry.rb b/clients/ruby/v1/lib/nomad_client/models/consul_ingress_config_entry.rb index 7c8929ac..1c912aad 100644 --- a/clients/ruby/v1/lib/nomad_client/models/consul_ingress_config_entry.rb +++ b/clients/ruby/v1/lib/nomad_client/models/consul_ingress_config_entry.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -43,6 +43,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'tls' ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/consul_ingress_listener.rb b/clients/ruby/v1/lib/nomad_client/models/consul_ingress_listener.rb index b4aedfc4..5a46a249 100644 --- a/clients/ruby/v1/lib/nomad_client/models/consul_ingress_listener.rb +++ b/clients/ruby/v1/lib/nomad_client/models/consul_ingress_listener.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/consul_ingress_service.rb b/clients/ruby/v1/lib/nomad_client/models/consul_ingress_service.rb index 500cf286..28cb5ddf 100644 --- a/clients/ruby/v1/lib/nomad_client/models/consul_ingress_service.rb +++ b/clients/ruby/v1/lib/nomad_client/models/consul_ingress_service.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/consul_linked_service.rb b/clients/ruby/v1/lib/nomad_client/models/consul_linked_service.rb index d11a0c9f..9510fe3b 100644 --- a/clients/ruby/v1/lib/nomad_client/models/consul_linked_service.rb +++ b/clients/ruby/v1/lib/nomad_client/models/consul_linked_service.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/consul_mesh_gateway.rb b/clients/ruby/v1/lib/nomad_client/models/consul_mesh_gateway.rb index 55e4c036..67d78e81 100644 --- a/clients/ruby/v1/lib/nomad_client/models/consul_mesh_gateway.rb +++ b/clients/ruby/v1/lib/nomad_client/models/consul_mesh_gateway.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/consul_proxy.rb b/clients/ruby/v1/lib/nomad_client/models/consul_proxy.rb index 16e0f881..ce8c711a 100644 --- a/clients/ruby/v1/lib/nomad_client/models/consul_proxy.rb +++ b/clients/ruby/v1/lib/nomad_client/models/consul_proxy.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -44,7 +44,7 @@ def self.acceptable_attributes # Attribute type mapping. def self.openapi_types { - :'config' => :'Hash', + :'config' => :'Hash', :'expose_config' => :'ConsulExposeConfig', :'local_service_address' => :'String', :'local_service_port' => :'Integer', @@ -55,6 +55,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'expose_config', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/consul_sidecar_service.rb b/clients/ruby/v1/lib/nomad_client/models/consul_sidecar_service.rb index 73dffdcb..38e9d8bc 100644 --- a/clients/ruby/v1/lib/nomad_client/models/consul_sidecar_service.rb +++ b/clients/ruby/v1/lib/nomad_client/models/consul_sidecar_service.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -51,6 +51,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'proxy', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/consul_terminating_config_entry.rb b/clients/ruby/v1/lib/nomad_client/models/consul_terminating_config_entry.rb index 07ecb92a..0f5a7775 100644 --- a/clients/ruby/v1/lib/nomad_client/models/consul_terminating_config_entry.rb +++ b/clients/ruby/v1/lib/nomad_client/models/consul_terminating_config_entry.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/consul_upstream.rb b/clients/ruby/v1/lib/nomad_client/models/consul_upstream.rb index a3069c4e..19b2b8bb 100644 --- a/clients/ruby/v1/lib/nomad_client/models/consul_upstream.rb +++ b/clients/ruby/v1/lib/nomad_client/models/consul_upstream.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -59,6 +59,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'mesh_gateway' ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/csi_controller_info.rb b/clients/ruby/v1/lib/nomad_client/models/csi_controller_info.rb index 04a2b30f..0005be14 100644 --- a/clients/ruby/v1/lib/nomad_client/models/csi_controller_info.rb +++ b/clients/ruby/v1/lib/nomad_client/models/csi_controller_info.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/csi_info.rb b/clients/ruby/v1/lib/nomad_client/models/csi_info.rb index 17913e4c..85f7284a 100644 --- a/clients/ruby/v1/lib/nomad_client/models/csi_info.rb +++ b/clients/ruby/v1/lib/nomad_client/models/csi_info.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -71,6 +71,9 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'controller_info', + :'node_info', + :'update_time' ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/csi_mount_options.rb b/clients/ruby/v1/lib/nomad_client/models/csi_mount_options.rb index d66d1dd0..19d853c4 100644 --- a/clients/ruby/v1/lib/nomad_client/models/csi_mount_options.rb +++ b/clients/ruby/v1/lib/nomad_client/models/csi_mount_options.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/csi_node_info.rb b/clients/ruby/v1/lib/nomad_client/models/csi_node_info.rb index f1b8b049..824b1917 100644 --- a/clients/ruby/v1/lib/nomad_client/models/csi_node_info.rb +++ b/clients/ruby/v1/lib/nomad_client/models/csi_node_info.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -63,6 +63,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'accessible_topology', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/csi_plugin.rb b/clients/ruby/v1/lib/nomad_client/models/csi_plugin.rb index f4bffc94..c7efa975 100644 --- a/clients/ruby/v1/lib/nomad_client/models/csi_plugin.rb +++ b/clients/ruby/v1/lib/nomad_client/models/csi_plugin.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/csi_plugin_list_stub.rb b/clients/ruby/v1/lib/nomad_client/models/csi_plugin_list_stub.rb index 6fba0a98..96b71719 100644 --- a/clients/ruby/v1/lib/nomad_client/models/csi_plugin_list_stub.rb +++ b/clients/ruby/v1/lib/nomad_client/models/csi_plugin_list_stub.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/csi_snapshot.rb b/clients/ruby/v1/lib/nomad_client/models/csi_snapshot.rb index 84534525..1f240b74 100644 --- a/clients/ruby/v1/lib/nomad_client/models/csi_snapshot.rb +++ b/clients/ruby/v1/lib/nomad_client/models/csi_snapshot.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/csi_snapshot_create_request.rb b/clients/ruby/v1/lib/nomad_client/models/csi_snapshot_create_request.rb index aa0dfba7..3e654d91 100644 --- a/clients/ruby/v1/lib/nomad_client/models/csi_snapshot_create_request.rb +++ b/clients/ruby/v1/lib/nomad_client/models/csi_snapshot_create_request.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/csi_snapshot_create_response.rb b/clients/ruby/v1/lib/nomad_client/models/csi_snapshot_create_response.rb index 2466a859..5e64ee7b 100644 --- a/clients/ruby/v1/lib/nomad_client/models/csi_snapshot_create_response.rb +++ b/clients/ruby/v1/lib/nomad_client/models/csi_snapshot_create_response.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/csi_snapshot_list_response.rb b/clients/ruby/v1/lib/nomad_client/models/csi_snapshot_list_response.rb index e762d1a6..0ef9a084 100644 --- a/clients/ruby/v1/lib/nomad_client/models/csi_snapshot_list_response.rb +++ b/clients/ruby/v1/lib/nomad_client/models/csi_snapshot_list_response.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/csi_topology.rb b/clients/ruby/v1/lib/nomad_client/models/csi_topology.rb index 5d3ea66b..4ba4b6c8 100644 --- a/clients/ruby/v1/lib/nomad_client/models/csi_topology.rb +++ b/clients/ruby/v1/lib/nomad_client/models/csi_topology.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/csi_topology_request.rb b/clients/ruby/v1/lib/nomad_client/models/csi_topology_request.rb index 64eb467a..2c54a5fe 100644 --- a/clients/ruby/v1/lib/nomad_client/models/csi_topology_request.rb +++ b/clients/ruby/v1/lib/nomad_client/models/csi_topology_request.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/csi_volume.rb b/clients/ruby/v1/lib/nomad_client/models/csi_volume.rb index bd95455e..60bd9cc5 100644 --- a/clients/ruby/v1/lib/nomad_client/models/csi_volume.rb +++ b/clients/ruby/v1/lib/nomad_client/models/csi_volume.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -167,6 +167,9 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'mount_options', + :'requested_topologies', + :'resource_exhausted', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/csi_volume_capability.rb b/clients/ruby/v1/lib/nomad_client/models/csi_volume_capability.rb index 9be63f99..accc72ec 100644 --- a/clients/ruby/v1/lib/nomad_client/models/csi_volume_capability.rb +++ b/clients/ruby/v1/lib/nomad_client/models/csi_volume_capability.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/csi_volume_create_request.rb b/clients/ruby/v1/lib/nomad_client/models/csi_volume_create_request.rb index b58b17ee..f7a351bf 100644 --- a/clients/ruby/v1/lib/nomad_client/models/csi_volume_create_request.rb +++ b/clients/ruby/v1/lib/nomad_client/models/csi_volume_create_request.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/csi_volume_external_stub.rb b/clients/ruby/v1/lib/nomad_client/models/csi_volume_external_stub.rb index 89cdbfa8..b1ac74dd 100644 --- a/clients/ruby/v1/lib/nomad_client/models/csi_volume_external_stub.rb +++ b/clients/ruby/v1/lib/nomad_client/models/csi_volume_external_stub.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/csi_volume_list_external_response.rb b/clients/ruby/v1/lib/nomad_client/models/csi_volume_list_external_response.rb index 41134593..955cbd4d 100644 --- a/clients/ruby/v1/lib/nomad_client/models/csi_volume_list_external_response.rb +++ b/clients/ruby/v1/lib/nomad_client/models/csi_volume_list_external_response.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/csi_volume_list_stub.rb b/clients/ruby/v1/lib/nomad_client/models/csi_volume_list_stub.rb index 6c0eae39..3f832fc9 100644 --- a/clients/ruby/v1/lib/nomad_client/models/csi_volume_list_stub.rb +++ b/clients/ruby/v1/lib/nomad_client/models/csi_volume_list_stub.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -107,6 +107,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'resource_exhausted', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/csi_volume_register_request.rb b/clients/ruby/v1/lib/nomad_client/models/csi_volume_register_request.rb index 4e9e2951..8b2b11b4 100644 --- a/clients/ruby/v1/lib/nomad_client/models/csi_volume_register_request.rb +++ b/clients/ruby/v1/lib/nomad_client/models/csi_volume_register_request.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/deployment.rb b/clients/ruby/v1/lib/nomad_client/models/deployment.rb index 403a99b7..66b74855 100644 --- a/clients/ruby/v1/lib/nomad_client/models/deployment.rb +++ b/clients/ruby/v1/lib/nomad_client/models/deployment.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/deployment_alloc_health_request.rb b/clients/ruby/v1/lib/nomad_client/models/deployment_alloc_health_request.rb index c4d7d32a..041a6a04 100644 --- a/clients/ruby/v1/lib/nomad_client/models/deployment_alloc_health_request.rb +++ b/clients/ruby/v1/lib/nomad_client/models/deployment_alloc_health_request.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/deployment_pause_request.rb b/clients/ruby/v1/lib/nomad_client/models/deployment_pause_request.rb index a33d3dd2..d8c79312 100644 --- a/clients/ruby/v1/lib/nomad_client/models/deployment_pause_request.rb +++ b/clients/ruby/v1/lib/nomad_client/models/deployment_pause_request.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/deployment_promote_request.rb b/clients/ruby/v1/lib/nomad_client/models/deployment_promote_request.rb index dcc29c36..11690149 100644 --- a/clients/ruby/v1/lib/nomad_client/models/deployment_promote_request.rb +++ b/clients/ruby/v1/lib/nomad_client/models/deployment_promote_request.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/deployment_state.rb b/clients/ruby/v1/lib/nomad_client/models/deployment_state.rb index b2143bc7..844c4cc8 100644 --- a/clients/ruby/v1/lib/nomad_client/models/deployment_state.rb +++ b/clients/ruby/v1/lib/nomad_client/models/deployment_state.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -75,6 +75,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'require_progress_by', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/deployment_unblock_request.rb b/clients/ruby/v1/lib/nomad_client/models/deployment_unblock_request.rb index 30a1da51..f5ceb482 100644 --- a/clients/ruby/v1/lib/nomad_client/models/deployment_unblock_request.rb +++ b/clients/ruby/v1/lib/nomad_client/models/deployment_unblock_request.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/deployment_update_response.rb b/clients/ruby/v1/lib/nomad_client/models/deployment_update_response.rb index 9c5e57b9..4618c08e 100644 --- a/clients/ruby/v1/lib/nomad_client/models/deployment_update_response.rb +++ b/clients/ruby/v1/lib/nomad_client/models/deployment_update_response.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/desired_transition.rb b/clients/ruby/v1/lib/nomad_client/models/desired_transition.rb index 832bb8aa..a4599204 100644 --- a/clients/ruby/v1/lib/nomad_client/models/desired_transition.rb +++ b/clients/ruby/v1/lib/nomad_client/models/desired_transition.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/desired_updates.rb b/clients/ruby/v1/lib/nomad_client/models/desired_updates.rb index 982ce432..6011bccd 100644 --- a/clients/ruby/v1/lib/nomad_client/models/desired_updates.rb +++ b/clients/ruby/v1/lib/nomad_client/models/desired_updates.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/dispatch_payload_config.rb b/clients/ruby/v1/lib/nomad_client/models/dispatch_payload_config.rb index 2049f6e0..d5c67b74 100644 --- a/clients/ruby/v1/lib/nomad_client/models/dispatch_payload_config.rb +++ b/clients/ruby/v1/lib/nomad_client/models/dispatch_payload_config.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/dns_config.rb b/clients/ruby/v1/lib/nomad_client/models/dns_config.rb index 2b273990..f7cc621c 100644 --- a/clients/ruby/v1/lib/nomad_client/models/dns_config.rb +++ b/clients/ruby/v1/lib/nomad_client/models/dns_config.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/drain_metadata.rb b/clients/ruby/v1/lib/nomad_client/models/drain_metadata.rb index f5ebc62c..ec8243c5 100644 --- a/clients/ruby/v1/lib/nomad_client/models/drain_metadata.rb +++ b/clients/ruby/v1/lib/nomad_client/models/drain_metadata.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -55,6 +55,8 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'started_at', + :'updated_at' ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/drain_spec.rb b/clients/ruby/v1/lib/nomad_client/models/drain_spec.rb index 8c993a4e..302f65cd 100644 --- a/clients/ruby/v1/lib/nomad_client/models/drain_spec.rb +++ b/clients/ruby/v1/lib/nomad_client/models/drain_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/drain_strategy.rb b/clients/ruby/v1/lib/nomad_client/models/drain_strategy.rb index 98d9786e..b8fb35d4 100644 --- a/clients/ruby/v1/lib/nomad_client/models/drain_strategy.rb +++ b/clients/ruby/v1/lib/nomad_client/models/drain_strategy.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -51,6 +51,8 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'force_deadline', + :'started_at' ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/driver_info.rb b/clients/ruby/v1/lib/nomad_client/models/driver_info.rb index 3d583531..a0c843dc 100644 --- a/clients/ruby/v1/lib/nomad_client/models/driver_info.rb +++ b/clients/ruby/v1/lib/nomad_client/models/driver_info.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -55,6 +55,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'update_time' ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/ephemeral_disk.rb b/clients/ruby/v1/lib/nomad_client/models/ephemeral_disk.rb index 9c21901d..ec029b83 100644 --- a/clients/ruby/v1/lib/nomad_client/models/ephemeral_disk.rb +++ b/clients/ruby/v1/lib/nomad_client/models/ephemeral_disk.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/eval_options.rb b/clients/ruby/v1/lib/nomad_client/models/eval_options.rb index dce323f4..83228510 100644 --- a/clients/ruby/v1/lib/nomad_client/models/eval_options.rb +++ b/clients/ruby/v1/lib/nomad_client/models/eval_options.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/evaluation.rb b/clients/ruby/v1/lib/nomad_client/models/evaluation.rb index 9c7e9c67..ac3aa15e 100644 --- a/clients/ruby/v1/lib/nomad_client/models/evaluation.rb +++ b/clients/ruby/v1/lib/nomad_client/models/evaluation.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -151,6 +151,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'wait_until' ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/evaluation_stub.rb b/clients/ruby/v1/lib/nomad_client/models/evaluation_stub.rb index b7e54007..8c659d2b 100644 --- a/clients/ruby/v1/lib/nomad_client/models/evaluation_stub.rb +++ b/clients/ruby/v1/lib/nomad_client/models/evaluation_stub.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -107,6 +107,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'wait_until' ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/field_diff.rb b/clients/ruby/v1/lib/nomad_client/models/field_diff.rb index 43b53b1c..95b6a6fd 100644 --- a/clients/ruby/v1/lib/nomad_client/models/field_diff.rb +++ b/clients/ruby/v1/lib/nomad_client/models/field_diff.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/fuzzy_match.rb b/clients/ruby/v1/lib/nomad_client/models/fuzzy_match.rb index 1a4b30e8..7588a395 100644 --- a/clients/ruby/v1/lib/nomad_client/models/fuzzy_match.rb +++ b/clients/ruby/v1/lib/nomad_client/models/fuzzy_match.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/fuzzy_search_request.rb b/clients/ruby/v1/lib/nomad_client/models/fuzzy_search_request.rb index 97c8e0da..1c664ed0 100644 --- a/clients/ruby/v1/lib/nomad_client/models/fuzzy_search_request.rb +++ b/clients/ruby/v1/lib/nomad_client/models/fuzzy_search_request.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/fuzzy_search_response.rb b/clients/ruby/v1/lib/nomad_client/models/fuzzy_search_response.rb index 553b5b91..2afcc432 100644 --- a/clients/ruby/v1/lib/nomad_client/models/fuzzy_search_response.rb +++ b/clients/ruby/v1/lib/nomad_client/models/fuzzy_search_response.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/gauge_value.rb b/clients/ruby/v1/lib/nomad_client/models/gauge_value.rb index b7e0042e..19b5c9fa 100644 --- a/clients/ruby/v1/lib/nomad_client/models/gauge_value.rb +++ b/clients/ruby/v1/lib/nomad_client/models/gauge_value.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/host_network_info.rb b/clients/ruby/v1/lib/nomad_client/models/host_network_info.rb index 4529691a..b04a9596 100644 --- a/clients/ruby/v1/lib/nomad_client/models/host_network_info.rb +++ b/clients/ruby/v1/lib/nomad_client/models/host_network_info.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/host_volume_info.rb b/clients/ruby/v1/lib/nomad_client/models/host_volume_info.rb index b307b0cf..50216a10 100644 --- a/clients/ruby/v1/lib/nomad_client/models/host_volume_info.rb +++ b/clients/ruby/v1/lib/nomad_client/models/host_volume_info.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/job.rb b/clients/ruby/v1/lib/nomad_client/models/job.rb index 69796d18..05dc34ec 100644 --- a/clients/ruby/v1/lib/nomad_client/models/job.rb +++ b/clients/ruby/v1/lib/nomad_client/models/job.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -183,6 +183,8 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'multiregion', + :'parameterized_job', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/job_children_summary.rb b/clients/ruby/v1/lib/nomad_client/models/job_children_summary.rb index 94c3a031..e06ddb2a 100644 --- a/clients/ruby/v1/lib/nomad_client/models/job_children_summary.rb +++ b/clients/ruby/v1/lib/nomad_client/models/job_children_summary.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/job_deregister_response.rb b/clients/ruby/v1/lib/nomad_client/models/job_deregister_response.rb index 15d10209..fa5e9033 100644 --- a/clients/ruby/v1/lib/nomad_client/models/job_deregister_response.rb +++ b/clients/ruby/v1/lib/nomad_client/models/job_deregister_response.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/job_diff.rb b/clients/ruby/v1/lib/nomad_client/models/job_diff.rb index 5f5c79f1..53155da7 100644 --- a/clients/ruby/v1/lib/nomad_client/models/job_diff.rb +++ b/clients/ruby/v1/lib/nomad_client/models/job_diff.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/job_dispatch_request.rb b/clients/ruby/v1/lib/nomad_client/models/job_dispatch_request.rb index 24e08344..e1661d55 100644 --- a/clients/ruby/v1/lib/nomad_client/models/job_dispatch_request.rb +++ b/clients/ruby/v1/lib/nomad_client/models/job_dispatch_request.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/job_dispatch_response.rb b/clients/ruby/v1/lib/nomad_client/models/job_dispatch_response.rb index 9748951d..6978c447 100644 --- a/clients/ruby/v1/lib/nomad_client/models/job_dispatch_response.rb +++ b/clients/ruby/v1/lib/nomad_client/models/job_dispatch_response.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/job_evaluate_request.rb b/clients/ruby/v1/lib/nomad_client/models/job_evaluate_request.rb index 77cb5d9f..da274f55 100644 --- a/clients/ruby/v1/lib/nomad_client/models/job_evaluate_request.rb +++ b/clients/ruby/v1/lib/nomad_client/models/job_evaluate_request.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -55,6 +55,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'eval_options', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/job_list_stub.rb b/clients/ruby/v1/lib/nomad_client/models/job_list_stub.rb index 3564018e..3649eaf6 100644 --- a/clients/ruby/v1/lib/nomad_client/models/job_list_stub.rb +++ b/clients/ruby/v1/lib/nomad_client/models/job_list_stub.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -103,6 +103,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'job_summary', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/job_plan_request.rb b/clients/ruby/v1/lib/nomad_client/models/job_plan_request.rb index b02300ed..605d2528 100644 --- a/clients/ruby/v1/lib/nomad_client/models/job_plan_request.rb +++ b/clients/ruby/v1/lib/nomad_client/models/job_plan_request.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -59,6 +59,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'job', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/job_plan_response.rb b/clients/ruby/v1/lib/nomad_client/models/job_plan_response.rb index 9b26d89d..b849ad12 100644 --- a/clients/ruby/v1/lib/nomad_client/models/job_plan_response.rb +++ b/clients/ruby/v1/lib/nomad_client/models/job_plan_response.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -63,6 +63,9 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'annotations', + :'diff', + :'next_periodic_launch', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/job_register_request.rb b/clients/ruby/v1/lib/nomad_client/models/job_register_request.rb index 1af7099c..559d5d3b 100644 --- a/clients/ruby/v1/lib/nomad_client/models/job_register_request.rb +++ b/clients/ruby/v1/lib/nomad_client/models/job_register_request.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -71,6 +71,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'job', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/job_register_response.rb b/clients/ruby/v1/lib/nomad_client/models/job_register_response.rb index 78959b9b..7d129295 100644 --- a/clients/ruby/v1/lib/nomad_client/models/job_register_response.rb +++ b/clients/ruby/v1/lib/nomad_client/models/job_register_response.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/job_revert_request.rb b/clients/ruby/v1/lib/nomad_client/models/job_revert_request.rb index eb19da43..e03545a6 100644 --- a/clients/ruby/v1/lib/nomad_client/models/job_revert_request.rb +++ b/clients/ruby/v1/lib/nomad_client/models/job_revert_request.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/job_scale_status_response.rb b/clients/ruby/v1/lib/nomad_client/models/job_scale_status_response.rb index 894a71cc..ed2a2b79 100644 --- a/clients/ruby/v1/lib/nomad_client/models/job_scale_status_response.rb +++ b/clients/ruby/v1/lib/nomad_client/models/job_scale_status_response.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/job_stability_request.rb b/clients/ruby/v1/lib/nomad_client/models/job_stability_request.rb index 80e57d0c..b6f58e5e 100644 --- a/clients/ruby/v1/lib/nomad_client/models/job_stability_request.rb +++ b/clients/ruby/v1/lib/nomad_client/models/job_stability_request.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/job_stability_response.rb b/clients/ruby/v1/lib/nomad_client/models/job_stability_response.rb index 2da90f7d..1e0915a0 100644 --- a/clients/ruby/v1/lib/nomad_client/models/job_stability_response.rb +++ b/clients/ruby/v1/lib/nomad_client/models/job_stability_response.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/job_summary.rb b/clients/ruby/v1/lib/nomad_client/models/job_summary.rb index 87d82b81..f0d28f3e 100644 --- a/clients/ruby/v1/lib/nomad_client/models/job_summary.rb +++ b/clients/ruby/v1/lib/nomad_client/models/job_summary.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -59,6 +59,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'children', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/job_validate_request.rb b/clients/ruby/v1/lib/nomad_client/models/job_validate_request.rb index c83f5899..78bfe463 100644 --- a/clients/ruby/v1/lib/nomad_client/models/job_validate_request.rb +++ b/clients/ruby/v1/lib/nomad_client/models/job_validate_request.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -51,6 +51,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'job', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/job_validate_response.rb b/clients/ruby/v1/lib/nomad_client/models/job_validate_response.rb index 4da8636a..28bb48f1 100644 --- a/clients/ruby/v1/lib/nomad_client/models/job_validate_response.rb +++ b/clients/ruby/v1/lib/nomad_client/models/job_validate_response.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/job_versions_response.rb b/clients/ruby/v1/lib/nomad_client/models/job_versions_response.rb index 4d594b3b..1d054bd9 100644 --- a/clients/ruby/v1/lib/nomad_client/models/job_versions_response.rb +++ b/clients/ruby/v1/lib/nomad_client/models/job_versions_response.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/jobs_parse_request.rb b/clients/ruby/v1/lib/nomad_client/models/jobs_parse_request.rb index c94963bb..332133f2 100644 --- a/clients/ruby/v1/lib/nomad_client/models/jobs_parse_request.rb +++ b/clients/ruby/v1/lib/nomad_client/models/jobs_parse_request.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/log_config.rb b/clients/ruby/v1/lib/nomad_client/models/log_config.rb index f0b56dad..6e6fd345 100644 --- a/clients/ruby/v1/lib/nomad_client/models/log_config.rb +++ b/clients/ruby/v1/lib/nomad_client/models/log_config.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/metrics_summary.rb b/clients/ruby/v1/lib/nomad_client/models/metrics_summary.rb index 3b523d48..b11cc1d1 100644 --- a/clients/ruby/v1/lib/nomad_client/models/metrics_summary.rb +++ b/clients/ruby/v1/lib/nomad_client/models/metrics_summary.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/migrate_strategy.rb b/clients/ruby/v1/lib/nomad_client/models/migrate_strategy.rb index 9957813f..23242084 100644 --- a/clients/ruby/v1/lib/nomad_client/models/migrate_strategy.rb +++ b/clients/ruby/v1/lib/nomad_client/models/migrate_strategy.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/multiregion.rb b/clients/ruby/v1/lib/nomad_client/models/multiregion.rb index 8dd07298..13e010ce 100644 --- a/clients/ruby/v1/lib/nomad_client/models/multiregion.rb +++ b/clients/ruby/v1/lib/nomad_client/models/multiregion.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/multiregion_region.rb b/clients/ruby/v1/lib/nomad_client/models/multiregion_region.rb index 084b8e96..d315260c 100644 --- a/clients/ruby/v1/lib/nomad_client/models/multiregion_region.rb +++ b/clients/ruby/v1/lib/nomad_client/models/multiregion_region.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/multiregion_strategy.rb b/clients/ruby/v1/lib/nomad_client/models/multiregion_strategy.rb index 55a1d6e9..c8e769c8 100644 --- a/clients/ruby/v1/lib/nomad_client/models/multiregion_strategy.rb +++ b/clients/ruby/v1/lib/nomad_client/models/multiregion_strategy.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/namespace.rb b/clients/ruby/v1/lib/nomad_client/models/namespace.rb index b748cddd..7be9fd90 100644 --- a/clients/ruby/v1/lib/nomad_client/models/namespace.rb +++ b/clients/ruby/v1/lib/nomad_client/models/namespace.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -63,6 +63,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'capabilities', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/namespace_capabilities.rb b/clients/ruby/v1/lib/nomad_client/models/namespace_capabilities.rb index b785aff4..3cae8a6b 100644 --- a/clients/ruby/v1/lib/nomad_client/models/namespace_capabilities.rb +++ b/clients/ruby/v1/lib/nomad_client/models/namespace_capabilities.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/network_resource.rb b/clients/ruby/v1/lib/nomad_client/models/network_resource.rb index 7443efc5..b9d0b31a 100644 --- a/clients/ruby/v1/lib/nomad_client/models/network_resource.rb +++ b/clients/ruby/v1/lib/nomad_client/models/network_resource.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -71,6 +71,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'dns', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/node.rb b/clients/ruby/v1/lib/nomad_client/models/node.rb index 45851eaa..2d2fd787 100644 --- a/clients/ruby/v1/lib/nomad_client/models/node.rb +++ b/clients/ruby/v1/lib/nomad_client/models/node.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -151,6 +151,12 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'drain_strategy', + :'last_drain', + :'node_resources', + :'reserved', + :'reserved_resources', + :'resources', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/node_cpu_resources.rb b/clients/ruby/v1/lib/nomad_client/models/node_cpu_resources.rb index ba2901bd..7c207b0b 100644 --- a/clients/ruby/v1/lib/nomad_client/models/node_cpu_resources.rb +++ b/clients/ruby/v1/lib/nomad_client/models/node_cpu_resources.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/node_device.rb b/clients/ruby/v1/lib/nomad_client/models/node_device.rb index b583325e..ec403ff6 100644 --- a/clients/ruby/v1/lib/nomad_client/models/node_device.rb +++ b/clients/ruby/v1/lib/nomad_client/models/node_device.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -51,6 +51,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'locality' ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/node_device_locality.rb b/clients/ruby/v1/lib/nomad_client/models/node_device_locality.rb index 95ebb458..0d2bebec 100644 --- a/clients/ruby/v1/lib/nomad_client/models/node_device_locality.rb +++ b/clients/ruby/v1/lib/nomad_client/models/node_device_locality.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/node_device_resource.rb b/clients/ruby/v1/lib/nomad_client/models/node_device_resource.rb index 153a0825..de19df1c 100644 --- a/clients/ruby/v1/lib/nomad_client/models/node_device_resource.rb +++ b/clients/ruby/v1/lib/nomad_client/models/node_device_resource.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/node_disk_resources.rb b/clients/ruby/v1/lib/nomad_client/models/node_disk_resources.rb index cc9a02fb..78014355 100644 --- a/clients/ruby/v1/lib/nomad_client/models/node_disk_resources.rb +++ b/clients/ruby/v1/lib/nomad_client/models/node_disk_resources.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/node_drain_update_response.rb b/clients/ruby/v1/lib/nomad_client/models/node_drain_update_response.rb index 16f8e316..49ae6740 100644 --- a/clients/ruby/v1/lib/nomad_client/models/node_drain_update_response.rb +++ b/clients/ruby/v1/lib/nomad_client/models/node_drain_update_response.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/node_eligibility_update_response.rb b/clients/ruby/v1/lib/nomad_client/models/node_eligibility_update_response.rb index 999475d2..85cc2d0e 100644 --- a/clients/ruby/v1/lib/nomad_client/models/node_eligibility_update_response.rb +++ b/clients/ruby/v1/lib/nomad_client/models/node_eligibility_update_response.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/node_event.rb b/clients/ruby/v1/lib/nomad_client/models/node_event.rb index 67753952..3932445f 100644 --- a/clients/ruby/v1/lib/nomad_client/models/node_event.rb +++ b/clients/ruby/v1/lib/nomad_client/models/node_event.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -55,6 +55,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'timestamp' ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/node_list_stub.rb b/clients/ruby/v1/lib/nomad_client/models/node_list_stub.rb index fde39ca0..ea3d6796 100644 --- a/clients/ruby/v1/lib/nomad_client/models/node_list_stub.rb +++ b/clients/ruby/v1/lib/nomad_client/models/node_list_stub.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -103,6 +103,9 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'last_drain', + :'node_resources', + :'reserved_resources', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/node_memory_resources.rb b/clients/ruby/v1/lib/nomad_client/models/node_memory_resources.rb index d372f4c9..9b7abdd2 100644 --- a/clients/ruby/v1/lib/nomad_client/models/node_memory_resources.rb +++ b/clients/ruby/v1/lib/nomad_client/models/node_memory_resources.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/node_purge_response.rb b/clients/ruby/v1/lib/nomad_client/models/node_purge_response.rb index 11ded47b..bd382c5e 100644 --- a/clients/ruby/v1/lib/nomad_client/models/node_purge_response.rb +++ b/clients/ruby/v1/lib/nomad_client/models/node_purge_response.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/node_reserved_cpu_resources.rb b/clients/ruby/v1/lib/nomad_client/models/node_reserved_cpu_resources.rb index 07ad0c3b..98050879 100644 --- a/clients/ruby/v1/lib/nomad_client/models/node_reserved_cpu_resources.rb +++ b/clients/ruby/v1/lib/nomad_client/models/node_reserved_cpu_resources.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/node_reserved_disk_resources.rb b/clients/ruby/v1/lib/nomad_client/models/node_reserved_disk_resources.rb index d9a650d2..dde84c0e 100644 --- a/clients/ruby/v1/lib/nomad_client/models/node_reserved_disk_resources.rb +++ b/clients/ruby/v1/lib/nomad_client/models/node_reserved_disk_resources.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/node_reserved_memory_resources.rb b/clients/ruby/v1/lib/nomad_client/models/node_reserved_memory_resources.rb index aed91583..270d301c 100644 --- a/clients/ruby/v1/lib/nomad_client/models/node_reserved_memory_resources.rb +++ b/clients/ruby/v1/lib/nomad_client/models/node_reserved_memory_resources.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/node_reserved_network_resources.rb b/clients/ruby/v1/lib/nomad_client/models/node_reserved_network_resources.rb index d72e2366..fb10decc 100644 --- a/clients/ruby/v1/lib/nomad_client/models/node_reserved_network_resources.rb +++ b/clients/ruby/v1/lib/nomad_client/models/node_reserved_network_resources.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/node_reserved_resources.rb b/clients/ruby/v1/lib/nomad_client/models/node_reserved_resources.rb index 621f6e20..8941133a 100644 --- a/clients/ruby/v1/lib/nomad_client/models/node_reserved_resources.rb +++ b/clients/ruby/v1/lib/nomad_client/models/node_reserved_resources.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -51,6 +51,10 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'cpu', + :'disk', + :'memory', + :'networks' ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/node_resources.rb b/clients/ruby/v1/lib/nomad_client/models/node_resources.rb index c3e79360..8eb5e586 100644 --- a/clients/ruby/v1/lib/nomad_client/models/node_resources.rb +++ b/clients/ruby/v1/lib/nomad_client/models/node_resources.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -63,6 +63,9 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'cpu', + :'disk', + :'memory', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/node_score_meta.rb b/clients/ruby/v1/lib/nomad_client/models/node_score_meta.rb index f8cce171..36720798 100644 --- a/clients/ruby/v1/lib/nomad_client/models/node_score_meta.rb +++ b/clients/ruby/v1/lib/nomad_client/models/node_score_meta.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/node_update_drain_request.rb b/clients/ruby/v1/lib/nomad_client/models/node_update_drain_request.rb index f192824b..efd54c0e 100644 --- a/clients/ruby/v1/lib/nomad_client/models/node_update_drain_request.rb +++ b/clients/ruby/v1/lib/nomad_client/models/node_update_drain_request.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -51,6 +51,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'drain_spec', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/node_update_eligibility_request.rb b/clients/ruby/v1/lib/nomad_client/models/node_update_eligibility_request.rb index 1ea35cf4..2957d119 100644 --- a/clients/ruby/v1/lib/nomad_client/models/node_update_eligibility_request.rb +++ b/clients/ruby/v1/lib/nomad_client/models/node_update_eligibility_request.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/object_diff.rb b/clients/ruby/v1/lib/nomad_client/models/object_diff.rb index 07949d10..ec9bcb5b 100644 --- a/clients/ruby/v1/lib/nomad_client/models/object_diff.rb +++ b/clients/ruby/v1/lib/nomad_client/models/object_diff.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/one_time_token.rb b/clients/ruby/v1/lib/nomad_client/models/one_time_token.rb index 247e29ac..bd1fb51a 100644 --- a/clients/ruby/v1/lib/nomad_client/models/one_time_token.rb +++ b/clients/ruby/v1/lib/nomad_client/models/one_time_token.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -55,6 +55,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'expires_at', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/one_time_token_exchange_request.rb b/clients/ruby/v1/lib/nomad_client/models/one_time_token_exchange_request.rb index c5f3c39f..2cfcd239 100644 --- a/clients/ruby/v1/lib/nomad_client/models/one_time_token_exchange_request.rb +++ b/clients/ruby/v1/lib/nomad_client/models/one_time_token_exchange_request.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/operator_health_reply.rb b/clients/ruby/v1/lib/nomad_client/models/operator_health_reply.rb index d2c4aec6..e7e3f933 100644 --- a/clients/ruby/v1/lib/nomad_client/models/operator_health_reply.rb +++ b/clients/ruby/v1/lib/nomad_client/models/operator_health_reply.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/parameterized_job_config.rb b/clients/ruby/v1/lib/nomad_client/models/parameterized_job_config.rb index 3111c6b9..0725560e 100644 --- a/clients/ruby/v1/lib/nomad_client/models/parameterized_job_config.rb +++ b/clients/ruby/v1/lib/nomad_client/models/parameterized_job_config.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/periodic_config.rb b/clients/ruby/v1/lib/nomad_client/models/periodic_config.rb index 065c4c42..993e6c41 100644 --- a/clients/ruby/v1/lib/nomad_client/models/periodic_config.rb +++ b/clients/ruby/v1/lib/nomad_client/models/periodic_config.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/periodic_force_response.rb b/clients/ruby/v1/lib/nomad_client/models/periodic_force_response.rb index 7298ece8..523cc036 100644 --- a/clients/ruby/v1/lib/nomad_client/models/periodic_force_response.rb +++ b/clients/ruby/v1/lib/nomad_client/models/periodic_force_response.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/plan_annotations.rb b/clients/ruby/v1/lib/nomad_client/models/plan_annotations.rb index e3521569..2bd77ecf 100644 --- a/clients/ruby/v1/lib/nomad_client/models/plan_annotations.rb +++ b/clients/ruby/v1/lib/nomad_client/models/plan_annotations.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/point_value.rb b/clients/ruby/v1/lib/nomad_client/models/point_value.rb index 2693c674..6306fe6c 100644 --- a/clients/ruby/v1/lib/nomad_client/models/point_value.rb +++ b/clients/ruby/v1/lib/nomad_client/models/point_value.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/port.rb b/clients/ruby/v1/lib/nomad_client/models/port.rb index a24de316..bd4c14fe 100644 --- a/clients/ruby/v1/lib/nomad_client/models/port.rb +++ b/clients/ruby/v1/lib/nomad_client/models/port.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/port_mapping.rb b/clients/ruby/v1/lib/nomad_client/models/port_mapping.rb index 7b6b92e4..1147dfe2 100644 --- a/clients/ruby/v1/lib/nomad_client/models/port_mapping.rb +++ b/clients/ruby/v1/lib/nomad_client/models/port_mapping.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/preemption_config.rb b/clients/ruby/v1/lib/nomad_client/models/preemption_config.rb index 6d4de51c..55295307 100644 --- a/clients/ruby/v1/lib/nomad_client/models/preemption_config.rb +++ b/clients/ruby/v1/lib/nomad_client/models/preemption_config.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/quota_limit.rb b/clients/ruby/v1/lib/nomad_client/models/quota_limit.rb index 6a2d3f9f..0134e4ca 100644 --- a/clients/ruby/v1/lib/nomad_client/models/quota_limit.rb +++ b/clients/ruby/v1/lib/nomad_client/models/quota_limit.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -47,6 +47,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'region_limit' ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/quota_spec.rb b/clients/ruby/v1/lib/nomad_client/models/quota_spec.rb index 72a08145..3e35ca8e 100644 --- a/clients/ruby/v1/lib/nomad_client/models/quota_spec.rb +++ b/clients/ruby/v1/lib/nomad_client/models/quota_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/raft_configuration.rb b/clients/ruby/v1/lib/nomad_client/models/raft_configuration.rb index 5672afab..c73b3a79 100644 --- a/clients/ruby/v1/lib/nomad_client/models/raft_configuration.rb +++ b/clients/ruby/v1/lib/nomad_client/models/raft_configuration.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/raft_server.rb b/clients/ruby/v1/lib/nomad_client/models/raft_server.rb index 05b8d444..daf7e736 100644 --- a/clients/ruby/v1/lib/nomad_client/models/raft_server.rb +++ b/clients/ruby/v1/lib/nomad_client/models/raft_server.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/requested_device.rb b/clients/ruby/v1/lib/nomad_client/models/requested_device.rb index e5cb6055..4ed4933f 100644 --- a/clients/ruby/v1/lib/nomad_client/models/requested_device.rb +++ b/clients/ruby/v1/lib/nomad_client/models/requested_device.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/reschedule_event.rb b/clients/ruby/v1/lib/nomad_client/models/reschedule_event.rb index 49b6c8a1..ffd4ad27 100644 --- a/clients/ruby/v1/lib/nomad_client/models/reschedule_event.rb +++ b/clients/ruby/v1/lib/nomad_client/models/reschedule_event.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/reschedule_policy.rb b/clients/ruby/v1/lib/nomad_client/models/reschedule_policy.rb index d4647f6b..ba98cdf8 100644 --- a/clients/ruby/v1/lib/nomad_client/models/reschedule_policy.rb +++ b/clients/ruby/v1/lib/nomad_client/models/reschedule_policy.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/reschedule_tracker.rb b/clients/ruby/v1/lib/nomad_client/models/reschedule_tracker.rb index c884c55c..0265c6a5 100644 --- a/clients/ruby/v1/lib/nomad_client/models/reschedule_tracker.rb +++ b/clients/ruby/v1/lib/nomad_client/models/reschedule_tracker.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/resources.rb b/clients/ruby/v1/lib/nomad_client/models/resources.rb index 6460d54c..d60372d1 100644 --- a/clients/ruby/v1/lib/nomad_client/models/resources.rb +++ b/clients/ruby/v1/lib/nomad_client/models/resources.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/restart_policy.rb b/clients/ruby/v1/lib/nomad_client/models/restart_policy.rb index ab98279b..03382a5b 100644 --- a/clients/ruby/v1/lib/nomad_client/models/restart_policy.rb +++ b/clients/ruby/v1/lib/nomad_client/models/restart_policy.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/sampled_value.rb b/clients/ruby/v1/lib/nomad_client/models/sampled_value.rb index 404e0d63..b05e3af3 100644 --- a/clients/ruby/v1/lib/nomad_client/models/sampled_value.rb +++ b/clients/ruby/v1/lib/nomad_client/models/sampled_value.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/scaling_event.rb b/clients/ruby/v1/lib/nomad_client/models/scaling_event.rb index fdf06be1..9eaa8659 100644 --- a/clients/ruby/v1/lib/nomad_client/models/scaling_event.rb +++ b/clients/ruby/v1/lib/nomad_client/models/scaling_event.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -58,7 +58,7 @@ def self.openapi_types :'error' => :'Boolean', :'eval_id' => :'String', :'message' => :'String', - :'meta' => :'Hash', + :'meta' => :'Hash', :'previous_count' => :'Integer', :'time' => :'Integer' } diff --git a/clients/ruby/v1/lib/nomad_client/models/scaling_policy.rb b/clients/ruby/v1/lib/nomad_client/models/scaling_policy.rb index a955ea30..a0a29911 100644 --- a/clients/ruby/v1/lib/nomad_client/models/scaling_policy.rb +++ b/clients/ruby/v1/lib/nomad_client/models/scaling_policy.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -66,7 +66,7 @@ def self.openapi_types :'min' => :'Integer', :'modify_index' => :'Integer', :'namespace' => :'String', - :'policy' => :'Hash', + :'policy' => :'Hash', :'target' => :'Hash', :'type' => :'String' } diff --git a/clients/ruby/v1/lib/nomad_client/models/scaling_policy_list_stub.rb b/clients/ruby/v1/lib/nomad_client/models/scaling_policy_list_stub.rb index dd088e04..d1ad9fc1 100644 --- a/clients/ruby/v1/lib/nomad_client/models/scaling_policy_list_stub.rb +++ b/clients/ruby/v1/lib/nomad_client/models/scaling_policy_list_stub.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/scaling_request.rb b/clients/ruby/v1/lib/nomad_client/models/scaling_request.rb index c376a731..304cb5fb 100644 --- a/clients/ruby/v1/lib/nomad_client/models/scaling_request.rb +++ b/clients/ruby/v1/lib/nomad_client/models/scaling_request.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -59,7 +59,7 @@ def self.openapi_types :'count' => :'Integer', :'error' => :'Boolean', :'message' => :'String', - :'meta' => :'Hash', + :'meta' => :'Hash', :'namespace' => :'String', :'policy_override' => :'Boolean', :'region' => :'String', diff --git a/clients/ruby/v1/lib/nomad_client/models/scheduler_configuration.rb b/clients/ruby/v1/lib/nomad_client/models/scheduler_configuration.rb index a7080112..d68df0da 100644 --- a/clients/ruby/v1/lib/nomad_client/models/scheduler_configuration.rb +++ b/clients/ruby/v1/lib/nomad_client/models/scheduler_configuration.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -63,6 +63,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'preemption_config', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/scheduler_configuration_response.rb b/clients/ruby/v1/lib/nomad_client/models/scheduler_configuration_response.rb index 0900269b..efd6528c 100644 --- a/clients/ruby/v1/lib/nomad_client/models/scheduler_configuration_response.rb +++ b/clients/ruby/v1/lib/nomad_client/models/scheduler_configuration_response.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -59,6 +59,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'scheduler_config' ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/scheduler_set_configuration_response.rb b/clients/ruby/v1/lib/nomad_client/models/scheduler_set_configuration_response.rb index 9e76386f..4ea4f0e8 100644 --- a/clients/ruby/v1/lib/nomad_client/models/scheduler_set_configuration_response.rb +++ b/clients/ruby/v1/lib/nomad_client/models/scheduler_set_configuration_response.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/search_request.rb b/clients/ruby/v1/lib/nomad_client/models/search_request.rb index 19dea8a8..0b0ac436 100644 --- a/clients/ruby/v1/lib/nomad_client/models/search_request.rb +++ b/clients/ruby/v1/lib/nomad_client/models/search_request.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/search_response.rb b/clients/ruby/v1/lib/nomad_client/models/search_response.rb index 4ad09998..abedf77d 100644 --- a/clients/ruby/v1/lib/nomad_client/models/search_response.rb +++ b/clients/ruby/v1/lib/nomad_client/models/search_response.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/server_health.rb b/clients/ruby/v1/lib/nomad_client/models/server_health.rb index 117bc525..2ee68aaf 100644 --- a/clients/ruby/v1/lib/nomad_client/models/server_health.rb +++ b/clients/ruby/v1/lib/nomad_client/models/server_health.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -83,6 +83,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'stable_since', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/service.rb b/clients/ruby/v1/lib/nomad_client/models/service.rb index 6325d13f..4748569b 100644 --- a/clients/ruby/v1/lib/nomad_client/models/service.rb +++ b/clients/ruby/v1/lib/nomad_client/models/service.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -99,6 +99,8 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'check_restart', + :'connect', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/service_check.rb b/clients/ruby/v1/lib/nomad_client/models/service_check.rb index dee641ed..6087eeda 100644 --- a/clients/ruby/v1/lib/nomad_client/models/service_check.rb +++ b/clients/ruby/v1/lib/nomad_client/models/service_check.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -131,6 +131,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'check_restart', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/service_registration.rb b/clients/ruby/v1/lib/nomad_client/models/service_registration.rb index d56b24b2..1be60fe4 100644 --- a/clients/ruby/v1/lib/nomad_client/models/service_registration.rb +++ b/clients/ruby/v1/lib/nomad_client/models/service_registration.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/sidecar_task.rb b/clients/ruby/v1/lib/nomad_client/models/sidecar_task.rb index 4c545e52..fc7fa767 100644 --- a/clients/ruby/v1/lib/nomad_client/models/sidecar_task.rb +++ b/clients/ruby/v1/lib/nomad_client/models/sidecar_task.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -62,7 +62,7 @@ def self.acceptable_attributes # Attribute type mapping. def self.openapi_types { - :'config' => :'Hash', + :'config' => :'Hash', :'driver' => :'String', :'env' => :'Hash', :'kill_signal' => :'String', @@ -79,6 +79,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'resources', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/spread.rb b/clients/ruby/v1/lib/nomad_client/models/spread.rb index b762c66c..261860b7 100644 --- a/clients/ruby/v1/lib/nomad_client/models/spread.rb +++ b/clients/ruby/v1/lib/nomad_client/models/spread.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/spread_target.rb b/clients/ruby/v1/lib/nomad_client/models/spread_target.rb index 7325237f..7cee2e03 100644 --- a/clients/ruby/v1/lib/nomad_client/models/spread_target.rb +++ b/clients/ruby/v1/lib/nomad_client/models/spread_target.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/task.rb b/clients/ruby/v1/lib/nomad_client/models/task.rb index d40ff108..887bf140 100644 --- a/clients/ruby/v1/lib/nomad_client/models/task.rb +++ b/clients/ruby/v1/lib/nomad_client/models/task.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -107,7 +107,7 @@ def self.openapi_types :'affinities' => :'Array', :'artifacts' => :'Array', :'csi_plugin_config' => :'TaskCSIPluginConfig', - :'config' => :'Hash', + :'config' => :'Hash', :'constraints' => :'Array', :'dispatch_payload' => :'DispatchPayloadConfig', :'driver' => :'String', @@ -135,6 +135,11 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'csi_plugin_config', + :'dispatch_payload', + :'lifecycle', + :'resources', + :'vault', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/task_artifact.rb b/clients/ruby/v1/lib/nomad_client/models/task_artifact.rb index 761d2e3b..59cf669f 100644 --- a/clients/ruby/v1/lib/nomad_client/models/task_artifact.rb +++ b/clients/ruby/v1/lib/nomad_client/models/task_artifact.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/task_csi_plugin_config.rb b/clients/ruby/v1/lib/nomad_client/models/task_csi_plugin_config.rb index cb2726d2..fc5e8c10 100644 --- a/clients/ruby/v1/lib/nomad_client/models/task_csi_plugin_config.rb +++ b/clients/ruby/v1/lib/nomad_client/models/task_csi_plugin_config.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/task_diff.rb b/clients/ruby/v1/lib/nomad_client/models/task_diff.rb index 3549be82..9050d1fc 100644 --- a/clients/ruby/v1/lib/nomad_client/models/task_diff.rb +++ b/clients/ruby/v1/lib/nomad_client/models/task_diff.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/task_event.rb b/clients/ruby/v1/lib/nomad_client/models/task_event.rb index e4781839..667189b9 100644 --- a/clients/ruby/v1/lib/nomad_client/models/task_event.rb +++ b/clients/ruby/v1/lib/nomad_client/models/task_event.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/task_group.rb b/clients/ruby/v1/lib/nomad_client/models/task_group.rb index e1d80d33..f23bd168 100644 --- a/clients/ruby/v1/lib/nomad_client/models/task_group.rb +++ b/clients/ruby/v1/lib/nomad_client/models/task_group.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -115,6 +115,8 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'consul', + :'scaling', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/task_group_diff.rb b/clients/ruby/v1/lib/nomad_client/models/task_group_diff.rb index 08013374..fb860081 100644 --- a/clients/ruby/v1/lib/nomad_client/models/task_group_diff.rb +++ b/clients/ruby/v1/lib/nomad_client/models/task_group_diff.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/task_group_scale_status.rb b/clients/ruby/v1/lib/nomad_client/models/task_group_scale_status.rb index f94de6a3..600d55b7 100644 --- a/clients/ruby/v1/lib/nomad_client/models/task_group_scale_status.rb +++ b/clients/ruby/v1/lib/nomad_client/models/task_group_scale_status.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/task_group_summary.rb b/clients/ruby/v1/lib/nomad_client/models/task_group_summary.rb index 79ddc5dd..0a1e8173 100644 --- a/clients/ruby/v1/lib/nomad_client/models/task_group_summary.rb +++ b/clients/ruby/v1/lib/nomad_client/models/task_group_summary.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/task_handle.rb b/clients/ruby/v1/lib/nomad_client/models/task_handle.rb index e3e7b4cb..df90c947 100644 --- a/clients/ruby/v1/lib/nomad_client/models/task_handle.rb +++ b/clients/ruby/v1/lib/nomad_client/models/task_handle.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/task_lifecycle.rb b/clients/ruby/v1/lib/nomad_client/models/task_lifecycle.rb index b9763282..e9ba0e48 100644 --- a/clients/ruby/v1/lib/nomad_client/models/task_lifecycle.rb +++ b/clients/ruby/v1/lib/nomad_client/models/task_lifecycle.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/task_state.rb b/clients/ruby/v1/lib/nomad_client/models/task_state.rb index ca51ef29..6033fdad 100644 --- a/clients/ruby/v1/lib/nomad_client/models/task_state.rb +++ b/clients/ruby/v1/lib/nomad_client/models/task_state.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -67,6 +67,10 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'finished_at', + :'last_restart', + :'started_at', + :'task_handle' ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/template.rb b/clients/ruby/v1/lib/nomad_client/models/template.rb index e3ede466..e5726c80 100644 --- a/clients/ruby/v1/lib/nomad_client/models/template.rb +++ b/clients/ruby/v1/lib/nomad_client/models/template.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/update_strategy.rb b/clients/ruby/v1/lib/nomad_client/models/update_strategy.rb index a963eb99..8647e93e 100644 --- a/clients/ruby/v1/lib/nomad_client/models/update_strategy.rb +++ b/clients/ruby/v1/lib/nomad_client/models/update_strategy.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/vault.rb b/clients/ruby/v1/lib/nomad_client/models/vault.rb index 50e70c41..d5065fbc 100644 --- a/clients/ruby/v1/lib/nomad_client/models/vault.rb +++ b/clients/ruby/v1/lib/nomad_client/models/vault.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/volume_mount.rb b/clients/ruby/v1/lib/nomad_client/models/volume_mount.rb index fc0fe900..aefbacb3 100644 --- a/clients/ruby/v1/lib/nomad_client/models/volume_mount.rb +++ b/clients/ruby/v1/lib/nomad_client/models/volume_mount.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/models/volume_request.rb b/clients/ruby/v1/lib/nomad_client/models/volume_request.rb index dd41243d..7a1f99d2 100644 --- a/clients/ruby/v1/lib/nomad_client/models/volume_request.rb +++ b/clients/ruby/v1/lib/nomad_client/models/volume_request.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -67,6 +67,7 @@ def self.openapi_types # List of attributes with nullable: true def self.openapi_nullable Set.new([ + :'mount_options', ]) end diff --git a/clients/ruby/v1/lib/nomad_client/models/wait_config.rb b/clients/ruby/v1/lib/nomad_client/models/wait_config.rb index 7a1d6389..e0f87c7c 100644 --- a/clients/ruby/v1/lib/nomad_client/models/wait_config.rb +++ b/clients/ruby/v1/lib/nomad_client/models/wait_config.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/lib/nomad_client/version.rb b/clients/ruby/v1/lib/nomad_client/version.rb index ea48ec1b..30239031 100644 --- a/clients/ruby/v1/lib/nomad_client/version.rb +++ b/clients/ruby/v1/lib/nomad_client/version.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/nomad_client.gemspec b/clients/ruby/v1/nomad_client.gemspec index 1d53aad8..8ba64228 100644 --- a/clients/ruby/v1/nomad_client.gemspec +++ b/clients/ruby/v1/nomad_client.gemspec @@ -8,7 +8,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/api/acl_api_spec.rb b/clients/ruby/v1/spec/api/acl_api_spec.rb index 13f07fe7..451940d4 100644 --- a/clients/ruby/v1/spec/api/acl_api_spec.rb +++ b/clients/ruby/v1/spec/api/acl_api_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/api/allocations_api_spec.rb b/clients/ruby/v1/spec/api/allocations_api_spec.rb index d6dfe937..c47da554 100644 --- a/clients/ruby/v1/spec/api/allocations_api_spec.rb +++ b/clients/ruby/v1/spec/api/allocations_api_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/api/deployments_api_spec.rb b/clients/ruby/v1/spec/api/deployments_api_spec.rb index 009e6019..ee8fdbd5 100644 --- a/clients/ruby/v1/spec/api/deployments_api_spec.rb +++ b/clients/ruby/v1/spec/api/deployments_api_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/api/enterprise_api_spec.rb b/clients/ruby/v1/spec/api/enterprise_api_spec.rb index f24c8693..29f55882 100644 --- a/clients/ruby/v1/spec/api/enterprise_api_spec.rb +++ b/clients/ruby/v1/spec/api/enterprise_api_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -90,7 +90,7 @@ # @option opts [String] :x_nomad_token A Nomad ACL token. # @option opts [Integer] :per_page Maximum number of results to return. # @option opts [String] :next_token Indicates where to start paging for queries that support pagination. - # @return [Array] + # @return [Array] describe 'get_quotas test' do it 'should work' do # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers diff --git a/clients/ruby/v1/spec/api/evaluations_api_spec.rb b/clients/ruby/v1/spec/api/evaluations_api_spec.rb index 4f3d3dd6..41832813 100644 --- a/clients/ruby/v1/spec/api/evaluations_api_spec.rb +++ b/clients/ruby/v1/spec/api/evaluations_api_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/api/jobs_api_spec.rb b/clients/ruby/v1/spec/api/jobs_api_spec.rb index dd2ac39d..84d78b43 100644 --- a/clients/ruby/v1/spec/api/jobs_api_spec.rb +++ b/clients/ruby/v1/spec/api/jobs_api_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/api/metrics_api_spec.rb b/clients/ruby/v1/spec/api/metrics_api_spec.rb index 17b82e39..73a00197 100644 --- a/clients/ruby/v1/spec/api/metrics_api_spec.rb +++ b/clients/ruby/v1/spec/api/metrics_api_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/api/namespaces_api_spec.rb b/clients/ruby/v1/spec/api/namespaces_api_spec.rb index fc82905c..db9641d4 100644 --- a/clients/ruby/v1/spec/api/namespaces_api_spec.rb +++ b/clients/ruby/v1/spec/api/namespaces_api_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/api/nodes_api_spec.rb b/clients/ruby/v1/spec/api/nodes_api_spec.rb index 6ba33da3..1a95b835 100644 --- a/clients/ruby/v1/spec/api/nodes_api_spec.rb +++ b/clients/ruby/v1/spec/api/nodes_api_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/api/operator_api_spec.rb b/clients/ruby/v1/spec/api/operator_api_spec.rb index 52729e42..6057d7c5 100644 --- a/clients/ruby/v1/spec/api/operator_api_spec.rb +++ b/clients/ruby/v1/spec/api/operator_api_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/api/plugins_api_spec.rb b/clients/ruby/v1/spec/api/plugins_api_spec.rb index b728eebf..866d92b5 100644 --- a/clients/ruby/v1/spec/api/plugins_api_spec.rb +++ b/clients/ruby/v1/spec/api/plugins_api_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/api/regions_api_spec.rb b/clients/ruby/v1/spec/api/regions_api_spec.rb index 1aeb7bd8..6a3382f6 100644 --- a/clients/ruby/v1/spec/api/regions_api_spec.rb +++ b/clients/ruby/v1/spec/api/regions_api_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/api/scaling_api_spec.rb b/clients/ruby/v1/spec/api/scaling_api_spec.rb index 42849c43..cd0986eb 100644 --- a/clients/ruby/v1/spec/api/scaling_api_spec.rb +++ b/clients/ruby/v1/spec/api/scaling_api_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/api/search_api_spec.rb b/clients/ruby/v1/spec/api/search_api_spec.rb index 96d0c1d4..99da2f4f 100644 --- a/clients/ruby/v1/spec/api/search_api_spec.rb +++ b/clients/ruby/v1/spec/api/search_api_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/api/status_api_spec.rb b/clients/ruby/v1/spec/api/status_api_spec.rb index c471c0ee..d989e1b3 100644 --- a/clients/ruby/v1/spec/api/status_api_spec.rb +++ b/clients/ruby/v1/spec/api/status_api_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/api/system_api_spec.rb b/clients/ruby/v1/spec/api/system_api_spec.rb index fa74503d..d669b815 100644 --- a/clients/ruby/v1/spec/api/system_api_spec.rb +++ b/clients/ruby/v1/spec/api/system_api_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/api/volumes_api_spec.rb b/clients/ruby/v1/spec/api/volumes_api_spec.rb index eb8a3078..f6e167bb 100644 --- a/clients/ruby/v1/spec/api/volumes_api_spec.rb +++ b/clients/ruby/v1/spec/api/volumes_api_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/api_client_spec.rb b/clients/ruby/v1/spec/api_client_spec.rb index fd3667ef..7f3b6c49 100644 --- a/clients/ruby/v1/spec/api_client_spec.rb +++ b/clients/ruby/v1/spec/api_client_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end @@ -197,8 +197,8 @@ let(:api_client) { NomadClient::ApiClient.new } it 'works' do - expect(api_client.select_header_content_type(nil)).to eq('application/json') - expect(api_client.select_header_content_type([])).to eq('application/json') + expect(api_client.select_header_content_type(nil)).to be_nil + expect(api_client.select_header_content_type([])).to be_nil expect(api_client.select_header_content_type(['application/json'])).to eq('application/json') expect(api_client.select_header_content_type(['application/xml', 'application/json; charset=UTF8'])).to eq('application/json; charset=UTF8') diff --git a/clients/ruby/v1/spec/configuration_spec.rb b/clients/ruby/v1/spec/configuration_spec.rb index 35d3e754..1431c604 100644 --- a/clients/ruby/v1/spec/configuration_spec.rb +++ b/clients/ruby/v1/spec/configuration_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/acl_policy_list_stub_spec.rb b/clients/ruby/v1/spec/models/acl_policy_list_stub_spec.rb index 645e9073..d2f80518 100644 --- a/clients/ruby/v1/spec/models/acl_policy_list_stub_spec.rb +++ b/clients/ruby/v1/spec/models/acl_policy_list_stub_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/acl_policy_spec.rb b/clients/ruby/v1/spec/models/acl_policy_spec.rb index 0dbe9d5c..aa5abe63 100644 --- a/clients/ruby/v1/spec/models/acl_policy_spec.rb +++ b/clients/ruby/v1/spec/models/acl_policy_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/acl_token_list_stub_spec.rb b/clients/ruby/v1/spec/models/acl_token_list_stub_spec.rb index c816544b..51593bcf 100644 --- a/clients/ruby/v1/spec/models/acl_token_list_stub_spec.rb +++ b/clients/ruby/v1/spec/models/acl_token_list_stub_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/acl_token_spec.rb b/clients/ruby/v1/spec/models/acl_token_spec.rb index e3902715..6aeb0e82 100644 --- a/clients/ruby/v1/spec/models/acl_token_spec.rb +++ b/clients/ruby/v1/spec/models/acl_token_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/affinity_spec.rb b/clients/ruby/v1/spec/models/affinity_spec.rb index 469380f9..8af27dca 100644 --- a/clients/ruby/v1/spec/models/affinity_spec.rb +++ b/clients/ruby/v1/spec/models/affinity_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/alloc_deployment_status_spec.rb b/clients/ruby/v1/spec/models/alloc_deployment_status_spec.rb index e6865d9a..d031d74e 100644 --- a/clients/ruby/v1/spec/models/alloc_deployment_status_spec.rb +++ b/clients/ruby/v1/spec/models/alloc_deployment_status_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/alloc_stop_response_spec.rb b/clients/ruby/v1/spec/models/alloc_stop_response_spec.rb index c3c79707..5d20259f 100644 --- a/clients/ruby/v1/spec/models/alloc_stop_response_spec.rb +++ b/clients/ruby/v1/spec/models/alloc_stop_response_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/allocated_cpu_resources_spec.rb b/clients/ruby/v1/spec/models/allocated_cpu_resources_spec.rb index c2b6abde..30b56f6d 100644 --- a/clients/ruby/v1/spec/models/allocated_cpu_resources_spec.rb +++ b/clients/ruby/v1/spec/models/allocated_cpu_resources_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/allocated_device_resource_spec.rb b/clients/ruby/v1/spec/models/allocated_device_resource_spec.rb index 3a6338fb..0113d249 100644 --- a/clients/ruby/v1/spec/models/allocated_device_resource_spec.rb +++ b/clients/ruby/v1/spec/models/allocated_device_resource_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/allocated_memory_resources_spec.rb b/clients/ruby/v1/spec/models/allocated_memory_resources_spec.rb index 36210940..d1798a0c 100644 --- a/clients/ruby/v1/spec/models/allocated_memory_resources_spec.rb +++ b/clients/ruby/v1/spec/models/allocated_memory_resources_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/allocated_resources_spec.rb b/clients/ruby/v1/spec/models/allocated_resources_spec.rb index 6acb9ab7..ff4e4c67 100644 --- a/clients/ruby/v1/spec/models/allocated_resources_spec.rb +++ b/clients/ruby/v1/spec/models/allocated_resources_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/allocated_shared_resources_spec.rb b/clients/ruby/v1/spec/models/allocated_shared_resources_spec.rb index ddf33eac..83c6889e 100644 --- a/clients/ruby/v1/spec/models/allocated_shared_resources_spec.rb +++ b/clients/ruby/v1/spec/models/allocated_shared_resources_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/allocated_task_resources_spec.rb b/clients/ruby/v1/spec/models/allocated_task_resources_spec.rb index d7474be8..5b0425f1 100644 --- a/clients/ruby/v1/spec/models/allocated_task_resources_spec.rb +++ b/clients/ruby/v1/spec/models/allocated_task_resources_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/allocation_list_stub_spec.rb b/clients/ruby/v1/spec/models/allocation_list_stub_spec.rb index 10865081..fca436dd 100644 --- a/clients/ruby/v1/spec/models/allocation_list_stub_spec.rb +++ b/clients/ruby/v1/spec/models/allocation_list_stub_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/allocation_metric_spec.rb b/clients/ruby/v1/spec/models/allocation_metric_spec.rb index 60f6e3be..3dc2ca97 100644 --- a/clients/ruby/v1/spec/models/allocation_metric_spec.rb +++ b/clients/ruby/v1/spec/models/allocation_metric_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/allocation_spec.rb b/clients/ruby/v1/spec/models/allocation_spec.rb index 2a8a9812..798ad720 100644 --- a/clients/ruby/v1/spec/models/allocation_spec.rb +++ b/clients/ruby/v1/spec/models/allocation_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/attribute_spec.rb b/clients/ruby/v1/spec/models/attribute_spec.rb index 5a971196..eab45cd8 100644 --- a/clients/ruby/v1/spec/models/attribute_spec.rb +++ b/clients/ruby/v1/spec/models/attribute_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/autopilot_configuration_spec.rb b/clients/ruby/v1/spec/models/autopilot_configuration_spec.rb index 8017e88b..2989defa 100644 --- a/clients/ruby/v1/spec/models/autopilot_configuration_spec.rb +++ b/clients/ruby/v1/spec/models/autopilot_configuration_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/check_restart_spec.rb b/clients/ruby/v1/spec/models/check_restart_spec.rb index debe9d31..a0b66b2c 100644 --- a/clients/ruby/v1/spec/models/check_restart_spec.rb +++ b/clients/ruby/v1/spec/models/check_restart_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/constraint_spec.rb b/clients/ruby/v1/spec/models/constraint_spec.rb index df462ede..59db1950 100644 --- a/clients/ruby/v1/spec/models/constraint_spec.rb +++ b/clients/ruby/v1/spec/models/constraint_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/consul_connect_spec.rb b/clients/ruby/v1/spec/models/consul_connect_spec.rb index 768967ef..3c55ae14 100644 --- a/clients/ruby/v1/spec/models/consul_connect_spec.rb +++ b/clients/ruby/v1/spec/models/consul_connect_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/consul_expose_config_spec.rb b/clients/ruby/v1/spec/models/consul_expose_config_spec.rb index df085de9..fe7bcda8 100644 --- a/clients/ruby/v1/spec/models/consul_expose_config_spec.rb +++ b/clients/ruby/v1/spec/models/consul_expose_config_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/consul_expose_path_spec.rb b/clients/ruby/v1/spec/models/consul_expose_path_spec.rb index f1a8fffc..1295d4dd 100644 --- a/clients/ruby/v1/spec/models/consul_expose_path_spec.rb +++ b/clients/ruby/v1/spec/models/consul_expose_path_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/consul_gateway_bind_address_spec.rb b/clients/ruby/v1/spec/models/consul_gateway_bind_address_spec.rb index a23deb47..b94e4161 100644 --- a/clients/ruby/v1/spec/models/consul_gateway_bind_address_spec.rb +++ b/clients/ruby/v1/spec/models/consul_gateway_bind_address_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/consul_gateway_proxy_spec.rb b/clients/ruby/v1/spec/models/consul_gateway_proxy_spec.rb index 42d5dd56..5c481f82 100644 --- a/clients/ruby/v1/spec/models/consul_gateway_proxy_spec.rb +++ b/clients/ruby/v1/spec/models/consul_gateway_proxy_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/consul_gateway_spec.rb b/clients/ruby/v1/spec/models/consul_gateway_spec.rb index d797f94b..1d011597 100644 --- a/clients/ruby/v1/spec/models/consul_gateway_spec.rb +++ b/clients/ruby/v1/spec/models/consul_gateway_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/consul_gateway_tls_config_spec.rb b/clients/ruby/v1/spec/models/consul_gateway_tls_config_spec.rb index cbd557ae..0e52e379 100644 --- a/clients/ruby/v1/spec/models/consul_gateway_tls_config_spec.rb +++ b/clients/ruby/v1/spec/models/consul_gateway_tls_config_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/consul_ingress_config_entry_spec.rb b/clients/ruby/v1/spec/models/consul_ingress_config_entry_spec.rb index 80f8dcbe..62efdacf 100644 --- a/clients/ruby/v1/spec/models/consul_ingress_config_entry_spec.rb +++ b/clients/ruby/v1/spec/models/consul_ingress_config_entry_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/consul_ingress_listener_spec.rb b/clients/ruby/v1/spec/models/consul_ingress_listener_spec.rb index 97121a34..3753ee69 100644 --- a/clients/ruby/v1/spec/models/consul_ingress_listener_spec.rb +++ b/clients/ruby/v1/spec/models/consul_ingress_listener_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/consul_ingress_service_spec.rb b/clients/ruby/v1/spec/models/consul_ingress_service_spec.rb index 05f1aba0..8160da5f 100644 --- a/clients/ruby/v1/spec/models/consul_ingress_service_spec.rb +++ b/clients/ruby/v1/spec/models/consul_ingress_service_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/consul_linked_service_spec.rb b/clients/ruby/v1/spec/models/consul_linked_service_spec.rb index 958b5afc..9e488d65 100644 --- a/clients/ruby/v1/spec/models/consul_linked_service_spec.rb +++ b/clients/ruby/v1/spec/models/consul_linked_service_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/consul_mesh_gateway_spec.rb b/clients/ruby/v1/spec/models/consul_mesh_gateway_spec.rb index 9538f2d5..548a95ea 100644 --- a/clients/ruby/v1/spec/models/consul_mesh_gateway_spec.rb +++ b/clients/ruby/v1/spec/models/consul_mesh_gateway_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/consul_proxy_spec.rb b/clients/ruby/v1/spec/models/consul_proxy_spec.rb index 2351aeb0..43f2fe78 100644 --- a/clients/ruby/v1/spec/models/consul_proxy_spec.rb +++ b/clients/ruby/v1/spec/models/consul_proxy_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/consul_sidecar_service_spec.rb b/clients/ruby/v1/spec/models/consul_sidecar_service_spec.rb index f5df673d..faa4231a 100644 --- a/clients/ruby/v1/spec/models/consul_sidecar_service_spec.rb +++ b/clients/ruby/v1/spec/models/consul_sidecar_service_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/consul_spec.rb b/clients/ruby/v1/spec/models/consul_spec.rb index 83a01307..c63eceeb 100644 --- a/clients/ruby/v1/spec/models/consul_spec.rb +++ b/clients/ruby/v1/spec/models/consul_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/consul_terminating_config_entry_spec.rb b/clients/ruby/v1/spec/models/consul_terminating_config_entry_spec.rb index aac88314..a6148077 100644 --- a/clients/ruby/v1/spec/models/consul_terminating_config_entry_spec.rb +++ b/clients/ruby/v1/spec/models/consul_terminating_config_entry_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/consul_upstream_spec.rb b/clients/ruby/v1/spec/models/consul_upstream_spec.rb index 9aae1343..b0ceaf33 100644 --- a/clients/ruby/v1/spec/models/consul_upstream_spec.rb +++ b/clients/ruby/v1/spec/models/consul_upstream_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/csi_controller_info_spec.rb b/clients/ruby/v1/spec/models/csi_controller_info_spec.rb index ac6cc563..4bedd41b 100644 --- a/clients/ruby/v1/spec/models/csi_controller_info_spec.rb +++ b/clients/ruby/v1/spec/models/csi_controller_info_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/csi_info_spec.rb b/clients/ruby/v1/spec/models/csi_info_spec.rb index 7ee008d9..fc2be437 100644 --- a/clients/ruby/v1/spec/models/csi_info_spec.rb +++ b/clients/ruby/v1/spec/models/csi_info_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/csi_mount_options_spec.rb b/clients/ruby/v1/spec/models/csi_mount_options_spec.rb index 4df5dd45..80d3acca 100644 --- a/clients/ruby/v1/spec/models/csi_mount_options_spec.rb +++ b/clients/ruby/v1/spec/models/csi_mount_options_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/csi_node_info_spec.rb b/clients/ruby/v1/spec/models/csi_node_info_spec.rb index 2279f5e9..b25be532 100644 --- a/clients/ruby/v1/spec/models/csi_node_info_spec.rb +++ b/clients/ruby/v1/spec/models/csi_node_info_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/csi_plugin_list_stub_spec.rb b/clients/ruby/v1/spec/models/csi_plugin_list_stub_spec.rb index bd9ec9f5..c804fa46 100644 --- a/clients/ruby/v1/spec/models/csi_plugin_list_stub_spec.rb +++ b/clients/ruby/v1/spec/models/csi_plugin_list_stub_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/csi_plugin_spec.rb b/clients/ruby/v1/spec/models/csi_plugin_spec.rb index 56060fe8..8b72f9f1 100644 --- a/clients/ruby/v1/spec/models/csi_plugin_spec.rb +++ b/clients/ruby/v1/spec/models/csi_plugin_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/csi_snapshot_create_request_spec.rb b/clients/ruby/v1/spec/models/csi_snapshot_create_request_spec.rb index 5c1bf622..fd13983b 100644 --- a/clients/ruby/v1/spec/models/csi_snapshot_create_request_spec.rb +++ b/clients/ruby/v1/spec/models/csi_snapshot_create_request_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/csi_snapshot_create_response_spec.rb b/clients/ruby/v1/spec/models/csi_snapshot_create_response_spec.rb index 4b3fbbf8..583d725c 100644 --- a/clients/ruby/v1/spec/models/csi_snapshot_create_response_spec.rb +++ b/clients/ruby/v1/spec/models/csi_snapshot_create_response_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/csi_snapshot_list_response_spec.rb b/clients/ruby/v1/spec/models/csi_snapshot_list_response_spec.rb index 77871b8e..feb432f8 100644 --- a/clients/ruby/v1/spec/models/csi_snapshot_list_response_spec.rb +++ b/clients/ruby/v1/spec/models/csi_snapshot_list_response_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/csi_snapshot_spec.rb b/clients/ruby/v1/spec/models/csi_snapshot_spec.rb index 4c78f2f7..800a8bdd 100644 --- a/clients/ruby/v1/spec/models/csi_snapshot_spec.rb +++ b/clients/ruby/v1/spec/models/csi_snapshot_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/csi_topology_request_spec.rb b/clients/ruby/v1/spec/models/csi_topology_request_spec.rb index 3f9b8d34..e021fe62 100644 --- a/clients/ruby/v1/spec/models/csi_topology_request_spec.rb +++ b/clients/ruby/v1/spec/models/csi_topology_request_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/csi_topology_spec.rb b/clients/ruby/v1/spec/models/csi_topology_spec.rb index 48a6f373..fb74241e 100644 --- a/clients/ruby/v1/spec/models/csi_topology_spec.rb +++ b/clients/ruby/v1/spec/models/csi_topology_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/csi_volume_capability_spec.rb b/clients/ruby/v1/spec/models/csi_volume_capability_spec.rb index 632ad25d..6448660f 100644 --- a/clients/ruby/v1/spec/models/csi_volume_capability_spec.rb +++ b/clients/ruby/v1/spec/models/csi_volume_capability_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/csi_volume_create_request_spec.rb b/clients/ruby/v1/spec/models/csi_volume_create_request_spec.rb index 89f119d7..27064ca2 100644 --- a/clients/ruby/v1/spec/models/csi_volume_create_request_spec.rb +++ b/clients/ruby/v1/spec/models/csi_volume_create_request_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/csi_volume_external_stub_spec.rb b/clients/ruby/v1/spec/models/csi_volume_external_stub_spec.rb index 9462fd33..45b57331 100644 --- a/clients/ruby/v1/spec/models/csi_volume_external_stub_spec.rb +++ b/clients/ruby/v1/spec/models/csi_volume_external_stub_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/csi_volume_list_external_response_spec.rb b/clients/ruby/v1/spec/models/csi_volume_list_external_response_spec.rb index f19787df..0413ea25 100644 --- a/clients/ruby/v1/spec/models/csi_volume_list_external_response_spec.rb +++ b/clients/ruby/v1/spec/models/csi_volume_list_external_response_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/csi_volume_list_stub_spec.rb b/clients/ruby/v1/spec/models/csi_volume_list_stub_spec.rb index 39775a63..e331343c 100644 --- a/clients/ruby/v1/spec/models/csi_volume_list_stub_spec.rb +++ b/clients/ruby/v1/spec/models/csi_volume_list_stub_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/csi_volume_register_request_spec.rb b/clients/ruby/v1/spec/models/csi_volume_register_request_spec.rb index 72e6f26d..b9af1880 100644 --- a/clients/ruby/v1/spec/models/csi_volume_register_request_spec.rb +++ b/clients/ruby/v1/spec/models/csi_volume_register_request_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/csi_volume_spec.rb b/clients/ruby/v1/spec/models/csi_volume_spec.rb index 4f92ad6e..a46851a3 100644 --- a/clients/ruby/v1/spec/models/csi_volume_spec.rb +++ b/clients/ruby/v1/spec/models/csi_volume_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/deployment_alloc_health_request_spec.rb b/clients/ruby/v1/spec/models/deployment_alloc_health_request_spec.rb index 1b8140b3..719c095d 100644 --- a/clients/ruby/v1/spec/models/deployment_alloc_health_request_spec.rb +++ b/clients/ruby/v1/spec/models/deployment_alloc_health_request_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/deployment_pause_request_spec.rb b/clients/ruby/v1/spec/models/deployment_pause_request_spec.rb index ba3d8aaa..721cca0b 100644 --- a/clients/ruby/v1/spec/models/deployment_pause_request_spec.rb +++ b/clients/ruby/v1/spec/models/deployment_pause_request_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/deployment_promote_request_spec.rb b/clients/ruby/v1/spec/models/deployment_promote_request_spec.rb index b0dc7e66..76e7ae39 100644 --- a/clients/ruby/v1/spec/models/deployment_promote_request_spec.rb +++ b/clients/ruby/v1/spec/models/deployment_promote_request_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/deployment_spec.rb b/clients/ruby/v1/spec/models/deployment_spec.rb index a71a129c..08be8ea6 100644 --- a/clients/ruby/v1/spec/models/deployment_spec.rb +++ b/clients/ruby/v1/spec/models/deployment_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/deployment_state_spec.rb b/clients/ruby/v1/spec/models/deployment_state_spec.rb index 9278b4db..50b0a9b6 100644 --- a/clients/ruby/v1/spec/models/deployment_state_spec.rb +++ b/clients/ruby/v1/spec/models/deployment_state_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/deployment_unblock_request_spec.rb b/clients/ruby/v1/spec/models/deployment_unblock_request_spec.rb index 3a0a98c9..babdf038 100644 --- a/clients/ruby/v1/spec/models/deployment_unblock_request_spec.rb +++ b/clients/ruby/v1/spec/models/deployment_unblock_request_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/deployment_update_response_spec.rb b/clients/ruby/v1/spec/models/deployment_update_response_spec.rb index 5e060a50..6438fbe3 100644 --- a/clients/ruby/v1/spec/models/deployment_update_response_spec.rb +++ b/clients/ruby/v1/spec/models/deployment_update_response_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/desired_transition_spec.rb b/clients/ruby/v1/spec/models/desired_transition_spec.rb index 247e8bd8..171a6b6a 100644 --- a/clients/ruby/v1/spec/models/desired_transition_spec.rb +++ b/clients/ruby/v1/spec/models/desired_transition_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/desired_updates_spec.rb b/clients/ruby/v1/spec/models/desired_updates_spec.rb index 4d2cdc59..98b5c1fe 100644 --- a/clients/ruby/v1/spec/models/desired_updates_spec.rb +++ b/clients/ruby/v1/spec/models/desired_updates_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/dispatch_payload_config_spec.rb b/clients/ruby/v1/spec/models/dispatch_payload_config_spec.rb index 166947e5..55c7ecbd 100644 --- a/clients/ruby/v1/spec/models/dispatch_payload_config_spec.rb +++ b/clients/ruby/v1/spec/models/dispatch_payload_config_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/dns_config_spec.rb b/clients/ruby/v1/spec/models/dns_config_spec.rb index 21a69413..df315f77 100644 --- a/clients/ruby/v1/spec/models/dns_config_spec.rb +++ b/clients/ruby/v1/spec/models/dns_config_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/drain_metadata_spec.rb b/clients/ruby/v1/spec/models/drain_metadata_spec.rb index 897f5bcf..8512b344 100644 --- a/clients/ruby/v1/spec/models/drain_metadata_spec.rb +++ b/clients/ruby/v1/spec/models/drain_metadata_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/drain_spec_spec.rb b/clients/ruby/v1/spec/models/drain_spec_spec.rb index 0d648326..babbb00c 100644 --- a/clients/ruby/v1/spec/models/drain_spec_spec.rb +++ b/clients/ruby/v1/spec/models/drain_spec_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/drain_strategy_spec.rb b/clients/ruby/v1/spec/models/drain_strategy_spec.rb index 2e4be5ce..71544f46 100644 --- a/clients/ruby/v1/spec/models/drain_strategy_spec.rb +++ b/clients/ruby/v1/spec/models/drain_strategy_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/driver_info_spec.rb b/clients/ruby/v1/spec/models/driver_info_spec.rb index 6478b7ee..da97289c 100644 --- a/clients/ruby/v1/spec/models/driver_info_spec.rb +++ b/clients/ruby/v1/spec/models/driver_info_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/ephemeral_disk_spec.rb b/clients/ruby/v1/spec/models/ephemeral_disk_spec.rb index 78f31a6a..732a7478 100644 --- a/clients/ruby/v1/spec/models/ephemeral_disk_spec.rb +++ b/clients/ruby/v1/spec/models/ephemeral_disk_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/eval_options_spec.rb b/clients/ruby/v1/spec/models/eval_options_spec.rb index f146391b..577b0cee 100644 --- a/clients/ruby/v1/spec/models/eval_options_spec.rb +++ b/clients/ruby/v1/spec/models/eval_options_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/evaluation_spec.rb b/clients/ruby/v1/spec/models/evaluation_spec.rb index 3dd7c78c..2bf727b9 100644 --- a/clients/ruby/v1/spec/models/evaluation_spec.rb +++ b/clients/ruby/v1/spec/models/evaluation_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/evaluation_stub_spec.rb b/clients/ruby/v1/spec/models/evaluation_stub_spec.rb index b28480cf..447ba728 100644 --- a/clients/ruby/v1/spec/models/evaluation_stub_spec.rb +++ b/clients/ruby/v1/spec/models/evaluation_stub_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/field_diff_spec.rb b/clients/ruby/v1/spec/models/field_diff_spec.rb index fcf20262..3678c57f 100644 --- a/clients/ruby/v1/spec/models/field_diff_spec.rb +++ b/clients/ruby/v1/spec/models/field_diff_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/fuzzy_match_spec.rb b/clients/ruby/v1/spec/models/fuzzy_match_spec.rb index 383d295f..912998ff 100644 --- a/clients/ruby/v1/spec/models/fuzzy_match_spec.rb +++ b/clients/ruby/v1/spec/models/fuzzy_match_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/fuzzy_search_request_spec.rb b/clients/ruby/v1/spec/models/fuzzy_search_request_spec.rb index 4e17a685..29853751 100644 --- a/clients/ruby/v1/spec/models/fuzzy_search_request_spec.rb +++ b/clients/ruby/v1/spec/models/fuzzy_search_request_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/fuzzy_search_response_spec.rb b/clients/ruby/v1/spec/models/fuzzy_search_response_spec.rb index 52b849ad..8a772d86 100644 --- a/clients/ruby/v1/spec/models/fuzzy_search_response_spec.rb +++ b/clients/ruby/v1/spec/models/fuzzy_search_response_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/gauge_value_spec.rb b/clients/ruby/v1/spec/models/gauge_value_spec.rb index 8e3bf3f5..a045e2a6 100644 --- a/clients/ruby/v1/spec/models/gauge_value_spec.rb +++ b/clients/ruby/v1/spec/models/gauge_value_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/host_network_info_spec.rb b/clients/ruby/v1/spec/models/host_network_info_spec.rb index 06b5c905..d0ce717c 100644 --- a/clients/ruby/v1/spec/models/host_network_info_spec.rb +++ b/clients/ruby/v1/spec/models/host_network_info_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/host_volume_info_spec.rb b/clients/ruby/v1/spec/models/host_volume_info_spec.rb index 0cb25a41..a01ab1cb 100644 --- a/clients/ruby/v1/spec/models/host_volume_info_spec.rb +++ b/clients/ruby/v1/spec/models/host_volume_info_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/job_children_summary_spec.rb b/clients/ruby/v1/spec/models/job_children_summary_spec.rb index 3a40f4fc..8ccadb53 100644 --- a/clients/ruby/v1/spec/models/job_children_summary_spec.rb +++ b/clients/ruby/v1/spec/models/job_children_summary_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/job_deregister_response_spec.rb b/clients/ruby/v1/spec/models/job_deregister_response_spec.rb index 5076b050..23706a3a 100644 --- a/clients/ruby/v1/spec/models/job_deregister_response_spec.rb +++ b/clients/ruby/v1/spec/models/job_deregister_response_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/job_diff_spec.rb b/clients/ruby/v1/spec/models/job_diff_spec.rb index 1d57e973..b7fecc3f 100644 --- a/clients/ruby/v1/spec/models/job_diff_spec.rb +++ b/clients/ruby/v1/spec/models/job_diff_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/job_dispatch_request_spec.rb b/clients/ruby/v1/spec/models/job_dispatch_request_spec.rb index ac84b968..bb5a94c0 100644 --- a/clients/ruby/v1/spec/models/job_dispatch_request_spec.rb +++ b/clients/ruby/v1/spec/models/job_dispatch_request_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/job_dispatch_response_spec.rb b/clients/ruby/v1/spec/models/job_dispatch_response_spec.rb index b0aabeed..35aae590 100644 --- a/clients/ruby/v1/spec/models/job_dispatch_response_spec.rb +++ b/clients/ruby/v1/spec/models/job_dispatch_response_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/job_evaluate_request_spec.rb b/clients/ruby/v1/spec/models/job_evaluate_request_spec.rb index 15daf21e..addbbfb2 100644 --- a/clients/ruby/v1/spec/models/job_evaluate_request_spec.rb +++ b/clients/ruby/v1/spec/models/job_evaluate_request_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/job_list_stub_spec.rb b/clients/ruby/v1/spec/models/job_list_stub_spec.rb index 4d58a1c9..6ab9c6bc 100644 --- a/clients/ruby/v1/spec/models/job_list_stub_spec.rb +++ b/clients/ruby/v1/spec/models/job_list_stub_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/job_plan_request_spec.rb b/clients/ruby/v1/spec/models/job_plan_request_spec.rb index 90b3b542..711602af 100644 --- a/clients/ruby/v1/spec/models/job_plan_request_spec.rb +++ b/clients/ruby/v1/spec/models/job_plan_request_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/job_plan_response_spec.rb b/clients/ruby/v1/spec/models/job_plan_response_spec.rb index 627224a3..986d27f4 100644 --- a/clients/ruby/v1/spec/models/job_plan_response_spec.rb +++ b/clients/ruby/v1/spec/models/job_plan_response_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/job_register_request_spec.rb b/clients/ruby/v1/spec/models/job_register_request_spec.rb index 570ec614..9709ad92 100644 --- a/clients/ruby/v1/spec/models/job_register_request_spec.rb +++ b/clients/ruby/v1/spec/models/job_register_request_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/job_register_response_spec.rb b/clients/ruby/v1/spec/models/job_register_response_spec.rb index 0a10c001..021c0a96 100644 --- a/clients/ruby/v1/spec/models/job_register_response_spec.rb +++ b/clients/ruby/v1/spec/models/job_register_response_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/job_revert_request_spec.rb b/clients/ruby/v1/spec/models/job_revert_request_spec.rb index 5e652fdc..bf54e566 100644 --- a/clients/ruby/v1/spec/models/job_revert_request_spec.rb +++ b/clients/ruby/v1/spec/models/job_revert_request_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/job_scale_status_response_spec.rb b/clients/ruby/v1/spec/models/job_scale_status_response_spec.rb index fc4986ed..2b9c6eb4 100644 --- a/clients/ruby/v1/spec/models/job_scale_status_response_spec.rb +++ b/clients/ruby/v1/spec/models/job_scale_status_response_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/job_spec.rb b/clients/ruby/v1/spec/models/job_spec.rb index fe14b857..fce64d0e 100644 --- a/clients/ruby/v1/spec/models/job_spec.rb +++ b/clients/ruby/v1/spec/models/job_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/job_stability_request_spec.rb b/clients/ruby/v1/spec/models/job_stability_request_spec.rb index 8482c5ae..e70fc9d6 100644 --- a/clients/ruby/v1/spec/models/job_stability_request_spec.rb +++ b/clients/ruby/v1/spec/models/job_stability_request_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/job_stability_response_spec.rb b/clients/ruby/v1/spec/models/job_stability_response_spec.rb index 9ddfcc50..42202df2 100644 --- a/clients/ruby/v1/spec/models/job_stability_response_spec.rb +++ b/clients/ruby/v1/spec/models/job_stability_response_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/job_summary_spec.rb b/clients/ruby/v1/spec/models/job_summary_spec.rb index d0e77d30..8f432278 100644 --- a/clients/ruby/v1/spec/models/job_summary_spec.rb +++ b/clients/ruby/v1/spec/models/job_summary_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/job_validate_request_spec.rb b/clients/ruby/v1/spec/models/job_validate_request_spec.rb index 253350d7..c59b4c49 100644 --- a/clients/ruby/v1/spec/models/job_validate_request_spec.rb +++ b/clients/ruby/v1/spec/models/job_validate_request_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/job_validate_response_spec.rb b/clients/ruby/v1/spec/models/job_validate_response_spec.rb index fb15a50a..900a66ed 100644 --- a/clients/ruby/v1/spec/models/job_validate_response_spec.rb +++ b/clients/ruby/v1/spec/models/job_validate_response_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/job_versions_response_spec.rb b/clients/ruby/v1/spec/models/job_versions_response_spec.rb index 9d7841ae..d662b6a9 100644 --- a/clients/ruby/v1/spec/models/job_versions_response_spec.rb +++ b/clients/ruby/v1/spec/models/job_versions_response_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/jobs_parse_request_spec.rb b/clients/ruby/v1/spec/models/jobs_parse_request_spec.rb index e523d36c..81c62980 100644 --- a/clients/ruby/v1/spec/models/jobs_parse_request_spec.rb +++ b/clients/ruby/v1/spec/models/jobs_parse_request_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/log_config_spec.rb b/clients/ruby/v1/spec/models/log_config_spec.rb index 6d8617eb..9ebca083 100644 --- a/clients/ruby/v1/spec/models/log_config_spec.rb +++ b/clients/ruby/v1/spec/models/log_config_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/metrics_summary_spec.rb b/clients/ruby/v1/spec/models/metrics_summary_spec.rb index 8a50d148..7d6023ab 100644 --- a/clients/ruby/v1/spec/models/metrics_summary_spec.rb +++ b/clients/ruby/v1/spec/models/metrics_summary_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/migrate_strategy_spec.rb b/clients/ruby/v1/spec/models/migrate_strategy_spec.rb index 647f973e..e63cc672 100644 --- a/clients/ruby/v1/spec/models/migrate_strategy_spec.rb +++ b/clients/ruby/v1/spec/models/migrate_strategy_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/multiregion_region_spec.rb b/clients/ruby/v1/spec/models/multiregion_region_spec.rb index 8d54942e..a3b9201f 100644 --- a/clients/ruby/v1/spec/models/multiregion_region_spec.rb +++ b/clients/ruby/v1/spec/models/multiregion_region_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/multiregion_spec.rb b/clients/ruby/v1/spec/models/multiregion_spec.rb index 653dc6b7..0f11a55b 100644 --- a/clients/ruby/v1/spec/models/multiregion_spec.rb +++ b/clients/ruby/v1/spec/models/multiregion_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/multiregion_strategy_spec.rb b/clients/ruby/v1/spec/models/multiregion_strategy_spec.rb index 8415839b..f5d343f2 100644 --- a/clients/ruby/v1/spec/models/multiregion_strategy_spec.rb +++ b/clients/ruby/v1/spec/models/multiregion_strategy_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/namespace_capabilities_spec.rb b/clients/ruby/v1/spec/models/namespace_capabilities_spec.rb index 00052924..86436e36 100644 --- a/clients/ruby/v1/spec/models/namespace_capabilities_spec.rb +++ b/clients/ruby/v1/spec/models/namespace_capabilities_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/namespace_spec.rb b/clients/ruby/v1/spec/models/namespace_spec.rb index e76c3dde..5b15245d 100644 --- a/clients/ruby/v1/spec/models/namespace_spec.rb +++ b/clients/ruby/v1/spec/models/namespace_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/network_resource_spec.rb b/clients/ruby/v1/spec/models/network_resource_spec.rb index 28566e66..f868b192 100644 --- a/clients/ruby/v1/spec/models/network_resource_spec.rb +++ b/clients/ruby/v1/spec/models/network_resource_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/node_cpu_resources_spec.rb b/clients/ruby/v1/spec/models/node_cpu_resources_spec.rb index 05e82416..6d10c1c4 100644 --- a/clients/ruby/v1/spec/models/node_cpu_resources_spec.rb +++ b/clients/ruby/v1/spec/models/node_cpu_resources_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/node_device_locality_spec.rb b/clients/ruby/v1/spec/models/node_device_locality_spec.rb index 865af790..ac62b029 100644 --- a/clients/ruby/v1/spec/models/node_device_locality_spec.rb +++ b/clients/ruby/v1/spec/models/node_device_locality_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/node_device_resource_spec.rb b/clients/ruby/v1/spec/models/node_device_resource_spec.rb index 43c6234a..f1501da1 100644 --- a/clients/ruby/v1/spec/models/node_device_resource_spec.rb +++ b/clients/ruby/v1/spec/models/node_device_resource_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/node_device_spec.rb b/clients/ruby/v1/spec/models/node_device_spec.rb index f92ebf93..26b73b6c 100644 --- a/clients/ruby/v1/spec/models/node_device_spec.rb +++ b/clients/ruby/v1/spec/models/node_device_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/node_disk_resources_spec.rb b/clients/ruby/v1/spec/models/node_disk_resources_spec.rb index 49ea706c..56c796bf 100644 --- a/clients/ruby/v1/spec/models/node_disk_resources_spec.rb +++ b/clients/ruby/v1/spec/models/node_disk_resources_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/node_drain_update_response_spec.rb b/clients/ruby/v1/spec/models/node_drain_update_response_spec.rb index 82b080cb..2ac7a99e 100644 --- a/clients/ruby/v1/spec/models/node_drain_update_response_spec.rb +++ b/clients/ruby/v1/spec/models/node_drain_update_response_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/node_eligibility_update_response_spec.rb b/clients/ruby/v1/spec/models/node_eligibility_update_response_spec.rb index 23e666f5..1003d44d 100644 --- a/clients/ruby/v1/spec/models/node_eligibility_update_response_spec.rb +++ b/clients/ruby/v1/spec/models/node_eligibility_update_response_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/node_event_spec.rb b/clients/ruby/v1/spec/models/node_event_spec.rb index f7dfb1c2..969ccb73 100644 --- a/clients/ruby/v1/spec/models/node_event_spec.rb +++ b/clients/ruby/v1/spec/models/node_event_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/node_list_stub_spec.rb b/clients/ruby/v1/spec/models/node_list_stub_spec.rb index d0adc041..34cd497d 100644 --- a/clients/ruby/v1/spec/models/node_list_stub_spec.rb +++ b/clients/ruby/v1/spec/models/node_list_stub_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/node_memory_resources_spec.rb b/clients/ruby/v1/spec/models/node_memory_resources_spec.rb index b51cee5c..db451fe6 100644 --- a/clients/ruby/v1/spec/models/node_memory_resources_spec.rb +++ b/clients/ruby/v1/spec/models/node_memory_resources_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/node_purge_response_spec.rb b/clients/ruby/v1/spec/models/node_purge_response_spec.rb index f6991443..0042fb4c 100644 --- a/clients/ruby/v1/spec/models/node_purge_response_spec.rb +++ b/clients/ruby/v1/spec/models/node_purge_response_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/node_reserved_cpu_resources_spec.rb b/clients/ruby/v1/spec/models/node_reserved_cpu_resources_spec.rb index 96d09cee..4623d690 100644 --- a/clients/ruby/v1/spec/models/node_reserved_cpu_resources_spec.rb +++ b/clients/ruby/v1/spec/models/node_reserved_cpu_resources_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/node_reserved_disk_resources_spec.rb b/clients/ruby/v1/spec/models/node_reserved_disk_resources_spec.rb index a3019e17..66e0c3c0 100644 --- a/clients/ruby/v1/spec/models/node_reserved_disk_resources_spec.rb +++ b/clients/ruby/v1/spec/models/node_reserved_disk_resources_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/node_reserved_memory_resources_spec.rb b/clients/ruby/v1/spec/models/node_reserved_memory_resources_spec.rb index bf717937..0adc607a 100644 --- a/clients/ruby/v1/spec/models/node_reserved_memory_resources_spec.rb +++ b/clients/ruby/v1/spec/models/node_reserved_memory_resources_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/node_reserved_network_resources_spec.rb b/clients/ruby/v1/spec/models/node_reserved_network_resources_spec.rb index 1f7d7557..43f074c9 100644 --- a/clients/ruby/v1/spec/models/node_reserved_network_resources_spec.rb +++ b/clients/ruby/v1/spec/models/node_reserved_network_resources_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/node_reserved_resources_spec.rb b/clients/ruby/v1/spec/models/node_reserved_resources_spec.rb index 293dfbc7..4093d286 100644 --- a/clients/ruby/v1/spec/models/node_reserved_resources_spec.rb +++ b/clients/ruby/v1/spec/models/node_reserved_resources_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/node_resources_spec.rb b/clients/ruby/v1/spec/models/node_resources_spec.rb index 3e6de607..3721108a 100644 --- a/clients/ruby/v1/spec/models/node_resources_spec.rb +++ b/clients/ruby/v1/spec/models/node_resources_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/node_score_meta_spec.rb b/clients/ruby/v1/spec/models/node_score_meta_spec.rb index 2a5edab3..87bb67f7 100644 --- a/clients/ruby/v1/spec/models/node_score_meta_spec.rb +++ b/clients/ruby/v1/spec/models/node_score_meta_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/node_spec.rb b/clients/ruby/v1/spec/models/node_spec.rb index 1167dfd2..213cf8ac 100644 --- a/clients/ruby/v1/spec/models/node_spec.rb +++ b/clients/ruby/v1/spec/models/node_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/node_update_drain_request_spec.rb b/clients/ruby/v1/spec/models/node_update_drain_request_spec.rb index 1a7618f4..828f3707 100644 --- a/clients/ruby/v1/spec/models/node_update_drain_request_spec.rb +++ b/clients/ruby/v1/spec/models/node_update_drain_request_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/node_update_eligibility_request_spec.rb b/clients/ruby/v1/spec/models/node_update_eligibility_request_spec.rb index 9f7284f5..e1372d06 100644 --- a/clients/ruby/v1/spec/models/node_update_eligibility_request_spec.rb +++ b/clients/ruby/v1/spec/models/node_update_eligibility_request_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/object_diff_spec.rb b/clients/ruby/v1/spec/models/object_diff_spec.rb index e6c3cf90..043e76b1 100644 --- a/clients/ruby/v1/spec/models/object_diff_spec.rb +++ b/clients/ruby/v1/spec/models/object_diff_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/one_time_token_exchange_request_spec.rb b/clients/ruby/v1/spec/models/one_time_token_exchange_request_spec.rb index 02cdf033..11925f0f 100644 --- a/clients/ruby/v1/spec/models/one_time_token_exchange_request_spec.rb +++ b/clients/ruby/v1/spec/models/one_time_token_exchange_request_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/one_time_token_spec.rb b/clients/ruby/v1/spec/models/one_time_token_spec.rb index c24f3b49..b2e4bbe8 100644 --- a/clients/ruby/v1/spec/models/one_time_token_spec.rb +++ b/clients/ruby/v1/spec/models/one_time_token_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/operator_health_reply_spec.rb b/clients/ruby/v1/spec/models/operator_health_reply_spec.rb index 142d13a6..a5474103 100644 --- a/clients/ruby/v1/spec/models/operator_health_reply_spec.rb +++ b/clients/ruby/v1/spec/models/operator_health_reply_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/parameterized_job_config_spec.rb b/clients/ruby/v1/spec/models/parameterized_job_config_spec.rb index d8305743..3f20cf44 100644 --- a/clients/ruby/v1/spec/models/parameterized_job_config_spec.rb +++ b/clients/ruby/v1/spec/models/parameterized_job_config_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/periodic_config_spec.rb b/clients/ruby/v1/spec/models/periodic_config_spec.rb index 96f3ece3..a0bc1516 100644 --- a/clients/ruby/v1/spec/models/periodic_config_spec.rb +++ b/clients/ruby/v1/spec/models/periodic_config_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/periodic_force_response_spec.rb b/clients/ruby/v1/spec/models/periodic_force_response_spec.rb index a91c4c84..49cc2dc3 100644 --- a/clients/ruby/v1/spec/models/periodic_force_response_spec.rb +++ b/clients/ruby/v1/spec/models/periodic_force_response_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/plan_annotations_spec.rb b/clients/ruby/v1/spec/models/plan_annotations_spec.rb index 569abe5c..b1ac29c1 100644 --- a/clients/ruby/v1/spec/models/plan_annotations_spec.rb +++ b/clients/ruby/v1/spec/models/plan_annotations_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/point_value_spec.rb b/clients/ruby/v1/spec/models/point_value_spec.rb index df2bdca5..c2c80237 100644 --- a/clients/ruby/v1/spec/models/point_value_spec.rb +++ b/clients/ruby/v1/spec/models/point_value_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/port_mapping_spec.rb b/clients/ruby/v1/spec/models/port_mapping_spec.rb index 2d4ec0a0..a7a9a90a 100644 --- a/clients/ruby/v1/spec/models/port_mapping_spec.rb +++ b/clients/ruby/v1/spec/models/port_mapping_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/port_spec.rb b/clients/ruby/v1/spec/models/port_spec.rb index 9355af6d..e7e77b16 100644 --- a/clients/ruby/v1/spec/models/port_spec.rb +++ b/clients/ruby/v1/spec/models/port_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/preemption_config_spec.rb b/clients/ruby/v1/spec/models/preemption_config_spec.rb index d9b0f3e9..28771373 100644 --- a/clients/ruby/v1/spec/models/preemption_config_spec.rb +++ b/clients/ruby/v1/spec/models/preemption_config_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/quota_limit_spec.rb b/clients/ruby/v1/spec/models/quota_limit_spec.rb index f407f140..4c82e6eb 100644 --- a/clients/ruby/v1/spec/models/quota_limit_spec.rb +++ b/clients/ruby/v1/spec/models/quota_limit_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/quota_spec_spec.rb b/clients/ruby/v1/spec/models/quota_spec_spec.rb index 7d5e6ca1..d1dfcc89 100644 --- a/clients/ruby/v1/spec/models/quota_spec_spec.rb +++ b/clients/ruby/v1/spec/models/quota_spec_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/raft_configuration_spec.rb b/clients/ruby/v1/spec/models/raft_configuration_spec.rb index 5da564b9..e66c5a3f 100644 --- a/clients/ruby/v1/spec/models/raft_configuration_spec.rb +++ b/clients/ruby/v1/spec/models/raft_configuration_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/raft_server_spec.rb b/clients/ruby/v1/spec/models/raft_server_spec.rb index be4abf76..d2746b26 100644 --- a/clients/ruby/v1/spec/models/raft_server_spec.rb +++ b/clients/ruby/v1/spec/models/raft_server_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/requested_device_spec.rb b/clients/ruby/v1/spec/models/requested_device_spec.rb index 6715c27a..30283800 100644 --- a/clients/ruby/v1/spec/models/requested_device_spec.rb +++ b/clients/ruby/v1/spec/models/requested_device_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/reschedule_event_spec.rb b/clients/ruby/v1/spec/models/reschedule_event_spec.rb index 7b0e90c9..d71113be 100644 --- a/clients/ruby/v1/spec/models/reschedule_event_spec.rb +++ b/clients/ruby/v1/spec/models/reschedule_event_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/reschedule_policy_spec.rb b/clients/ruby/v1/spec/models/reschedule_policy_spec.rb index 816859a9..92a76d38 100644 --- a/clients/ruby/v1/spec/models/reschedule_policy_spec.rb +++ b/clients/ruby/v1/spec/models/reschedule_policy_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/reschedule_tracker_spec.rb b/clients/ruby/v1/spec/models/reschedule_tracker_spec.rb index f79b0021..cab5828f 100644 --- a/clients/ruby/v1/spec/models/reschedule_tracker_spec.rb +++ b/clients/ruby/v1/spec/models/reschedule_tracker_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/resources_spec.rb b/clients/ruby/v1/spec/models/resources_spec.rb index 7617751e..131e51df 100644 --- a/clients/ruby/v1/spec/models/resources_spec.rb +++ b/clients/ruby/v1/spec/models/resources_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/restart_policy_spec.rb b/clients/ruby/v1/spec/models/restart_policy_spec.rb index 920c628b..1c1e4ce0 100644 --- a/clients/ruby/v1/spec/models/restart_policy_spec.rb +++ b/clients/ruby/v1/spec/models/restart_policy_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/sampled_value_spec.rb b/clients/ruby/v1/spec/models/sampled_value_spec.rb index 35d3c1c0..8b393ce4 100644 --- a/clients/ruby/v1/spec/models/sampled_value_spec.rb +++ b/clients/ruby/v1/spec/models/sampled_value_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/scaling_event_spec.rb b/clients/ruby/v1/spec/models/scaling_event_spec.rb index db5a42ef..63ea3583 100644 --- a/clients/ruby/v1/spec/models/scaling_event_spec.rb +++ b/clients/ruby/v1/spec/models/scaling_event_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/scaling_policy_list_stub_spec.rb b/clients/ruby/v1/spec/models/scaling_policy_list_stub_spec.rb index b41d46dc..8c66a70f 100644 --- a/clients/ruby/v1/spec/models/scaling_policy_list_stub_spec.rb +++ b/clients/ruby/v1/spec/models/scaling_policy_list_stub_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/scaling_policy_spec.rb b/clients/ruby/v1/spec/models/scaling_policy_spec.rb index a4343632..3531c47a 100644 --- a/clients/ruby/v1/spec/models/scaling_policy_spec.rb +++ b/clients/ruby/v1/spec/models/scaling_policy_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/scaling_request_spec.rb b/clients/ruby/v1/spec/models/scaling_request_spec.rb index 250367db..8f902604 100644 --- a/clients/ruby/v1/spec/models/scaling_request_spec.rb +++ b/clients/ruby/v1/spec/models/scaling_request_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/scheduler_configuration_response_spec.rb b/clients/ruby/v1/spec/models/scheduler_configuration_response_spec.rb index b6382c48..2e244a04 100644 --- a/clients/ruby/v1/spec/models/scheduler_configuration_response_spec.rb +++ b/clients/ruby/v1/spec/models/scheduler_configuration_response_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/scheduler_configuration_spec.rb b/clients/ruby/v1/spec/models/scheduler_configuration_spec.rb index 09e6f0f1..3e4f01c0 100644 --- a/clients/ruby/v1/spec/models/scheduler_configuration_spec.rb +++ b/clients/ruby/v1/spec/models/scheduler_configuration_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/scheduler_set_configuration_response_spec.rb b/clients/ruby/v1/spec/models/scheduler_set_configuration_response_spec.rb index 5c75fdf7..9d47e2fb 100644 --- a/clients/ruby/v1/spec/models/scheduler_set_configuration_response_spec.rb +++ b/clients/ruby/v1/spec/models/scheduler_set_configuration_response_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/search_request_spec.rb b/clients/ruby/v1/spec/models/search_request_spec.rb index 2a729dd8..84b3582d 100644 --- a/clients/ruby/v1/spec/models/search_request_spec.rb +++ b/clients/ruby/v1/spec/models/search_request_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/search_response_spec.rb b/clients/ruby/v1/spec/models/search_response_spec.rb index 7bb4fab2..2429a7c6 100644 --- a/clients/ruby/v1/spec/models/search_response_spec.rb +++ b/clients/ruby/v1/spec/models/search_response_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/server_health_spec.rb b/clients/ruby/v1/spec/models/server_health_spec.rb index 420e00fa..bd4be07b 100644 --- a/clients/ruby/v1/spec/models/server_health_spec.rb +++ b/clients/ruby/v1/spec/models/server_health_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/service_check_spec.rb b/clients/ruby/v1/spec/models/service_check_spec.rb index 64e261cb..38c6a7e7 100644 --- a/clients/ruby/v1/spec/models/service_check_spec.rb +++ b/clients/ruby/v1/spec/models/service_check_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/service_registration_spec.rb b/clients/ruby/v1/spec/models/service_registration_spec.rb index 77156b66..fe800d74 100644 --- a/clients/ruby/v1/spec/models/service_registration_spec.rb +++ b/clients/ruby/v1/spec/models/service_registration_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/service_spec.rb b/clients/ruby/v1/spec/models/service_spec.rb index 0f8b729f..bcc6aad1 100644 --- a/clients/ruby/v1/spec/models/service_spec.rb +++ b/clients/ruby/v1/spec/models/service_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/sidecar_task_spec.rb b/clients/ruby/v1/spec/models/sidecar_task_spec.rb index 01868f9d..753512bc 100644 --- a/clients/ruby/v1/spec/models/sidecar_task_spec.rb +++ b/clients/ruby/v1/spec/models/sidecar_task_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/spread_spec.rb b/clients/ruby/v1/spec/models/spread_spec.rb index 92c59c89..bd10b09b 100644 --- a/clients/ruby/v1/spec/models/spread_spec.rb +++ b/clients/ruby/v1/spec/models/spread_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/spread_target_spec.rb b/clients/ruby/v1/spec/models/spread_target_spec.rb index 8a550da0..1ce743ed 100644 --- a/clients/ruby/v1/spec/models/spread_target_spec.rb +++ b/clients/ruby/v1/spec/models/spread_target_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/task_artifact_spec.rb b/clients/ruby/v1/spec/models/task_artifact_spec.rb index e18c0337..e3bbd123 100644 --- a/clients/ruby/v1/spec/models/task_artifact_spec.rb +++ b/clients/ruby/v1/spec/models/task_artifact_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/task_csi_plugin_config_spec.rb b/clients/ruby/v1/spec/models/task_csi_plugin_config_spec.rb index 55781c68..3091716a 100644 --- a/clients/ruby/v1/spec/models/task_csi_plugin_config_spec.rb +++ b/clients/ruby/v1/spec/models/task_csi_plugin_config_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/task_diff_spec.rb b/clients/ruby/v1/spec/models/task_diff_spec.rb index 97c9d3d7..0c23d109 100644 --- a/clients/ruby/v1/spec/models/task_diff_spec.rb +++ b/clients/ruby/v1/spec/models/task_diff_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/task_event_spec.rb b/clients/ruby/v1/spec/models/task_event_spec.rb index fde24a2d..8c68f386 100644 --- a/clients/ruby/v1/spec/models/task_event_spec.rb +++ b/clients/ruby/v1/spec/models/task_event_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/task_group_diff_spec.rb b/clients/ruby/v1/spec/models/task_group_diff_spec.rb index f820dc35..d4995988 100644 --- a/clients/ruby/v1/spec/models/task_group_diff_spec.rb +++ b/clients/ruby/v1/spec/models/task_group_diff_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/task_group_scale_status_spec.rb b/clients/ruby/v1/spec/models/task_group_scale_status_spec.rb index 2257a2bc..7b4961d6 100644 --- a/clients/ruby/v1/spec/models/task_group_scale_status_spec.rb +++ b/clients/ruby/v1/spec/models/task_group_scale_status_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/task_group_spec.rb b/clients/ruby/v1/spec/models/task_group_spec.rb index 1d084b80..9e5b9316 100644 --- a/clients/ruby/v1/spec/models/task_group_spec.rb +++ b/clients/ruby/v1/spec/models/task_group_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/task_group_summary_spec.rb b/clients/ruby/v1/spec/models/task_group_summary_spec.rb index b19bfc7f..8b873baa 100644 --- a/clients/ruby/v1/spec/models/task_group_summary_spec.rb +++ b/clients/ruby/v1/spec/models/task_group_summary_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/task_handle_spec.rb b/clients/ruby/v1/spec/models/task_handle_spec.rb index be51332d..c34f43c0 100644 --- a/clients/ruby/v1/spec/models/task_handle_spec.rb +++ b/clients/ruby/v1/spec/models/task_handle_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/task_lifecycle_spec.rb b/clients/ruby/v1/spec/models/task_lifecycle_spec.rb index 6f638ebb..11537026 100644 --- a/clients/ruby/v1/spec/models/task_lifecycle_spec.rb +++ b/clients/ruby/v1/spec/models/task_lifecycle_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/task_spec.rb b/clients/ruby/v1/spec/models/task_spec.rb index db2af27a..b7871e84 100644 --- a/clients/ruby/v1/spec/models/task_spec.rb +++ b/clients/ruby/v1/spec/models/task_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/task_state_spec.rb b/clients/ruby/v1/spec/models/task_state_spec.rb index 5e97cce1..472e151c 100644 --- a/clients/ruby/v1/spec/models/task_state_spec.rb +++ b/clients/ruby/v1/spec/models/task_state_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/template_spec.rb b/clients/ruby/v1/spec/models/template_spec.rb index ff9c1aac..9edb0f14 100644 --- a/clients/ruby/v1/spec/models/template_spec.rb +++ b/clients/ruby/v1/spec/models/template_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/update_strategy_spec.rb b/clients/ruby/v1/spec/models/update_strategy_spec.rb index 78bc9f55..a14f6fbf 100644 --- a/clients/ruby/v1/spec/models/update_strategy_spec.rb +++ b/clients/ruby/v1/spec/models/update_strategy_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/vault_spec.rb b/clients/ruby/v1/spec/models/vault_spec.rb index 2b0da1e3..d3e56a34 100644 --- a/clients/ruby/v1/spec/models/vault_spec.rb +++ b/clients/ruby/v1/spec/models/vault_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/volume_mount_spec.rb b/clients/ruby/v1/spec/models/volume_mount_spec.rb index f31ef40b..bf4826de 100644 --- a/clients/ruby/v1/spec/models/volume_mount_spec.rb +++ b/clients/ruby/v1/spec/models/volume_mount_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/volume_request_spec.rb b/clients/ruby/v1/spec/models/volume_request_spec.rb index bb70f898..2f59f457 100644 --- a/clients/ruby/v1/spec/models/volume_request_spec.rb +++ b/clients/ruby/v1/spec/models/volume_request_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/models/wait_config_spec.rb b/clients/ruby/v1/spec/models/wait_config_spec.rb index 12c3f4ee..1c153efb 100644 --- a/clients/ruby/v1/spec/models/wait_config_spec.rb +++ b/clients/ruby/v1/spec/models/wait_config_spec.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/ruby/v1/spec/spec_helper.rb b/clients/ruby/v1/spec/spec_helper.rb index 92c8590f..041b6191 100644 --- a/clients/ruby/v1/spec/spec_helper.rb +++ b/clients/ruby/v1/spec/spec_helper.rb @@ -6,7 +6,7 @@ The version of the OpenAPI document: 1.1.4 Contact: support@hashicorp.com Generated by: https://openapi-generator.tech -OpenAPI Generator version: 5.2.0 +OpenAPI Generator version: 5.4.0 =end diff --git a/clients/rust/hyper/v1/.openapi-generator/VERSION b/clients/rust/hyper/v1/.openapi-generator/VERSION index 7cbea073..1e20ec35 100644 --- a/clients/rust/hyper/v1/.openapi-generator/VERSION +++ b/clients/rust/hyper/v1/.openapi-generator/VERSION @@ -1 +1 @@ -5.2.0 \ No newline at end of file +5.4.0 \ No newline at end of file diff --git a/clients/rust/hyper/v1/Cargo.toml b/clients/rust/hyper/v1/Cargo.toml index ffbbb8a4..6f54c560 100644 --- a/clients/rust/hyper/v1/Cargo.toml +++ b/clients/rust/hyper/v1/Cargo.toml @@ -9,10 +9,12 @@ serde = "^1.0" serde_derive = "^1.0" serde_json = "^1.0" url = "^2.2" -hyper = "~0.11" +hyper = { version = "~0.14", features = ["full"] } +hyper-tls = "~0.5" +http = "~0.2" serde_yaml = "0.7" base64 = "~0.7.0" -futures = "0.1.23" +futures = "^0.3" [dev-dependencies] tokio-core = "*" diff --git a/clients/rust/hyper/v1/docs/ACLApi.md b/clients/rust/hyper/v1/docs/ACLApi.md index 95891832..d6f0071b 100644 --- a/clients/rust/hyper/v1/docs/ACLApi.md +++ b/clients/rust/hyper/v1/docs/ACLApi.md @@ -307,7 +307,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **policy_name** | **String** | The ACL policy name. | [required] | -**acl_policy** | [**AclPolicy**](AclPolicy.md) | | [required] | +**acl_policy** | Option<[**AclPolicy**](AclPolicy.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -340,7 +340,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **token_accessor** | **String** | The token accessor ID. | [required] | -**acl_token** | [**AclToken**](AclToken.md) | | [required] | +**acl_token** | Option<[**AclToken**](AclToken.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -403,7 +403,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- -**one_time_token_exchange_request** | [**OneTimeTokenExchangeRequest**](OneTimeTokenExchangeRequest.md) | | [required] | +**one_time_token_exchange_request** | Option<[**OneTimeTokenExchangeRequest**](OneTimeTokenExchangeRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | diff --git a/clients/rust/hyper/v1/docs/DeploymentsApi.md b/clients/rust/hyper/v1/docs/DeploymentsApi.md index a906f5bc..35427088 100644 --- a/clients/rust/hyper/v1/docs/DeploymentsApi.md +++ b/clients/rust/hyper/v1/docs/DeploymentsApi.md @@ -136,7 +136,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **deployment_id** | **String** | Deployment ID. | [required] | -**deployment_alloc_health_request** | [**DeploymentAllocHealthRequest**](DeploymentAllocHealthRequest.md) | | [required] | +**deployment_alloc_health_request** | Option<[**DeploymentAllocHealthRequest**](DeploymentAllocHealthRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -201,7 +201,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **deployment_id** | **String** | Deployment ID. | [required] | -**deployment_pause_request** | [**DeploymentPauseRequest**](DeploymentPauseRequest.md) | | [required] | +**deployment_pause_request** | Option<[**DeploymentPauseRequest**](DeploymentPauseRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -234,7 +234,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **deployment_id** | **String** | Deployment ID. | [required] | -**deployment_promote_request** | [**DeploymentPromoteRequest**](DeploymentPromoteRequest.md) | | [required] | +**deployment_promote_request** | Option<[**DeploymentPromoteRequest**](DeploymentPromoteRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -267,7 +267,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **deployment_id** | **String** | Deployment ID. | [required] | -**deployment_unblock_request** | [**DeploymentUnblockRequest**](DeploymentUnblockRequest.md) | | [required] | +**deployment_unblock_request** | Option<[**DeploymentUnblockRequest**](DeploymentUnblockRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | diff --git a/clients/rust/hyper/v1/docs/EnterpriseApi.md b/clients/rust/hyper/v1/docs/EnterpriseApi.md index 74bbe6de..8bb89cec 100644 --- a/clients/rust/hyper/v1/docs/EnterpriseApi.md +++ b/clients/rust/hyper/v1/docs/EnterpriseApi.md @@ -22,7 +22,7 @@ Method | HTTP request | Description Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- -**quota_spec** | [**QuotaSpec**](QuotaSpec.md) | | [required] | +**quota_spec** | Option<[**QuotaSpec**](QuotaSpec.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -160,7 +160,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **spec_name** | **String** | The quota spec identifier. | [required] | -**quota_spec** | [**QuotaSpec**](QuotaSpec.md) | | [required] | +**quota_spec** | Option<[**QuotaSpec**](QuotaSpec.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | diff --git a/clients/rust/hyper/v1/docs/JobsApi.md b/clients/rust/hyper/v1/docs/JobsApi.md index 4da1dd64..e70bbb4b 100644 --- a/clients/rust/hyper/v1/docs/JobsApi.md +++ b/clients/rust/hyper/v1/docs/JobsApi.md @@ -408,7 +408,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **job_name** | **String** | The job identifier. | [required] | -**job_register_request** | [**JobRegisterRequest**](JobRegisterRequest.md) | | [required] | +**job_register_request** | Option<[**JobRegisterRequest**](JobRegisterRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -441,7 +441,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **job_name** | **String** | The job identifier. | [required] | -**job_dispatch_request** | [**JobDispatchRequest**](JobDispatchRequest.md) | | [required] | +**job_dispatch_request** | Option<[**JobDispatchRequest**](JobDispatchRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -474,7 +474,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **job_name** | **String** | The job identifier. | [required] | -**job_evaluate_request** | [**JobEvaluateRequest**](JobEvaluateRequest.md) | | [required] | +**job_evaluate_request** | Option<[**JobEvaluateRequest**](JobEvaluateRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -506,7 +506,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- -**jobs_parse_request** | [**JobsParseRequest**](JobsParseRequest.md) | | [required] | +**jobs_parse_request** | Option<[**JobsParseRequest**](JobsParseRequest.md)> | | [required] | ### Return type @@ -567,7 +567,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **job_name** | **String** | The job identifier. | [required] | -**job_plan_request** | [**JobPlanRequest**](JobPlanRequest.md) | | [required] | +**job_plan_request** | Option<[**JobPlanRequest**](JobPlanRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -600,7 +600,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **job_name** | **String** | The job identifier. | [required] | -**job_revert_request** | [**JobRevertRequest**](JobRevertRequest.md) | | [required] | +**job_revert_request** | Option<[**JobRevertRequest**](JobRevertRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -633,7 +633,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **job_name** | **String** | The job identifier. | [required] | -**scaling_request** | [**ScalingRequest**](ScalingRequest.md) | | [required] | +**scaling_request** | Option<[**ScalingRequest**](ScalingRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -666,7 +666,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **job_name** | **String** | The job identifier. | [required] | -**job_stability_request** | [**JobStabilityRequest**](JobStabilityRequest.md) | | [required] | +**job_stability_request** | Option<[**JobStabilityRequest**](JobStabilityRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -698,7 +698,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- -**job_validate_request** | [**JobValidateRequest**](JobValidateRequest.md) | | [required] | +**job_validate_request** | Option<[**JobValidateRequest**](JobValidateRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -730,7 +730,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- -**job_register_request** | [**JobRegisterRequest**](JobRegisterRequest.md) | | [required] | +**job_register_request** | Option<[**JobRegisterRequest**](JobRegisterRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | diff --git a/clients/rust/hyper/v1/docs/NamespacesApi.md b/clients/rust/hyper/v1/docs/NamespacesApi.md index 31be9ba7..6ac16b91 100644 --- a/clients/rust/hyper/v1/docs/NamespacesApi.md +++ b/clients/rust/hyper/v1/docs/NamespacesApi.md @@ -159,7 +159,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **namespace_name** | **String** | The namespace identifier. | [required] | -**namespace2** | [**Namespace**](Namespace.md) | | [required] | +**namespace2** | Option<[**Namespace**](Namespace.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | diff --git a/clients/rust/hyper/v1/docs/NodesApi.md b/clients/rust/hyper/v1/docs/NodesApi.md index a4ca4975..e70e2d73 100644 --- a/clients/rust/hyper/v1/docs/NodesApi.md +++ b/clients/rust/hyper/v1/docs/NodesApi.md @@ -135,7 +135,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **node_id** | **String** | The ID of the node. | [required] | -**node_update_drain_request** | [**NodeUpdateDrainRequest**](NodeUpdateDrainRequest.md) | | [required] | +**node_update_drain_request** | Option<[**NodeUpdateDrainRequest**](NodeUpdateDrainRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **index** | Option<**i32**> | If set, wait until query exceeds given index. Must be provided with WaitParam. | | @@ -173,7 +173,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **node_id** | **String** | The ID of the node. | [required] | -**node_update_eligibility_request** | [**NodeUpdateEligibilityRequest**](NodeUpdateEligibilityRequest.md) | | [required] | +**node_update_eligibility_request** | Option<[**NodeUpdateEligibilityRequest**](NodeUpdateEligibilityRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **index** | Option<**i32**> | If set, wait until query exceeds given index. Must be provided with WaitParam. | | diff --git a/clients/rust/hyper/v1/docs/OperatorApi.md b/clients/rust/hyper/v1/docs/OperatorApi.md index fab92efc..60754102 100644 --- a/clients/rust/hyper/v1/docs/OperatorApi.md +++ b/clients/rust/hyper/v1/docs/OperatorApi.md @@ -199,7 +199,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- -**scheduler_configuration** | [**SchedulerConfiguration**](SchedulerConfiguration.md) | | [required] | +**scheduler_configuration** | Option<[**SchedulerConfiguration**](SchedulerConfiguration.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -231,7 +231,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- -**autopilot_configuration** | [**AutopilotConfiguration**](AutopilotConfiguration.md) | | [required] | +**autopilot_configuration** | Option<[**AutopilotConfiguration**](AutopilotConfiguration.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | diff --git a/clients/rust/hyper/v1/docs/SearchApi.md b/clients/rust/hyper/v1/docs/SearchApi.md index a12be2ad..f70ad082 100644 --- a/clients/rust/hyper/v1/docs/SearchApi.md +++ b/clients/rust/hyper/v1/docs/SearchApi.md @@ -19,7 +19,7 @@ Method | HTTP request | Description Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- -**fuzzy_search_request** | [**FuzzySearchRequest**](FuzzySearchRequest.md) | | [required] | +**fuzzy_search_request** | Option<[**FuzzySearchRequest**](FuzzySearchRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **index** | Option<**i32**> | If set, wait until query exceeds given index. Must be provided with WaitParam. | | @@ -56,7 +56,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- -**search_request** | [**SearchRequest**](SearchRequest.md) | | [required] | +**search_request** | Option<[**SearchRequest**](SearchRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **index** | Option<**i32**> | If set, wait until query exceeds given index. Must be provided with WaitParam. | | diff --git a/clients/rust/hyper/v1/docs/VolumesApi.md b/clients/rust/hyper/v1/docs/VolumesApi.md index 2fd1564b..d597dcf1 100644 --- a/clients/rust/hyper/v1/docs/VolumesApi.md +++ b/clients/rust/hyper/v1/docs/VolumesApi.md @@ -30,7 +30,7 @@ Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **volume_id** | **String** | Volume unique identifier. | [required] | **action** | **String** | The action to perform on the Volume (create, detach, delete). | [required] | -**csi_volume_create_request** | [**CsiVolumeCreateRequest**](CsiVolumeCreateRequest.md) | | [required] | +**csi_volume_create_request** | Option<[**CsiVolumeCreateRequest**](CsiVolumeCreateRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -312,7 +312,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- -**csi_snapshot_create_request** | [**CsiSnapshotCreateRequest**](CsiSnapshotCreateRequest.md) | | [required] | +**csi_snapshot_create_request** | Option<[**CsiSnapshotCreateRequest**](CsiSnapshotCreateRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -344,7 +344,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- -**csi_volume_register_request** | [**CsiVolumeRegisterRequest**](CsiVolumeRegisterRequest.md) | | [required] | +**csi_volume_register_request** | Option<[**CsiVolumeRegisterRequest**](CsiVolumeRegisterRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -377,7 +377,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **volume_id** | **String** | Volume unique identifier. | [required] | -**csi_volume_register_request** | [**CsiVolumeRegisterRequest**](CsiVolumeRegisterRequest.md) | | [required] | +**csi_volume_register_request** | Option<[**CsiVolumeRegisterRequest**](CsiVolumeRegisterRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | diff --git a/clients/rust/hyper/v1/src/apis/acl_api.rs b/clients/rust/hyper/v1/src/apis/acl_api.rs index 3c29fcf9..db59cb9b 100644 --- a/clients/rust/hyper/v1/src/apis/acl_api.rs +++ b/clients/rust/hyper/v1/src/apis/acl_api.rs @@ -10,21 +10,23 @@ use std::rc::Rc; use std::borrow::Borrow; +use std::pin::Pin; #[allow(unused_imports)] use std::option::Option; use hyper; -use serde_json; use futures::Future; use super::{Error, configuration}; use super::request as __internal_request; -pub struct ACLApiClient { +pub struct ACLApiClient + where C: Clone + std::marker::Send + Sync + 'static { configuration: Rc>, } -impl ACLApiClient { +impl ACLApiClient + where C: Clone + std::marker::Send + Sync { pub fn new(configuration: Rc>) -> ACLApiClient { ACLApiClient { configuration, @@ -33,23 +35,25 @@ impl ACLApiClient { } pub trait ACLApi { - fn delete_acl_policy(&self, policy_name: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; - fn delete_acl_token(&self, token_accessor: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; - fn get_acl_policies(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>>; - fn get_acl_policy(&self, policy_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>>; - fn get_acl_token(&self, token_accessor: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>>; - fn get_acl_token_self(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>>; - fn get_acl_tokens(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>>; - fn post_acl_bootstrap(&self, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; - fn post_acl_policy(&self, policy_name: &str, acl_policy: crate::models::AclPolicy, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; - fn post_acl_token(&self, token_accessor: &str, acl_token: crate::models::AclToken, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; - fn post_acl_token_onetime(&self, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; - fn post_acl_token_onetime_exchange(&self, one_time_token_exchange_request: crate::models::OneTimeTokenExchangeRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; + fn delete_acl_policy(&self, policy_name: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; + fn delete_acl_token(&self, token_accessor: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; + fn get_acl_policies(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>>; + fn get_acl_policy(&self, policy_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>>; + fn get_acl_token(&self, token_accessor: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>>; + fn get_acl_token_self(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>>; + fn get_acl_tokens(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>>; + fn post_acl_bootstrap(&self, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; + fn post_acl_policy(&self, policy_name: &str, acl_policy: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; + fn post_acl_token(&self, token_accessor: &str, acl_token: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; + fn post_acl_token_onetime(&self, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; + fn post_acl_token_onetime_exchange(&self, one_time_token_exchange_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; } -implACLApi for ACLApiClient { - fn delete_acl_policy(&self, policy_name: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Delete, "/acl/policy/{policyName}".to_string()) +implACLApi for ACLApiClient + where C: Clone + std::marker::Send + Sync { + #[allow(unused_mut)] + fn delete_acl_policy(&self, policy_name: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::DELETE, "/acl/policy/{policyName}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -57,13 +61,16 @@ implACLApi for ACLApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } req = req.with_path_param("policyName".to_string(), policy_name.to_string()); if let Some(param_value) = x_nomad_token { @@ -74,8 +81,9 @@ implACLApi for ACLApiClient { req.execute(self.configuration.borrow()) } - fn delete_acl_token(&self, token_accessor: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Delete, "/acl/token/{tokenAccessor}".to_string()) + #[allow(unused_mut)] + fn delete_acl_token(&self, token_accessor: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::DELETE, "/acl/token/{tokenAccessor}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -83,13 +91,16 @@ implACLApi for ACLApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } req = req.with_path_param("tokenAccessor".to_string(), token_accessor.to_string()); if let Some(param_value) = x_nomad_token { @@ -100,8 +111,9 @@ implACLApi for ACLApiClient { req.execute(self.configuration.borrow()) } - fn get_acl_policies(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/acl/policies".to_string()) + #[allow(unused_mut)] + fn get_acl_policies(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/acl/policies".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -109,25 +121,32 @@ implACLApi for ACLApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } if let Some(param_value) = index { req = req.with_header_param("index".to_string(), param_value.to_string()); @@ -139,8 +158,9 @@ implACLApi for ACLApiClient { req.execute(self.configuration.borrow()) } - fn get_acl_policy(&self, policy_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/acl/policy/{policyName}".to_string()) + #[allow(unused_mut)] + fn get_acl_policy(&self, policy_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/acl/policy/{policyName}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -148,25 +168,32 @@ implACLApi for ACLApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } req = req.with_path_param("policyName".to_string(), policy_name.to_string()); if let Some(param_value) = index { @@ -179,8 +206,9 @@ implACLApi for ACLApiClient { req.execute(self.configuration.borrow()) } - fn get_acl_token(&self, token_accessor: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/acl/token/{tokenAccessor}".to_string()) + #[allow(unused_mut)] + fn get_acl_token(&self, token_accessor: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/acl/token/{tokenAccessor}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -188,25 +216,32 @@ implACLApi for ACLApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } req = req.with_path_param("tokenAccessor".to_string(), token_accessor.to_string()); if let Some(param_value) = index { @@ -219,8 +254,9 @@ implACLApi for ACLApiClient { req.execute(self.configuration.borrow()) } - fn get_acl_token_self(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/acl/token".to_string()) + #[allow(unused_mut)] + fn get_acl_token_self(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/acl/token".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -228,25 +264,32 @@ implACLApi for ACLApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } if let Some(param_value) = index { req = req.with_header_param("index".to_string(), param_value.to_string()); @@ -258,8 +301,9 @@ implACLApi for ACLApiClient { req.execute(self.configuration.borrow()) } - fn get_acl_tokens(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/acl/tokens".to_string()) + #[allow(unused_mut)] + fn get_acl_tokens(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/acl/tokens".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -267,25 +311,32 @@ implACLApi for ACLApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } if let Some(param_value) = index { req = req.with_header_param("index".to_string(), param_value.to_string()); @@ -297,8 +348,9 @@ implACLApi for ACLApiClient { req.execute(self.configuration.borrow()) } - fn post_acl_bootstrap(&self, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/acl/bootstrap".to_string()) + #[allow(unused_mut)] + fn post_acl_bootstrap(&self, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/acl/bootstrap".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -306,13 +358,16 @@ implACLApi for ACLApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } if let Some(param_value) = x_nomad_token { req = req.with_header_param("X-Nomad-Token".to_string(), param_value.to_string()); @@ -321,8 +376,9 @@ implACLApi for ACLApiClient { req.execute(self.configuration.borrow()) } - fn post_acl_policy(&self, policy_name: &str, acl_policy: crate::models::AclPolicy, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/acl/policy/{policyName}".to_string()) + #[allow(unused_mut)] + fn post_acl_policy(&self, policy_name: &str, acl_policy: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/acl/policy/{policyName}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -330,13 +386,16 @@ implACLApi for ACLApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } req = req.with_path_param("policyName".to_string(), policy_name.to_string()); if let Some(param_value) = x_nomad_token { @@ -348,8 +407,9 @@ implACLApi for ACLApiClient { req.execute(self.configuration.borrow()) } - fn post_acl_token(&self, token_accessor: &str, acl_token: crate::models::AclToken, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/acl/token/{tokenAccessor}".to_string()) + #[allow(unused_mut)] + fn post_acl_token(&self, token_accessor: &str, acl_token: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/acl/token/{tokenAccessor}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -357,13 +417,16 @@ implACLApi for ACLApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } req = req.with_path_param("tokenAccessor".to_string(), token_accessor.to_string()); if let Some(param_value) = x_nomad_token { @@ -374,8 +437,9 @@ implACLApi for ACLApiClient { req.execute(self.configuration.borrow()) } - fn post_acl_token_onetime(&self, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/acl/token/onetime".to_string()) + #[allow(unused_mut)] + fn post_acl_token_onetime(&self, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/acl/token/onetime".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -383,13 +447,16 @@ implACLApi for ACLApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } if let Some(param_value) = x_nomad_token { req = req.with_header_param("X-Nomad-Token".to_string(), param_value.to_string()); @@ -398,8 +465,9 @@ implACLApi for ACLApiClient { req.execute(self.configuration.borrow()) } - fn post_acl_token_onetime_exchange(&self, one_time_token_exchange_request: crate::models::OneTimeTokenExchangeRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/acl/token/onetime/exchange".to_string()) + #[allow(unused_mut)] + fn post_acl_token_onetime_exchange(&self, one_time_token_exchange_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/acl/token/onetime/exchange".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -407,13 +475,16 @@ implACLApi for ACLApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } if let Some(param_value) = x_nomad_token { req = req.with_header_param("X-Nomad-Token".to_string(), param_value.to_string()); diff --git a/clients/rust/hyper/v1/src/apis/allocations_api.rs b/clients/rust/hyper/v1/src/apis/allocations_api.rs index 975e0a2d..ef44f46d 100644 --- a/clients/rust/hyper/v1/src/apis/allocations_api.rs +++ b/clients/rust/hyper/v1/src/apis/allocations_api.rs @@ -10,21 +10,23 @@ use std::rc::Rc; use std::borrow::Borrow; +use std::pin::Pin; #[allow(unused_imports)] use std::option::Option; use hyper; -use serde_json; use futures::Future; use super::{Error, configuration}; use super::request as __internal_request; -pub struct AllocationsApiClient { +pub struct AllocationsApiClient + where C: Clone + std::marker::Send + Sync + 'static { configuration: Rc>, } -impl AllocationsApiClient { +impl AllocationsApiClient + where C: Clone + std::marker::Send + Sync { pub fn new(configuration: Rc>) -> AllocationsApiClient { AllocationsApiClient { configuration, @@ -33,15 +35,17 @@ impl AllocationsApiClient { } pub trait AllocationsApi { - fn get_allocation(&self, alloc_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>>; - fn get_allocation_services(&self, alloc_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>>; - fn get_allocations(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, resources: Option, task_states: Option) -> Box, Error = Error>>; - fn post_allocation_stop(&self, alloc_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, no_shutdown_delay: Option) -> Box>>; + fn get_allocation(&self, alloc_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>>; + fn get_allocation_services(&self, alloc_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>>; + fn get_allocations(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, resources: Option, task_states: Option) -> Pin, Error>>>>; + fn post_allocation_stop(&self, alloc_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, no_shutdown_delay: Option) -> Pin>>>; } -implAllocationsApi for AllocationsApiClient { - fn get_allocation(&self, alloc_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/allocation/{allocID}".to_string()) +implAllocationsApi for AllocationsApiClient + where C: Clone + std::marker::Send + Sync { + #[allow(unused_mut)] + fn get_allocation(&self, alloc_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/allocation/{allocID}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -49,25 +53,32 @@ implAllocationsApi for AllocationsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } req = req.with_path_param("allocID".to_string(), alloc_id.to_string()); if let Some(param_value) = index { @@ -80,8 +91,9 @@ implAllocationsApi for AllocationsApiClient { req.execute(self.configuration.borrow()) } - fn get_allocation_services(&self, alloc_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/allocation/{allocID}/services".to_string()) + #[allow(unused_mut)] + fn get_allocation_services(&self, alloc_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/allocation/{allocID}/services".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -89,25 +101,32 @@ implAllocationsApi for AllocationsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } req = req.with_path_param("allocID".to_string(), alloc_id.to_string()); if let Some(param_value) = index { @@ -120,8 +139,9 @@ implAllocationsApi for AllocationsApiClient { req.execute(self.configuration.borrow()) } - fn get_allocations(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, resources: Option, task_states: Option) -> Box, Error = Error>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/allocations".to_string()) + #[allow(unused_mut)] + fn get_allocations(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, resources: Option, task_states: Option) -> Pin, Error>>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/allocations".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -129,31 +149,40 @@ implAllocationsApi for AllocationsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } if let Some(ref s) = resources { - req = req.with_query_param("resources".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("resources".to_string(), query_value); } if let Some(ref s) = task_states { - req = req.with_query_param("task_states".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("task_states".to_string(), query_value); } if let Some(param_value) = index { req = req.with_header_param("index".to_string(), param_value.to_string()); @@ -165,8 +194,9 @@ implAllocationsApi for AllocationsApiClient { req.execute(self.configuration.borrow()) } - fn post_allocation_stop(&self, alloc_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, no_shutdown_delay: Option) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/allocation/{allocID}/stop".to_string()) + #[allow(unused_mut)] + fn post_allocation_stop(&self, alloc_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, no_shutdown_delay: Option) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/allocation/{allocID}/stop".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -174,28 +204,36 @@ implAllocationsApi for AllocationsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } if let Some(ref s) = no_shutdown_delay { - req = req.with_query_param("no_shutdown_delay".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("no_shutdown_delay".to_string(), query_value); } req = req.with_path_param("allocID".to_string(), alloc_id.to_string()); if let Some(param_value) = index { diff --git a/clients/rust/hyper/v1/src/apis/client.rs b/clients/rust/hyper/v1/src/apis/client.rs index 828dfae2..6acfe9be 100644 --- a/clients/rust/hyper/v1/src/apis/client.rs +++ b/clients/rust/hyper/v1/src/apis/client.rs @@ -24,7 +24,8 @@ pub struct APIClient { } impl APIClient { - pub fn new(configuration: Configuration) -> APIClient { + pub fn new(configuration: Configuration) -> APIClient + where C: Clone + std::marker::Send + Sync + 'static { let rc = Rc::new(configuration); APIClient { diff --git a/clients/rust/hyper/v1/src/apis/configuration.rs b/clients/rust/hyper/v1/src/apis/configuration.rs index 849509b3..57e82d3c 100644 --- a/clients/rust/hyper/v1/src/apis/configuration.rs +++ b/clients/rust/hyper/v1/src/apis/configuration.rs @@ -10,7 +10,8 @@ use hyper; -pub struct Configuration { +pub struct Configuration + where C: Clone + std::marker::Send + Sync + 'static { pub base_path: String, pub user_agent: Option, pub client: hyper::client::Client, @@ -27,12 +28,13 @@ pub struct ApiKey { pub key: String, } -impl Configuration { +impl Configuration + where C: Clone + std::marker::Send + Sync { pub fn new(client: hyper::client::Client) -> Configuration { Configuration { base_path: "https://127.0.0.1:4646/v1".to_owned(), user_agent: Some("OpenAPI-Generator/1.1.4/rust".to_owned()), - client: client, + client, basic_auth: None, oauth_access_token: None, api_key: None, diff --git a/clients/rust/hyper/v1/src/apis/deployments_api.rs b/clients/rust/hyper/v1/src/apis/deployments_api.rs index 69c02e71..7bac8e95 100644 --- a/clients/rust/hyper/v1/src/apis/deployments_api.rs +++ b/clients/rust/hyper/v1/src/apis/deployments_api.rs @@ -10,21 +10,23 @@ use std::rc::Rc; use std::borrow::Borrow; +use std::pin::Pin; #[allow(unused_imports)] use std::option::Option; use hyper; -use serde_json; use futures::Future; use super::{Error, configuration}; use super::request as __internal_request; -pub struct DeploymentsApiClient { +pub struct DeploymentsApiClient + where C: Clone + std::marker::Send + Sync + 'static { configuration: Rc>, } -impl DeploymentsApiClient { +impl DeploymentsApiClient + where C: Clone + std::marker::Send + Sync { pub fn new(configuration: Rc>) -> DeploymentsApiClient { DeploymentsApiClient { configuration, @@ -33,19 +35,21 @@ impl DeploymentsApiClient { } pub trait DeploymentsApi { - fn get_deployment(&self, deployment_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>>; - fn get_deployment_allocations(&self, deployment_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>>; - fn get_deployments(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>>; - fn post_deployment_allocation_health(&self, deployment_id: &str, deployment_alloc_health_request: crate::models::DeploymentAllocHealthRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; - fn post_deployment_fail(&self, deployment_id: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; - fn post_deployment_pause(&self, deployment_id: &str, deployment_pause_request: crate::models::DeploymentPauseRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; - fn post_deployment_promote(&self, deployment_id: &str, deployment_promote_request: crate::models::DeploymentPromoteRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; - fn post_deployment_unblock(&self, deployment_id: &str, deployment_unblock_request: crate::models::DeploymentUnblockRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; + fn get_deployment(&self, deployment_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>>; + fn get_deployment_allocations(&self, deployment_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>>; + fn get_deployments(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>>; + fn post_deployment_allocation_health(&self, deployment_id: &str, deployment_alloc_health_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; + fn post_deployment_fail(&self, deployment_id: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; + fn post_deployment_pause(&self, deployment_id: &str, deployment_pause_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; + fn post_deployment_promote(&self, deployment_id: &str, deployment_promote_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; + fn post_deployment_unblock(&self, deployment_id: &str, deployment_unblock_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; } -implDeploymentsApi for DeploymentsApiClient { - fn get_deployment(&self, deployment_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/deployment/{deploymentID}".to_string()) +implDeploymentsApi for DeploymentsApiClient + where C: Clone + std::marker::Send + Sync { + #[allow(unused_mut)] + fn get_deployment(&self, deployment_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/deployment/{deploymentID}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -53,25 +57,32 @@ implDeploymentsApi for DeploymentsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } req = req.with_path_param("deploymentID".to_string(), deployment_id.to_string()); if let Some(param_value) = index { @@ -84,8 +95,9 @@ implDeploymentsApi for DeploymentsApiClient { req.execute(self.configuration.borrow()) } - fn get_deployment_allocations(&self, deployment_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/deployment/allocations/{deploymentID}".to_string()) + #[allow(unused_mut)] + fn get_deployment_allocations(&self, deployment_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/deployment/allocations/{deploymentID}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -93,25 +105,32 @@ implDeploymentsApi for DeploymentsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } req = req.with_path_param("deploymentID".to_string(), deployment_id.to_string()); if let Some(param_value) = index { @@ -124,8 +143,9 @@ implDeploymentsApi for DeploymentsApiClient { req.execute(self.configuration.borrow()) } - fn get_deployments(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/deployments".to_string()) + #[allow(unused_mut)] + fn get_deployments(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/deployments".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -133,25 +153,32 @@ implDeploymentsApi for DeploymentsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } if let Some(param_value) = index { req = req.with_header_param("index".to_string(), param_value.to_string()); @@ -163,8 +190,9 @@ implDeploymentsApi for DeploymentsApiClient { req.execute(self.configuration.borrow()) } - fn post_deployment_allocation_health(&self, deployment_id: &str, deployment_alloc_health_request: crate::models::DeploymentAllocHealthRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/deployment/allocation-health/{deploymentID}".to_string()) + #[allow(unused_mut)] + fn post_deployment_allocation_health(&self, deployment_id: &str, deployment_alloc_health_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/deployment/allocation-health/{deploymentID}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -172,13 +200,16 @@ implDeploymentsApi for DeploymentsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } req = req.with_path_param("deploymentID".to_string(), deployment_id.to_string()); if let Some(param_value) = x_nomad_token { @@ -189,8 +220,9 @@ implDeploymentsApi for DeploymentsApiClient { req.execute(self.configuration.borrow()) } - fn post_deployment_fail(&self, deployment_id: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/deployment/fail/{deploymentID}".to_string()) + #[allow(unused_mut)] + fn post_deployment_fail(&self, deployment_id: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/deployment/fail/{deploymentID}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -198,13 +230,16 @@ implDeploymentsApi for DeploymentsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } req = req.with_path_param("deploymentID".to_string(), deployment_id.to_string()); if let Some(param_value) = x_nomad_token { @@ -214,8 +249,9 @@ implDeploymentsApi for DeploymentsApiClient { req.execute(self.configuration.borrow()) } - fn post_deployment_pause(&self, deployment_id: &str, deployment_pause_request: crate::models::DeploymentPauseRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/deployment/pause/{deploymentID}".to_string()) + #[allow(unused_mut)] + fn post_deployment_pause(&self, deployment_id: &str, deployment_pause_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/deployment/pause/{deploymentID}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -223,13 +259,16 @@ implDeploymentsApi for DeploymentsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } req = req.with_path_param("deploymentID".to_string(), deployment_id.to_string()); if let Some(param_value) = x_nomad_token { @@ -240,8 +279,9 @@ implDeploymentsApi for DeploymentsApiClient { req.execute(self.configuration.borrow()) } - fn post_deployment_promote(&self, deployment_id: &str, deployment_promote_request: crate::models::DeploymentPromoteRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/deployment/promote/{deploymentID}".to_string()) + #[allow(unused_mut)] + fn post_deployment_promote(&self, deployment_id: &str, deployment_promote_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/deployment/promote/{deploymentID}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -249,13 +289,16 @@ implDeploymentsApi for DeploymentsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } req = req.with_path_param("deploymentID".to_string(), deployment_id.to_string()); if let Some(param_value) = x_nomad_token { @@ -266,8 +309,9 @@ implDeploymentsApi for DeploymentsApiClient { req.execute(self.configuration.borrow()) } - fn post_deployment_unblock(&self, deployment_id: &str, deployment_unblock_request: crate::models::DeploymentUnblockRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/deployment/unblock/{deploymentID}".to_string()) + #[allow(unused_mut)] + fn post_deployment_unblock(&self, deployment_id: &str, deployment_unblock_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/deployment/unblock/{deploymentID}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -275,13 +319,16 @@ implDeploymentsApi for DeploymentsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } req = req.with_path_param("deploymentID".to_string(), deployment_id.to_string()); if let Some(param_value) = x_nomad_token { diff --git a/clients/rust/hyper/v1/src/apis/enterprise_api.rs b/clients/rust/hyper/v1/src/apis/enterprise_api.rs index 8e544132..e64f1e3e 100644 --- a/clients/rust/hyper/v1/src/apis/enterprise_api.rs +++ b/clients/rust/hyper/v1/src/apis/enterprise_api.rs @@ -10,21 +10,23 @@ use std::rc::Rc; use std::borrow::Borrow; +use std::pin::Pin; #[allow(unused_imports)] use std::option::Option; use hyper; -use serde_json; use futures::Future; use super::{Error, configuration}; use super::request as __internal_request; -pub struct EnterpriseApiClient { +pub struct EnterpriseApiClient + where C: Clone + std::marker::Send + Sync + 'static { configuration: Rc>, } -impl EnterpriseApiClient { +impl EnterpriseApiClient + where C: Clone + std::marker::Send + Sync { pub fn new(configuration: Rc>) -> EnterpriseApiClient { EnterpriseApiClient { configuration, @@ -33,16 +35,18 @@ impl EnterpriseApiClient { } pub trait EnterpriseApi { - fn create_quota_spec(&self, quota_spec: crate::models::QuotaSpec, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; - fn delete_quota_spec(&self, spec_name: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; - fn get_quota_spec(&self, spec_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>>; - fn get_quotas(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>>; - fn post_quota_spec(&self, spec_name: &str, quota_spec: crate::models::QuotaSpec, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; + fn create_quota_spec(&self, quota_spec: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; + fn delete_quota_spec(&self, spec_name: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; + fn get_quota_spec(&self, spec_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>>; + fn get_quotas(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>>; + fn post_quota_spec(&self, spec_name: &str, quota_spec: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; } -implEnterpriseApi for EnterpriseApiClient { - fn create_quota_spec(&self, quota_spec: crate::models::QuotaSpec, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/quota".to_string()) +implEnterpriseApi for EnterpriseApiClient + where C: Clone + std::marker::Send + Sync { + #[allow(unused_mut)] + fn create_quota_spec(&self, quota_spec: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/quota".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -50,13 +54,16 @@ implEnterpriseApi for EnterpriseApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } if let Some(param_value) = x_nomad_token { req = req.with_header_param("X-Nomad-Token".to_string(), param_value.to_string()); @@ -67,8 +74,9 @@ implEnterpriseApi for EnterpriseApiClient { req.execute(self.configuration.borrow()) } - fn delete_quota_spec(&self, spec_name: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Delete, "/quota/{specName}".to_string()) + #[allow(unused_mut)] + fn delete_quota_spec(&self, spec_name: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::DELETE, "/quota/{specName}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -76,13 +84,16 @@ implEnterpriseApi for EnterpriseApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } req = req.with_path_param("specName".to_string(), spec_name.to_string()); if let Some(param_value) = x_nomad_token { @@ -93,8 +104,9 @@ implEnterpriseApi for EnterpriseApiClient { req.execute(self.configuration.borrow()) } - fn get_quota_spec(&self, spec_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/quota/{specName}".to_string()) + #[allow(unused_mut)] + fn get_quota_spec(&self, spec_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/quota/{specName}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -102,25 +114,32 @@ implEnterpriseApi for EnterpriseApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } req = req.with_path_param("specName".to_string(), spec_name.to_string()); if let Some(param_value) = index { @@ -133,8 +152,9 @@ implEnterpriseApi for EnterpriseApiClient { req.execute(self.configuration.borrow()) } - fn get_quotas(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/quotas".to_string()) + #[allow(unused_mut)] + fn get_quotas(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/quotas".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -142,25 +162,32 @@ implEnterpriseApi for EnterpriseApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } if let Some(param_value) = index { req = req.with_header_param("index".to_string(), param_value.to_string()); @@ -172,8 +199,9 @@ implEnterpriseApi for EnterpriseApiClient { req.execute(self.configuration.borrow()) } - fn post_quota_spec(&self, spec_name: &str, quota_spec: crate::models::QuotaSpec, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/quota/{specName}".to_string()) + #[allow(unused_mut)] + fn post_quota_spec(&self, spec_name: &str, quota_spec: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/quota/{specName}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -181,13 +209,16 @@ implEnterpriseApi for EnterpriseApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } req = req.with_path_param("specName".to_string(), spec_name.to_string()); if let Some(param_value) = x_nomad_token { diff --git a/clients/rust/hyper/v1/src/apis/evaluations_api.rs b/clients/rust/hyper/v1/src/apis/evaluations_api.rs index bffbeca3..0822d462 100644 --- a/clients/rust/hyper/v1/src/apis/evaluations_api.rs +++ b/clients/rust/hyper/v1/src/apis/evaluations_api.rs @@ -10,21 +10,23 @@ use std::rc::Rc; use std::borrow::Borrow; +use std::pin::Pin; #[allow(unused_imports)] use std::option::Option; use hyper; -use serde_json; use futures::Future; use super::{Error, configuration}; use super::request as __internal_request; -pub struct EvaluationsApiClient { +pub struct EvaluationsApiClient + where C: Clone + std::marker::Send + Sync + 'static { configuration: Rc>, } -impl EvaluationsApiClient { +impl EvaluationsApiClient + where C: Clone + std::marker::Send + Sync { pub fn new(configuration: Rc>) -> EvaluationsApiClient { EvaluationsApiClient { configuration, @@ -33,14 +35,16 @@ impl EvaluationsApiClient { } pub trait EvaluationsApi { - fn get_evaluation(&self, eval_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>>; - fn get_evaluation_allocations(&self, eval_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>>; - fn get_evaluations(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>>; + fn get_evaluation(&self, eval_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>>; + fn get_evaluation_allocations(&self, eval_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>>; + fn get_evaluations(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>>; } -implEvaluationsApi for EvaluationsApiClient { - fn get_evaluation(&self, eval_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/evaluation/{evalID}".to_string()) +implEvaluationsApi for EvaluationsApiClient + where C: Clone + std::marker::Send + Sync { + #[allow(unused_mut)] + fn get_evaluation(&self, eval_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/evaluation/{evalID}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -48,25 +52,32 @@ implEvaluationsApi for EvaluationsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } req = req.with_path_param("evalID".to_string(), eval_id.to_string()); if let Some(param_value) = index { @@ -79,8 +90,9 @@ implEvaluationsApi for EvaluationsApiClient { req.execute(self.configuration.borrow()) } - fn get_evaluation_allocations(&self, eval_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/evaluation/{evalID}/allocations".to_string()) + #[allow(unused_mut)] + fn get_evaluation_allocations(&self, eval_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/evaluation/{evalID}/allocations".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -88,25 +100,32 @@ implEvaluationsApi for EvaluationsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } req = req.with_path_param("evalID".to_string(), eval_id.to_string()); if let Some(param_value) = index { @@ -119,8 +138,9 @@ implEvaluationsApi for EvaluationsApiClient { req.execute(self.configuration.borrow()) } - fn get_evaluations(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/evaluations".to_string()) + #[allow(unused_mut)] + fn get_evaluations(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/evaluations".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -128,25 +148,32 @@ implEvaluationsApi for EvaluationsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } if let Some(param_value) = index { req = req.with_header_param("index".to_string(), param_value.to_string()); diff --git a/clients/rust/hyper/v1/src/apis/jobs_api.rs b/clients/rust/hyper/v1/src/apis/jobs_api.rs index ac71251e..09258d10 100644 --- a/clients/rust/hyper/v1/src/apis/jobs_api.rs +++ b/clients/rust/hyper/v1/src/apis/jobs_api.rs @@ -10,21 +10,23 @@ use std::rc::Rc; use std::borrow::Borrow; +use std::pin::Pin; #[allow(unused_imports)] use std::option::Option; use hyper; -use serde_json; use futures::Future; use super::{Error, configuration}; use super::request as __internal_request; -pub struct JobsApiClient { +pub struct JobsApiClient + where C: Clone + std::marker::Send + Sync + 'static { configuration: Rc>, } -impl JobsApiClient { +impl JobsApiClient + where C: Clone + std::marker::Send + Sync { pub fn new(configuration: Rc>) -> JobsApiClient { JobsApiClient { configuration, @@ -33,32 +35,34 @@ impl JobsApiClient { } pub trait JobsApi { - fn delete_job(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>, purge: Option, global: Option) -> Box>>; - fn get_job(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>>; - fn get_job_allocations(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, all: Option) -> Box, Error = Error>>; - fn get_job_deployment(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>>; - fn get_job_deployments(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, all: Option) -> Box, Error = Error>>; - fn get_job_evaluations(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>>; - fn get_job_scale_status(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>>; - fn get_job_summary(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>>; - fn get_job_versions(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, diffs: Option) -> Box>>; - fn get_jobs(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>>; - fn post_job(&self, job_name: &str, job_register_request: crate::models::JobRegisterRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; - fn post_job_dispatch(&self, job_name: &str, job_dispatch_request: crate::models::JobDispatchRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; - fn post_job_evaluate(&self, job_name: &str, job_evaluate_request: crate::models::JobEvaluateRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; - fn post_job_parse(&self, jobs_parse_request: crate::models::JobsParseRequest) -> Box>>; - fn post_job_periodic_force(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; - fn post_job_plan(&self, job_name: &str, job_plan_request: crate::models::JobPlanRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; - fn post_job_revert(&self, job_name: &str, job_revert_request: crate::models::JobRevertRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; - fn post_job_scaling_request(&self, job_name: &str, scaling_request: crate::models::ScalingRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; - fn post_job_stability(&self, job_name: &str, job_stability_request: crate::models::JobStabilityRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; - fn post_job_validate_request(&self, job_validate_request: crate::models::JobValidateRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; - fn register_job(&self, job_register_request: crate::models::JobRegisterRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; + fn delete_job(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>, purge: Option, global: Option) -> Pin>>>; + fn get_job(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>>; + fn get_job_allocations(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, all: Option) -> Pin, Error>>>>; + fn get_job_deployment(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>>; + fn get_job_deployments(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, all: Option) -> Pin, Error>>>>; + fn get_job_evaluations(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>>; + fn get_job_scale_status(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>>; + fn get_job_summary(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>>; + fn get_job_versions(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, diffs: Option) -> Pin>>>; + fn get_jobs(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>>; + fn post_job(&self, job_name: &str, job_register_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; + fn post_job_dispatch(&self, job_name: &str, job_dispatch_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; + fn post_job_evaluate(&self, job_name: &str, job_evaluate_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; + fn post_job_parse(&self, jobs_parse_request: Option) -> Pin>>>; + fn post_job_periodic_force(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; + fn post_job_plan(&self, job_name: &str, job_plan_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; + fn post_job_revert(&self, job_name: &str, job_revert_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; + fn post_job_scaling_request(&self, job_name: &str, scaling_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; + fn post_job_stability(&self, job_name: &str, job_stability_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; + fn post_job_validate_request(&self, job_validate_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; + fn register_job(&self, job_register_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; } -implJobsApi for JobsApiClient { - fn delete_job(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>, purge: Option, global: Option) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Delete, "/job/{jobName}".to_string()) +implJobsApi for JobsApiClient + where C: Clone + std::marker::Send + Sync { + #[allow(unused_mut)] + fn delete_job(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>, purge: Option, global: Option) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::DELETE, "/job/{jobName}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -66,19 +70,24 @@ implJobsApi for JobsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } if let Some(ref s) = purge { - req = req.with_query_param("purge".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("purge".to_string(), query_value); } if let Some(ref s) = global { - req = req.with_query_param("global".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("global".to_string(), query_value); } req = req.with_path_param("jobName".to_string(), job_name.to_string()); if let Some(param_value) = x_nomad_token { @@ -88,8 +97,9 @@ implJobsApi for JobsApiClient { req.execute(self.configuration.borrow()) } - fn get_job(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/job/{jobName}".to_string()) + #[allow(unused_mut)] + fn get_job(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/job/{jobName}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -97,25 +107,32 @@ implJobsApi for JobsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } req = req.with_path_param("jobName".to_string(), job_name.to_string()); if let Some(param_value) = index { @@ -128,8 +145,9 @@ implJobsApi for JobsApiClient { req.execute(self.configuration.borrow()) } - fn get_job_allocations(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, all: Option) -> Box, Error = Error>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/job/{jobName}/allocations".to_string()) + #[allow(unused_mut)] + fn get_job_allocations(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, all: Option) -> Pin, Error>>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/job/{jobName}/allocations".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -137,28 +155,36 @@ implJobsApi for JobsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } if let Some(ref s) = all { - req = req.with_query_param("all".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("all".to_string(), query_value); } req = req.with_path_param("jobName".to_string(), job_name.to_string()); if let Some(param_value) = index { @@ -171,8 +197,9 @@ implJobsApi for JobsApiClient { req.execute(self.configuration.borrow()) } - fn get_job_deployment(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/job/{jobName}/deployment".to_string()) + #[allow(unused_mut)] + fn get_job_deployment(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/job/{jobName}/deployment".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -180,25 +207,32 @@ implJobsApi for JobsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } req = req.with_path_param("jobName".to_string(), job_name.to_string()); if let Some(param_value) = index { @@ -211,8 +245,9 @@ implJobsApi for JobsApiClient { req.execute(self.configuration.borrow()) } - fn get_job_deployments(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, all: Option) -> Box, Error = Error>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/job/{jobName}/deployments".to_string()) + #[allow(unused_mut)] + fn get_job_deployments(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, all: Option) -> Pin, Error>>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/job/{jobName}/deployments".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -220,28 +255,36 @@ implJobsApi for JobsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } if let Some(ref s) = all { - req = req.with_query_param("all".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("all".to_string(), query_value); } req = req.with_path_param("jobName".to_string(), job_name.to_string()); if let Some(param_value) = index { @@ -254,8 +297,9 @@ implJobsApi for JobsApiClient { req.execute(self.configuration.borrow()) } - fn get_job_evaluations(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/job/{jobName}/evaluations".to_string()) + #[allow(unused_mut)] + fn get_job_evaluations(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/job/{jobName}/evaluations".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -263,25 +307,32 @@ implJobsApi for JobsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } req = req.with_path_param("jobName".to_string(), job_name.to_string()); if let Some(param_value) = index { @@ -294,8 +345,9 @@ implJobsApi for JobsApiClient { req.execute(self.configuration.borrow()) } - fn get_job_scale_status(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/job/{jobName}/scale".to_string()) + #[allow(unused_mut)] + fn get_job_scale_status(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/job/{jobName}/scale".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -303,25 +355,32 @@ implJobsApi for JobsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } req = req.with_path_param("jobName".to_string(), job_name.to_string()); if let Some(param_value) = index { @@ -334,8 +393,9 @@ implJobsApi for JobsApiClient { req.execute(self.configuration.borrow()) } - fn get_job_summary(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/job/{jobName}/summary".to_string()) + #[allow(unused_mut)] + fn get_job_summary(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/job/{jobName}/summary".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -343,25 +403,32 @@ implJobsApi for JobsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } req = req.with_path_param("jobName".to_string(), job_name.to_string()); if let Some(param_value) = index { @@ -374,8 +441,9 @@ implJobsApi for JobsApiClient { req.execute(self.configuration.borrow()) } - fn get_job_versions(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, diffs: Option) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/job/{jobName}/versions".to_string()) + #[allow(unused_mut)] + fn get_job_versions(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, diffs: Option) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/job/{jobName}/versions".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -383,28 +451,36 @@ implJobsApi for JobsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } if let Some(ref s) = diffs { - req = req.with_query_param("diffs".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("diffs".to_string(), query_value); } req = req.with_path_param("jobName".to_string(), job_name.to_string()); if let Some(param_value) = index { @@ -417,8 +493,9 @@ implJobsApi for JobsApiClient { req.execute(self.configuration.borrow()) } - fn get_jobs(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/jobs".to_string()) + #[allow(unused_mut)] + fn get_jobs(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/jobs".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -426,25 +503,32 @@ implJobsApi for JobsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } if let Some(param_value) = index { req = req.with_header_param("index".to_string(), param_value.to_string()); @@ -456,8 +540,9 @@ implJobsApi for JobsApiClient { req.execute(self.configuration.borrow()) } - fn post_job(&self, job_name: &str, job_register_request: crate::models::JobRegisterRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/job/{jobName}".to_string()) + #[allow(unused_mut)] + fn post_job(&self, job_name: &str, job_register_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/job/{jobName}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -465,13 +550,16 @@ implJobsApi for JobsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } req = req.with_path_param("jobName".to_string(), job_name.to_string()); if let Some(param_value) = x_nomad_token { @@ -482,8 +570,9 @@ implJobsApi for JobsApiClient { req.execute(self.configuration.borrow()) } - fn post_job_dispatch(&self, job_name: &str, job_dispatch_request: crate::models::JobDispatchRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/job/{jobName}/dispatch".to_string()) + #[allow(unused_mut)] + fn post_job_dispatch(&self, job_name: &str, job_dispatch_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/job/{jobName}/dispatch".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -491,13 +580,16 @@ implJobsApi for JobsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } req = req.with_path_param("jobName".to_string(), job_name.to_string()); if let Some(param_value) = x_nomad_token { @@ -508,8 +600,9 @@ implJobsApi for JobsApiClient { req.execute(self.configuration.borrow()) } - fn post_job_evaluate(&self, job_name: &str, job_evaluate_request: crate::models::JobEvaluateRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/job/{jobName}/evaluate".to_string()) + #[allow(unused_mut)] + fn post_job_evaluate(&self, job_name: &str, job_evaluate_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/job/{jobName}/evaluate".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -517,13 +610,16 @@ implJobsApi for JobsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } req = req.with_path_param("jobName".to_string(), job_name.to_string()); if let Some(param_value) = x_nomad_token { @@ -534,8 +630,9 @@ implJobsApi for JobsApiClient { req.execute(self.configuration.borrow()) } - fn post_job_parse(&self, jobs_parse_request: crate::models::JobsParseRequest) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/jobs/parse".to_string()) + #[allow(unused_mut)] + fn post_job_parse(&self, jobs_parse_request: Option) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/jobs/parse".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -547,8 +644,9 @@ implJobsApi for JobsApiClient { req.execute(self.configuration.borrow()) } - fn post_job_periodic_force(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/job/{jobName}/periodic/force".to_string()) + #[allow(unused_mut)] + fn post_job_periodic_force(&self, job_name: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/job/{jobName}/periodic/force".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -556,13 +654,16 @@ implJobsApi for JobsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } req = req.with_path_param("jobName".to_string(), job_name.to_string()); if let Some(param_value) = x_nomad_token { @@ -572,8 +673,9 @@ implJobsApi for JobsApiClient { req.execute(self.configuration.borrow()) } - fn post_job_plan(&self, job_name: &str, job_plan_request: crate::models::JobPlanRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/job/{jobName}/plan".to_string()) + #[allow(unused_mut)] + fn post_job_plan(&self, job_name: &str, job_plan_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/job/{jobName}/plan".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -581,13 +683,16 @@ implJobsApi for JobsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } req = req.with_path_param("jobName".to_string(), job_name.to_string()); if let Some(param_value) = x_nomad_token { @@ -598,8 +703,9 @@ implJobsApi for JobsApiClient { req.execute(self.configuration.borrow()) } - fn post_job_revert(&self, job_name: &str, job_revert_request: crate::models::JobRevertRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/job/{jobName}/revert".to_string()) + #[allow(unused_mut)] + fn post_job_revert(&self, job_name: &str, job_revert_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/job/{jobName}/revert".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -607,13 +713,16 @@ implJobsApi for JobsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } req = req.with_path_param("jobName".to_string(), job_name.to_string()); if let Some(param_value) = x_nomad_token { @@ -624,8 +733,9 @@ implJobsApi for JobsApiClient { req.execute(self.configuration.borrow()) } - fn post_job_scaling_request(&self, job_name: &str, scaling_request: crate::models::ScalingRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/job/{jobName}/scale".to_string()) + #[allow(unused_mut)] + fn post_job_scaling_request(&self, job_name: &str, scaling_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/job/{jobName}/scale".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -633,13 +743,16 @@ implJobsApi for JobsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } req = req.with_path_param("jobName".to_string(), job_name.to_string()); if let Some(param_value) = x_nomad_token { @@ -650,8 +763,9 @@ implJobsApi for JobsApiClient { req.execute(self.configuration.borrow()) } - fn post_job_stability(&self, job_name: &str, job_stability_request: crate::models::JobStabilityRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/job/{jobName}/stable".to_string()) + #[allow(unused_mut)] + fn post_job_stability(&self, job_name: &str, job_stability_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/job/{jobName}/stable".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -659,13 +773,16 @@ implJobsApi for JobsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } req = req.with_path_param("jobName".to_string(), job_name.to_string()); if let Some(param_value) = x_nomad_token { @@ -676,8 +793,9 @@ implJobsApi for JobsApiClient { req.execute(self.configuration.borrow()) } - fn post_job_validate_request(&self, job_validate_request: crate::models::JobValidateRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/validate/job".to_string()) + #[allow(unused_mut)] + fn post_job_validate_request(&self, job_validate_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/validate/job".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -685,13 +803,16 @@ implJobsApi for JobsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } if let Some(param_value) = x_nomad_token { req = req.with_header_param("X-Nomad-Token".to_string(), param_value.to_string()); @@ -701,8 +822,9 @@ implJobsApi for JobsApiClient { req.execute(self.configuration.borrow()) } - fn register_job(&self, job_register_request: crate::models::JobRegisterRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/jobs".to_string()) + #[allow(unused_mut)] + fn register_job(&self, job_register_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/jobs".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -710,13 +832,16 @@ implJobsApi for JobsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } if let Some(param_value) = x_nomad_token { req = req.with_header_param("X-Nomad-Token".to_string(), param_value.to_string()); diff --git a/clients/rust/hyper/v1/src/apis/metrics_api.rs b/clients/rust/hyper/v1/src/apis/metrics_api.rs index 9a685693..9813f760 100644 --- a/clients/rust/hyper/v1/src/apis/metrics_api.rs +++ b/clients/rust/hyper/v1/src/apis/metrics_api.rs @@ -10,21 +10,23 @@ use std::rc::Rc; use std::borrow::Borrow; +use std::pin::Pin; #[allow(unused_imports)] use std::option::Option; use hyper; -use serde_json; use futures::Future; use super::{Error, configuration}; use super::request as __internal_request; -pub struct MetricsApiClient { +pub struct MetricsApiClient + where C: Clone + std::marker::Send + Sync + 'static { configuration: Rc>, } -impl MetricsApiClient { +impl MetricsApiClient + where C: Clone + std::marker::Send + Sync { pub fn new(configuration: Rc>) -> MetricsApiClient { MetricsApiClient { configuration, @@ -33,12 +35,14 @@ impl MetricsApiClient { } pub trait MetricsApi { - fn get_metrics_summary(&self, format: Option<&str>) -> Box>>; + fn get_metrics_summary(&self, format: Option<&str>) -> Pin>>>; } -implMetricsApi for MetricsApiClient { - fn get_metrics_summary(&self, format: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/metrics".to_string()) +implMetricsApi for MetricsApiClient + where C: Clone + std::marker::Send + Sync { + #[allow(unused_mut)] + fn get_metrics_summary(&self, format: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/metrics".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -46,7 +50,8 @@ implMetricsApi for MetricsApiClient { })) ; if let Some(ref s) = format { - req = req.with_query_param("format".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("format".to_string(), query_value); } req.execute(self.configuration.borrow()) diff --git a/clients/rust/hyper/v1/src/apis/mod.rs b/clients/rust/hyper/v1/src/apis/mod.rs index 4ba8a259..e4bd87a7 100644 --- a/clients/rust/hyper/v1/src/apis/mod.rs +++ b/clients/rust/hyper/v1/src/apis/mod.rs @@ -1,49 +1,45 @@ +use http; use hyper; -use serde; use serde_json; #[derive(Debug)] -pub enum Error { - UriError(hyper::error::UriError), +pub enum Error { + Api(ApiError), + Header(hyper::http::header::InvalidHeaderValue), + Http(http::Error), Hyper(hyper::Error), Serde(serde_json::Error), - ApiError(ApiError), + UriError(http::uri::InvalidUri), } #[derive(Debug)] -pub struct ApiError { +pub struct ApiError { pub code: hyper::StatusCode, - pub content: Option, + pub body: hyper::body::Body, } -impl<'de, T> From<(hyper::StatusCode, &'de [u8])> for Error - where T: serde::Deserialize<'de> { - fn from(e: (hyper::StatusCode, &'de [u8])) -> Self { - if e.1.len() == 0 { - return Error::ApiError(ApiError{ - code: e.0, - content: None, - }); - } - match serde_json::from_slice::(e.1) { - Ok(t) => Error::ApiError(ApiError{ - code: e.0, - content: Some(t), - }), - Err(e) => { - Error::from(e) - } - } +impl From<(hyper::StatusCode, hyper::body::Body)> for Error { + fn from(e: (hyper::StatusCode, hyper::body::Body)) -> Self { + Error::Api(ApiError { + code: e.0, + body: e.1, + }) } } -impl From for Error { +impl From for Error { + fn from(e: http::Error) -> Self { + return Error::Http(e) + } +} + +impl From for Error { fn from(e: hyper::Error) -> Self { return Error::Hyper(e) } } -impl From for Error { +impl From for Error { fn from(e: serde_json::Error) -> Self { return Error::Serde(e) } diff --git a/clients/rust/hyper/v1/src/apis/namespaces_api.rs b/clients/rust/hyper/v1/src/apis/namespaces_api.rs index d8876736..cce54fed 100644 --- a/clients/rust/hyper/v1/src/apis/namespaces_api.rs +++ b/clients/rust/hyper/v1/src/apis/namespaces_api.rs @@ -10,21 +10,23 @@ use std::rc::Rc; use std::borrow::Borrow; +use std::pin::Pin; #[allow(unused_imports)] use std::option::Option; use hyper; -use serde_json; use futures::Future; use super::{Error, configuration}; use super::request as __internal_request; -pub struct NamespacesApiClient { +pub struct NamespacesApiClient + where C: Clone + std::marker::Send + Sync + 'static { configuration: Rc>, } -impl NamespacesApiClient { +impl NamespacesApiClient + where C: Clone + std::marker::Send + Sync { pub fn new(configuration: Rc>) -> NamespacesApiClient { NamespacesApiClient { configuration, @@ -33,16 +35,18 @@ impl NamespacesApiClient { } pub trait NamespacesApi { - fn create_namespace(&self, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; - fn delete_namespace(&self, namespace_name: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; - fn get_namespace(&self, namespace_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>>; - fn get_namespaces(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>>; - fn post_namespace(&self, namespace_name: &str, namespace2: crate::models::Namespace, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; + fn create_namespace(&self, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; + fn delete_namespace(&self, namespace_name: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; + fn get_namespace(&self, namespace_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>>; + fn get_namespaces(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>>; + fn post_namespace(&self, namespace_name: &str, namespace2: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; } -implNamespacesApi for NamespacesApiClient { - fn create_namespace(&self, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/namespace".to_string()) +implNamespacesApi for NamespacesApiClient + where C: Clone + std::marker::Send + Sync { + #[allow(unused_mut)] + fn create_namespace(&self, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/namespace".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -50,13 +54,16 @@ implNamespacesApi for NamespacesApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } if let Some(param_value) = x_nomad_token { req = req.with_header_param("X-Nomad-Token".to_string(), param_value.to_string()); @@ -66,8 +73,9 @@ implNamespacesApi for NamespacesApiClient { req.execute(self.configuration.borrow()) } - fn delete_namespace(&self, namespace_name: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Delete, "/namespace/{namespaceName}".to_string()) + #[allow(unused_mut)] + fn delete_namespace(&self, namespace_name: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::DELETE, "/namespace/{namespaceName}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -75,13 +83,16 @@ implNamespacesApi for NamespacesApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } req = req.with_path_param("namespaceName".to_string(), namespace_name.to_string()); if let Some(param_value) = x_nomad_token { @@ -92,8 +103,9 @@ implNamespacesApi for NamespacesApiClient { req.execute(self.configuration.borrow()) } - fn get_namespace(&self, namespace_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/namespace/{namespaceName}".to_string()) + #[allow(unused_mut)] + fn get_namespace(&self, namespace_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/namespace/{namespaceName}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -101,25 +113,32 @@ implNamespacesApi for NamespacesApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } req = req.with_path_param("namespaceName".to_string(), namespace_name.to_string()); if let Some(param_value) = index { @@ -132,8 +151,9 @@ implNamespacesApi for NamespacesApiClient { req.execute(self.configuration.borrow()) } - fn get_namespaces(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/namespaces".to_string()) + #[allow(unused_mut)] + fn get_namespaces(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/namespaces".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -141,25 +161,32 @@ implNamespacesApi for NamespacesApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } if let Some(param_value) = index { req = req.with_header_param("index".to_string(), param_value.to_string()); @@ -171,8 +198,9 @@ implNamespacesApi for NamespacesApiClient { req.execute(self.configuration.borrow()) } - fn post_namespace(&self, namespace_name: &str, namespace2: crate::models::Namespace, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/namespace/{namespaceName}".to_string()) + #[allow(unused_mut)] + fn post_namespace(&self, namespace_name: &str, namespace2: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/namespace/{namespaceName}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -180,13 +208,16 @@ implNamespacesApi for NamespacesApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } req = req.with_path_param("namespaceName".to_string(), namespace_name.to_string()); if let Some(param_value) = x_nomad_token { diff --git a/clients/rust/hyper/v1/src/apis/nodes_api.rs b/clients/rust/hyper/v1/src/apis/nodes_api.rs index 8cc17f72..f892e2ee 100644 --- a/clients/rust/hyper/v1/src/apis/nodes_api.rs +++ b/clients/rust/hyper/v1/src/apis/nodes_api.rs @@ -10,21 +10,23 @@ use std::rc::Rc; use std::borrow::Borrow; +use std::pin::Pin; #[allow(unused_imports)] use std::option::Option; use hyper; -use serde_json; use futures::Future; use super::{Error, configuration}; use super::request as __internal_request; -pub struct NodesApiClient { +pub struct NodesApiClient + where C: Clone + std::marker::Send + Sync + 'static { configuration: Rc>, } -impl NodesApiClient { +impl NodesApiClient + where C: Clone + std::marker::Send + Sync { pub fn new(configuration: Rc>) -> NodesApiClient { NodesApiClient { configuration, @@ -33,17 +35,19 @@ impl NodesApiClient { } pub trait NodesApi { - fn get_node(&self, node_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>>; - fn get_node_allocations(&self, node_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>>; - fn get_nodes(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, resources: Option) -> Box, Error = Error>>; - fn update_node_drain(&self, node_id: &str, node_update_drain_request: crate::models::NodeUpdateDrainRequest, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>>; - fn update_node_eligibility(&self, node_id: &str, node_update_eligibility_request: crate::models::NodeUpdateEligibilityRequest, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>>; - fn update_node_purge(&self, node_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>>; + fn get_node(&self, node_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>>; + fn get_node_allocations(&self, node_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>>; + fn get_nodes(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, resources: Option) -> Pin, Error>>>>; + fn update_node_drain(&self, node_id: &str, node_update_drain_request: Option, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>>; + fn update_node_eligibility(&self, node_id: &str, node_update_eligibility_request: Option, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>>; + fn update_node_purge(&self, node_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>>; } -implNodesApi for NodesApiClient { - fn get_node(&self, node_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/node/{nodeId}".to_string()) +implNodesApi for NodesApiClient + where C: Clone + std::marker::Send + Sync { + #[allow(unused_mut)] + fn get_node(&self, node_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/node/{nodeId}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -51,25 +55,32 @@ implNodesApi for NodesApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } req = req.with_path_param("nodeId".to_string(), node_id.to_string()); if let Some(param_value) = index { @@ -82,8 +93,9 @@ implNodesApi for NodesApiClient { req.execute(self.configuration.borrow()) } - fn get_node_allocations(&self, node_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/node/{nodeId}/allocations".to_string()) + #[allow(unused_mut)] + fn get_node_allocations(&self, node_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/node/{nodeId}/allocations".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -91,25 +103,32 @@ implNodesApi for NodesApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } req = req.with_path_param("nodeId".to_string(), node_id.to_string()); if let Some(param_value) = index { @@ -122,8 +141,9 @@ implNodesApi for NodesApiClient { req.execute(self.configuration.borrow()) } - fn get_nodes(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, resources: Option) -> Box, Error = Error>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/nodes".to_string()) + #[allow(unused_mut)] + fn get_nodes(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, resources: Option) -> Pin, Error>>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/nodes".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -131,28 +151,36 @@ implNodesApi for NodesApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } if let Some(ref s) = resources { - req = req.with_query_param("resources".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("resources".to_string(), query_value); } if let Some(param_value) = index { req = req.with_header_param("index".to_string(), param_value.to_string()); @@ -164,8 +192,9 @@ implNodesApi for NodesApiClient { req.execute(self.configuration.borrow()) } - fn update_node_drain(&self, node_id: &str, node_update_drain_request: crate::models::NodeUpdateDrainRequest, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/node/{nodeId}/drain".to_string()) + #[allow(unused_mut)] + fn update_node_drain(&self, node_id: &str, node_update_drain_request: Option, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/node/{nodeId}/drain".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -173,25 +202,32 @@ implNodesApi for NodesApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } req = req.with_path_param("nodeId".to_string(), node_id.to_string()); if let Some(param_value) = index { @@ -205,8 +241,9 @@ implNodesApi for NodesApiClient { req.execute(self.configuration.borrow()) } - fn update_node_eligibility(&self, node_id: &str, node_update_eligibility_request: crate::models::NodeUpdateEligibilityRequest, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/node/{nodeId}/eligibility".to_string()) + #[allow(unused_mut)] + fn update_node_eligibility(&self, node_id: &str, node_update_eligibility_request: Option, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/node/{nodeId}/eligibility".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -214,25 +251,32 @@ implNodesApi for NodesApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } req = req.with_path_param("nodeId".to_string(), node_id.to_string()); if let Some(param_value) = index { @@ -246,8 +290,9 @@ implNodesApi for NodesApiClient { req.execute(self.configuration.borrow()) } - fn update_node_purge(&self, node_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/node/{nodeId}/purge".to_string()) + #[allow(unused_mut)] + fn update_node_purge(&self, node_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/node/{nodeId}/purge".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -255,25 +300,32 @@ implNodesApi for NodesApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } req = req.with_path_param("nodeId".to_string(), node_id.to_string()); if let Some(param_value) = index { diff --git a/clients/rust/hyper/v1/src/apis/operator_api.rs b/clients/rust/hyper/v1/src/apis/operator_api.rs index 3d75fd89..750abdef 100644 --- a/clients/rust/hyper/v1/src/apis/operator_api.rs +++ b/clients/rust/hyper/v1/src/apis/operator_api.rs @@ -10,21 +10,23 @@ use std::rc::Rc; use std::borrow::Borrow; +use std::pin::Pin; #[allow(unused_imports)] use std::option::Option; use hyper; -use serde_json; use futures::Future; use super::{Error, configuration}; use super::request as __internal_request; -pub struct OperatorApiClient { +pub struct OperatorApiClient + where C: Clone + std::marker::Send + Sync + 'static { configuration: Rc>, } -impl OperatorApiClient { +impl OperatorApiClient + where C: Clone + std::marker::Send + Sync { pub fn new(configuration: Rc>) -> OperatorApiClient { OperatorApiClient { configuration, @@ -33,18 +35,20 @@ impl OperatorApiClient { } pub trait OperatorApi { - fn delete_operator_raft_peer(&self, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; - fn get_operator_autopilot_configuration(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>>; - fn get_operator_autopilot_health(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>>; - fn get_operator_raft_configuration(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>>; - fn get_operator_scheduler_configuration(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>>; - fn post_operator_scheduler_configuration(&self, scheduler_configuration: crate::models::SchedulerConfiguration, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; - fn put_operator_autopilot_configuration(&self, autopilot_configuration: crate::models::AutopilotConfiguration, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; + fn delete_operator_raft_peer(&self, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; + fn get_operator_autopilot_configuration(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>>; + fn get_operator_autopilot_health(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>>; + fn get_operator_raft_configuration(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>>; + fn get_operator_scheduler_configuration(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>>; + fn post_operator_scheduler_configuration(&self, scheduler_configuration: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; + fn put_operator_autopilot_configuration(&self, autopilot_configuration: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; } -implOperatorApi for OperatorApiClient { - fn delete_operator_raft_peer(&self, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Delete, "/operator/raft/peer".to_string()) +implOperatorApi for OperatorApiClient + where C: Clone + std::marker::Send + Sync { + #[allow(unused_mut)] + fn delete_operator_raft_peer(&self, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::DELETE, "/operator/raft/peer".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -52,13 +56,16 @@ implOperatorApi for OperatorApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } if let Some(param_value) = x_nomad_token { req = req.with_header_param("X-Nomad-Token".to_string(), param_value.to_string()); @@ -68,8 +75,9 @@ implOperatorApi for OperatorApiClient { req.execute(self.configuration.borrow()) } - fn get_operator_autopilot_configuration(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/operator/autopilot/configuration".to_string()) + #[allow(unused_mut)] + fn get_operator_autopilot_configuration(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/operator/autopilot/configuration".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -77,25 +85,32 @@ implOperatorApi for OperatorApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } if let Some(param_value) = index { req = req.with_header_param("index".to_string(), param_value.to_string()); @@ -107,8 +122,9 @@ implOperatorApi for OperatorApiClient { req.execute(self.configuration.borrow()) } - fn get_operator_autopilot_health(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/operator/autopilot/health".to_string()) + #[allow(unused_mut)] + fn get_operator_autopilot_health(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/operator/autopilot/health".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -116,25 +132,32 @@ implOperatorApi for OperatorApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } if let Some(param_value) = index { req = req.with_header_param("index".to_string(), param_value.to_string()); @@ -146,8 +169,9 @@ implOperatorApi for OperatorApiClient { req.execute(self.configuration.borrow()) } - fn get_operator_raft_configuration(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/operator/raft/configuration".to_string()) + #[allow(unused_mut)] + fn get_operator_raft_configuration(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/operator/raft/configuration".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -155,25 +179,32 @@ implOperatorApi for OperatorApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } if let Some(param_value) = index { req = req.with_header_param("index".to_string(), param_value.to_string()); @@ -185,8 +216,9 @@ implOperatorApi for OperatorApiClient { req.execute(self.configuration.borrow()) } - fn get_operator_scheduler_configuration(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/operator/scheduler/configuration".to_string()) + #[allow(unused_mut)] + fn get_operator_scheduler_configuration(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/operator/scheduler/configuration".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -194,25 +226,32 @@ implOperatorApi for OperatorApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } if let Some(param_value) = index { req = req.with_header_param("index".to_string(), param_value.to_string()); @@ -224,8 +263,9 @@ implOperatorApi for OperatorApiClient { req.execute(self.configuration.borrow()) } - fn post_operator_scheduler_configuration(&self, scheduler_configuration: crate::models::SchedulerConfiguration, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/operator/scheduler/configuration".to_string()) + #[allow(unused_mut)] + fn post_operator_scheduler_configuration(&self, scheduler_configuration: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/operator/scheduler/configuration".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -233,13 +273,16 @@ implOperatorApi for OperatorApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } if let Some(param_value) = x_nomad_token { req = req.with_header_param("X-Nomad-Token".to_string(), param_value.to_string()); @@ -249,8 +292,9 @@ implOperatorApi for OperatorApiClient { req.execute(self.configuration.borrow()) } - fn put_operator_autopilot_configuration(&self, autopilot_configuration: crate::models::AutopilotConfiguration, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Put, "/operator/autopilot/configuration".to_string()) + #[allow(unused_mut)] + fn put_operator_autopilot_configuration(&self, autopilot_configuration: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::PUT, "/operator/autopilot/configuration".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -258,13 +302,16 @@ implOperatorApi for OperatorApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } if let Some(param_value) = x_nomad_token { req = req.with_header_param("X-Nomad-Token".to_string(), param_value.to_string()); diff --git a/clients/rust/hyper/v1/src/apis/plugins_api.rs b/clients/rust/hyper/v1/src/apis/plugins_api.rs index f18fdbb8..8fb9acb2 100644 --- a/clients/rust/hyper/v1/src/apis/plugins_api.rs +++ b/clients/rust/hyper/v1/src/apis/plugins_api.rs @@ -10,21 +10,23 @@ use std::rc::Rc; use std::borrow::Borrow; +use std::pin::Pin; #[allow(unused_imports)] use std::option::Option; use hyper; -use serde_json; use futures::Future; use super::{Error, configuration}; use super::request as __internal_request; -pub struct PluginsApiClient { +pub struct PluginsApiClient + where C: Clone + std::marker::Send + Sync + 'static { configuration: Rc>, } -impl PluginsApiClient { +impl PluginsApiClient + where C: Clone + std::marker::Send + Sync { pub fn new(configuration: Rc>) -> PluginsApiClient { PluginsApiClient { configuration, @@ -33,13 +35,15 @@ impl PluginsApiClient { } pub trait PluginsApi { - fn get_plugin_csi(&self, plugin_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>>; - fn get_plugins(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>>; + fn get_plugin_csi(&self, plugin_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>>; + fn get_plugins(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>>; } -implPluginsApi for PluginsApiClient { - fn get_plugin_csi(&self, plugin_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/plugin/csi/{pluginID}".to_string()) +implPluginsApi for PluginsApiClient + where C: Clone + std::marker::Send + Sync { + #[allow(unused_mut)] + fn get_plugin_csi(&self, plugin_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/plugin/csi/{pluginID}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -47,25 +51,32 @@ implPluginsApi for PluginsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } req = req.with_path_param("pluginID".to_string(), plugin_id.to_string()); if let Some(param_value) = index { @@ -78,8 +89,9 @@ implPluginsApi for PluginsApiClient { req.execute(self.configuration.borrow()) } - fn get_plugins(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/plugins".to_string()) + #[allow(unused_mut)] + fn get_plugins(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/plugins".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -87,25 +99,32 @@ implPluginsApi for PluginsApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } if let Some(param_value) = index { req = req.with_header_param("index".to_string(), param_value.to_string()); diff --git a/clients/rust/hyper/v1/src/apis/regions_api.rs b/clients/rust/hyper/v1/src/apis/regions_api.rs index 3e969ca2..7ba490b7 100644 --- a/clients/rust/hyper/v1/src/apis/regions_api.rs +++ b/clients/rust/hyper/v1/src/apis/regions_api.rs @@ -10,21 +10,23 @@ use std::rc::Rc; use std::borrow::Borrow; +use std::pin::Pin; #[allow(unused_imports)] use std::option::Option; use hyper; -use serde_json; use futures::Future; use super::{Error, configuration}; use super::request as __internal_request; -pub struct RegionsApiClient { +pub struct RegionsApiClient + where C: Clone + std::marker::Send + Sync + 'static { configuration: Rc>, } -impl RegionsApiClient { +impl RegionsApiClient + where C: Clone + std::marker::Send + Sync { pub fn new(configuration: Rc>) -> RegionsApiClient { RegionsApiClient { configuration, @@ -33,12 +35,14 @@ impl RegionsApiClient { } pub trait RegionsApi { - fn get_regions(&self, ) -> Box, Error = Error>>; + fn get_regions(&self, ) -> Pin, Error>>>>; } -implRegionsApi for RegionsApiClient { - fn get_regions(&self, ) -> Box, Error = Error>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/regions".to_string()) +implRegionsApi for RegionsApiClient + where C: Clone + std::marker::Send + Sync { + #[allow(unused_mut)] + fn get_regions(&self, ) -> Pin, Error>>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/regions".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, diff --git a/clients/rust/hyper/v1/src/apis/request.rs b/clients/rust/hyper/v1/src/apis/request.rs index f97b5277..0aa51fa0 100644 --- a/clients/rust/hyper/v1/src/apis/request.rs +++ b/clients/rust/hyper/v1/src/apis/request.rs @@ -1,14 +1,16 @@ -use std::borrow::Cow; use std::collections::HashMap; +use std::pin::Pin; -use super::{configuration, Error}; use futures; -use futures::{Future, Stream}; +use futures::Future; +use futures::future::*; use hyper; -use hyper::header::UserAgent; +use hyper::header::{AUTHORIZATION, CONTENT_LENGTH, CONTENT_TYPE, HeaderValue, USER_AGENT}; use serde; use serde_json; +use super::{configuration, Error}; + pub(crate) struct ApiKey { pub in_header: bool, pub in_query: bool, @@ -32,8 +34,11 @@ pub(crate) enum Auth { Oauth, } +/// If the authorization type is unspecified then it will be automatically detected based +/// on the configuration. This functionality is useful when the OpenAPI definition does not +/// include an authorization scheme. pub(crate) struct Request { - auth: Auth, + auth: Option, method: hyper::Method, path: String, query_params: HashMap, @@ -48,9 +53,9 @@ pub(crate) struct Request { impl Request { pub fn new(method: hyper::Method, path: String) -> Self { Request { - auth: Auth::None, - method: method, - path: path, + auth: None, + method, + path, query_params: HashMap::new(), path_params: HashMap::new(), form_params: HashMap::new(), @@ -91,24 +96,20 @@ impl Request { } pub fn with_auth(mut self, auth: Auth) -> Self { - self.auth = auth; + self.auth = Some(auth); self } pub fn execute<'a, C, U>( self, conf: &configuration::Configuration, - ) -> Box> + 'a> - where - C: hyper::client::Connect, - U: Sized + 'a, - for<'de> U: serde::Deserialize<'de>, + ) -> Pin> + 'a>> + where + C: hyper::client::connect::Connect + Clone + std::marker::Send + Sync, + U: Sized + std::marker::Send + 'a, + for<'de> U: serde::Deserialize<'de>, { let mut query_string = ::url::form_urlencoded::Serializer::new("".to_owned()); - // raw_headers is for headers we don't know the proper type of (e.g. custom api key - // headers); headers is for ones we do know the type of. - let mut raw_headers = HashMap::new(); - let mut headers: hyper::header::Headers = hyper::header::Headers::new(); let mut path = self.path; for (k, v) in self.path_params { @@ -116,15 +117,39 @@ impl Request { path = path.replace(&format!("{{{}}}", k), &v); } - for (k, v) in self.header_params { - raw_headers.insert(k, v); - } - for (key, val) in self.query_params { query_string.append_pair(&key, &val); } - match self.auth { + let mut uri_str = format!("{}{}", conf.base_path, path); + + let query_string_str = query_string.finish(); + if query_string_str != "" { + uri_str += "?"; + uri_str += &query_string_str; + } + let uri: hyper::Uri = match uri_str.parse() { + Err(e) => return Box::pin(futures::future::err(Error::UriError(e))), + Ok(u) => u, + }; + + let mut req_builder = hyper::Request::builder() + .uri(uri) + .method(self.method); + + // Detect the authorization type if it hasn't been set. + let auth = self.auth.unwrap_or_else(|| + if conf.api_key.is_some() { + panic!("Cannot automatically set the API key from the configuration, it must be specified in the OpenAPI definition") + } else if conf.oauth_access_token.is_some() { + Auth::Oauth + } else if conf.basic_auth.is_some() { + Auth::Basic + } else { + Auth::None + } + ); + match auth { Auth::ApiKey(apikey) => { if let Some(ref key) = conf.api_key { let val = apikey.key(&key.prefix, &key.key); @@ -132,108 +157,82 @@ impl Request { query_string.append_pair(&apikey.param_name, &val); } if apikey.in_header { - raw_headers.insert(apikey.param_name, val); + req_builder = req_builder.header(&apikey.param_name, val); } } } Auth::Basic => { if let Some(ref auth_conf) = conf.basic_auth { - let auth = hyper::header::Authorization(hyper::header::Basic { - username: auth_conf.0.to_owned(), - password: auth_conf.1.to_owned(), - }); - headers.set(auth); + let mut text = auth_conf.0.clone(); + text.push(':'); + if let Some(ref pass) = auth_conf.1 { + text.push_str(&pass[..]); + } + let encoded = base64::encode(&text); + req_builder = req_builder.header(AUTHORIZATION, encoded); } } Auth::Oauth => { if let Some(ref token) = conf.oauth_access_token { - let auth = hyper::header::Authorization(hyper::header::Bearer { - token: token.to_owned(), - }); - headers.set(auth); + let text = "Bearer ".to_owned() + token; + req_builder = req_builder.header(AUTHORIZATION, text); } } Auth::None => {} } - let mut uri_str = format!("{}{}", conf.base_path, path); - - let query_string_str = query_string.finish(); - if query_string_str != "" { - uri_str += "?"; - uri_str += &query_string_str; + if let Some(ref user_agent) = conf.user_agent { + req_builder = req_builder.header(USER_AGENT, match HeaderValue::from_str(user_agent) { + Ok(header_value) => header_value, + Err(e) => return Box::pin(futures::future::err(super::Error::Header(e))) + }); } - let uri: hyper::Uri = match uri_str.parse() { - Err(e) => { - return Box::new(futures::future::err(Error::UriError(e))); - } - Ok(u) => u, - }; - - let mut req = hyper::Request::new(self.method, uri); - { - let req_headers = req.headers_mut(); - if let Some(ref user_agent) = conf.user_agent { - req_headers.set(UserAgent::new(Cow::Owned(user_agent.clone()))); - } - req_headers.extend(headers.iter()); - - for (key, val) in raw_headers { - req_headers.set_raw(key, val); - } + for (k, v) in self.header_params { + req_builder = req_builder.header(&k, v); } - if self.form_params.len() > 0 { - req.headers_mut().set(hyper::header::ContentType::form_url_encoded()); + let req_headers = req_builder.headers_mut().unwrap(); + let request_result = if self.form_params.len() > 0 { + req_headers.insert(CONTENT_TYPE, HeaderValue::from_static("application/ x-www-form-urlencoded")); let mut enc = ::url::form_urlencoded::Serializer::new("".to_owned()); for (k, v) in self.form_params { enc.append_pair(&k, &v); } - req.set_body(enc.finish()); - } - - if let Some(body) = self.serialized_body { - req.headers_mut().set(hyper::header::ContentType::json()); - req.headers_mut() - .set(hyper::header::ContentLength(body.len() as u64)); - req.set_body(body); - } + req_builder.body(hyper::Body::from(enc.finish())) + } else if let Some(body) = self.serialized_body { + req_headers.insert(CONTENT_TYPE, HeaderValue::from_static("application/json")); + req_headers.insert(CONTENT_LENGTH, body.len().into()); + req_builder.body(hyper::Body::from(body)) + } else { + req_builder.body(hyper::Body::default()) + }; + let request = match request_result { + Ok(request) => request, + Err(e) => return Box::pin(futures::future::err(Error::from(e))) + }; - let no_ret_type = self.no_return_type; - let res = conf.client - .request(req) - .map_err(|e| Error::from(e)) - .and_then(|resp| { - let status = resp.status(); - resp.body() - .concat2() - .and_then(move |body| Ok((status, body))) - .map_err(|e| Error::from(e)) - }) - .and_then(|(status, body)| { - if status.is_success() { - Ok(body) - } else { - Err(Error::from((status, &*body))) - } - }); - Box::new( - res - .and_then(move |body| { - let parsed: Result = if no_ret_type { - // This is a hack; if there's no_ret_type, U is (), but serde_json gives an - // error when deserializing "" into (), so deserialize 'null' into it - // instead. - // An alternate option would be to require U: Default, and then return - // U::default() here instead since () implements that, but then we'd - // need to impl default for all models. - serde_json::from_str("null") - } else { - serde_json::from_slice(&body) - }; - parsed.map_err(|e| Error::from(e)) - }) - ) + let no_return_type = self.no_return_type; + Box::pin(conf.client + .request(request) + .map_err(|e| Error::from(e)) + .and_then(move |response| { + let status = response.status(); + if !status.is_success() { + futures::future::err::(Error::from((status, response.into_body()))).boxed() + } else if no_return_type { + // This is a hack; if there's no_ret_type, U is (), but serde_json gives an + // error when deserializing "" into (), so deserialize 'null' into it + // instead. + // An alternate option would be to require U: Default, and then return + // U::default() here instead since () implements that, but then we'd + // need to impl default for all models. + futures::future::ok::(serde_json::from_str("null").expect("serde null value")).boxed() + } else { + hyper::body::to_bytes(response.into_body()) + .map(|bytes| serde_json::from_slice(&bytes.unwrap())) + .map_err(|e| Error::from(e)).boxed() + } + })) } } diff --git a/clients/rust/hyper/v1/src/apis/scaling_api.rs b/clients/rust/hyper/v1/src/apis/scaling_api.rs index a957bfed..449f5ae2 100644 --- a/clients/rust/hyper/v1/src/apis/scaling_api.rs +++ b/clients/rust/hyper/v1/src/apis/scaling_api.rs @@ -10,21 +10,23 @@ use std::rc::Rc; use std::borrow::Borrow; +use std::pin::Pin; #[allow(unused_imports)] use std::option::Option; use hyper; -use serde_json; use futures::Future; use super::{Error, configuration}; use super::request as __internal_request; -pub struct ScalingApiClient { +pub struct ScalingApiClient + where C: Clone + std::marker::Send + Sync + 'static { configuration: Rc>, } -impl ScalingApiClient { +impl ScalingApiClient + where C: Clone + std::marker::Send + Sync { pub fn new(configuration: Rc>) -> ScalingApiClient { ScalingApiClient { configuration, @@ -33,13 +35,15 @@ impl ScalingApiClient { } pub trait ScalingApi { - fn get_scaling_policies(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>>; - fn get_scaling_policy(&self, policy_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>>; + fn get_scaling_policies(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>>; + fn get_scaling_policy(&self, policy_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>>; } -implScalingApi for ScalingApiClient { - fn get_scaling_policies(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/scaling/policies".to_string()) +implScalingApi for ScalingApiClient + where C: Clone + std::marker::Send + Sync { + #[allow(unused_mut)] + fn get_scaling_policies(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/scaling/policies".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -47,25 +51,32 @@ implScalingApi for ScalingApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } if let Some(param_value) = index { req = req.with_header_param("index".to_string(), param_value.to_string()); @@ -77,8 +88,9 @@ implScalingApi for ScalingApiClient { req.execute(self.configuration.borrow()) } - fn get_scaling_policy(&self, policy_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/scaling/policy/{policyID}".to_string()) + #[allow(unused_mut)] + fn get_scaling_policy(&self, policy_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/scaling/policy/{policyID}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -86,25 +98,32 @@ implScalingApi for ScalingApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } req = req.with_path_param("policyID".to_string(), policy_id.to_string()); if let Some(param_value) = index { diff --git a/clients/rust/hyper/v1/src/apis/search_api.rs b/clients/rust/hyper/v1/src/apis/search_api.rs index f74c478e..bae70345 100644 --- a/clients/rust/hyper/v1/src/apis/search_api.rs +++ b/clients/rust/hyper/v1/src/apis/search_api.rs @@ -10,21 +10,23 @@ use std::rc::Rc; use std::borrow::Borrow; +use std::pin::Pin; #[allow(unused_imports)] use std::option::Option; use hyper; -use serde_json; use futures::Future; use super::{Error, configuration}; use super::request as __internal_request; -pub struct SearchApiClient { +pub struct SearchApiClient + where C: Clone + std::marker::Send + Sync + 'static { configuration: Rc>, } -impl SearchApiClient { +impl SearchApiClient + where C: Clone + std::marker::Send + Sync { pub fn new(configuration: Rc>) -> SearchApiClient { SearchApiClient { configuration, @@ -33,13 +35,15 @@ impl SearchApiClient { } pub trait SearchApi { - fn get_fuzzy_search(&self, fuzzy_search_request: crate::models::FuzzySearchRequest, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>>; - fn get_search(&self, search_request: crate::models::SearchRequest, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>>; + fn get_fuzzy_search(&self, fuzzy_search_request: Option, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>>; + fn get_search(&self, search_request: Option, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>>; } -implSearchApi for SearchApiClient { - fn get_fuzzy_search(&self, fuzzy_search_request: crate::models::FuzzySearchRequest, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/search/fuzzy".to_string()) +implSearchApi for SearchApiClient + where C: Clone + std::marker::Send + Sync { + #[allow(unused_mut)] + fn get_fuzzy_search(&self, fuzzy_search_request: Option, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/search/fuzzy".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -47,25 +51,32 @@ implSearchApi for SearchApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } if let Some(param_value) = index { req = req.with_header_param("index".to_string(), param_value.to_string()); @@ -78,8 +89,9 @@ implSearchApi for SearchApiClient { req.execute(self.configuration.borrow()) } - fn get_search(&self, search_request: crate::models::SearchRequest, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/search".to_string()) + #[allow(unused_mut)] + fn get_search(&self, search_request: Option, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/search".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -87,25 +99,32 @@ implSearchApi for SearchApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } if let Some(param_value) = index { req = req.with_header_param("index".to_string(), param_value.to_string()); diff --git a/clients/rust/hyper/v1/src/apis/status_api.rs b/clients/rust/hyper/v1/src/apis/status_api.rs index adde7c9f..1d001979 100644 --- a/clients/rust/hyper/v1/src/apis/status_api.rs +++ b/clients/rust/hyper/v1/src/apis/status_api.rs @@ -10,21 +10,23 @@ use std::rc::Rc; use std::borrow::Borrow; +use std::pin::Pin; #[allow(unused_imports)] use std::option::Option; use hyper; -use serde_json; use futures::Future; use super::{Error, configuration}; use super::request as __internal_request; -pub struct StatusApiClient { +pub struct StatusApiClient + where C: Clone + std::marker::Send + Sync + 'static { configuration: Rc>, } -impl StatusApiClient { +impl StatusApiClient + where C: Clone + std::marker::Send + Sync { pub fn new(configuration: Rc>) -> StatusApiClient { StatusApiClient { configuration, @@ -33,13 +35,15 @@ impl StatusApiClient { } pub trait StatusApi { - fn get_status_leader(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>>; - fn get_status_peers(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>>; + fn get_status_leader(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>>; + fn get_status_peers(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>>; } -implStatusApi for StatusApiClient { - fn get_status_leader(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/status/leader".to_string()) +implStatusApi for StatusApiClient + where C: Clone + std::marker::Send + Sync { + #[allow(unused_mut)] + fn get_status_leader(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/status/leader".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -47,25 +51,32 @@ implStatusApi for StatusApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } if let Some(param_value) = index { req = req.with_header_param("index".to_string(), param_value.to_string()); @@ -77,8 +88,9 @@ implStatusApi for StatusApiClient { req.execute(self.configuration.borrow()) } - fn get_status_peers(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box, Error = Error>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/status/peers".to_string()) + #[allow(unused_mut)] + fn get_status_peers(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin, Error>>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/status/peers".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -86,25 +98,32 @@ implStatusApi for StatusApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } if let Some(param_value) = index { req = req.with_header_param("index".to_string(), param_value.to_string()); diff --git a/clients/rust/hyper/v1/src/apis/system_api.rs b/clients/rust/hyper/v1/src/apis/system_api.rs index 1087dde8..717858a0 100644 --- a/clients/rust/hyper/v1/src/apis/system_api.rs +++ b/clients/rust/hyper/v1/src/apis/system_api.rs @@ -10,21 +10,23 @@ use std::rc::Rc; use std::borrow::Borrow; +use std::pin::Pin; #[allow(unused_imports)] use std::option::Option; use hyper; -use serde_json; use futures::Future; use super::{Error, configuration}; use super::request as __internal_request; -pub struct SystemApiClient { +pub struct SystemApiClient + where C: Clone + std::marker::Send + Sync + 'static { configuration: Rc>, } -impl SystemApiClient { +impl SystemApiClient + where C: Clone + std::marker::Send + Sync { pub fn new(configuration: Rc>) -> SystemApiClient { SystemApiClient { configuration, @@ -33,13 +35,15 @@ impl SystemApiClient { } pub trait SystemApi { - fn put_system_gc(&self, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; - fn put_system_reconcile_summaries(&self, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; + fn put_system_gc(&self, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; + fn put_system_reconcile_summaries(&self, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; } -implSystemApi for SystemApiClient { - fn put_system_gc(&self, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Put, "/system/gc".to_string()) +implSystemApi for SystemApiClient + where C: Clone + std::marker::Send + Sync { + #[allow(unused_mut)] + fn put_system_gc(&self, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::PUT, "/system/gc".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -47,13 +51,16 @@ implSystemApi for SystemApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } if let Some(param_value) = x_nomad_token { req = req.with_header_param("X-Nomad-Token".to_string(), param_value.to_string()); @@ -63,8 +70,9 @@ implSystemApi for SystemApiClient { req.execute(self.configuration.borrow()) } - fn put_system_reconcile_summaries(&self, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Put, "/system/reconcile/summaries".to_string()) + #[allow(unused_mut)] + fn put_system_reconcile_summaries(&self, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::PUT, "/system/reconcile/summaries".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -72,13 +80,16 @@ implSystemApi for SystemApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } if let Some(param_value) = x_nomad_token { req = req.with_header_param("X-Nomad-Token".to_string(), param_value.to_string()); diff --git a/clients/rust/hyper/v1/src/apis/volumes_api.rs b/clients/rust/hyper/v1/src/apis/volumes_api.rs index 43fe1ae5..a27e67db 100644 --- a/clients/rust/hyper/v1/src/apis/volumes_api.rs +++ b/clients/rust/hyper/v1/src/apis/volumes_api.rs @@ -10,21 +10,23 @@ use std::rc::Rc; use std::borrow::Borrow; +use std::pin::Pin; #[allow(unused_imports)] use std::option::Option; use hyper; -use serde_json; use futures::Future; use super::{Error, configuration}; use super::request as __internal_request; -pub struct VolumesApiClient { +pub struct VolumesApiClient + where C: Clone + std::marker::Send + Sync + 'static { configuration: Rc>, } -impl VolumesApiClient { +impl VolumesApiClient + where C: Clone + std::marker::Send + Sync { pub fn new(configuration: Rc>) -> VolumesApiClient { VolumesApiClient { configuration, @@ -33,22 +35,24 @@ impl VolumesApiClient { } pub trait VolumesApi { - fn create_volume(&self, volume_id: &str, action: &str, csi_volume_create_request: crate::models::CsiVolumeCreateRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; - fn delete_snapshot(&self, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>, plugin_id: Option<&str>, snapshot_id: Option<&str>) -> Box>>; - fn delete_volume_registration(&self, volume_id: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>, force: Option<&str>) -> Box>>; - fn detach_or_delete_volume(&self, volume_id: &str, action: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>, node: Option<&str>) -> Box>>; - fn get_external_volumes(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, plugin_id: Option<&str>) -> Box>>; - fn get_snapshots(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, plugin_id: Option<&str>) -> Box>>; - fn get_volume(&self, volume_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>>; - fn get_volumes(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, node_id: Option<&str>, plugin_id: Option<&str>, _type: Option<&str>) -> Box, Error = Error>>; - fn post_snapshot(&self, csi_snapshot_create_request: crate::models::CsiSnapshotCreateRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; - fn post_volume(&self, csi_volume_register_request: crate::models::CsiVolumeRegisterRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; - fn post_volume_registration(&self, volume_id: &str, csi_volume_register_request: crate::models::CsiVolumeRegisterRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>>; + fn create_volume(&self, volume_id: &str, action: &str, csi_volume_create_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; + fn delete_snapshot(&self, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>, plugin_id: Option<&str>, snapshot_id: Option<&str>) -> Pin>>>; + fn delete_volume_registration(&self, volume_id: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>, force: Option<&str>) -> Pin>>>; + fn detach_or_delete_volume(&self, volume_id: &str, action: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>, node: Option<&str>) -> Pin>>>; + fn get_external_volumes(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, plugin_id: Option<&str>) -> Pin>>>; + fn get_snapshots(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, plugin_id: Option<&str>) -> Pin>>>; + fn get_volume(&self, volume_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>>; + fn get_volumes(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, node_id: Option<&str>, plugin_id: Option<&str>, _type: Option<&str>) -> Pin, Error>>>>; + fn post_snapshot(&self, csi_snapshot_create_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; + fn post_volume(&self, csi_volume_register_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; + fn post_volume_registration(&self, volume_id: &str, csi_volume_register_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>>; } -implVolumesApi for VolumesApiClient { - fn create_volume(&self, volume_id: &str, action: &str, csi_volume_create_request: crate::models::CsiVolumeCreateRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/volume/csi/{volumeId}/{action}".to_string()) +implVolumesApi for VolumesApiClient + where C: Clone + std::marker::Send + Sync { + #[allow(unused_mut)] + fn create_volume(&self, volume_id: &str, action: &str, csi_volume_create_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/volume/csi/{volumeId}/{action}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -56,13 +60,16 @@ implVolumesApi for VolumesApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } req = req.with_path_param("volumeId".to_string(), volume_id.to_string()); req = req.with_path_param("action".to_string(), action.to_string()); @@ -75,8 +82,9 @@ implVolumesApi for VolumesApiClient { req.execute(self.configuration.borrow()) } - fn delete_snapshot(&self, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>, plugin_id: Option<&str>, snapshot_id: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Delete, "/volumes/snapshot".to_string()) + #[allow(unused_mut)] + fn delete_snapshot(&self, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>, plugin_id: Option<&str>, snapshot_id: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::DELETE, "/volumes/snapshot".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -84,19 +92,24 @@ implVolumesApi for VolumesApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } if let Some(ref s) = plugin_id { - req = req.with_query_param("plugin_id".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("plugin_id".to_string(), query_value); } if let Some(ref s) = snapshot_id { - req = req.with_query_param("snapshot_id".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("snapshot_id".to_string(), query_value); } if let Some(param_value) = x_nomad_token { req = req.with_header_param("X-Nomad-Token".to_string(), param_value.to_string()); @@ -106,8 +119,9 @@ implVolumesApi for VolumesApiClient { req.execute(self.configuration.borrow()) } - fn delete_volume_registration(&self, volume_id: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>, force: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Delete, "/volume/csi/{volumeId}".to_string()) + #[allow(unused_mut)] + fn delete_volume_registration(&self, volume_id: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>, force: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::DELETE, "/volume/csi/{volumeId}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -115,16 +129,20 @@ implVolumesApi for VolumesApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } if let Some(ref s) = force { - req = req.with_query_param("force".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("force".to_string(), query_value); } req = req.with_path_param("volumeId".to_string(), volume_id.to_string()); if let Some(param_value) = x_nomad_token { @@ -135,8 +153,9 @@ implVolumesApi for VolumesApiClient { req.execute(self.configuration.borrow()) } - fn detach_or_delete_volume(&self, volume_id: &str, action: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>, node: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Delete, "/volume/csi/{volumeId}/{action}".to_string()) + #[allow(unused_mut)] + fn detach_or_delete_volume(&self, volume_id: &str, action: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>, node: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::DELETE, "/volume/csi/{volumeId}/{action}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -144,16 +163,20 @@ implVolumesApi for VolumesApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } if let Some(ref s) = node { - req = req.with_query_param("node".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("node".to_string(), query_value); } req = req.with_path_param("volumeId".to_string(), volume_id.to_string()); req = req.with_path_param("action".to_string(), action.to_string()); @@ -165,8 +188,9 @@ implVolumesApi for VolumesApiClient { req.execute(self.configuration.borrow()) } - fn get_external_volumes(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, plugin_id: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/volumes/external".to_string()) + #[allow(unused_mut)] + fn get_external_volumes(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, plugin_id: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/volumes/external".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -174,28 +198,36 @@ implVolumesApi for VolumesApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } if let Some(ref s) = plugin_id { - req = req.with_query_param("plugin_id".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("plugin_id".to_string(), query_value); } if let Some(param_value) = index { req = req.with_header_param("index".to_string(), param_value.to_string()); @@ -207,8 +239,9 @@ implVolumesApi for VolumesApiClient { req.execute(self.configuration.borrow()) } - fn get_snapshots(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, plugin_id: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/volumes/snapshot".to_string()) + #[allow(unused_mut)] + fn get_snapshots(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, plugin_id: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/volumes/snapshot".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -216,28 +249,36 @@ implVolumesApi for VolumesApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } if let Some(ref s) = plugin_id { - req = req.with_query_param("plugin_id".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("plugin_id".to_string(), query_value); } if let Some(param_value) = index { req = req.with_header_param("index".to_string(), param_value.to_string()); @@ -249,8 +290,9 @@ implVolumesApi for VolumesApiClient { req.execute(self.configuration.borrow()) } - fn get_volume(&self, volume_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/volume/csi/{volumeId}".to_string()) + #[allow(unused_mut)] + fn get_volume(&self, volume_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/volume/csi/{volumeId}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -258,25 +300,32 @@ implVolumesApi for VolumesApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } req = req.with_path_param("volumeId".to_string(), volume_id.to_string()); if let Some(param_value) = index { @@ -289,8 +338,9 @@ implVolumesApi for VolumesApiClient { req.execute(self.configuration.borrow()) } - fn get_volumes(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, node_id: Option<&str>, plugin_id: Option<&str>, _type: Option<&str>) -> Box, Error = Error>> { - let mut req = __internal_request::Request::new(hyper::Method::Get, "/volumes".to_string()) + #[allow(unused_mut)] + fn get_volumes(&self, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, node_id: Option<&str>, plugin_id: Option<&str>, _type: Option<&str>) -> Pin, Error>>>> { + let mut req = __internal_request::Request::new(hyper::Method::GET, "/volumes".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -298,34 +348,44 @@ implVolumesApi for VolumesApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = wait { - req = req.with_query_param("wait".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("wait".to_string(), query_value); } if let Some(ref s) = stale { - req = req.with_query_param("stale".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("stale".to_string(), query_value); } if let Some(ref s) = prefix { - req = req.with_query_param("prefix".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("prefix".to_string(), query_value); } if let Some(ref s) = per_page { - req = req.with_query_param("per_page".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("per_page".to_string(), query_value); } if let Some(ref s) = next_token { - req = req.with_query_param("next_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("next_token".to_string(), query_value); } if let Some(ref s) = node_id { - req = req.with_query_param("node_id".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("node_id".to_string(), query_value); } if let Some(ref s) = plugin_id { - req = req.with_query_param("plugin_id".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("plugin_id".to_string(), query_value); } if let Some(ref s) = _type { - req = req.with_query_param("type".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("type".to_string(), query_value); } if let Some(param_value) = index { req = req.with_header_param("index".to_string(), param_value.to_string()); @@ -337,8 +397,9 @@ implVolumesApi for VolumesApiClient { req.execute(self.configuration.borrow()) } - fn post_snapshot(&self, csi_snapshot_create_request: crate::models::CsiSnapshotCreateRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/volumes/snapshot".to_string()) + #[allow(unused_mut)] + fn post_snapshot(&self, csi_snapshot_create_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/volumes/snapshot".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -346,13 +407,16 @@ implVolumesApi for VolumesApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } if let Some(param_value) = x_nomad_token { req = req.with_header_param("X-Nomad-Token".to_string(), param_value.to_string()); @@ -362,8 +426,9 @@ implVolumesApi for VolumesApiClient { req.execute(self.configuration.borrow()) } - fn post_volume(&self, csi_volume_register_request: crate::models::CsiVolumeRegisterRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/volumes".to_string()) + #[allow(unused_mut)] + fn post_volume(&self, csi_volume_register_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/volumes".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -371,13 +436,16 @@ implVolumesApi for VolumesApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } if let Some(param_value) = x_nomad_token { req = req.with_header_param("X-Nomad-Token".to_string(), param_value.to_string()); @@ -388,8 +456,9 @@ implVolumesApi for VolumesApiClient { req.execute(self.configuration.borrow()) } - fn post_volume_registration(&self, volume_id: &str, csi_volume_register_request: crate::models::CsiVolumeRegisterRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Box>> { - let mut req = __internal_request::Request::new(hyper::Method::Post, "/volume/csi/{volumeId}".to_string()) + #[allow(unused_mut)] + fn post_volume_registration(&self, volume_id: &str, csi_volume_register_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Pin>>> { + let mut req = __internal_request::Request::new(hyper::Method::POST, "/volume/csi/{volumeId}".to_string()) .with_auth(__internal_request::Auth::ApiKey(__internal_request::ApiKey{ in_header: true, in_query: false, @@ -397,13 +466,16 @@ implVolumesApi for VolumesApiClient { })) ; if let Some(ref s) = region { - req = req.with_query_param("region".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("region".to_string(), query_value); } if let Some(ref s) = namespace { - req = req.with_query_param("namespace".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("namespace".to_string(), query_value); } if let Some(ref s) = idempotency_token { - req = req.with_query_param("idempotency_token".to_string(), s.to_string()); + let query_value = s.to_string(); + req = req.with_query_param("idempotency_token".to_string(), query_value); } req = req.with_path_param("volumeId".to_string(), volume_id.to_string()); if let Some(param_value) = x_nomad_token { diff --git a/clients/rust/hyper/v1/src/models/acl_policy.rs b/clients/rust/hyper/v1/src/models/acl_policy.rs index b1edcdce..ce66dd76 100644 --- a/clients/rust/hyper/v1/src/models/acl_policy.rs +++ b/clients/rust/hyper/v1/src/models/acl_policy.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AclPolicy { #[serde(rename = "CreateIndex", skip_serializing_if = "Option::is_none")] pub create_index: Option, diff --git a/clients/rust/hyper/v1/src/models/acl_policy_list_stub.rs b/clients/rust/hyper/v1/src/models/acl_policy_list_stub.rs index 60c0f2ae..f8d48327 100644 --- a/clients/rust/hyper/v1/src/models/acl_policy_list_stub.rs +++ b/clients/rust/hyper/v1/src/models/acl_policy_list_stub.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AclPolicyListStub { #[serde(rename = "CreateIndex", skip_serializing_if = "Option::is_none")] pub create_index: Option, diff --git a/clients/rust/hyper/v1/src/models/acl_token.rs b/clients/rust/hyper/v1/src/models/acl_token.rs index 28a3f488..ada8823c 100644 --- a/clients/rust/hyper/v1/src/models/acl_token.rs +++ b/clients/rust/hyper/v1/src/models/acl_token.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AclToken { #[serde(rename = "AccessorID", skip_serializing_if = "Option::is_none")] pub accessor_id: Option, diff --git a/clients/rust/hyper/v1/src/models/acl_token_list_stub.rs b/clients/rust/hyper/v1/src/models/acl_token_list_stub.rs index dd25ec2a..79bb61f5 100644 --- a/clients/rust/hyper/v1/src/models/acl_token_list_stub.rs +++ b/clients/rust/hyper/v1/src/models/acl_token_list_stub.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AclTokenListStub { #[serde(rename = "AccessorID", skip_serializing_if = "Option::is_none")] pub accessor_id: Option, diff --git a/clients/rust/hyper/v1/src/models/affinity.rs b/clients/rust/hyper/v1/src/models/affinity.rs index 7c461060..aa2d7661 100644 --- a/clients/rust/hyper/v1/src/models/affinity.rs +++ b/clients/rust/hyper/v1/src/models/affinity.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Affinity { #[serde(rename = "LTarget", skip_serializing_if = "Option::is_none")] pub l_target: Option, diff --git a/clients/rust/hyper/v1/src/models/alloc_deployment_status.rs b/clients/rust/hyper/v1/src/models/alloc_deployment_status.rs index 4db2f6b4..e1874884 100644 --- a/clients/rust/hyper/v1/src/models/alloc_deployment_status.rs +++ b/clients/rust/hyper/v1/src/models/alloc_deployment_status.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AllocDeploymentStatus { #[serde(rename = "Canary", skip_serializing_if = "Option::is_none")] pub canary: Option, diff --git a/clients/rust/hyper/v1/src/models/alloc_stop_response.rs b/clients/rust/hyper/v1/src/models/alloc_stop_response.rs index 6bd1b9d0..5a28972b 100644 --- a/clients/rust/hyper/v1/src/models/alloc_stop_response.rs +++ b/clients/rust/hyper/v1/src/models/alloc_stop_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AllocStopResponse { #[serde(rename = "EvalID", skip_serializing_if = "Option::is_none")] pub eval_id: Option, diff --git a/clients/rust/hyper/v1/src/models/allocated_cpu_resources.rs b/clients/rust/hyper/v1/src/models/allocated_cpu_resources.rs index 9bf06cf1..167729ec 100644 --- a/clients/rust/hyper/v1/src/models/allocated_cpu_resources.rs +++ b/clients/rust/hyper/v1/src/models/allocated_cpu_resources.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AllocatedCpuResources { #[serde(rename = "CpuShares", skip_serializing_if = "Option::is_none")] pub cpu_shares: Option, diff --git a/clients/rust/hyper/v1/src/models/allocated_device_resource.rs b/clients/rust/hyper/v1/src/models/allocated_device_resource.rs index dd91af8a..bdcfb8b6 100644 --- a/clients/rust/hyper/v1/src/models/allocated_device_resource.rs +++ b/clients/rust/hyper/v1/src/models/allocated_device_resource.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AllocatedDeviceResource { #[serde(rename = "DeviceIDs", skip_serializing_if = "Option::is_none")] pub device_ids: Option>, diff --git a/clients/rust/hyper/v1/src/models/allocated_memory_resources.rs b/clients/rust/hyper/v1/src/models/allocated_memory_resources.rs index eb82f5b0..43763d9e 100644 --- a/clients/rust/hyper/v1/src/models/allocated_memory_resources.rs +++ b/clients/rust/hyper/v1/src/models/allocated_memory_resources.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AllocatedMemoryResources { #[serde(rename = "MemoryMB", skip_serializing_if = "Option::is_none")] pub memory_mb: Option, diff --git a/clients/rust/hyper/v1/src/models/allocated_resources.rs b/clients/rust/hyper/v1/src/models/allocated_resources.rs index d67f31ab..af4e57dd 100644 --- a/clients/rust/hyper/v1/src/models/allocated_resources.rs +++ b/clients/rust/hyper/v1/src/models/allocated_resources.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AllocatedResources { #[serde(rename = "Shared", skip_serializing_if = "Option::is_none")] pub shared: Option>, diff --git a/clients/rust/hyper/v1/src/models/allocated_shared_resources.rs b/clients/rust/hyper/v1/src/models/allocated_shared_resources.rs index 7b11065f..67de7da2 100644 --- a/clients/rust/hyper/v1/src/models/allocated_shared_resources.rs +++ b/clients/rust/hyper/v1/src/models/allocated_shared_resources.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AllocatedSharedResources { #[serde(rename = "DiskMB", skip_serializing_if = "Option::is_none")] pub disk_mb: Option, diff --git a/clients/rust/hyper/v1/src/models/allocated_task_resources.rs b/clients/rust/hyper/v1/src/models/allocated_task_resources.rs index 0757bfdd..4e08c81a 100644 --- a/clients/rust/hyper/v1/src/models/allocated_task_resources.rs +++ b/clients/rust/hyper/v1/src/models/allocated_task_resources.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AllocatedTaskResources { #[serde(rename = "Cpu", skip_serializing_if = "Option::is_none")] pub cpu: Option>, diff --git a/clients/rust/hyper/v1/src/models/allocation.rs b/clients/rust/hyper/v1/src/models/allocation.rs index 22157a77..0dadd7a6 100644 --- a/clients/rust/hyper/v1/src/models/allocation.rs +++ b/clients/rust/hyper/v1/src/models/allocation.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Allocation { #[serde(rename = "AllocModifyIndex", skip_serializing_if = "Option::is_none")] pub alloc_modify_index: Option, diff --git a/clients/rust/hyper/v1/src/models/allocation_list_stub.rs b/clients/rust/hyper/v1/src/models/allocation_list_stub.rs index a325595f..0c0365ce 100644 --- a/clients/rust/hyper/v1/src/models/allocation_list_stub.rs +++ b/clients/rust/hyper/v1/src/models/allocation_list_stub.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AllocationListStub { #[serde(rename = "AllocatedResources", skip_serializing_if = "Option::is_none")] pub allocated_resources: Option>, diff --git a/clients/rust/hyper/v1/src/models/allocation_metric.rs b/clients/rust/hyper/v1/src/models/allocation_metric.rs index b0691234..f03bdf20 100644 --- a/clients/rust/hyper/v1/src/models/allocation_metric.rs +++ b/clients/rust/hyper/v1/src/models/allocation_metric.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AllocationMetric { #[serde(rename = "AllocationTime", skip_serializing_if = "Option::is_none")] pub allocation_time: Option, diff --git a/clients/rust/hyper/v1/src/models/attribute.rs b/clients/rust/hyper/v1/src/models/attribute.rs index 5bdca899..6a907906 100644 --- a/clients/rust/hyper/v1/src/models/attribute.rs +++ b/clients/rust/hyper/v1/src/models/attribute.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Attribute { #[serde(rename = "Bool", skip_serializing_if = "Option::is_none")] pub bool: Option, diff --git a/clients/rust/hyper/v1/src/models/autopilot_configuration.rs b/clients/rust/hyper/v1/src/models/autopilot_configuration.rs index 4b1845ee..c722e4bb 100644 --- a/clients/rust/hyper/v1/src/models/autopilot_configuration.rs +++ b/clients/rust/hyper/v1/src/models/autopilot_configuration.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AutopilotConfiguration { #[serde(rename = "CleanupDeadServers", skip_serializing_if = "Option::is_none")] pub cleanup_dead_servers: Option, diff --git a/clients/rust/hyper/v1/src/models/check_restart.rs b/clients/rust/hyper/v1/src/models/check_restart.rs index 8d2e24c9..df2a4d0c 100644 --- a/clients/rust/hyper/v1/src/models/check_restart.rs +++ b/clients/rust/hyper/v1/src/models/check_restart.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CheckRestart { #[serde(rename = "Grace", skip_serializing_if = "Option::is_none")] pub grace: Option, diff --git a/clients/rust/hyper/v1/src/models/constraint.rs b/clients/rust/hyper/v1/src/models/constraint.rs index e589b7ff..f1a9a200 100644 --- a/clients/rust/hyper/v1/src/models/constraint.rs +++ b/clients/rust/hyper/v1/src/models/constraint.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Constraint { #[serde(rename = "LTarget", skip_serializing_if = "Option::is_none")] pub l_target: Option, diff --git a/clients/rust/hyper/v1/src/models/consul.rs b/clients/rust/hyper/v1/src/models/consul.rs index d4046804..3405eaf5 100644 --- a/clients/rust/hyper/v1/src/models/consul.rs +++ b/clients/rust/hyper/v1/src/models/consul.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Consul { #[serde(rename = "Namespace", skip_serializing_if = "Option::is_none")] pub namespace: Option, diff --git a/clients/rust/hyper/v1/src/models/consul_connect.rs b/clients/rust/hyper/v1/src/models/consul_connect.rs index 5ab97898..7386665b 100644 --- a/clients/rust/hyper/v1/src/models/consul_connect.rs +++ b/clients/rust/hyper/v1/src/models/consul_connect.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulConnect { #[serde(rename = "Gateway", skip_serializing_if = "Option::is_none")] pub gateway: Option>, diff --git a/clients/rust/hyper/v1/src/models/consul_expose_config.rs b/clients/rust/hyper/v1/src/models/consul_expose_config.rs index 2bd8d3b7..0028c731 100644 --- a/clients/rust/hyper/v1/src/models/consul_expose_config.rs +++ b/clients/rust/hyper/v1/src/models/consul_expose_config.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulExposeConfig { #[serde(rename = "Path", skip_serializing_if = "Option::is_none")] pub path: Option>, diff --git a/clients/rust/hyper/v1/src/models/consul_expose_path.rs b/clients/rust/hyper/v1/src/models/consul_expose_path.rs index 77f8ba79..ed3743a0 100644 --- a/clients/rust/hyper/v1/src/models/consul_expose_path.rs +++ b/clients/rust/hyper/v1/src/models/consul_expose_path.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulExposePath { #[serde(rename = "ListenerPort", skip_serializing_if = "Option::is_none")] pub listener_port: Option, diff --git a/clients/rust/hyper/v1/src/models/consul_gateway.rs b/clients/rust/hyper/v1/src/models/consul_gateway.rs index 7e11dbda..2160cf5e 100644 --- a/clients/rust/hyper/v1/src/models/consul_gateway.rs +++ b/clients/rust/hyper/v1/src/models/consul_gateway.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulGateway { #[serde(rename = "Ingress", skip_serializing_if = "Option::is_none")] pub ingress: Option>, diff --git a/clients/rust/hyper/v1/src/models/consul_gateway_bind_address.rs b/clients/rust/hyper/v1/src/models/consul_gateway_bind_address.rs index 251958fb..e8f5c5cd 100644 --- a/clients/rust/hyper/v1/src/models/consul_gateway_bind_address.rs +++ b/clients/rust/hyper/v1/src/models/consul_gateway_bind_address.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulGatewayBindAddress { #[serde(rename = "Address", skip_serializing_if = "Option::is_none")] pub address: Option, diff --git a/clients/rust/hyper/v1/src/models/consul_gateway_proxy.rs b/clients/rust/hyper/v1/src/models/consul_gateway_proxy.rs index d532b976..4393868c 100644 --- a/clients/rust/hyper/v1/src/models/consul_gateway_proxy.rs +++ b/clients/rust/hyper/v1/src/models/consul_gateway_proxy.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulGatewayProxy { #[serde(rename = "Config", skip_serializing_if = "Option::is_none")] pub config: Option<::std::collections::HashMap>, diff --git a/clients/rust/hyper/v1/src/models/consul_gateway_tls_config.rs b/clients/rust/hyper/v1/src/models/consul_gateway_tls_config.rs index 03f8bddb..08b80130 100644 --- a/clients/rust/hyper/v1/src/models/consul_gateway_tls_config.rs +++ b/clients/rust/hyper/v1/src/models/consul_gateway_tls_config.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulGatewayTlsConfig { #[serde(rename = "CipherSuites", skip_serializing_if = "Option::is_none")] pub cipher_suites: Option>, diff --git a/clients/rust/hyper/v1/src/models/consul_ingress_config_entry.rs b/clients/rust/hyper/v1/src/models/consul_ingress_config_entry.rs index 1e77961e..211df97d 100644 --- a/clients/rust/hyper/v1/src/models/consul_ingress_config_entry.rs +++ b/clients/rust/hyper/v1/src/models/consul_ingress_config_entry.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulIngressConfigEntry { #[serde(rename = "Listeners", skip_serializing_if = "Option::is_none")] pub listeners: Option>, diff --git a/clients/rust/hyper/v1/src/models/consul_ingress_listener.rs b/clients/rust/hyper/v1/src/models/consul_ingress_listener.rs index 1115ec15..09f1f0e9 100644 --- a/clients/rust/hyper/v1/src/models/consul_ingress_listener.rs +++ b/clients/rust/hyper/v1/src/models/consul_ingress_listener.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulIngressListener { #[serde(rename = "Port", skip_serializing_if = "Option::is_none")] pub port: Option, diff --git a/clients/rust/hyper/v1/src/models/consul_ingress_service.rs b/clients/rust/hyper/v1/src/models/consul_ingress_service.rs index 29d04c12..be497f8b 100644 --- a/clients/rust/hyper/v1/src/models/consul_ingress_service.rs +++ b/clients/rust/hyper/v1/src/models/consul_ingress_service.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulIngressService { #[serde(rename = "Hosts", skip_serializing_if = "Option::is_none")] pub hosts: Option>, diff --git a/clients/rust/hyper/v1/src/models/consul_linked_service.rs b/clients/rust/hyper/v1/src/models/consul_linked_service.rs index 9ae03e92..ee9d6e7f 100644 --- a/clients/rust/hyper/v1/src/models/consul_linked_service.rs +++ b/clients/rust/hyper/v1/src/models/consul_linked_service.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulLinkedService { #[serde(rename = "CAFile", skip_serializing_if = "Option::is_none")] pub ca_file: Option, diff --git a/clients/rust/hyper/v1/src/models/consul_mesh_gateway.rs b/clients/rust/hyper/v1/src/models/consul_mesh_gateway.rs index bac5dacd..564423f5 100644 --- a/clients/rust/hyper/v1/src/models/consul_mesh_gateway.rs +++ b/clients/rust/hyper/v1/src/models/consul_mesh_gateway.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulMeshGateway { #[serde(rename = "Mode", skip_serializing_if = "Option::is_none")] pub mode: Option, diff --git a/clients/rust/hyper/v1/src/models/consul_proxy.rs b/clients/rust/hyper/v1/src/models/consul_proxy.rs index 9c5dbf05..8ffec7ad 100644 --- a/clients/rust/hyper/v1/src/models/consul_proxy.rs +++ b/clients/rust/hyper/v1/src/models/consul_proxy.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulProxy { #[serde(rename = "Config", skip_serializing_if = "Option::is_none")] pub config: Option<::std::collections::HashMap>, diff --git a/clients/rust/hyper/v1/src/models/consul_sidecar_service.rs b/clients/rust/hyper/v1/src/models/consul_sidecar_service.rs index 3253287b..390a5b93 100644 --- a/clients/rust/hyper/v1/src/models/consul_sidecar_service.rs +++ b/clients/rust/hyper/v1/src/models/consul_sidecar_service.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulSidecarService { #[serde(rename = "DisableDefaultTCPCheck", skip_serializing_if = "Option::is_none")] pub disable_default_tcp_check: Option, diff --git a/clients/rust/hyper/v1/src/models/consul_terminating_config_entry.rs b/clients/rust/hyper/v1/src/models/consul_terminating_config_entry.rs index 053e343a..15fcf040 100644 --- a/clients/rust/hyper/v1/src/models/consul_terminating_config_entry.rs +++ b/clients/rust/hyper/v1/src/models/consul_terminating_config_entry.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulTerminatingConfigEntry { #[serde(rename = "Services", skip_serializing_if = "Option::is_none")] pub services: Option>, diff --git a/clients/rust/hyper/v1/src/models/consul_upstream.rs b/clients/rust/hyper/v1/src/models/consul_upstream.rs index 0ce4f520..cde3e6bb 100644 --- a/clients/rust/hyper/v1/src/models/consul_upstream.rs +++ b/clients/rust/hyper/v1/src/models/consul_upstream.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulUpstream { #[serde(rename = "Datacenter", skip_serializing_if = "Option::is_none")] pub datacenter: Option, diff --git a/clients/rust/hyper/v1/src/models/csi_controller_info.rs b/clients/rust/hyper/v1/src/models/csi_controller_info.rs index 1e834ebf..2e5549cd 100644 --- a/clients/rust/hyper/v1/src/models/csi_controller_info.rs +++ b/clients/rust/hyper/v1/src/models/csi_controller_info.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiControllerInfo { #[serde(rename = "SupportsAttachDetach", skip_serializing_if = "Option::is_none")] pub supports_attach_detach: Option, diff --git a/clients/rust/hyper/v1/src/models/csi_info.rs b/clients/rust/hyper/v1/src/models/csi_info.rs index d0ce4e8e..a8cac8e5 100644 --- a/clients/rust/hyper/v1/src/models/csi_info.rs +++ b/clients/rust/hyper/v1/src/models/csi_info.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiInfo { #[serde(rename = "AllocID", skip_serializing_if = "Option::is_none")] pub alloc_id: Option, diff --git a/clients/rust/hyper/v1/src/models/csi_mount_options.rs b/clients/rust/hyper/v1/src/models/csi_mount_options.rs index 8e1ab73f..98968f57 100644 --- a/clients/rust/hyper/v1/src/models/csi_mount_options.rs +++ b/clients/rust/hyper/v1/src/models/csi_mount_options.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiMountOptions { #[serde(rename = "FSType", skip_serializing_if = "Option::is_none")] pub fs_type: Option, diff --git a/clients/rust/hyper/v1/src/models/csi_node_info.rs b/clients/rust/hyper/v1/src/models/csi_node_info.rs index 81546ec6..33ed8813 100644 --- a/clients/rust/hyper/v1/src/models/csi_node_info.rs +++ b/clients/rust/hyper/v1/src/models/csi_node_info.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiNodeInfo { #[serde(rename = "AccessibleTopology", skip_serializing_if = "Option::is_none")] pub accessible_topology: Option>, diff --git a/clients/rust/hyper/v1/src/models/csi_plugin.rs b/clients/rust/hyper/v1/src/models/csi_plugin.rs index ef86360c..f92e7a32 100644 --- a/clients/rust/hyper/v1/src/models/csi_plugin.rs +++ b/clients/rust/hyper/v1/src/models/csi_plugin.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiPlugin { #[serde(rename = "Allocations", skip_serializing_if = "Option::is_none")] pub allocations: Option>, diff --git a/clients/rust/hyper/v1/src/models/csi_plugin_list_stub.rs b/clients/rust/hyper/v1/src/models/csi_plugin_list_stub.rs index da6cf41c..9e973a9a 100644 --- a/clients/rust/hyper/v1/src/models/csi_plugin_list_stub.rs +++ b/clients/rust/hyper/v1/src/models/csi_plugin_list_stub.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiPluginListStub { #[serde(rename = "ControllerRequired", skip_serializing_if = "Option::is_none")] pub controller_required: Option, diff --git a/clients/rust/hyper/v1/src/models/csi_snapshot.rs b/clients/rust/hyper/v1/src/models/csi_snapshot.rs index c9c3b508..10ee1dae 100644 --- a/clients/rust/hyper/v1/src/models/csi_snapshot.rs +++ b/clients/rust/hyper/v1/src/models/csi_snapshot.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiSnapshot { #[serde(rename = "CreateTime", skip_serializing_if = "Option::is_none")] pub create_time: Option, diff --git a/clients/rust/hyper/v1/src/models/csi_snapshot_create_request.rs b/clients/rust/hyper/v1/src/models/csi_snapshot_create_request.rs index b2a4d147..164e005e 100644 --- a/clients/rust/hyper/v1/src/models/csi_snapshot_create_request.rs +++ b/clients/rust/hyper/v1/src/models/csi_snapshot_create_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiSnapshotCreateRequest { #[serde(rename = "Namespace", skip_serializing_if = "Option::is_none")] pub namespace: Option, diff --git a/clients/rust/hyper/v1/src/models/csi_snapshot_create_response.rs b/clients/rust/hyper/v1/src/models/csi_snapshot_create_response.rs index 86ca0e45..ba5e49b4 100644 --- a/clients/rust/hyper/v1/src/models/csi_snapshot_create_response.rs +++ b/clients/rust/hyper/v1/src/models/csi_snapshot_create_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiSnapshotCreateResponse { #[serde(rename = "KnownLeader", skip_serializing_if = "Option::is_none")] pub known_leader: Option, diff --git a/clients/rust/hyper/v1/src/models/csi_snapshot_list_response.rs b/clients/rust/hyper/v1/src/models/csi_snapshot_list_response.rs index 6513c969..48b3dde5 100644 --- a/clients/rust/hyper/v1/src/models/csi_snapshot_list_response.rs +++ b/clients/rust/hyper/v1/src/models/csi_snapshot_list_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiSnapshotListResponse { #[serde(rename = "KnownLeader", skip_serializing_if = "Option::is_none")] pub known_leader: Option, diff --git a/clients/rust/hyper/v1/src/models/csi_topology.rs b/clients/rust/hyper/v1/src/models/csi_topology.rs index 4b1b2e2e..da47f855 100644 --- a/clients/rust/hyper/v1/src/models/csi_topology.rs +++ b/clients/rust/hyper/v1/src/models/csi_topology.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiTopology { #[serde(rename = "Segments", skip_serializing_if = "Option::is_none")] pub segments: Option<::std::collections::HashMap>, diff --git a/clients/rust/hyper/v1/src/models/csi_topology_request.rs b/clients/rust/hyper/v1/src/models/csi_topology_request.rs index 1162efa3..9fca6d73 100644 --- a/clients/rust/hyper/v1/src/models/csi_topology_request.rs +++ b/clients/rust/hyper/v1/src/models/csi_topology_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiTopologyRequest { #[serde(rename = "Preferred", skip_serializing_if = "Option::is_none")] pub preferred: Option>, diff --git a/clients/rust/hyper/v1/src/models/csi_volume.rs b/clients/rust/hyper/v1/src/models/csi_volume.rs index 78e0310f..781b1d33 100644 --- a/clients/rust/hyper/v1/src/models/csi_volume.rs +++ b/clients/rust/hyper/v1/src/models/csi_volume.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiVolume { #[serde(rename = "AccessMode", skip_serializing_if = "Option::is_none")] pub access_mode: Option, diff --git a/clients/rust/hyper/v1/src/models/csi_volume_capability.rs b/clients/rust/hyper/v1/src/models/csi_volume_capability.rs index 667ad365..e78567ee 100644 --- a/clients/rust/hyper/v1/src/models/csi_volume_capability.rs +++ b/clients/rust/hyper/v1/src/models/csi_volume_capability.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiVolumeCapability { #[serde(rename = "AccessMode", skip_serializing_if = "Option::is_none")] pub access_mode: Option, diff --git a/clients/rust/hyper/v1/src/models/csi_volume_create_request.rs b/clients/rust/hyper/v1/src/models/csi_volume_create_request.rs index 82ad1ac4..e684ba5c 100644 --- a/clients/rust/hyper/v1/src/models/csi_volume_create_request.rs +++ b/clients/rust/hyper/v1/src/models/csi_volume_create_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiVolumeCreateRequest { #[serde(rename = "Namespace", skip_serializing_if = "Option::is_none")] pub namespace: Option, diff --git a/clients/rust/hyper/v1/src/models/csi_volume_external_stub.rs b/clients/rust/hyper/v1/src/models/csi_volume_external_stub.rs index c3296192..7e5aef87 100644 --- a/clients/rust/hyper/v1/src/models/csi_volume_external_stub.rs +++ b/clients/rust/hyper/v1/src/models/csi_volume_external_stub.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiVolumeExternalStub { #[serde(rename = "CapacityBytes", skip_serializing_if = "Option::is_none")] pub capacity_bytes: Option, diff --git a/clients/rust/hyper/v1/src/models/csi_volume_list_external_response.rs b/clients/rust/hyper/v1/src/models/csi_volume_list_external_response.rs index 16fb143f..d9f350b2 100644 --- a/clients/rust/hyper/v1/src/models/csi_volume_list_external_response.rs +++ b/clients/rust/hyper/v1/src/models/csi_volume_list_external_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiVolumeListExternalResponse { #[serde(rename = "NextToken", skip_serializing_if = "Option::is_none")] pub next_token: Option, diff --git a/clients/rust/hyper/v1/src/models/csi_volume_list_stub.rs b/clients/rust/hyper/v1/src/models/csi_volume_list_stub.rs index 82ac6b5a..5de566cb 100644 --- a/clients/rust/hyper/v1/src/models/csi_volume_list_stub.rs +++ b/clients/rust/hyper/v1/src/models/csi_volume_list_stub.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiVolumeListStub { #[serde(rename = "AccessMode", skip_serializing_if = "Option::is_none")] pub access_mode: Option, diff --git a/clients/rust/hyper/v1/src/models/csi_volume_register_request.rs b/clients/rust/hyper/v1/src/models/csi_volume_register_request.rs index 429344d8..db9e1ce6 100644 --- a/clients/rust/hyper/v1/src/models/csi_volume_register_request.rs +++ b/clients/rust/hyper/v1/src/models/csi_volume_register_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiVolumeRegisterRequest { #[serde(rename = "Namespace", skip_serializing_if = "Option::is_none")] pub namespace: Option, diff --git a/clients/rust/hyper/v1/src/models/deployment.rs b/clients/rust/hyper/v1/src/models/deployment.rs index c920b2ff..ebd5ddd5 100644 --- a/clients/rust/hyper/v1/src/models/deployment.rs +++ b/clients/rust/hyper/v1/src/models/deployment.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Deployment { #[serde(rename = "CreateIndex", skip_serializing_if = "Option::is_none")] pub create_index: Option, diff --git a/clients/rust/hyper/v1/src/models/deployment_alloc_health_request.rs b/clients/rust/hyper/v1/src/models/deployment_alloc_health_request.rs index 63b8f71f..9ba87dc1 100644 --- a/clients/rust/hyper/v1/src/models/deployment_alloc_health_request.rs +++ b/clients/rust/hyper/v1/src/models/deployment_alloc_health_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct DeploymentAllocHealthRequest { #[serde(rename = "DeploymentID", skip_serializing_if = "Option::is_none")] pub deployment_id: Option, diff --git a/clients/rust/hyper/v1/src/models/deployment_pause_request.rs b/clients/rust/hyper/v1/src/models/deployment_pause_request.rs index 56de42e6..1d899133 100644 --- a/clients/rust/hyper/v1/src/models/deployment_pause_request.rs +++ b/clients/rust/hyper/v1/src/models/deployment_pause_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct DeploymentPauseRequest { #[serde(rename = "DeploymentID", skip_serializing_if = "Option::is_none")] pub deployment_id: Option, diff --git a/clients/rust/hyper/v1/src/models/deployment_promote_request.rs b/clients/rust/hyper/v1/src/models/deployment_promote_request.rs index 255b0941..b27ca50c 100644 --- a/clients/rust/hyper/v1/src/models/deployment_promote_request.rs +++ b/clients/rust/hyper/v1/src/models/deployment_promote_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct DeploymentPromoteRequest { #[serde(rename = "All", skip_serializing_if = "Option::is_none")] pub all: Option, diff --git a/clients/rust/hyper/v1/src/models/deployment_state.rs b/clients/rust/hyper/v1/src/models/deployment_state.rs index d83bc5d9..31662709 100644 --- a/clients/rust/hyper/v1/src/models/deployment_state.rs +++ b/clients/rust/hyper/v1/src/models/deployment_state.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct DeploymentState { #[serde(rename = "AutoRevert", skip_serializing_if = "Option::is_none")] pub auto_revert: Option, diff --git a/clients/rust/hyper/v1/src/models/deployment_unblock_request.rs b/clients/rust/hyper/v1/src/models/deployment_unblock_request.rs index 6cf4d6a6..9408cb19 100644 --- a/clients/rust/hyper/v1/src/models/deployment_unblock_request.rs +++ b/clients/rust/hyper/v1/src/models/deployment_unblock_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct DeploymentUnblockRequest { #[serde(rename = "DeploymentID", skip_serializing_if = "Option::is_none")] pub deployment_id: Option, diff --git a/clients/rust/hyper/v1/src/models/deployment_update_response.rs b/clients/rust/hyper/v1/src/models/deployment_update_response.rs index 6e32f600..aea37898 100644 --- a/clients/rust/hyper/v1/src/models/deployment_update_response.rs +++ b/clients/rust/hyper/v1/src/models/deployment_update_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct DeploymentUpdateResponse { #[serde(rename = "DeploymentModifyIndex", skip_serializing_if = "Option::is_none")] pub deployment_modify_index: Option, diff --git a/clients/rust/hyper/v1/src/models/desired_transition.rs b/clients/rust/hyper/v1/src/models/desired_transition.rs index 5f9c818b..c271d376 100644 --- a/clients/rust/hyper/v1/src/models/desired_transition.rs +++ b/clients/rust/hyper/v1/src/models/desired_transition.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct DesiredTransition { #[serde(rename = "Migrate", skip_serializing_if = "Option::is_none")] pub migrate: Option, diff --git a/clients/rust/hyper/v1/src/models/desired_updates.rs b/clients/rust/hyper/v1/src/models/desired_updates.rs index e5e594d3..87b632ea 100644 --- a/clients/rust/hyper/v1/src/models/desired_updates.rs +++ b/clients/rust/hyper/v1/src/models/desired_updates.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct DesiredUpdates { #[serde(rename = "Canary", skip_serializing_if = "Option::is_none")] pub canary: Option, diff --git a/clients/rust/hyper/v1/src/models/dispatch_payload_config.rs b/clients/rust/hyper/v1/src/models/dispatch_payload_config.rs index b0b75cb3..ba7df09b 100644 --- a/clients/rust/hyper/v1/src/models/dispatch_payload_config.rs +++ b/clients/rust/hyper/v1/src/models/dispatch_payload_config.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct DispatchPayloadConfig { #[serde(rename = "File", skip_serializing_if = "Option::is_none")] pub file: Option, diff --git a/clients/rust/hyper/v1/src/models/dns_config.rs b/clients/rust/hyper/v1/src/models/dns_config.rs index 6ff654f9..de93dbb0 100644 --- a/clients/rust/hyper/v1/src/models/dns_config.rs +++ b/clients/rust/hyper/v1/src/models/dns_config.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct DnsConfig { #[serde(rename = "Options", skip_serializing_if = "Option::is_none")] pub options: Option>, diff --git a/clients/rust/hyper/v1/src/models/drain_metadata.rs b/clients/rust/hyper/v1/src/models/drain_metadata.rs index e6189e22..a0e5a01c 100644 --- a/clients/rust/hyper/v1/src/models/drain_metadata.rs +++ b/clients/rust/hyper/v1/src/models/drain_metadata.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct DrainMetadata { #[serde(rename = "AccessorID", skip_serializing_if = "Option::is_none")] pub accessor_id: Option, diff --git a/clients/rust/hyper/v1/src/models/drain_spec.rs b/clients/rust/hyper/v1/src/models/drain_spec.rs index 98b34280..d386c2ca 100644 --- a/clients/rust/hyper/v1/src/models/drain_spec.rs +++ b/clients/rust/hyper/v1/src/models/drain_spec.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct DrainSpec { #[serde(rename = "Deadline", skip_serializing_if = "Option::is_none")] pub deadline: Option, diff --git a/clients/rust/hyper/v1/src/models/drain_strategy.rs b/clients/rust/hyper/v1/src/models/drain_strategy.rs index 612cf7f5..0d0d215d 100644 --- a/clients/rust/hyper/v1/src/models/drain_strategy.rs +++ b/clients/rust/hyper/v1/src/models/drain_strategy.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct DrainStrategy { #[serde(rename = "Deadline", skip_serializing_if = "Option::is_none")] pub deadline: Option, diff --git a/clients/rust/hyper/v1/src/models/driver_info.rs b/clients/rust/hyper/v1/src/models/driver_info.rs index 6db78592..95b5ee7b 100644 --- a/clients/rust/hyper/v1/src/models/driver_info.rs +++ b/clients/rust/hyper/v1/src/models/driver_info.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct DriverInfo { #[serde(rename = "Attributes", skip_serializing_if = "Option::is_none")] pub attributes: Option<::std::collections::HashMap>, diff --git a/clients/rust/hyper/v1/src/models/ephemeral_disk.rs b/clients/rust/hyper/v1/src/models/ephemeral_disk.rs index 525a6c27..d1750c86 100644 --- a/clients/rust/hyper/v1/src/models/ephemeral_disk.rs +++ b/clients/rust/hyper/v1/src/models/ephemeral_disk.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct EphemeralDisk { #[serde(rename = "Migrate", skip_serializing_if = "Option::is_none")] pub migrate: Option, diff --git a/clients/rust/hyper/v1/src/models/eval_options.rs b/clients/rust/hyper/v1/src/models/eval_options.rs index 58193f02..5fc78282 100644 --- a/clients/rust/hyper/v1/src/models/eval_options.rs +++ b/clients/rust/hyper/v1/src/models/eval_options.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct EvalOptions { #[serde(rename = "ForceReschedule", skip_serializing_if = "Option::is_none")] pub force_reschedule: Option, diff --git a/clients/rust/hyper/v1/src/models/evaluation.rs b/clients/rust/hyper/v1/src/models/evaluation.rs index e7b59192..1d46d711 100644 --- a/clients/rust/hyper/v1/src/models/evaluation.rs +++ b/clients/rust/hyper/v1/src/models/evaluation.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Evaluation { #[serde(rename = "AnnotatePlan", skip_serializing_if = "Option::is_none")] pub annotate_plan: Option, diff --git a/clients/rust/hyper/v1/src/models/evaluation_stub.rs b/clients/rust/hyper/v1/src/models/evaluation_stub.rs index a4a57ffb..05d8d031 100644 --- a/clients/rust/hyper/v1/src/models/evaluation_stub.rs +++ b/clients/rust/hyper/v1/src/models/evaluation_stub.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct EvaluationStub { #[serde(rename = "BlockedEval", skip_serializing_if = "Option::is_none")] pub blocked_eval: Option, diff --git a/clients/rust/hyper/v1/src/models/field_diff.rs b/clients/rust/hyper/v1/src/models/field_diff.rs index 7668562d..9efe4aee 100644 --- a/clients/rust/hyper/v1/src/models/field_diff.rs +++ b/clients/rust/hyper/v1/src/models/field_diff.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct FieldDiff { #[serde(rename = "Annotations", skip_serializing_if = "Option::is_none")] pub annotations: Option>, diff --git a/clients/rust/hyper/v1/src/models/fuzzy_match.rs b/clients/rust/hyper/v1/src/models/fuzzy_match.rs index 1f27edd6..16487382 100644 --- a/clients/rust/hyper/v1/src/models/fuzzy_match.rs +++ b/clients/rust/hyper/v1/src/models/fuzzy_match.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct FuzzyMatch { #[serde(rename = "ID", skip_serializing_if = "Option::is_none")] pub ID: Option, diff --git a/clients/rust/hyper/v1/src/models/fuzzy_search_request.rs b/clients/rust/hyper/v1/src/models/fuzzy_search_request.rs index 90410ed0..41721f80 100644 --- a/clients/rust/hyper/v1/src/models/fuzzy_search_request.rs +++ b/clients/rust/hyper/v1/src/models/fuzzy_search_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct FuzzySearchRequest { #[serde(rename = "AllowStale", skip_serializing_if = "Option::is_none")] pub allow_stale: Option, diff --git a/clients/rust/hyper/v1/src/models/fuzzy_search_response.rs b/clients/rust/hyper/v1/src/models/fuzzy_search_response.rs index 338dc6c9..aec16d1a 100644 --- a/clients/rust/hyper/v1/src/models/fuzzy_search_response.rs +++ b/clients/rust/hyper/v1/src/models/fuzzy_search_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct FuzzySearchResponse { #[serde(rename = "KnownLeader", skip_serializing_if = "Option::is_none")] pub known_leader: Option, diff --git a/clients/rust/hyper/v1/src/models/gauge_value.rs b/clients/rust/hyper/v1/src/models/gauge_value.rs index e0968c24..f49a9eb7 100644 --- a/clients/rust/hyper/v1/src/models/gauge_value.rs +++ b/clients/rust/hyper/v1/src/models/gauge_value.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GaugeValue { #[serde(rename = "Labels", skip_serializing_if = "Option::is_none")] pub labels: Option<::std::collections::HashMap>, diff --git a/clients/rust/hyper/v1/src/models/host_network_info.rs b/clients/rust/hyper/v1/src/models/host_network_info.rs index cf6039f2..f019d608 100644 --- a/clients/rust/hyper/v1/src/models/host_network_info.rs +++ b/clients/rust/hyper/v1/src/models/host_network_info.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct HostNetworkInfo { #[serde(rename = "CIDR", skip_serializing_if = "Option::is_none")] pub CIDR: Option, diff --git a/clients/rust/hyper/v1/src/models/host_volume_info.rs b/clients/rust/hyper/v1/src/models/host_volume_info.rs index ab73c447..a52a0ce6 100644 --- a/clients/rust/hyper/v1/src/models/host_volume_info.rs +++ b/clients/rust/hyper/v1/src/models/host_volume_info.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct HostVolumeInfo { #[serde(rename = "Path", skip_serializing_if = "Option::is_none")] pub path: Option, diff --git a/clients/rust/hyper/v1/src/models/job.rs b/clients/rust/hyper/v1/src/models/job.rs index 1997fb32..5ef536d9 100644 --- a/clients/rust/hyper/v1/src/models/job.rs +++ b/clients/rust/hyper/v1/src/models/job.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Job { #[serde(rename = "Affinities", skip_serializing_if = "Option::is_none")] pub affinities: Option>, diff --git a/clients/rust/hyper/v1/src/models/job_children_summary.rs b/clients/rust/hyper/v1/src/models/job_children_summary.rs index 3aef86ee..394fab5a 100644 --- a/clients/rust/hyper/v1/src/models/job_children_summary.rs +++ b/clients/rust/hyper/v1/src/models/job_children_summary.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobChildrenSummary { #[serde(rename = "Dead", skip_serializing_if = "Option::is_none")] pub dead: Option, diff --git a/clients/rust/hyper/v1/src/models/job_deregister_response.rs b/clients/rust/hyper/v1/src/models/job_deregister_response.rs index 066f961c..22e03aad 100644 --- a/clients/rust/hyper/v1/src/models/job_deregister_response.rs +++ b/clients/rust/hyper/v1/src/models/job_deregister_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobDeregisterResponse { #[serde(rename = "EvalCreateIndex", skip_serializing_if = "Option::is_none")] pub eval_create_index: Option, diff --git a/clients/rust/hyper/v1/src/models/job_diff.rs b/clients/rust/hyper/v1/src/models/job_diff.rs index 34aa3def..64aba342 100644 --- a/clients/rust/hyper/v1/src/models/job_diff.rs +++ b/clients/rust/hyper/v1/src/models/job_diff.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobDiff { #[serde(rename = "Fields", skip_serializing_if = "Option::is_none")] pub fields: Option>, diff --git a/clients/rust/hyper/v1/src/models/job_dispatch_request.rs b/clients/rust/hyper/v1/src/models/job_dispatch_request.rs index c08ce8d5..79ac5f87 100644 --- a/clients/rust/hyper/v1/src/models/job_dispatch_request.rs +++ b/clients/rust/hyper/v1/src/models/job_dispatch_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobDispatchRequest { #[serde(rename = "JobID", skip_serializing_if = "Option::is_none")] pub job_id: Option, diff --git a/clients/rust/hyper/v1/src/models/job_dispatch_response.rs b/clients/rust/hyper/v1/src/models/job_dispatch_response.rs index 6c9b527b..a3b96d14 100644 --- a/clients/rust/hyper/v1/src/models/job_dispatch_response.rs +++ b/clients/rust/hyper/v1/src/models/job_dispatch_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobDispatchResponse { #[serde(rename = "DispatchedJobID", skip_serializing_if = "Option::is_none")] pub dispatched_job_id: Option, diff --git a/clients/rust/hyper/v1/src/models/job_evaluate_request.rs b/clients/rust/hyper/v1/src/models/job_evaluate_request.rs index 52bbcf19..7f718ecf 100644 --- a/clients/rust/hyper/v1/src/models/job_evaluate_request.rs +++ b/clients/rust/hyper/v1/src/models/job_evaluate_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobEvaluateRequest { #[serde(rename = "EvalOptions", skip_serializing_if = "Option::is_none")] pub eval_options: Option>, diff --git a/clients/rust/hyper/v1/src/models/job_list_stub.rs b/clients/rust/hyper/v1/src/models/job_list_stub.rs index 021aeb8e..60356a0a 100644 --- a/clients/rust/hyper/v1/src/models/job_list_stub.rs +++ b/clients/rust/hyper/v1/src/models/job_list_stub.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobListStub { #[serde(rename = "CreateIndex", skip_serializing_if = "Option::is_none")] pub create_index: Option, diff --git a/clients/rust/hyper/v1/src/models/job_plan_request.rs b/clients/rust/hyper/v1/src/models/job_plan_request.rs index ec1198f7..468f3e30 100644 --- a/clients/rust/hyper/v1/src/models/job_plan_request.rs +++ b/clients/rust/hyper/v1/src/models/job_plan_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobPlanRequest { #[serde(rename = "Diff", skip_serializing_if = "Option::is_none")] pub diff: Option, diff --git a/clients/rust/hyper/v1/src/models/job_plan_response.rs b/clients/rust/hyper/v1/src/models/job_plan_response.rs index 01f1452f..a29d5a35 100644 --- a/clients/rust/hyper/v1/src/models/job_plan_response.rs +++ b/clients/rust/hyper/v1/src/models/job_plan_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobPlanResponse { #[serde(rename = "Annotations", skip_serializing_if = "Option::is_none")] pub annotations: Option>, diff --git a/clients/rust/hyper/v1/src/models/job_register_request.rs b/clients/rust/hyper/v1/src/models/job_register_request.rs index 464d71a1..5037c6c4 100644 --- a/clients/rust/hyper/v1/src/models/job_register_request.rs +++ b/clients/rust/hyper/v1/src/models/job_register_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobRegisterRequest { #[serde(rename = "EnforceIndex", skip_serializing_if = "Option::is_none")] pub enforce_index: Option, diff --git a/clients/rust/hyper/v1/src/models/job_register_response.rs b/clients/rust/hyper/v1/src/models/job_register_response.rs index cafa8935..2f36349c 100644 --- a/clients/rust/hyper/v1/src/models/job_register_response.rs +++ b/clients/rust/hyper/v1/src/models/job_register_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobRegisterResponse { #[serde(rename = "EvalCreateIndex", skip_serializing_if = "Option::is_none")] pub eval_create_index: Option, diff --git a/clients/rust/hyper/v1/src/models/job_revert_request.rs b/clients/rust/hyper/v1/src/models/job_revert_request.rs index abf3eafb..ff6fd7fe 100644 --- a/clients/rust/hyper/v1/src/models/job_revert_request.rs +++ b/clients/rust/hyper/v1/src/models/job_revert_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobRevertRequest { #[serde(rename = "ConsulToken", skip_serializing_if = "Option::is_none")] pub consul_token: Option, diff --git a/clients/rust/hyper/v1/src/models/job_scale_status_response.rs b/clients/rust/hyper/v1/src/models/job_scale_status_response.rs index 832cdb76..c1ef689c 100644 --- a/clients/rust/hyper/v1/src/models/job_scale_status_response.rs +++ b/clients/rust/hyper/v1/src/models/job_scale_status_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobScaleStatusResponse { #[serde(rename = "JobCreateIndex", skip_serializing_if = "Option::is_none")] pub job_create_index: Option, diff --git a/clients/rust/hyper/v1/src/models/job_stability_request.rs b/clients/rust/hyper/v1/src/models/job_stability_request.rs index 721999c0..eba77f55 100644 --- a/clients/rust/hyper/v1/src/models/job_stability_request.rs +++ b/clients/rust/hyper/v1/src/models/job_stability_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobStabilityRequest { #[serde(rename = "JobID", skip_serializing_if = "Option::is_none")] pub job_id: Option, diff --git a/clients/rust/hyper/v1/src/models/job_stability_response.rs b/clients/rust/hyper/v1/src/models/job_stability_response.rs index 70cdfe79..90818bb5 100644 --- a/clients/rust/hyper/v1/src/models/job_stability_response.rs +++ b/clients/rust/hyper/v1/src/models/job_stability_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobStabilityResponse { #[serde(rename = "Index", skip_serializing_if = "Option::is_none")] pub index: Option, diff --git a/clients/rust/hyper/v1/src/models/job_summary.rs b/clients/rust/hyper/v1/src/models/job_summary.rs index c558db84..a1d1bc0c 100644 --- a/clients/rust/hyper/v1/src/models/job_summary.rs +++ b/clients/rust/hyper/v1/src/models/job_summary.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobSummary { #[serde(rename = "Children", skip_serializing_if = "Option::is_none")] pub children: Option>, diff --git a/clients/rust/hyper/v1/src/models/job_validate_request.rs b/clients/rust/hyper/v1/src/models/job_validate_request.rs index 1935983e..1214d6a4 100644 --- a/clients/rust/hyper/v1/src/models/job_validate_request.rs +++ b/clients/rust/hyper/v1/src/models/job_validate_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobValidateRequest { #[serde(rename = "Job", skip_serializing_if = "Option::is_none")] pub job: Option>, diff --git a/clients/rust/hyper/v1/src/models/job_validate_response.rs b/clients/rust/hyper/v1/src/models/job_validate_response.rs index f64fb559..35271063 100644 --- a/clients/rust/hyper/v1/src/models/job_validate_response.rs +++ b/clients/rust/hyper/v1/src/models/job_validate_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobValidateResponse { #[serde(rename = "DriverConfigValidated", skip_serializing_if = "Option::is_none")] pub driver_config_validated: Option, diff --git a/clients/rust/hyper/v1/src/models/job_versions_response.rs b/clients/rust/hyper/v1/src/models/job_versions_response.rs index c9200046..bc025570 100644 --- a/clients/rust/hyper/v1/src/models/job_versions_response.rs +++ b/clients/rust/hyper/v1/src/models/job_versions_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobVersionsResponse { #[serde(rename = "Diffs", skip_serializing_if = "Option::is_none")] pub diffs: Option>, diff --git a/clients/rust/hyper/v1/src/models/jobs_parse_request.rs b/clients/rust/hyper/v1/src/models/jobs_parse_request.rs index cb7c4a16..27e0a57d 100644 --- a/clients/rust/hyper/v1/src/models/jobs_parse_request.rs +++ b/clients/rust/hyper/v1/src/models/jobs_parse_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobsParseRequest { #[serde(rename = "Canonicalize", skip_serializing_if = "Option::is_none")] pub canonicalize: Option, diff --git a/clients/rust/hyper/v1/src/models/log_config.rs b/clients/rust/hyper/v1/src/models/log_config.rs index 78262385..6752b071 100644 --- a/clients/rust/hyper/v1/src/models/log_config.rs +++ b/clients/rust/hyper/v1/src/models/log_config.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct LogConfig { #[serde(rename = "MaxFileSizeMB", skip_serializing_if = "Option::is_none")] pub max_file_size_mb: Option, diff --git a/clients/rust/hyper/v1/src/models/metrics_summary.rs b/clients/rust/hyper/v1/src/models/metrics_summary.rs index 5517ce36..1e36191b 100644 --- a/clients/rust/hyper/v1/src/models/metrics_summary.rs +++ b/clients/rust/hyper/v1/src/models/metrics_summary.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct MetricsSummary { #[serde(rename = "Counters", skip_serializing_if = "Option::is_none")] pub counters: Option>, diff --git a/clients/rust/hyper/v1/src/models/migrate_strategy.rs b/clients/rust/hyper/v1/src/models/migrate_strategy.rs index d019b33c..b7c08158 100644 --- a/clients/rust/hyper/v1/src/models/migrate_strategy.rs +++ b/clients/rust/hyper/v1/src/models/migrate_strategy.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct MigrateStrategy { #[serde(rename = "HealthCheck", skip_serializing_if = "Option::is_none")] pub health_check: Option, diff --git a/clients/rust/hyper/v1/src/models/multiregion.rs b/clients/rust/hyper/v1/src/models/multiregion.rs index 447b7284..db3be120 100644 --- a/clients/rust/hyper/v1/src/models/multiregion.rs +++ b/clients/rust/hyper/v1/src/models/multiregion.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Multiregion { #[serde(rename = "Regions", skip_serializing_if = "Option::is_none")] pub regions: Option>, diff --git a/clients/rust/hyper/v1/src/models/multiregion_region.rs b/clients/rust/hyper/v1/src/models/multiregion_region.rs index db9b42fd..44528842 100644 --- a/clients/rust/hyper/v1/src/models/multiregion_region.rs +++ b/clients/rust/hyper/v1/src/models/multiregion_region.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct MultiregionRegion { #[serde(rename = "Count", skip_serializing_if = "Option::is_none")] pub count: Option, diff --git a/clients/rust/hyper/v1/src/models/multiregion_strategy.rs b/clients/rust/hyper/v1/src/models/multiregion_strategy.rs index 94c02c74..12bb3db9 100644 --- a/clients/rust/hyper/v1/src/models/multiregion_strategy.rs +++ b/clients/rust/hyper/v1/src/models/multiregion_strategy.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct MultiregionStrategy { #[serde(rename = "MaxParallel", skip_serializing_if = "Option::is_none")] pub max_parallel: Option, diff --git a/clients/rust/hyper/v1/src/models/namespace.rs b/clients/rust/hyper/v1/src/models/namespace.rs index fdb5d38c..6fbdd447 100644 --- a/clients/rust/hyper/v1/src/models/namespace.rs +++ b/clients/rust/hyper/v1/src/models/namespace.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Namespace { #[serde(rename = "Capabilities", skip_serializing_if = "Option::is_none")] pub capabilities: Option>, diff --git a/clients/rust/hyper/v1/src/models/namespace_capabilities.rs b/clients/rust/hyper/v1/src/models/namespace_capabilities.rs index fc3cf7c2..23e03414 100644 --- a/clients/rust/hyper/v1/src/models/namespace_capabilities.rs +++ b/clients/rust/hyper/v1/src/models/namespace_capabilities.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NamespaceCapabilities { #[serde(rename = "DisabledTaskDrivers", skip_serializing_if = "Option::is_none")] pub disabled_task_drivers: Option>, diff --git a/clients/rust/hyper/v1/src/models/network_resource.rs b/clients/rust/hyper/v1/src/models/network_resource.rs index 66181d40..11f10228 100644 --- a/clients/rust/hyper/v1/src/models/network_resource.rs +++ b/clients/rust/hyper/v1/src/models/network_resource.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NetworkResource { #[serde(rename = "CIDR", skip_serializing_if = "Option::is_none")] pub CIDR: Option, diff --git a/clients/rust/hyper/v1/src/models/node.rs b/clients/rust/hyper/v1/src/models/node.rs index 71730728..954cd664 100644 --- a/clients/rust/hyper/v1/src/models/node.rs +++ b/clients/rust/hyper/v1/src/models/node.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Node { #[serde(rename = "Attributes", skip_serializing_if = "Option::is_none")] pub attributes: Option<::std::collections::HashMap>, diff --git a/clients/rust/hyper/v1/src/models/node_cpu_resources.rs b/clients/rust/hyper/v1/src/models/node_cpu_resources.rs index 6d659f86..11cb141a 100644 --- a/clients/rust/hyper/v1/src/models/node_cpu_resources.rs +++ b/clients/rust/hyper/v1/src/models/node_cpu_resources.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeCpuResources { #[serde(rename = "CpuShares", skip_serializing_if = "Option::is_none")] pub cpu_shares: Option, diff --git a/clients/rust/hyper/v1/src/models/node_device.rs b/clients/rust/hyper/v1/src/models/node_device.rs index ddb9de8a..df6ec5d8 100644 --- a/clients/rust/hyper/v1/src/models/node_device.rs +++ b/clients/rust/hyper/v1/src/models/node_device.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeDevice { #[serde(rename = "HealthDescription", skip_serializing_if = "Option::is_none")] pub health_description: Option, diff --git a/clients/rust/hyper/v1/src/models/node_device_locality.rs b/clients/rust/hyper/v1/src/models/node_device_locality.rs index 54ee328e..31be2375 100644 --- a/clients/rust/hyper/v1/src/models/node_device_locality.rs +++ b/clients/rust/hyper/v1/src/models/node_device_locality.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeDeviceLocality { #[serde(rename = "PciBusID", skip_serializing_if = "Option::is_none")] pub pci_bus_id: Option, diff --git a/clients/rust/hyper/v1/src/models/node_device_resource.rs b/clients/rust/hyper/v1/src/models/node_device_resource.rs index 563e1a08..4b6c4b7b 100644 --- a/clients/rust/hyper/v1/src/models/node_device_resource.rs +++ b/clients/rust/hyper/v1/src/models/node_device_resource.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeDeviceResource { #[serde(rename = "Attributes", skip_serializing_if = "Option::is_none")] pub attributes: Option<::std::collections::HashMap>, diff --git a/clients/rust/hyper/v1/src/models/node_disk_resources.rs b/clients/rust/hyper/v1/src/models/node_disk_resources.rs index 4fd94746..c1f1ae51 100644 --- a/clients/rust/hyper/v1/src/models/node_disk_resources.rs +++ b/clients/rust/hyper/v1/src/models/node_disk_resources.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeDiskResources { #[serde(rename = "DiskMB", skip_serializing_if = "Option::is_none")] pub disk_mb: Option, diff --git a/clients/rust/hyper/v1/src/models/node_drain_update_response.rs b/clients/rust/hyper/v1/src/models/node_drain_update_response.rs index 3890fdcf..3c7eae06 100644 --- a/clients/rust/hyper/v1/src/models/node_drain_update_response.rs +++ b/clients/rust/hyper/v1/src/models/node_drain_update_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeDrainUpdateResponse { #[serde(rename = "EvalCreateIndex", skip_serializing_if = "Option::is_none")] pub eval_create_index: Option, diff --git a/clients/rust/hyper/v1/src/models/node_eligibility_update_response.rs b/clients/rust/hyper/v1/src/models/node_eligibility_update_response.rs index 6b1883e5..7b1f3d29 100644 --- a/clients/rust/hyper/v1/src/models/node_eligibility_update_response.rs +++ b/clients/rust/hyper/v1/src/models/node_eligibility_update_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeEligibilityUpdateResponse { #[serde(rename = "EvalCreateIndex", skip_serializing_if = "Option::is_none")] pub eval_create_index: Option, diff --git a/clients/rust/hyper/v1/src/models/node_event.rs b/clients/rust/hyper/v1/src/models/node_event.rs index e7db09a8..9ad18755 100644 --- a/clients/rust/hyper/v1/src/models/node_event.rs +++ b/clients/rust/hyper/v1/src/models/node_event.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeEvent { #[serde(rename = "CreateIndex", skip_serializing_if = "Option::is_none")] pub create_index: Option, diff --git a/clients/rust/hyper/v1/src/models/node_list_stub.rs b/clients/rust/hyper/v1/src/models/node_list_stub.rs index 7fb4f792..456812fc 100644 --- a/clients/rust/hyper/v1/src/models/node_list_stub.rs +++ b/clients/rust/hyper/v1/src/models/node_list_stub.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeListStub { #[serde(rename = "Address", skip_serializing_if = "Option::is_none")] pub address: Option, diff --git a/clients/rust/hyper/v1/src/models/node_memory_resources.rs b/clients/rust/hyper/v1/src/models/node_memory_resources.rs index 49160a17..c13e4ad7 100644 --- a/clients/rust/hyper/v1/src/models/node_memory_resources.rs +++ b/clients/rust/hyper/v1/src/models/node_memory_resources.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeMemoryResources { #[serde(rename = "MemoryMB", skip_serializing_if = "Option::is_none")] pub memory_mb: Option, diff --git a/clients/rust/hyper/v1/src/models/node_purge_response.rs b/clients/rust/hyper/v1/src/models/node_purge_response.rs index a867284f..3807e6f9 100644 --- a/clients/rust/hyper/v1/src/models/node_purge_response.rs +++ b/clients/rust/hyper/v1/src/models/node_purge_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodePurgeResponse { #[serde(rename = "EvalCreateIndex", skip_serializing_if = "Option::is_none")] pub eval_create_index: Option, diff --git a/clients/rust/hyper/v1/src/models/node_reserved_cpu_resources.rs b/clients/rust/hyper/v1/src/models/node_reserved_cpu_resources.rs index 1e0e4e67..32d52d26 100644 --- a/clients/rust/hyper/v1/src/models/node_reserved_cpu_resources.rs +++ b/clients/rust/hyper/v1/src/models/node_reserved_cpu_resources.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeReservedCpuResources { #[serde(rename = "CpuShares", skip_serializing_if = "Option::is_none")] pub cpu_shares: Option, diff --git a/clients/rust/hyper/v1/src/models/node_reserved_disk_resources.rs b/clients/rust/hyper/v1/src/models/node_reserved_disk_resources.rs index 1534f9e4..0dbf2571 100644 --- a/clients/rust/hyper/v1/src/models/node_reserved_disk_resources.rs +++ b/clients/rust/hyper/v1/src/models/node_reserved_disk_resources.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeReservedDiskResources { #[serde(rename = "DiskMB", skip_serializing_if = "Option::is_none")] pub disk_mb: Option, diff --git a/clients/rust/hyper/v1/src/models/node_reserved_memory_resources.rs b/clients/rust/hyper/v1/src/models/node_reserved_memory_resources.rs index dfd32fbf..c1c5e854 100644 --- a/clients/rust/hyper/v1/src/models/node_reserved_memory_resources.rs +++ b/clients/rust/hyper/v1/src/models/node_reserved_memory_resources.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeReservedMemoryResources { #[serde(rename = "MemoryMB", skip_serializing_if = "Option::is_none")] pub memory_mb: Option, diff --git a/clients/rust/hyper/v1/src/models/node_reserved_network_resources.rs b/clients/rust/hyper/v1/src/models/node_reserved_network_resources.rs index 8450b9c8..59cf6eb7 100644 --- a/clients/rust/hyper/v1/src/models/node_reserved_network_resources.rs +++ b/clients/rust/hyper/v1/src/models/node_reserved_network_resources.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeReservedNetworkResources { #[serde(rename = "ReservedHostPorts", skip_serializing_if = "Option::is_none")] pub reserved_host_ports: Option, diff --git a/clients/rust/hyper/v1/src/models/node_reserved_resources.rs b/clients/rust/hyper/v1/src/models/node_reserved_resources.rs index 90c28a7c..3a8c21cf 100644 --- a/clients/rust/hyper/v1/src/models/node_reserved_resources.rs +++ b/clients/rust/hyper/v1/src/models/node_reserved_resources.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeReservedResources { #[serde(rename = "Cpu", skip_serializing_if = "Option::is_none")] pub cpu: Option>, diff --git a/clients/rust/hyper/v1/src/models/node_resources.rs b/clients/rust/hyper/v1/src/models/node_resources.rs index b44fe892..0fcab6c6 100644 --- a/clients/rust/hyper/v1/src/models/node_resources.rs +++ b/clients/rust/hyper/v1/src/models/node_resources.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeResources { #[serde(rename = "Cpu", skip_serializing_if = "Option::is_none")] pub cpu: Option>, diff --git a/clients/rust/hyper/v1/src/models/node_score_meta.rs b/clients/rust/hyper/v1/src/models/node_score_meta.rs index 8127dde7..71148895 100644 --- a/clients/rust/hyper/v1/src/models/node_score_meta.rs +++ b/clients/rust/hyper/v1/src/models/node_score_meta.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeScoreMeta { #[serde(rename = "NodeID", skip_serializing_if = "Option::is_none")] pub node_id: Option, diff --git a/clients/rust/hyper/v1/src/models/node_update_drain_request.rs b/clients/rust/hyper/v1/src/models/node_update_drain_request.rs index b75884bf..b411a3e5 100644 --- a/clients/rust/hyper/v1/src/models/node_update_drain_request.rs +++ b/clients/rust/hyper/v1/src/models/node_update_drain_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeUpdateDrainRequest { #[serde(rename = "DrainSpec", skip_serializing_if = "Option::is_none")] pub drain_spec: Option>, diff --git a/clients/rust/hyper/v1/src/models/node_update_eligibility_request.rs b/clients/rust/hyper/v1/src/models/node_update_eligibility_request.rs index 6b949861..680442c1 100644 --- a/clients/rust/hyper/v1/src/models/node_update_eligibility_request.rs +++ b/clients/rust/hyper/v1/src/models/node_update_eligibility_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeUpdateEligibilityRequest { #[serde(rename = "Eligibility", skip_serializing_if = "Option::is_none")] pub eligibility: Option, diff --git a/clients/rust/hyper/v1/src/models/object_diff.rs b/clients/rust/hyper/v1/src/models/object_diff.rs index 26463ec2..bbe14e66 100644 --- a/clients/rust/hyper/v1/src/models/object_diff.rs +++ b/clients/rust/hyper/v1/src/models/object_diff.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ObjectDiff { #[serde(rename = "Fields", skip_serializing_if = "Option::is_none")] pub fields: Option>, diff --git a/clients/rust/hyper/v1/src/models/one_time_token.rs b/clients/rust/hyper/v1/src/models/one_time_token.rs index 8b934321..c9c8c4ce 100644 --- a/clients/rust/hyper/v1/src/models/one_time_token.rs +++ b/clients/rust/hyper/v1/src/models/one_time_token.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct OneTimeToken { #[serde(rename = "AccessorID", skip_serializing_if = "Option::is_none")] pub accessor_id: Option, diff --git a/clients/rust/hyper/v1/src/models/one_time_token_exchange_request.rs b/clients/rust/hyper/v1/src/models/one_time_token_exchange_request.rs index 0fdb3257..8c760752 100644 --- a/clients/rust/hyper/v1/src/models/one_time_token_exchange_request.rs +++ b/clients/rust/hyper/v1/src/models/one_time_token_exchange_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct OneTimeTokenExchangeRequest { #[serde(rename = "OneTimeSecretID", skip_serializing_if = "Option::is_none")] pub one_time_secret_id: Option, diff --git a/clients/rust/hyper/v1/src/models/operator_health_reply.rs b/clients/rust/hyper/v1/src/models/operator_health_reply.rs index 22725303..7bc863e7 100644 --- a/clients/rust/hyper/v1/src/models/operator_health_reply.rs +++ b/clients/rust/hyper/v1/src/models/operator_health_reply.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct OperatorHealthReply { #[serde(rename = "FailureTolerance", skip_serializing_if = "Option::is_none")] pub failure_tolerance: Option, diff --git a/clients/rust/hyper/v1/src/models/parameterized_job_config.rs b/clients/rust/hyper/v1/src/models/parameterized_job_config.rs index 6c7f0178..56f0d7a0 100644 --- a/clients/rust/hyper/v1/src/models/parameterized_job_config.rs +++ b/clients/rust/hyper/v1/src/models/parameterized_job_config.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ParameterizedJobConfig { #[serde(rename = "MetaOptional", skip_serializing_if = "Option::is_none")] pub meta_optional: Option>, diff --git a/clients/rust/hyper/v1/src/models/periodic_config.rs b/clients/rust/hyper/v1/src/models/periodic_config.rs index 483855f8..c8c59f4f 100644 --- a/clients/rust/hyper/v1/src/models/periodic_config.rs +++ b/clients/rust/hyper/v1/src/models/periodic_config.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct PeriodicConfig { #[serde(rename = "Enabled", skip_serializing_if = "Option::is_none")] pub enabled: Option, diff --git a/clients/rust/hyper/v1/src/models/periodic_force_response.rs b/clients/rust/hyper/v1/src/models/periodic_force_response.rs index 5f599595..4f926192 100644 --- a/clients/rust/hyper/v1/src/models/periodic_force_response.rs +++ b/clients/rust/hyper/v1/src/models/periodic_force_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct PeriodicForceResponse { #[serde(rename = "EvalCreateIndex", skip_serializing_if = "Option::is_none")] pub eval_create_index: Option, diff --git a/clients/rust/hyper/v1/src/models/plan_annotations.rs b/clients/rust/hyper/v1/src/models/plan_annotations.rs index f440fa2f..377f48f3 100644 --- a/clients/rust/hyper/v1/src/models/plan_annotations.rs +++ b/clients/rust/hyper/v1/src/models/plan_annotations.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct PlanAnnotations { #[serde(rename = "DesiredTGUpdates", skip_serializing_if = "Option::is_none")] pub desired_tg_updates: Option<::std::collections::HashMap>, diff --git a/clients/rust/hyper/v1/src/models/point_value.rs b/clients/rust/hyper/v1/src/models/point_value.rs index 7728b192..07fdd851 100644 --- a/clients/rust/hyper/v1/src/models/point_value.rs +++ b/clients/rust/hyper/v1/src/models/point_value.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct PointValue { #[serde(rename = "Name", skip_serializing_if = "Option::is_none")] pub name: Option, diff --git a/clients/rust/hyper/v1/src/models/port.rs b/clients/rust/hyper/v1/src/models/port.rs index e8d15352..236a2d59 100644 --- a/clients/rust/hyper/v1/src/models/port.rs +++ b/clients/rust/hyper/v1/src/models/port.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Port { #[serde(rename = "HostNetwork", skip_serializing_if = "Option::is_none")] pub host_network: Option, diff --git a/clients/rust/hyper/v1/src/models/port_mapping.rs b/clients/rust/hyper/v1/src/models/port_mapping.rs index 4709ee2f..d3cafffd 100644 --- a/clients/rust/hyper/v1/src/models/port_mapping.rs +++ b/clients/rust/hyper/v1/src/models/port_mapping.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct PortMapping { #[serde(rename = "HostIP", skip_serializing_if = "Option::is_none")] pub host_ip: Option, diff --git a/clients/rust/hyper/v1/src/models/preemption_config.rs b/clients/rust/hyper/v1/src/models/preemption_config.rs index 6eec6854..1a96db40 100644 --- a/clients/rust/hyper/v1/src/models/preemption_config.rs +++ b/clients/rust/hyper/v1/src/models/preemption_config.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct PreemptionConfig { #[serde(rename = "BatchSchedulerEnabled", skip_serializing_if = "Option::is_none")] pub batch_scheduler_enabled: Option, diff --git a/clients/rust/hyper/v1/src/models/quota_limit.rs b/clients/rust/hyper/v1/src/models/quota_limit.rs index 0c7dfd5a..d41a1e4e 100644 --- a/clients/rust/hyper/v1/src/models/quota_limit.rs +++ b/clients/rust/hyper/v1/src/models/quota_limit.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct QuotaLimit { #[serde(rename = "Hash", skip_serializing_if = "Option::is_none")] pub hash: Option, diff --git a/clients/rust/hyper/v1/src/models/quota_spec.rs b/clients/rust/hyper/v1/src/models/quota_spec.rs index f9a315d9..32272cad 100644 --- a/clients/rust/hyper/v1/src/models/quota_spec.rs +++ b/clients/rust/hyper/v1/src/models/quota_spec.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct QuotaSpec { #[serde(rename = "CreateIndex", skip_serializing_if = "Option::is_none")] pub create_index: Option, diff --git a/clients/rust/hyper/v1/src/models/raft_configuration.rs b/clients/rust/hyper/v1/src/models/raft_configuration.rs index b01115ea..db42e2bd 100644 --- a/clients/rust/hyper/v1/src/models/raft_configuration.rs +++ b/clients/rust/hyper/v1/src/models/raft_configuration.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct RaftConfiguration { #[serde(rename = "Index", skip_serializing_if = "Option::is_none")] pub index: Option, diff --git a/clients/rust/hyper/v1/src/models/raft_server.rs b/clients/rust/hyper/v1/src/models/raft_server.rs index f1a78882..07ec13d7 100644 --- a/clients/rust/hyper/v1/src/models/raft_server.rs +++ b/clients/rust/hyper/v1/src/models/raft_server.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct RaftServer { #[serde(rename = "Address", skip_serializing_if = "Option::is_none")] pub address: Option, diff --git a/clients/rust/hyper/v1/src/models/requested_device.rs b/clients/rust/hyper/v1/src/models/requested_device.rs index f2213fa6..de6cb04c 100644 --- a/clients/rust/hyper/v1/src/models/requested_device.rs +++ b/clients/rust/hyper/v1/src/models/requested_device.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct RequestedDevice { #[serde(rename = "Affinities", skip_serializing_if = "Option::is_none")] pub affinities: Option>, diff --git a/clients/rust/hyper/v1/src/models/reschedule_event.rs b/clients/rust/hyper/v1/src/models/reschedule_event.rs index d5615627..26e9ecaf 100644 --- a/clients/rust/hyper/v1/src/models/reschedule_event.rs +++ b/clients/rust/hyper/v1/src/models/reschedule_event.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct RescheduleEvent { #[serde(rename = "PrevAllocID", skip_serializing_if = "Option::is_none")] pub prev_alloc_id: Option, diff --git a/clients/rust/hyper/v1/src/models/reschedule_policy.rs b/clients/rust/hyper/v1/src/models/reschedule_policy.rs index 03605e72..c25fd990 100644 --- a/clients/rust/hyper/v1/src/models/reschedule_policy.rs +++ b/clients/rust/hyper/v1/src/models/reschedule_policy.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ReschedulePolicy { #[serde(rename = "Attempts", skip_serializing_if = "Option::is_none")] pub attempts: Option, diff --git a/clients/rust/hyper/v1/src/models/reschedule_tracker.rs b/clients/rust/hyper/v1/src/models/reschedule_tracker.rs index 35c345c9..0044b8f9 100644 --- a/clients/rust/hyper/v1/src/models/reschedule_tracker.rs +++ b/clients/rust/hyper/v1/src/models/reschedule_tracker.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct RescheduleTracker { #[serde(rename = "Events", skip_serializing_if = "Option::is_none")] pub events: Option>, diff --git a/clients/rust/hyper/v1/src/models/resources.rs b/clients/rust/hyper/v1/src/models/resources.rs index fa8748ce..7ec869fd 100644 --- a/clients/rust/hyper/v1/src/models/resources.rs +++ b/clients/rust/hyper/v1/src/models/resources.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Resources { #[serde(rename = "CPU", skip_serializing_if = "Option::is_none")] pub CPU: Option, diff --git a/clients/rust/hyper/v1/src/models/restart_policy.rs b/clients/rust/hyper/v1/src/models/restart_policy.rs index fd1c23e8..040c61da 100644 --- a/clients/rust/hyper/v1/src/models/restart_policy.rs +++ b/clients/rust/hyper/v1/src/models/restart_policy.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct RestartPolicy { #[serde(rename = "Attempts", skip_serializing_if = "Option::is_none")] pub attempts: Option, diff --git a/clients/rust/hyper/v1/src/models/sampled_value.rs b/clients/rust/hyper/v1/src/models/sampled_value.rs index f9d0e92f..1cd8effd 100644 --- a/clients/rust/hyper/v1/src/models/sampled_value.rs +++ b/clients/rust/hyper/v1/src/models/sampled_value.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct SampledValue { #[serde(rename = "Count", skip_serializing_if = "Option::is_none")] pub count: Option, diff --git a/clients/rust/hyper/v1/src/models/scaling_event.rs b/clients/rust/hyper/v1/src/models/scaling_event.rs index d3329490..6096f50f 100644 --- a/clients/rust/hyper/v1/src/models/scaling_event.rs +++ b/clients/rust/hyper/v1/src/models/scaling_event.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ScalingEvent { #[serde(rename = "Count", skip_serializing_if = "Option::is_none")] pub count: Option, diff --git a/clients/rust/hyper/v1/src/models/scaling_policy.rs b/clients/rust/hyper/v1/src/models/scaling_policy.rs index f335fc19..5b8aa77b 100644 --- a/clients/rust/hyper/v1/src/models/scaling_policy.rs +++ b/clients/rust/hyper/v1/src/models/scaling_policy.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ScalingPolicy { #[serde(rename = "CreateIndex", skip_serializing_if = "Option::is_none")] pub create_index: Option, diff --git a/clients/rust/hyper/v1/src/models/scaling_policy_list_stub.rs b/clients/rust/hyper/v1/src/models/scaling_policy_list_stub.rs index b8745212..ffcc501f 100644 --- a/clients/rust/hyper/v1/src/models/scaling_policy_list_stub.rs +++ b/clients/rust/hyper/v1/src/models/scaling_policy_list_stub.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ScalingPolicyListStub { #[serde(rename = "CreateIndex", skip_serializing_if = "Option::is_none")] pub create_index: Option, diff --git a/clients/rust/hyper/v1/src/models/scaling_request.rs b/clients/rust/hyper/v1/src/models/scaling_request.rs index 6fb2d030..e4fccd6b 100644 --- a/clients/rust/hyper/v1/src/models/scaling_request.rs +++ b/clients/rust/hyper/v1/src/models/scaling_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ScalingRequest { #[serde(rename = "Count", skip_serializing_if = "Option::is_none")] pub count: Option, diff --git a/clients/rust/hyper/v1/src/models/scheduler_configuration.rs b/clients/rust/hyper/v1/src/models/scheduler_configuration.rs index 584a7ad2..6b7c9efd 100644 --- a/clients/rust/hyper/v1/src/models/scheduler_configuration.rs +++ b/clients/rust/hyper/v1/src/models/scheduler_configuration.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct SchedulerConfiguration { #[serde(rename = "CreateIndex", skip_serializing_if = "Option::is_none")] pub create_index: Option, diff --git a/clients/rust/hyper/v1/src/models/scheduler_configuration_response.rs b/clients/rust/hyper/v1/src/models/scheduler_configuration_response.rs index db372329..0ece22fb 100644 --- a/clients/rust/hyper/v1/src/models/scheduler_configuration_response.rs +++ b/clients/rust/hyper/v1/src/models/scheduler_configuration_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct SchedulerConfigurationResponse { #[serde(rename = "KnownLeader", skip_serializing_if = "Option::is_none")] pub known_leader: Option, diff --git a/clients/rust/hyper/v1/src/models/scheduler_set_configuration_response.rs b/clients/rust/hyper/v1/src/models/scheduler_set_configuration_response.rs index db11ba13..6206afb0 100644 --- a/clients/rust/hyper/v1/src/models/scheduler_set_configuration_response.rs +++ b/clients/rust/hyper/v1/src/models/scheduler_set_configuration_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct SchedulerSetConfigurationResponse { #[serde(rename = "LastIndex", skip_serializing_if = "Option::is_none")] pub last_index: Option, diff --git a/clients/rust/hyper/v1/src/models/search_request.rs b/clients/rust/hyper/v1/src/models/search_request.rs index da833972..a2462caf 100644 --- a/clients/rust/hyper/v1/src/models/search_request.rs +++ b/clients/rust/hyper/v1/src/models/search_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct SearchRequest { #[serde(rename = "AllowStale", skip_serializing_if = "Option::is_none")] pub allow_stale: Option, diff --git a/clients/rust/hyper/v1/src/models/search_response.rs b/clients/rust/hyper/v1/src/models/search_response.rs index 8b83cd5f..b8445de2 100644 --- a/clients/rust/hyper/v1/src/models/search_response.rs +++ b/clients/rust/hyper/v1/src/models/search_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct SearchResponse { #[serde(rename = "KnownLeader", skip_serializing_if = "Option::is_none")] pub known_leader: Option, diff --git a/clients/rust/hyper/v1/src/models/server_health.rs b/clients/rust/hyper/v1/src/models/server_health.rs index dd923155..96d2e352 100644 --- a/clients/rust/hyper/v1/src/models/server_health.rs +++ b/clients/rust/hyper/v1/src/models/server_health.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ServerHealth { #[serde(rename = "Address", skip_serializing_if = "Option::is_none")] pub address: Option, diff --git a/clients/rust/hyper/v1/src/models/service.rs b/clients/rust/hyper/v1/src/models/service.rs index 76e7bb86..dfe67a33 100644 --- a/clients/rust/hyper/v1/src/models/service.rs +++ b/clients/rust/hyper/v1/src/models/service.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Service { #[serde(rename = "Address", skip_serializing_if = "Option::is_none")] pub address: Option, diff --git a/clients/rust/hyper/v1/src/models/service_check.rs b/clients/rust/hyper/v1/src/models/service_check.rs index e0e304e3..e8d9f474 100644 --- a/clients/rust/hyper/v1/src/models/service_check.rs +++ b/clients/rust/hyper/v1/src/models/service_check.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ServiceCheck { #[serde(rename = "AddressMode", skip_serializing_if = "Option::is_none")] pub address_mode: Option, diff --git a/clients/rust/hyper/v1/src/models/service_registration.rs b/clients/rust/hyper/v1/src/models/service_registration.rs index 9f15a556..907aeff3 100644 --- a/clients/rust/hyper/v1/src/models/service_registration.rs +++ b/clients/rust/hyper/v1/src/models/service_registration.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ServiceRegistration { #[serde(rename = "Address", skip_serializing_if = "Option::is_none")] pub address: Option, diff --git a/clients/rust/hyper/v1/src/models/sidecar_task.rs b/clients/rust/hyper/v1/src/models/sidecar_task.rs index 0bad40aa..58bf3a24 100644 --- a/clients/rust/hyper/v1/src/models/sidecar_task.rs +++ b/clients/rust/hyper/v1/src/models/sidecar_task.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct SidecarTask { #[serde(rename = "Config", skip_serializing_if = "Option::is_none")] pub config: Option<::std::collections::HashMap>, diff --git a/clients/rust/hyper/v1/src/models/spread.rs b/clients/rust/hyper/v1/src/models/spread.rs index 89ccc74a..63f3aade 100644 --- a/clients/rust/hyper/v1/src/models/spread.rs +++ b/clients/rust/hyper/v1/src/models/spread.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Spread { #[serde(rename = "Attribute", skip_serializing_if = "Option::is_none")] pub attribute: Option, diff --git a/clients/rust/hyper/v1/src/models/spread_target.rs b/clients/rust/hyper/v1/src/models/spread_target.rs index 68cb4597..de972446 100644 --- a/clients/rust/hyper/v1/src/models/spread_target.rs +++ b/clients/rust/hyper/v1/src/models/spread_target.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct SpreadTarget { #[serde(rename = "Percent", skip_serializing_if = "Option::is_none")] pub percent: Option, diff --git a/clients/rust/hyper/v1/src/models/task.rs b/clients/rust/hyper/v1/src/models/task.rs index f6f0f161..5e3d2c30 100644 --- a/clients/rust/hyper/v1/src/models/task.rs +++ b/clients/rust/hyper/v1/src/models/task.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Task { #[serde(rename = "Affinities", skip_serializing_if = "Option::is_none")] pub affinities: Option>, diff --git a/clients/rust/hyper/v1/src/models/task_artifact.rs b/clients/rust/hyper/v1/src/models/task_artifact.rs index 08809484..5e76d837 100644 --- a/clients/rust/hyper/v1/src/models/task_artifact.rs +++ b/clients/rust/hyper/v1/src/models/task_artifact.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct TaskArtifact { #[serde(rename = "GetterHeaders", skip_serializing_if = "Option::is_none")] pub getter_headers: Option<::std::collections::HashMap>, diff --git a/clients/rust/hyper/v1/src/models/task_csi_plugin_config.rs b/clients/rust/hyper/v1/src/models/task_csi_plugin_config.rs index 476ec727..62261cee 100644 --- a/clients/rust/hyper/v1/src/models/task_csi_plugin_config.rs +++ b/clients/rust/hyper/v1/src/models/task_csi_plugin_config.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct TaskCsiPluginConfig { #[serde(rename = "HealthTimeout", skip_serializing_if = "Option::is_none")] pub health_timeout: Option, diff --git a/clients/rust/hyper/v1/src/models/task_diff.rs b/clients/rust/hyper/v1/src/models/task_diff.rs index e07a72e6..fd002c91 100644 --- a/clients/rust/hyper/v1/src/models/task_diff.rs +++ b/clients/rust/hyper/v1/src/models/task_diff.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct TaskDiff { #[serde(rename = "Annotations", skip_serializing_if = "Option::is_none")] pub annotations: Option>, diff --git a/clients/rust/hyper/v1/src/models/task_event.rs b/clients/rust/hyper/v1/src/models/task_event.rs index d47309dd..4a165c38 100644 --- a/clients/rust/hyper/v1/src/models/task_event.rs +++ b/clients/rust/hyper/v1/src/models/task_event.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct TaskEvent { #[serde(rename = "Details", skip_serializing_if = "Option::is_none")] pub details: Option<::std::collections::HashMap>, diff --git a/clients/rust/hyper/v1/src/models/task_group.rs b/clients/rust/hyper/v1/src/models/task_group.rs index e13346e8..b7939a22 100644 --- a/clients/rust/hyper/v1/src/models/task_group.rs +++ b/clients/rust/hyper/v1/src/models/task_group.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct TaskGroup { #[serde(rename = "Affinities", skip_serializing_if = "Option::is_none")] pub affinities: Option>, diff --git a/clients/rust/hyper/v1/src/models/task_group_diff.rs b/clients/rust/hyper/v1/src/models/task_group_diff.rs index 8c4cd60f..7e4904e4 100644 --- a/clients/rust/hyper/v1/src/models/task_group_diff.rs +++ b/clients/rust/hyper/v1/src/models/task_group_diff.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct TaskGroupDiff { #[serde(rename = "Fields", skip_serializing_if = "Option::is_none")] pub fields: Option>, diff --git a/clients/rust/hyper/v1/src/models/task_group_scale_status.rs b/clients/rust/hyper/v1/src/models/task_group_scale_status.rs index 933ba155..68555593 100644 --- a/clients/rust/hyper/v1/src/models/task_group_scale_status.rs +++ b/clients/rust/hyper/v1/src/models/task_group_scale_status.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct TaskGroupScaleStatus { #[serde(rename = "Desired", skip_serializing_if = "Option::is_none")] pub desired: Option, diff --git a/clients/rust/hyper/v1/src/models/task_group_summary.rs b/clients/rust/hyper/v1/src/models/task_group_summary.rs index 2dc5a6d6..7350e3d9 100644 --- a/clients/rust/hyper/v1/src/models/task_group_summary.rs +++ b/clients/rust/hyper/v1/src/models/task_group_summary.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct TaskGroupSummary { #[serde(rename = "Complete", skip_serializing_if = "Option::is_none")] pub complete: Option, diff --git a/clients/rust/hyper/v1/src/models/task_handle.rs b/clients/rust/hyper/v1/src/models/task_handle.rs index 90dbf3d1..1df196eb 100644 --- a/clients/rust/hyper/v1/src/models/task_handle.rs +++ b/clients/rust/hyper/v1/src/models/task_handle.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct TaskHandle { #[serde(rename = "DriverState", skip_serializing_if = "Option::is_none")] pub driver_state: Option, diff --git a/clients/rust/hyper/v1/src/models/task_lifecycle.rs b/clients/rust/hyper/v1/src/models/task_lifecycle.rs index daa669fa..ec95a9f8 100644 --- a/clients/rust/hyper/v1/src/models/task_lifecycle.rs +++ b/clients/rust/hyper/v1/src/models/task_lifecycle.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct TaskLifecycle { #[serde(rename = "Hook", skip_serializing_if = "Option::is_none")] pub hook: Option, diff --git a/clients/rust/hyper/v1/src/models/task_state.rs b/clients/rust/hyper/v1/src/models/task_state.rs index 5143b7fd..be48aa0b 100644 --- a/clients/rust/hyper/v1/src/models/task_state.rs +++ b/clients/rust/hyper/v1/src/models/task_state.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct TaskState { #[serde(rename = "Events", skip_serializing_if = "Option::is_none")] pub events: Option>, diff --git a/clients/rust/hyper/v1/src/models/template.rs b/clients/rust/hyper/v1/src/models/template.rs index 37789b7c..10f842aa 100644 --- a/clients/rust/hyper/v1/src/models/template.rs +++ b/clients/rust/hyper/v1/src/models/template.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Template { #[serde(rename = "ChangeMode", skip_serializing_if = "Option::is_none")] pub change_mode: Option, diff --git a/clients/rust/hyper/v1/src/models/update_strategy.rs b/clients/rust/hyper/v1/src/models/update_strategy.rs index 7791201e..2966118a 100644 --- a/clients/rust/hyper/v1/src/models/update_strategy.rs +++ b/clients/rust/hyper/v1/src/models/update_strategy.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct UpdateStrategy { #[serde(rename = "AutoPromote", skip_serializing_if = "Option::is_none")] pub auto_promote: Option, diff --git a/clients/rust/hyper/v1/src/models/vault.rs b/clients/rust/hyper/v1/src/models/vault.rs index 74ede05d..780d4697 100644 --- a/clients/rust/hyper/v1/src/models/vault.rs +++ b/clients/rust/hyper/v1/src/models/vault.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Vault { #[serde(rename = "ChangeMode", skip_serializing_if = "Option::is_none")] pub change_mode: Option, diff --git a/clients/rust/hyper/v1/src/models/volume_mount.rs b/clients/rust/hyper/v1/src/models/volume_mount.rs index e106c185..71132ecc 100644 --- a/clients/rust/hyper/v1/src/models/volume_mount.rs +++ b/clients/rust/hyper/v1/src/models/volume_mount.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct VolumeMount { #[serde(rename = "Destination", skip_serializing_if = "Option::is_none")] pub destination: Option, diff --git a/clients/rust/hyper/v1/src/models/volume_request.rs b/clients/rust/hyper/v1/src/models/volume_request.rs index fb8178fd..0c53df00 100644 --- a/clients/rust/hyper/v1/src/models/volume_request.rs +++ b/clients/rust/hyper/v1/src/models/volume_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct VolumeRequest { #[serde(rename = "AccessMode", skip_serializing_if = "Option::is_none")] pub access_mode: Option, diff --git a/clients/rust/hyper/v1/src/models/wait_config.rs b/clients/rust/hyper/v1/src/models/wait_config.rs index b11bfba4..ec763d88 100644 --- a/clients/rust/hyper/v1/src/models/wait_config.rs +++ b/clients/rust/hyper/v1/src/models/wait_config.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct WaitConfig { #[serde(rename = "Max", skip_serializing_if = "Option::is_none")] pub max: Option, diff --git a/clients/rust/reqwest/v1/.openapi-generator/VERSION b/clients/rust/reqwest/v1/.openapi-generator/VERSION index 7cbea073..1e20ec35 100644 --- a/clients/rust/reqwest/v1/.openapi-generator/VERSION +++ b/clients/rust/reqwest/v1/.openapi-generator/VERSION @@ -1 +1 @@ -5.2.0 \ No newline at end of file +5.4.0 \ No newline at end of file diff --git a/clients/rust/reqwest/v1/Cargo.toml b/clients/rust/reqwest/v1/Cargo.toml index 130cedbf..28faf675 100644 --- a/clients/rust/reqwest/v1/Cargo.toml +++ b/clients/rust/reqwest/v1/Cargo.toml @@ -11,7 +11,6 @@ serde_json = "^1.0" url = "^2.2" [dependencies.reqwest] version = "^0.11" -default-features = false features = ["json", "multipart"] [dev-dependencies] diff --git a/clients/rust/reqwest/v1/docs/ACLApi.md b/clients/rust/reqwest/v1/docs/ACLApi.md index a393e017..750eaf8e 100644 --- a/clients/rust/reqwest/v1/docs/ACLApi.md +++ b/clients/rust/reqwest/v1/docs/ACLApi.md @@ -307,7 +307,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **policy_name** | **String** | The ACL policy name. | [required] | -**acl_policy** | [**AclPolicy**](AclPolicy.md) | | [required] | +**acl_policy** | Option<[**AclPolicy**](AclPolicy.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -340,7 +340,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **token_accessor** | **String** | The token accessor ID. | [required] | -**acl_token** | [**AclToken**](AclToken.md) | | [required] | +**acl_token** | Option<[**AclToken**](AclToken.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -403,7 +403,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- -**one_time_token_exchange_request** | [**OneTimeTokenExchangeRequest**](OneTimeTokenExchangeRequest.md) | | [required] | +**one_time_token_exchange_request** | Option<[**OneTimeTokenExchangeRequest**](OneTimeTokenExchangeRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | diff --git a/clients/rust/reqwest/v1/docs/DeploymentsApi.md b/clients/rust/reqwest/v1/docs/DeploymentsApi.md index ab788db1..52c930fa 100644 --- a/clients/rust/reqwest/v1/docs/DeploymentsApi.md +++ b/clients/rust/reqwest/v1/docs/DeploymentsApi.md @@ -136,7 +136,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **deployment_id** | **String** | Deployment ID. | [required] | -**deployment_alloc_health_request** | [**DeploymentAllocHealthRequest**](DeploymentAllocHealthRequest.md) | | [required] | +**deployment_alloc_health_request** | Option<[**DeploymentAllocHealthRequest**](DeploymentAllocHealthRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -201,7 +201,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **deployment_id** | **String** | Deployment ID. | [required] | -**deployment_pause_request** | [**DeploymentPauseRequest**](DeploymentPauseRequest.md) | | [required] | +**deployment_pause_request** | Option<[**DeploymentPauseRequest**](DeploymentPauseRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -234,7 +234,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **deployment_id** | **String** | Deployment ID. | [required] | -**deployment_promote_request** | [**DeploymentPromoteRequest**](DeploymentPromoteRequest.md) | | [required] | +**deployment_promote_request** | Option<[**DeploymentPromoteRequest**](DeploymentPromoteRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -267,7 +267,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **deployment_id** | **String** | Deployment ID. | [required] | -**deployment_unblock_request** | [**DeploymentUnblockRequest**](DeploymentUnblockRequest.md) | | [required] | +**deployment_unblock_request** | Option<[**DeploymentUnblockRequest**](DeploymentUnblockRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | diff --git a/clients/rust/reqwest/v1/docs/EnterpriseApi.md b/clients/rust/reqwest/v1/docs/EnterpriseApi.md index 8d72fbb2..b9bc2443 100644 --- a/clients/rust/reqwest/v1/docs/EnterpriseApi.md +++ b/clients/rust/reqwest/v1/docs/EnterpriseApi.md @@ -22,7 +22,7 @@ Method | HTTP request | Description Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- -**quota_spec** | [**QuotaSpec**](QuotaSpec.md) | | [required] | +**quota_spec** | Option<[**QuotaSpec**](QuotaSpec.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -160,7 +160,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **spec_name** | **String** | The quota spec identifier. | [required] | -**quota_spec** | [**QuotaSpec**](QuotaSpec.md) | | [required] | +**quota_spec** | Option<[**QuotaSpec**](QuotaSpec.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | diff --git a/clients/rust/reqwest/v1/docs/JobsApi.md b/clients/rust/reqwest/v1/docs/JobsApi.md index 96a75a43..f368bbbd 100644 --- a/clients/rust/reqwest/v1/docs/JobsApi.md +++ b/clients/rust/reqwest/v1/docs/JobsApi.md @@ -408,7 +408,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **job_name** | **String** | The job identifier. | [required] | -**job_register_request** | [**JobRegisterRequest**](JobRegisterRequest.md) | | [required] | +**job_register_request** | Option<[**JobRegisterRequest**](JobRegisterRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -441,7 +441,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **job_name** | **String** | The job identifier. | [required] | -**job_dispatch_request** | [**JobDispatchRequest**](JobDispatchRequest.md) | | [required] | +**job_dispatch_request** | Option<[**JobDispatchRequest**](JobDispatchRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -474,7 +474,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **job_name** | **String** | The job identifier. | [required] | -**job_evaluate_request** | [**JobEvaluateRequest**](JobEvaluateRequest.md) | | [required] | +**job_evaluate_request** | Option<[**JobEvaluateRequest**](JobEvaluateRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -506,7 +506,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- -**jobs_parse_request** | [**JobsParseRequest**](JobsParseRequest.md) | | [required] | +**jobs_parse_request** | Option<[**JobsParseRequest**](JobsParseRequest.md)> | | [required] | ### Return type @@ -567,7 +567,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **job_name** | **String** | The job identifier. | [required] | -**job_plan_request** | [**JobPlanRequest**](JobPlanRequest.md) | | [required] | +**job_plan_request** | Option<[**JobPlanRequest**](JobPlanRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -600,7 +600,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **job_name** | **String** | The job identifier. | [required] | -**job_revert_request** | [**JobRevertRequest**](JobRevertRequest.md) | | [required] | +**job_revert_request** | Option<[**JobRevertRequest**](JobRevertRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -633,7 +633,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **job_name** | **String** | The job identifier. | [required] | -**scaling_request** | [**ScalingRequest**](ScalingRequest.md) | | [required] | +**scaling_request** | Option<[**ScalingRequest**](ScalingRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -666,7 +666,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **job_name** | **String** | The job identifier. | [required] | -**job_stability_request** | [**JobStabilityRequest**](JobStabilityRequest.md) | | [required] | +**job_stability_request** | Option<[**JobStabilityRequest**](JobStabilityRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -698,7 +698,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- -**job_validate_request** | [**JobValidateRequest**](JobValidateRequest.md) | | [required] | +**job_validate_request** | Option<[**JobValidateRequest**](JobValidateRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -730,7 +730,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- -**job_register_request** | [**JobRegisterRequest**](JobRegisterRequest.md) | | [required] | +**job_register_request** | Option<[**JobRegisterRequest**](JobRegisterRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | diff --git a/clients/rust/reqwest/v1/docs/NamespacesApi.md b/clients/rust/reqwest/v1/docs/NamespacesApi.md index e7dcefd8..ed766a39 100644 --- a/clients/rust/reqwest/v1/docs/NamespacesApi.md +++ b/clients/rust/reqwest/v1/docs/NamespacesApi.md @@ -159,7 +159,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **namespace_name** | **String** | The namespace identifier. | [required] | -**namespace2** | [**Namespace**](Namespace.md) | | [required] | +**namespace2** | Option<[**Namespace**](Namespace.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | diff --git a/clients/rust/reqwest/v1/docs/NodesApi.md b/clients/rust/reqwest/v1/docs/NodesApi.md index 30e77ece..a0a60d20 100644 --- a/clients/rust/reqwest/v1/docs/NodesApi.md +++ b/clients/rust/reqwest/v1/docs/NodesApi.md @@ -135,7 +135,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **node_id** | **String** | The ID of the node. | [required] | -**node_update_drain_request** | [**NodeUpdateDrainRequest**](NodeUpdateDrainRequest.md) | | [required] | +**node_update_drain_request** | Option<[**NodeUpdateDrainRequest**](NodeUpdateDrainRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **index** | Option<**i32**> | If set, wait until query exceeds given index. Must be provided with WaitParam. | | @@ -173,7 +173,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **node_id** | **String** | The ID of the node. | [required] | -**node_update_eligibility_request** | [**NodeUpdateEligibilityRequest**](NodeUpdateEligibilityRequest.md) | | [required] | +**node_update_eligibility_request** | Option<[**NodeUpdateEligibilityRequest**](NodeUpdateEligibilityRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **index** | Option<**i32**> | If set, wait until query exceeds given index. Must be provided with WaitParam. | | diff --git a/clients/rust/reqwest/v1/docs/OperatorApi.md b/clients/rust/reqwest/v1/docs/OperatorApi.md index 9249fe39..148d098b 100644 --- a/clients/rust/reqwest/v1/docs/OperatorApi.md +++ b/clients/rust/reqwest/v1/docs/OperatorApi.md @@ -199,7 +199,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- -**scheduler_configuration** | [**SchedulerConfiguration**](SchedulerConfiguration.md) | | [required] | +**scheduler_configuration** | Option<[**SchedulerConfiguration**](SchedulerConfiguration.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -231,7 +231,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- -**autopilot_configuration** | [**AutopilotConfiguration**](AutopilotConfiguration.md) | | [required] | +**autopilot_configuration** | Option<[**AutopilotConfiguration**](AutopilotConfiguration.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | diff --git a/clients/rust/reqwest/v1/docs/SearchApi.md b/clients/rust/reqwest/v1/docs/SearchApi.md index 39742848..0bc868c4 100644 --- a/clients/rust/reqwest/v1/docs/SearchApi.md +++ b/clients/rust/reqwest/v1/docs/SearchApi.md @@ -19,7 +19,7 @@ Method | HTTP request | Description Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- -**fuzzy_search_request** | [**FuzzySearchRequest**](FuzzySearchRequest.md) | | [required] | +**fuzzy_search_request** | Option<[**FuzzySearchRequest**](FuzzySearchRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **index** | Option<**i32**> | If set, wait until query exceeds given index. Must be provided with WaitParam. | | @@ -56,7 +56,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- -**search_request** | [**SearchRequest**](SearchRequest.md) | | [required] | +**search_request** | Option<[**SearchRequest**](SearchRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **index** | Option<**i32**> | If set, wait until query exceeds given index. Must be provided with WaitParam. | | diff --git a/clients/rust/reqwest/v1/docs/VolumesApi.md b/clients/rust/reqwest/v1/docs/VolumesApi.md index 83a23f0c..8312a2ca 100644 --- a/clients/rust/reqwest/v1/docs/VolumesApi.md +++ b/clients/rust/reqwest/v1/docs/VolumesApi.md @@ -30,7 +30,7 @@ Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **volume_id** | **String** | Volume unique identifier. | [required] | **action** | **String** | The action to perform on the Volume (create, detach, delete). | [required] | -**csi_volume_create_request** | [**CsiVolumeCreateRequest**](CsiVolumeCreateRequest.md) | | [required] | +**csi_volume_create_request** | Option<[**CsiVolumeCreateRequest**](CsiVolumeCreateRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -312,7 +312,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- -**csi_snapshot_create_request** | [**CsiSnapshotCreateRequest**](CsiSnapshotCreateRequest.md) | | [required] | +**csi_snapshot_create_request** | Option<[**CsiSnapshotCreateRequest**](CsiSnapshotCreateRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -344,7 +344,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- -**csi_volume_register_request** | [**CsiVolumeRegisterRequest**](CsiVolumeRegisterRequest.md) | | [required] | +**csi_volume_register_request** | Option<[**CsiVolumeRegisterRequest**](CsiVolumeRegisterRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | @@ -377,7 +377,7 @@ Name | Type | Description | Required | Notes Name | Type | Description | Required | Notes ------------- | ------------- | ------------- | ------------- | ------------- **volume_id** | **String** | Volume unique identifier. | [required] | -**csi_volume_register_request** | [**CsiVolumeRegisterRequest**](CsiVolumeRegisterRequest.md) | | [required] | +**csi_volume_register_request** | Option<[**CsiVolumeRegisterRequest**](CsiVolumeRegisterRequest.md)> | | [required] | **region** | Option<**String**> | Filters results based on the specified region. | | **namespace** | Option<**String**> | Filters results based on the specified namespace. | | **x_nomad_token** | Option<**String**> | A Nomad ACL token. | | diff --git a/clients/rust/reqwest/v1/src/apis/acl_api.rs b/clients/rust/reqwest/v1/src/apis/acl_api.rs index 3fa143ed..ef15c41e 100644 --- a/clients/rust/reqwest/v1/src/apis/acl_api.rs +++ b/clients/rust/reqwest/v1/src/apis/acl_api.rs @@ -15,7 +15,7 @@ use crate::apis::ResponseContent; use super::{Error, configuration}; -/// struct for typed errors of method `delete_acl_policy` +/// struct for typed errors of method [`delete_acl_policy`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum DeleteAclPolicyError { @@ -26,7 +26,7 @@ pub enum DeleteAclPolicyError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `delete_acl_token` +/// struct for typed errors of method [`delete_acl_token`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum DeleteAclTokenError { @@ -37,7 +37,7 @@ pub enum DeleteAclTokenError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_acl_policies` +/// struct for typed errors of method [`get_acl_policies`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetAclPoliciesError { @@ -48,7 +48,7 @@ pub enum GetAclPoliciesError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_acl_policy` +/// struct for typed errors of method [`get_acl_policy`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetAclPolicyError { @@ -59,7 +59,7 @@ pub enum GetAclPolicyError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_acl_token` +/// struct for typed errors of method [`get_acl_token`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetAclTokenError { @@ -70,7 +70,7 @@ pub enum GetAclTokenError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_acl_token_self` +/// struct for typed errors of method [`get_acl_token_self`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetAclTokenSelfError { @@ -81,7 +81,7 @@ pub enum GetAclTokenSelfError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_acl_tokens` +/// struct for typed errors of method [`get_acl_tokens`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetAclTokensError { @@ -92,7 +92,7 @@ pub enum GetAclTokensError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `post_acl_bootstrap` +/// struct for typed errors of method [`post_acl_bootstrap`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PostAclBootstrapError { @@ -103,7 +103,7 @@ pub enum PostAclBootstrapError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `post_acl_policy` +/// struct for typed errors of method [`post_acl_policy`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PostAclPolicyError { @@ -114,7 +114,7 @@ pub enum PostAclPolicyError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `post_acl_token` +/// struct for typed errors of method [`post_acl_token`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PostAclTokenError { @@ -125,7 +125,7 @@ pub enum PostAclTokenError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `post_acl_token_onetime` +/// struct for typed errors of method [`post_acl_token_onetime`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PostAclTokenOnetimeError { @@ -136,7 +136,7 @@ pub enum PostAclTokenOnetimeError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `post_acl_token_onetime_exchange` +/// struct for typed errors of method [`post_acl_token_onetime_exchange`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PostAclTokenOnetimeExchangeError { @@ -149,10 +149,11 @@ pub enum PostAclTokenOnetimeExchangeError { pub async fn delete_acl_policy(configuration: &configuration::Configuration, policy_name: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result<(), Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/acl/policy/{policyName}", configuration.base_path, policyName=crate::apis::urlencode(policy_name)); + let local_var_uri_str = format!("{}/acl/policy/{policyName}", local_var_configuration.base_path, policyName=crate::apis::urlencode(policy_name)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::DELETE, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -164,13 +165,13 @@ pub async fn delete_acl_policy(configuration: &configuration::Configuration, pol if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -195,10 +196,11 @@ pub async fn delete_acl_policy(configuration: &configuration::Configuration, pol } pub async fn delete_acl_token(configuration: &configuration::Configuration, token_accessor: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result<(), Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/acl/token/{tokenAccessor}", configuration.base_path, tokenAccessor=crate::apis::urlencode(token_accessor)); + let local_var_uri_str = format!("{}/acl/token/{tokenAccessor}", local_var_configuration.base_path, tokenAccessor=crate::apis::urlencode(token_accessor)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::DELETE, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -210,13 +212,13 @@ pub async fn delete_acl_token(configuration: &configuration::Configuration, toke if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -241,10 +243,11 @@ pub async fn delete_acl_token(configuration: &configuration::Configuration, toke } pub async fn get_acl_policies(configuration: &configuration::Configuration, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result, Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/acl/policies", configuration.base_path); + let local_var_uri_str = format!("{}/acl/policies", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -268,7 +271,7 @@ pub async fn get_acl_policies(configuration: &configuration::Configuration, regi if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -277,7 +280,7 @@ pub async fn get_acl_policies(configuration: &configuration::Configuration, regi if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -302,10 +305,11 @@ pub async fn get_acl_policies(configuration: &configuration::Configuration, regi } pub async fn get_acl_policy(configuration: &configuration::Configuration, policy_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/acl/policy/{policyName}", configuration.base_path, policyName=crate::apis::urlencode(policy_name)); + let local_var_uri_str = format!("{}/acl/policy/{policyName}", local_var_configuration.base_path, policyName=crate::apis::urlencode(policy_name)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -329,7 +333,7 @@ pub async fn get_acl_policy(configuration: &configuration::Configuration, policy if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -338,7 +342,7 @@ pub async fn get_acl_policy(configuration: &configuration::Configuration, policy if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -363,10 +367,11 @@ pub async fn get_acl_policy(configuration: &configuration::Configuration, policy } pub async fn get_acl_token(configuration: &configuration::Configuration, token_accessor: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/acl/token/{tokenAccessor}", configuration.base_path, tokenAccessor=crate::apis::urlencode(token_accessor)); + let local_var_uri_str = format!("{}/acl/token/{tokenAccessor}", local_var_configuration.base_path, tokenAccessor=crate::apis::urlencode(token_accessor)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -390,7 +395,7 @@ pub async fn get_acl_token(configuration: &configuration::Configuration, token_a if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -399,7 +404,7 @@ pub async fn get_acl_token(configuration: &configuration::Configuration, token_a if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -424,10 +429,11 @@ pub async fn get_acl_token(configuration: &configuration::Configuration, token_a } pub async fn get_acl_token_self(configuration: &configuration::Configuration, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/acl/token", configuration.base_path); + let local_var_uri_str = format!("{}/acl/token", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -451,7 +457,7 @@ pub async fn get_acl_token_self(configuration: &configuration::Configuration, re if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -460,7 +466,7 @@ pub async fn get_acl_token_self(configuration: &configuration::Configuration, re if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -485,10 +491,11 @@ pub async fn get_acl_token_self(configuration: &configuration::Configuration, re } pub async fn get_acl_tokens(configuration: &configuration::Configuration, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result, Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/acl/tokens", configuration.base_path); + let local_var_uri_str = format!("{}/acl/tokens", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -512,7 +519,7 @@ pub async fn get_acl_tokens(configuration: &configuration::Configuration, region if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -521,7 +528,7 @@ pub async fn get_acl_tokens(configuration: &configuration::Configuration, region if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -546,10 +553,11 @@ pub async fn get_acl_tokens(configuration: &configuration::Configuration, region } pub async fn post_acl_bootstrap(configuration: &configuration::Configuration, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/acl/bootstrap", configuration.base_path); + let local_var_uri_str = format!("{}/acl/bootstrap", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -561,13 +569,13 @@ pub async fn post_acl_bootstrap(configuration: &configuration::Configuration, re if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -591,11 +599,12 @@ pub async fn post_acl_bootstrap(configuration: &configuration::Configuration, re } } -pub async fn post_acl_policy(configuration: &configuration::Configuration, policy_name: &str, acl_policy: crate::models::AclPolicy, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result<(), Error> { +pub async fn post_acl_policy(configuration: &configuration::Configuration, policy_name: &str, acl_policy: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result<(), Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/acl/policy/{policyName}", configuration.base_path, policyName=crate::apis::urlencode(policy_name)); + let local_var_uri_str = format!("{}/acl/policy/{policyName}", local_var_configuration.base_path, policyName=crate::apis::urlencode(policy_name)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -607,13 +616,13 @@ pub async fn post_acl_policy(configuration: &configuration::Configuration, polic if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -638,11 +647,12 @@ pub async fn post_acl_policy(configuration: &configuration::Configuration, polic } } -pub async fn post_acl_token(configuration: &configuration::Configuration, token_accessor: &str, acl_token: crate::models::AclToken, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { +pub async fn post_acl_token(configuration: &configuration::Configuration, token_accessor: &str, acl_token: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/acl/token/{tokenAccessor}", configuration.base_path, tokenAccessor=crate::apis::urlencode(token_accessor)); + let local_var_uri_str = format!("{}/acl/token/{tokenAccessor}", local_var_configuration.base_path, tokenAccessor=crate::apis::urlencode(token_accessor)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -654,13 +664,13 @@ pub async fn post_acl_token(configuration: &configuration::Configuration, token_ if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -686,10 +696,11 @@ pub async fn post_acl_token(configuration: &configuration::Configuration, token_ } pub async fn post_acl_token_onetime(configuration: &configuration::Configuration, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/acl/token/onetime", configuration.base_path); + let local_var_uri_str = format!("{}/acl/token/onetime", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -701,13 +712,13 @@ pub async fn post_acl_token_onetime(configuration: &configuration::Configuration if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -731,11 +742,12 @@ pub async fn post_acl_token_onetime(configuration: &configuration::Configuration } } -pub async fn post_acl_token_onetime_exchange(configuration: &configuration::Configuration, one_time_token_exchange_request: crate::models::OneTimeTokenExchangeRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { +pub async fn post_acl_token_onetime_exchange(configuration: &configuration::Configuration, one_time_token_exchange_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/acl/token/onetime/exchange", configuration.base_path); + let local_var_uri_str = format!("{}/acl/token/onetime/exchange", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -747,13 +759,13 @@ pub async fn post_acl_token_onetime_exchange(configuration: &configuration::Conf if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), diff --git a/clients/rust/reqwest/v1/src/apis/allocations_api.rs b/clients/rust/reqwest/v1/src/apis/allocations_api.rs index 855cc726..0f8b3384 100644 --- a/clients/rust/reqwest/v1/src/apis/allocations_api.rs +++ b/clients/rust/reqwest/v1/src/apis/allocations_api.rs @@ -15,7 +15,7 @@ use crate::apis::ResponseContent; use super::{Error, configuration}; -/// struct for typed errors of method `get_allocation` +/// struct for typed errors of method [`get_allocation`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetAllocationError { @@ -26,7 +26,7 @@ pub enum GetAllocationError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_allocation_services` +/// struct for typed errors of method [`get_allocation_services`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetAllocationServicesError { @@ -37,7 +37,7 @@ pub enum GetAllocationServicesError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_allocations` +/// struct for typed errors of method [`get_allocations`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetAllocationsError { @@ -48,7 +48,7 @@ pub enum GetAllocationsError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `post_allocation_stop` +/// struct for typed errors of method [`post_allocation_stop`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PostAllocationStopError { @@ -61,10 +61,11 @@ pub enum PostAllocationStopError { pub async fn get_allocation(configuration: &configuration::Configuration, alloc_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/allocation/{allocID}", configuration.base_path, allocID=crate::apis::urlencode(alloc_id)); + let local_var_uri_str = format!("{}/allocation/{allocID}", local_var_configuration.base_path, allocID=crate::apis::urlencode(alloc_id)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -88,7 +89,7 @@ pub async fn get_allocation(configuration: &configuration::Configuration, alloc_ if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -97,7 +98,7 @@ pub async fn get_allocation(configuration: &configuration::Configuration, alloc_ if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -122,10 +123,11 @@ pub async fn get_allocation(configuration: &configuration::Configuration, alloc_ } pub async fn get_allocation_services(configuration: &configuration::Configuration, alloc_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result, Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/allocation/{allocID}/services", configuration.base_path, allocID=crate::apis::urlencode(alloc_id)); + let local_var_uri_str = format!("{}/allocation/{allocID}/services", local_var_configuration.base_path, allocID=crate::apis::urlencode(alloc_id)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -149,7 +151,7 @@ pub async fn get_allocation_services(configuration: &configuration::Configuratio if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -158,7 +160,7 @@ pub async fn get_allocation_services(configuration: &configuration::Configuratio if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -183,10 +185,11 @@ pub async fn get_allocation_services(configuration: &configuration::Configuratio } pub async fn get_allocations(configuration: &configuration::Configuration, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, resources: Option, task_states: Option) -> Result, Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/allocations", configuration.base_path); + let local_var_uri_str = format!("{}/allocations", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -216,7 +219,7 @@ pub async fn get_allocations(configuration: &configuration::Configuration, regio if let Some(ref local_var_str) = task_states { local_var_req_builder = local_var_req_builder.query(&[("task_states", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -225,7 +228,7 @@ pub async fn get_allocations(configuration: &configuration::Configuration, regio if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -250,10 +253,11 @@ pub async fn get_allocations(configuration: &configuration::Configuration, regio } pub async fn post_allocation_stop(configuration: &configuration::Configuration, alloc_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, no_shutdown_delay: Option) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/allocation/{allocID}/stop", configuration.base_path, allocID=crate::apis::urlencode(alloc_id)); + let local_var_uri_str = format!("{}/allocation/{allocID}/stop", local_var_configuration.base_path, allocID=crate::apis::urlencode(alloc_id)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -280,7 +284,7 @@ pub async fn post_allocation_stop(configuration: &configuration::Configuration, if let Some(ref local_var_str) = no_shutdown_delay { local_var_req_builder = local_var_req_builder.query(&[("no_shutdown_delay", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -289,7 +293,7 @@ pub async fn post_allocation_stop(configuration: &configuration::Configuration, if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), diff --git a/clients/rust/reqwest/v1/src/apis/deployments_api.rs b/clients/rust/reqwest/v1/src/apis/deployments_api.rs index 9d9b3b7d..c75884b2 100644 --- a/clients/rust/reqwest/v1/src/apis/deployments_api.rs +++ b/clients/rust/reqwest/v1/src/apis/deployments_api.rs @@ -15,7 +15,7 @@ use crate::apis::ResponseContent; use super::{Error, configuration}; -/// struct for typed errors of method `get_deployment` +/// struct for typed errors of method [`get_deployment`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetDeploymentError { @@ -26,7 +26,7 @@ pub enum GetDeploymentError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_deployment_allocations` +/// struct for typed errors of method [`get_deployment_allocations`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetDeploymentAllocationsError { @@ -37,7 +37,7 @@ pub enum GetDeploymentAllocationsError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_deployments` +/// struct for typed errors of method [`get_deployments`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetDeploymentsError { @@ -48,7 +48,7 @@ pub enum GetDeploymentsError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `post_deployment_allocation_health` +/// struct for typed errors of method [`post_deployment_allocation_health`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PostDeploymentAllocationHealthError { @@ -59,7 +59,7 @@ pub enum PostDeploymentAllocationHealthError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `post_deployment_fail` +/// struct for typed errors of method [`post_deployment_fail`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PostDeploymentFailError { @@ -70,7 +70,7 @@ pub enum PostDeploymentFailError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `post_deployment_pause` +/// struct for typed errors of method [`post_deployment_pause`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PostDeploymentPauseError { @@ -81,7 +81,7 @@ pub enum PostDeploymentPauseError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `post_deployment_promote` +/// struct for typed errors of method [`post_deployment_promote`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PostDeploymentPromoteError { @@ -92,7 +92,7 @@ pub enum PostDeploymentPromoteError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `post_deployment_unblock` +/// struct for typed errors of method [`post_deployment_unblock`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PostDeploymentUnblockError { @@ -105,10 +105,11 @@ pub enum PostDeploymentUnblockError { pub async fn get_deployment(configuration: &configuration::Configuration, deployment_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/deployment/{deploymentID}", configuration.base_path, deploymentID=crate::apis::urlencode(deployment_id)); + let local_var_uri_str = format!("{}/deployment/{deploymentID}", local_var_configuration.base_path, deploymentID=crate::apis::urlencode(deployment_id)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -132,7 +133,7 @@ pub async fn get_deployment(configuration: &configuration::Configuration, deploy if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -141,7 +142,7 @@ pub async fn get_deployment(configuration: &configuration::Configuration, deploy if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -166,10 +167,11 @@ pub async fn get_deployment(configuration: &configuration::Configuration, deploy } pub async fn get_deployment_allocations(configuration: &configuration::Configuration, deployment_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result, Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/deployment/allocations/{deploymentID}", configuration.base_path, deploymentID=crate::apis::urlencode(deployment_id)); + let local_var_uri_str = format!("{}/deployment/allocations/{deploymentID}", local_var_configuration.base_path, deploymentID=crate::apis::urlencode(deployment_id)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -193,7 +195,7 @@ pub async fn get_deployment_allocations(configuration: &configuration::Configura if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -202,7 +204,7 @@ pub async fn get_deployment_allocations(configuration: &configuration::Configura if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -227,10 +229,11 @@ pub async fn get_deployment_allocations(configuration: &configuration::Configura } pub async fn get_deployments(configuration: &configuration::Configuration, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result, Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/deployments", configuration.base_path); + let local_var_uri_str = format!("{}/deployments", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -254,7 +257,7 @@ pub async fn get_deployments(configuration: &configuration::Configuration, regio if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -263,7 +266,7 @@ pub async fn get_deployments(configuration: &configuration::Configuration, regio if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -287,11 +290,12 @@ pub async fn get_deployments(configuration: &configuration::Configuration, regio } } -pub async fn post_deployment_allocation_health(configuration: &configuration::Configuration, deployment_id: &str, deployment_alloc_health_request: crate::models::DeploymentAllocHealthRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { +pub async fn post_deployment_allocation_health(configuration: &configuration::Configuration, deployment_id: &str, deployment_alloc_health_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/deployment/allocation-health/{deploymentID}", configuration.base_path, deploymentID=crate::apis::urlencode(deployment_id)); + let local_var_uri_str = format!("{}/deployment/allocation-health/{deploymentID}", local_var_configuration.base_path, deploymentID=crate::apis::urlencode(deployment_id)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -303,13 +307,13 @@ pub async fn post_deployment_allocation_health(configuration: &configuration::Co if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -335,10 +339,11 @@ pub async fn post_deployment_allocation_health(configuration: &configuration::Co } pub async fn post_deployment_fail(configuration: &configuration::Configuration, deployment_id: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/deployment/fail/{deploymentID}", configuration.base_path, deploymentID=crate::apis::urlencode(deployment_id)); + let local_var_uri_str = format!("{}/deployment/fail/{deploymentID}", local_var_configuration.base_path, deploymentID=crate::apis::urlencode(deployment_id)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -350,13 +355,13 @@ pub async fn post_deployment_fail(configuration: &configuration::Configuration, if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -380,11 +385,12 @@ pub async fn post_deployment_fail(configuration: &configuration::Configuration, } } -pub async fn post_deployment_pause(configuration: &configuration::Configuration, deployment_id: &str, deployment_pause_request: crate::models::DeploymentPauseRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { +pub async fn post_deployment_pause(configuration: &configuration::Configuration, deployment_id: &str, deployment_pause_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/deployment/pause/{deploymentID}", configuration.base_path, deploymentID=crate::apis::urlencode(deployment_id)); + let local_var_uri_str = format!("{}/deployment/pause/{deploymentID}", local_var_configuration.base_path, deploymentID=crate::apis::urlencode(deployment_id)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -396,13 +402,13 @@ pub async fn post_deployment_pause(configuration: &configuration::Configuration, if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -427,11 +433,12 @@ pub async fn post_deployment_pause(configuration: &configuration::Configuration, } } -pub async fn post_deployment_promote(configuration: &configuration::Configuration, deployment_id: &str, deployment_promote_request: crate::models::DeploymentPromoteRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { +pub async fn post_deployment_promote(configuration: &configuration::Configuration, deployment_id: &str, deployment_promote_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/deployment/promote/{deploymentID}", configuration.base_path, deploymentID=crate::apis::urlencode(deployment_id)); + let local_var_uri_str = format!("{}/deployment/promote/{deploymentID}", local_var_configuration.base_path, deploymentID=crate::apis::urlencode(deployment_id)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -443,13 +450,13 @@ pub async fn post_deployment_promote(configuration: &configuration::Configuratio if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -474,11 +481,12 @@ pub async fn post_deployment_promote(configuration: &configuration::Configuratio } } -pub async fn post_deployment_unblock(configuration: &configuration::Configuration, deployment_id: &str, deployment_unblock_request: crate::models::DeploymentUnblockRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { +pub async fn post_deployment_unblock(configuration: &configuration::Configuration, deployment_id: &str, deployment_unblock_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/deployment/unblock/{deploymentID}", configuration.base_path, deploymentID=crate::apis::urlencode(deployment_id)); + let local_var_uri_str = format!("{}/deployment/unblock/{deploymentID}", local_var_configuration.base_path, deploymentID=crate::apis::urlencode(deployment_id)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -490,13 +498,13 @@ pub async fn post_deployment_unblock(configuration: &configuration::Configuratio if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), diff --git a/clients/rust/reqwest/v1/src/apis/enterprise_api.rs b/clients/rust/reqwest/v1/src/apis/enterprise_api.rs index 0633c14a..d942778b 100644 --- a/clients/rust/reqwest/v1/src/apis/enterprise_api.rs +++ b/clients/rust/reqwest/v1/src/apis/enterprise_api.rs @@ -15,7 +15,7 @@ use crate::apis::ResponseContent; use super::{Error, configuration}; -/// struct for typed errors of method `create_quota_spec` +/// struct for typed errors of method [`create_quota_spec`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CreateQuotaSpecError { @@ -26,7 +26,7 @@ pub enum CreateQuotaSpecError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `delete_quota_spec` +/// struct for typed errors of method [`delete_quota_spec`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum DeleteQuotaSpecError { @@ -37,7 +37,7 @@ pub enum DeleteQuotaSpecError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_quota_spec` +/// struct for typed errors of method [`get_quota_spec`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetQuotaSpecError { @@ -48,7 +48,7 @@ pub enum GetQuotaSpecError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_quotas` +/// struct for typed errors of method [`get_quotas`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetQuotasError { @@ -59,7 +59,7 @@ pub enum GetQuotasError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `post_quota_spec` +/// struct for typed errors of method [`post_quota_spec`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PostQuotaSpecError { @@ -71,11 +71,12 @@ pub enum PostQuotaSpecError { } -pub async fn create_quota_spec(configuration: &configuration::Configuration, quota_spec: crate::models::QuotaSpec, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result<(), Error> { +pub async fn create_quota_spec(configuration: &configuration::Configuration, quota_spec: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result<(), Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/quota", configuration.base_path); + let local_var_uri_str = format!("{}/quota", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -87,13 +88,13 @@ pub async fn create_quota_spec(configuration: &configuration::Configuration, quo if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -119,10 +120,11 @@ pub async fn create_quota_spec(configuration: &configuration::Configuration, quo } pub async fn delete_quota_spec(configuration: &configuration::Configuration, spec_name: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result<(), Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/quota/{specName}", configuration.base_path, specName=crate::apis::urlencode(spec_name)); + let local_var_uri_str = format!("{}/quota/{specName}", local_var_configuration.base_path, specName=crate::apis::urlencode(spec_name)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::DELETE, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -134,13 +136,13 @@ pub async fn delete_quota_spec(configuration: &configuration::Configuration, spe if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -165,10 +167,11 @@ pub async fn delete_quota_spec(configuration: &configuration::Configuration, spe } pub async fn get_quota_spec(configuration: &configuration::Configuration, spec_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/quota/{specName}", configuration.base_path, specName=crate::apis::urlencode(spec_name)); + let local_var_uri_str = format!("{}/quota/{specName}", local_var_configuration.base_path, specName=crate::apis::urlencode(spec_name)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -192,7 +195,7 @@ pub async fn get_quota_spec(configuration: &configuration::Configuration, spec_n if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -201,7 +204,7 @@ pub async fn get_quota_spec(configuration: &configuration::Configuration, spec_n if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -226,10 +229,11 @@ pub async fn get_quota_spec(configuration: &configuration::Configuration, spec_n } pub async fn get_quotas(configuration: &configuration::Configuration, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result, Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/quotas", configuration.base_path); + let local_var_uri_str = format!("{}/quotas", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -253,7 +257,7 @@ pub async fn get_quotas(configuration: &configuration::Configuration, region: Op if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -262,7 +266,7 @@ pub async fn get_quotas(configuration: &configuration::Configuration, region: Op if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -286,11 +290,12 @@ pub async fn get_quotas(configuration: &configuration::Configuration, region: Op } } -pub async fn post_quota_spec(configuration: &configuration::Configuration, spec_name: &str, quota_spec: crate::models::QuotaSpec, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result<(), Error> { +pub async fn post_quota_spec(configuration: &configuration::Configuration, spec_name: &str, quota_spec: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result<(), Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/quota/{specName}", configuration.base_path, specName=crate::apis::urlencode(spec_name)); + let local_var_uri_str = format!("{}/quota/{specName}", local_var_configuration.base_path, specName=crate::apis::urlencode(spec_name)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -302,13 +307,13 @@ pub async fn post_quota_spec(configuration: &configuration::Configuration, spec_ if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), diff --git a/clients/rust/reqwest/v1/src/apis/evaluations_api.rs b/clients/rust/reqwest/v1/src/apis/evaluations_api.rs index 16eb7ee3..5027d588 100644 --- a/clients/rust/reqwest/v1/src/apis/evaluations_api.rs +++ b/clients/rust/reqwest/v1/src/apis/evaluations_api.rs @@ -15,7 +15,7 @@ use crate::apis::ResponseContent; use super::{Error, configuration}; -/// struct for typed errors of method `get_evaluation` +/// struct for typed errors of method [`get_evaluation`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetEvaluationError { @@ -26,7 +26,7 @@ pub enum GetEvaluationError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_evaluation_allocations` +/// struct for typed errors of method [`get_evaluation_allocations`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetEvaluationAllocationsError { @@ -37,7 +37,7 @@ pub enum GetEvaluationAllocationsError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_evaluations` +/// struct for typed errors of method [`get_evaluations`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetEvaluationsError { @@ -50,10 +50,11 @@ pub enum GetEvaluationsError { pub async fn get_evaluation(configuration: &configuration::Configuration, eval_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/evaluation/{evalID}", configuration.base_path, evalID=crate::apis::urlencode(eval_id)); + let local_var_uri_str = format!("{}/evaluation/{evalID}", local_var_configuration.base_path, evalID=crate::apis::urlencode(eval_id)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -77,7 +78,7 @@ pub async fn get_evaluation(configuration: &configuration::Configuration, eval_i if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -86,7 +87,7 @@ pub async fn get_evaluation(configuration: &configuration::Configuration, eval_i if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -111,10 +112,11 @@ pub async fn get_evaluation(configuration: &configuration::Configuration, eval_i } pub async fn get_evaluation_allocations(configuration: &configuration::Configuration, eval_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result, Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/evaluation/{evalID}/allocations", configuration.base_path, evalID=crate::apis::urlencode(eval_id)); + let local_var_uri_str = format!("{}/evaluation/{evalID}/allocations", local_var_configuration.base_path, evalID=crate::apis::urlencode(eval_id)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -138,7 +140,7 @@ pub async fn get_evaluation_allocations(configuration: &configuration::Configura if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -147,7 +149,7 @@ pub async fn get_evaluation_allocations(configuration: &configuration::Configura if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -172,10 +174,11 @@ pub async fn get_evaluation_allocations(configuration: &configuration::Configura } pub async fn get_evaluations(configuration: &configuration::Configuration, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result, Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/evaluations", configuration.base_path); + let local_var_uri_str = format!("{}/evaluations", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -199,7 +202,7 @@ pub async fn get_evaluations(configuration: &configuration::Configuration, regio if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -208,7 +211,7 @@ pub async fn get_evaluations(configuration: &configuration::Configuration, regio if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), diff --git a/clients/rust/reqwest/v1/src/apis/jobs_api.rs b/clients/rust/reqwest/v1/src/apis/jobs_api.rs index 701446bf..b57aaa8f 100644 --- a/clients/rust/reqwest/v1/src/apis/jobs_api.rs +++ b/clients/rust/reqwest/v1/src/apis/jobs_api.rs @@ -15,7 +15,7 @@ use crate::apis::ResponseContent; use super::{Error, configuration}; -/// struct for typed errors of method `delete_job` +/// struct for typed errors of method [`delete_job`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum DeleteJobError { @@ -26,7 +26,7 @@ pub enum DeleteJobError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_job` +/// struct for typed errors of method [`get_job`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetJobError { @@ -37,7 +37,7 @@ pub enum GetJobError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_job_allocations` +/// struct for typed errors of method [`get_job_allocations`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetJobAllocationsError { @@ -48,7 +48,7 @@ pub enum GetJobAllocationsError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_job_deployment` +/// struct for typed errors of method [`get_job_deployment`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetJobDeploymentError { @@ -59,7 +59,7 @@ pub enum GetJobDeploymentError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_job_deployments` +/// struct for typed errors of method [`get_job_deployments`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetJobDeploymentsError { @@ -70,7 +70,7 @@ pub enum GetJobDeploymentsError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_job_evaluations` +/// struct for typed errors of method [`get_job_evaluations`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetJobEvaluationsError { @@ -81,7 +81,7 @@ pub enum GetJobEvaluationsError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_job_scale_status` +/// struct for typed errors of method [`get_job_scale_status`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetJobScaleStatusError { @@ -92,7 +92,7 @@ pub enum GetJobScaleStatusError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_job_summary` +/// struct for typed errors of method [`get_job_summary`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetJobSummaryError { @@ -103,7 +103,7 @@ pub enum GetJobSummaryError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_job_versions` +/// struct for typed errors of method [`get_job_versions`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetJobVersionsError { @@ -114,7 +114,7 @@ pub enum GetJobVersionsError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_jobs` +/// struct for typed errors of method [`get_jobs`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetJobsError { @@ -125,7 +125,7 @@ pub enum GetJobsError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `post_job` +/// struct for typed errors of method [`post_job`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PostJobError { @@ -136,7 +136,7 @@ pub enum PostJobError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `post_job_dispatch` +/// struct for typed errors of method [`post_job_dispatch`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PostJobDispatchError { @@ -147,7 +147,7 @@ pub enum PostJobDispatchError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `post_job_evaluate` +/// struct for typed errors of method [`post_job_evaluate`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PostJobEvaluateError { @@ -158,7 +158,7 @@ pub enum PostJobEvaluateError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `post_job_parse` +/// struct for typed errors of method [`post_job_parse`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PostJobParseError { @@ -169,7 +169,7 @@ pub enum PostJobParseError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `post_job_periodic_force` +/// struct for typed errors of method [`post_job_periodic_force`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PostJobPeriodicForceError { @@ -180,7 +180,7 @@ pub enum PostJobPeriodicForceError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `post_job_plan` +/// struct for typed errors of method [`post_job_plan`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PostJobPlanError { @@ -191,7 +191,7 @@ pub enum PostJobPlanError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `post_job_revert` +/// struct for typed errors of method [`post_job_revert`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PostJobRevertError { @@ -202,7 +202,7 @@ pub enum PostJobRevertError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `post_job_scaling_request` +/// struct for typed errors of method [`post_job_scaling_request`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PostJobScalingRequestError { @@ -213,7 +213,7 @@ pub enum PostJobScalingRequestError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `post_job_stability` +/// struct for typed errors of method [`post_job_stability`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PostJobStabilityError { @@ -224,7 +224,7 @@ pub enum PostJobStabilityError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `post_job_validate_request` +/// struct for typed errors of method [`post_job_validate_request`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PostJobValidateRequestError { @@ -235,7 +235,7 @@ pub enum PostJobValidateRequestError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `register_job` +/// struct for typed errors of method [`register_job`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum RegisterJobError { @@ -248,10 +248,11 @@ pub enum RegisterJobError { pub async fn delete_job(configuration: &configuration::Configuration, job_name: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>, purge: Option, global: Option) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/job/{jobName}", configuration.base_path, jobName=crate::apis::urlencode(job_name)); + let local_var_uri_str = format!("{}/job/{jobName}", local_var_configuration.base_path, jobName=crate::apis::urlencode(job_name)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::DELETE, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -269,13 +270,13 @@ pub async fn delete_job(configuration: &configuration::Configuration, job_name: if let Some(ref local_var_str) = global { local_var_req_builder = local_var_req_builder.query(&[("global", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -300,10 +301,11 @@ pub async fn delete_job(configuration: &configuration::Configuration, job_name: } pub async fn get_job(configuration: &configuration::Configuration, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/job/{jobName}", configuration.base_path, jobName=crate::apis::urlencode(job_name)); + let local_var_uri_str = format!("{}/job/{jobName}", local_var_configuration.base_path, jobName=crate::apis::urlencode(job_name)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -327,7 +329,7 @@ pub async fn get_job(configuration: &configuration::Configuration, job_name: &st if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -336,7 +338,7 @@ pub async fn get_job(configuration: &configuration::Configuration, job_name: &st if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -361,10 +363,11 @@ pub async fn get_job(configuration: &configuration::Configuration, job_name: &st } pub async fn get_job_allocations(configuration: &configuration::Configuration, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, all: Option) -> Result, Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/job/{jobName}/allocations", configuration.base_path, jobName=crate::apis::urlencode(job_name)); + let local_var_uri_str = format!("{}/job/{jobName}/allocations", local_var_configuration.base_path, jobName=crate::apis::urlencode(job_name)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -391,7 +394,7 @@ pub async fn get_job_allocations(configuration: &configuration::Configuration, j if let Some(ref local_var_str) = all { local_var_req_builder = local_var_req_builder.query(&[("all", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -400,7 +403,7 @@ pub async fn get_job_allocations(configuration: &configuration::Configuration, j if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -425,10 +428,11 @@ pub async fn get_job_allocations(configuration: &configuration::Configuration, j } pub async fn get_job_deployment(configuration: &configuration::Configuration, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/job/{jobName}/deployment", configuration.base_path, jobName=crate::apis::urlencode(job_name)); + let local_var_uri_str = format!("{}/job/{jobName}/deployment", local_var_configuration.base_path, jobName=crate::apis::urlencode(job_name)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -452,7 +456,7 @@ pub async fn get_job_deployment(configuration: &configuration::Configuration, jo if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -461,7 +465,7 @@ pub async fn get_job_deployment(configuration: &configuration::Configuration, jo if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -486,10 +490,11 @@ pub async fn get_job_deployment(configuration: &configuration::Configuration, jo } pub async fn get_job_deployments(configuration: &configuration::Configuration, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, all: Option) -> Result, Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/job/{jobName}/deployments", configuration.base_path, jobName=crate::apis::urlencode(job_name)); + let local_var_uri_str = format!("{}/job/{jobName}/deployments", local_var_configuration.base_path, jobName=crate::apis::urlencode(job_name)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -516,7 +521,7 @@ pub async fn get_job_deployments(configuration: &configuration::Configuration, j if let Some(ref local_var_str) = all { local_var_req_builder = local_var_req_builder.query(&[("all", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -525,7 +530,7 @@ pub async fn get_job_deployments(configuration: &configuration::Configuration, j if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -550,10 +555,11 @@ pub async fn get_job_deployments(configuration: &configuration::Configuration, j } pub async fn get_job_evaluations(configuration: &configuration::Configuration, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result, Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/job/{jobName}/evaluations", configuration.base_path, jobName=crate::apis::urlencode(job_name)); + let local_var_uri_str = format!("{}/job/{jobName}/evaluations", local_var_configuration.base_path, jobName=crate::apis::urlencode(job_name)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -577,7 +583,7 @@ pub async fn get_job_evaluations(configuration: &configuration::Configuration, j if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -586,7 +592,7 @@ pub async fn get_job_evaluations(configuration: &configuration::Configuration, j if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -611,10 +617,11 @@ pub async fn get_job_evaluations(configuration: &configuration::Configuration, j } pub async fn get_job_scale_status(configuration: &configuration::Configuration, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/job/{jobName}/scale", configuration.base_path, jobName=crate::apis::urlencode(job_name)); + let local_var_uri_str = format!("{}/job/{jobName}/scale", local_var_configuration.base_path, jobName=crate::apis::urlencode(job_name)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -638,7 +645,7 @@ pub async fn get_job_scale_status(configuration: &configuration::Configuration, if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -647,7 +654,7 @@ pub async fn get_job_scale_status(configuration: &configuration::Configuration, if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -672,10 +679,11 @@ pub async fn get_job_scale_status(configuration: &configuration::Configuration, } pub async fn get_job_summary(configuration: &configuration::Configuration, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/job/{jobName}/summary", configuration.base_path, jobName=crate::apis::urlencode(job_name)); + let local_var_uri_str = format!("{}/job/{jobName}/summary", local_var_configuration.base_path, jobName=crate::apis::urlencode(job_name)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -699,7 +707,7 @@ pub async fn get_job_summary(configuration: &configuration::Configuration, job_n if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -708,7 +716,7 @@ pub async fn get_job_summary(configuration: &configuration::Configuration, job_n if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -733,10 +741,11 @@ pub async fn get_job_summary(configuration: &configuration::Configuration, job_n } pub async fn get_job_versions(configuration: &configuration::Configuration, job_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, diffs: Option) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/job/{jobName}/versions", configuration.base_path, jobName=crate::apis::urlencode(job_name)); + let local_var_uri_str = format!("{}/job/{jobName}/versions", local_var_configuration.base_path, jobName=crate::apis::urlencode(job_name)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -763,7 +772,7 @@ pub async fn get_job_versions(configuration: &configuration::Configuration, job_ if let Some(ref local_var_str) = diffs { local_var_req_builder = local_var_req_builder.query(&[("diffs", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -772,7 +781,7 @@ pub async fn get_job_versions(configuration: &configuration::Configuration, job_ if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -797,10 +806,11 @@ pub async fn get_job_versions(configuration: &configuration::Configuration, job_ } pub async fn get_jobs(configuration: &configuration::Configuration, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result, Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/jobs", configuration.base_path); + let local_var_uri_str = format!("{}/jobs", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -824,7 +834,7 @@ pub async fn get_jobs(configuration: &configuration::Configuration, region: Opti if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -833,7 +843,7 @@ pub async fn get_jobs(configuration: &configuration::Configuration, region: Opti if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -857,11 +867,12 @@ pub async fn get_jobs(configuration: &configuration::Configuration, region: Opti } } -pub async fn post_job(configuration: &configuration::Configuration, job_name: &str, job_register_request: crate::models::JobRegisterRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { +pub async fn post_job(configuration: &configuration::Configuration, job_name: &str, job_register_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/job/{jobName}", configuration.base_path, jobName=crate::apis::urlencode(job_name)); + let local_var_uri_str = format!("{}/job/{jobName}", local_var_configuration.base_path, jobName=crate::apis::urlencode(job_name)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -873,13 +884,13 @@ pub async fn post_job(configuration: &configuration::Configuration, job_name: &s if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -904,11 +915,12 @@ pub async fn post_job(configuration: &configuration::Configuration, job_name: &s } } -pub async fn post_job_dispatch(configuration: &configuration::Configuration, job_name: &str, job_dispatch_request: crate::models::JobDispatchRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { +pub async fn post_job_dispatch(configuration: &configuration::Configuration, job_name: &str, job_dispatch_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/job/{jobName}/dispatch", configuration.base_path, jobName=crate::apis::urlencode(job_name)); + let local_var_uri_str = format!("{}/job/{jobName}/dispatch", local_var_configuration.base_path, jobName=crate::apis::urlencode(job_name)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -920,13 +932,13 @@ pub async fn post_job_dispatch(configuration: &configuration::Configuration, job if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -951,11 +963,12 @@ pub async fn post_job_dispatch(configuration: &configuration::Configuration, job } } -pub async fn post_job_evaluate(configuration: &configuration::Configuration, job_name: &str, job_evaluate_request: crate::models::JobEvaluateRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { +pub async fn post_job_evaluate(configuration: &configuration::Configuration, job_name: &str, job_evaluate_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/job/{jobName}/evaluate", configuration.base_path, jobName=crate::apis::urlencode(job_name)); + let local_var_uri_str = format!("{}/job/{jobName}/evaluate", local_var_configuration.base_path, jobName=crate::apis::urlencode(job_name)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -967,13 +980,13 @@ pub async fn post_job_evaluate(configuration: &configuration::Configuration, job if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -998,17 +1011,18 @@ pub async fn post_job_evaluate(configuration: &configuration::Configuration, job } } -pub async fn post_job_parse(configuration: &configuration::Configuration, jobs_parse_request: crate::models::JobsParseRequest) -> Result> { +pub async fn post_job_parse(configuration: &configuration::Configuration, jobs_parse_request: Option) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/jobs/parse", configuration.base_path); + let local_var_uri_str = format!("{}/jobs/parse", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -1034,10 +1048,11 @@ pub async fn post_job_parse(configuration: &configuration::Configuration, jobs_p } pub async fn post_job_periodic_force(configuration: &configuration::Configuration, job_name: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/job/{jobName}/periodic/force", configuration.base_path, jobName=crate::apis::urlencode(job_name)); + let local_var_uri_str = format!("{}/job/{jobName}/periodic/force", local_var_configuration.base_path, jobName=crate::apis::urlencode(job_name)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -1049,13 +1064,13 @@ pub async fn post_job_periodic_force(configuration: &configuration::Configuratio if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -1079,11 +1094,12 @@ pub async fn post_job_periodic_force(configuration: &configuration::Configuratio } } -pub async fn post_job_plan(configuration: &configuration::Configuration, job_name: &str, job_plan_request: crate::models::JobPlanRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { +pub async fn post_job_plan(configuration: &configuration::Configuration, job_name: &str, job_plan_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/job/{jobName}/plan", configuration.base_path, jobName=crate::apis::urlencode(job_name)); + let local_var_uri_str = format!("{}/job/{jobName}/plan", local_var_configuration.base_path, jobName=crate::apis::urlencode(job_name)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -1095,13 +1111,13 @@ pub async fn post_job_plan(configuration: &configuration::Configuration, job_nam if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -1126,11 +1142,12 @@ pub async fn post_job_plan(configuration: &configuration::Configuration, job_nam } } -pub async fn post_job_revert(configuration: &configuration::Configuration, job_name: &str, job_revert_request: crate::models::JobRevertRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { +pub async fn post_job_revert(configuration: &configuration::Configuration, job_name: &str, job_revert_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/job/{jobName}/revert", configuration.base_path, jobName=crate::apis::urlencode(job_name)); + let local_var_uri_str = format!("{}/job/{jobName}/revert", local_var_configuration.base_path, jobName=crate::apis::urlencode(job_name)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -1142,13 +1159,13 @@ pub async fn post_job_revert(configuration: &configuration::Configuration, job_n if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -1173,11 +1190,12 @@ pub async fn post_job_revert(configuration: &configuration::Configuration, job_n } } -pub async fn post_job_scaling_request(configuration: &configuration::Configuration, job_name: &str, scaling_request: crate::models::ScalingRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { +pub async fn post_job_scaling_request(configuration: &configuration::Configuration, job_name: &str, scaling_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/job/{jobName}/scale", configuration.base_path, jobName=crate::apis::urlencode(job_name)); + let local_var_uri_str = format!("{}/job/{jobName}/scale", local_var_configuration.base_path, jobName=crate::apis::urlencode(job_name)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -1189,13 +1207,13 @@ pub async fn post_job_scaling_request(configuration: &configuration::Configurati if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -1220,11 +1238,12 @@ pub async fn post_job_scaling_request(configuration: &configuration::Configurati } } -pub async fn post_job_stability(configuration: &configuration::Configuration, job_name: &str, job_stability_request: crate::models::JobStabilityRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { +pub async fn post_job_stability(configuration: &configuration::Configuration, job_name: &str, job_stability_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/job/{jobName}/stable", configuration.base_path, jobName=crate::apis::urlencode(job_name)); + let local_var_uri_str = format!("{}/job/{jobName}/stable", local_var_configuration.base_path, jobName=crate::apis::urlencode(job_name)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -1236,13 +1255,13 @@ pub async fn post_job_stability(configuration: &configuration::Configuration, jo if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -1267,11 +1286,12 @@ pub async fn post_job_stability(configuration: &configuration::Configuration, jo } } -pub async fn post_job_validate_request(configuration: &configuration::Configuration, job_validate_request: crate::models::JobValidateRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { +pub async fn post_job_validate_request(configuration: &configuration::Configuration, job_validate_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/validate/job", configuration.base_path); + let local_var_uri_str = format!("{}/validate/job", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -1283,13 +1303,13 @@ pub async fn post_job_validate_request(configuration: &configuration::Configurat if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -1314,11 +1334,12 @@ pub async fn post_job_validate_request(configuration: &configuration::Configurat } } -pub async fn register_job(configuration: &configuration::Configuration, job_register_request: crate::models::JobRegisterRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { +pub async fn register_job(configuration: &configuration::Configuration, job_register_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/jobs", configuration.base_path); + let local_var_uri_str = format!("{}/jobs", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -1330,13 +1351,13 @@ pub async fn register_job(configuration: &configuration::Configuration, job_regi if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), diff --git a/clients/rust/reqwest/v1/src/apis/metrics_api.rs b/clients/rust/reqwest/v1/src/apis/metrics_api.rs index 694b4627..b5e7cf2e 100644 --- a/clients/rust/reqwest/v1/src/apis/metrics_api.rs +++ b/clients/rust/reqwest/v1/src/apis/metrics_api.rs @@ -15,7 +15,7 @@ use crate::apis::ResponseContent; use super::{Error, configuration}; -/// struct for typed errors of method `get_metrics_summary` +/// struct for typed errors of method [`get_metrics_summary`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetMetricsSummaryError { @@ -28,19 +28,20 @@ pub enum GetMetricsSummaryError { pub async fn get_metrics_summary(configuration: &configuration::Configuration, format: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/metrics", configuration.base_path); + let local_var_uri_str = format!("{}/metrics", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = format { local_var_req_builder = local_var_req_builder.query(&[("format", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), diff --git a/clients/rust/reqwest/v1/src/apis/namespaces_api.rs b/clients/rust/reqwest/v1/src/apis/namespaces_api.rs index be94ac9c..e8e25264 100644 --- a/clients/rust/reqwest/v1/src/apis/namespaces_api.rs +++ b/clients/rust/reqwest/v1/src/apis/namespaces_api.rs @@ -15,7 +15,7 @@ use crate::apis::ResponseContent; use super::{Error, configuration}; -/// struct for typed errors of method `create_namespace` +/// struct for typed errors of method [`create_namespace`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CreateNamespaceError { @@ -26,7 +26,7 @@ pub enum CreateNamespaceError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `delete_namespace` +/// struct for typed errors of method [`delete_namespace`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum DeleteNamespaceError { @@ -37,7 +37,7 @@ pub enum DeleteNamespaceError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_namespace` +/// struct for typed errors of method [`get_namespace`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetNamespaceError { @@ -48,7 +48,7 @@ pub enum GetNamespaceError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_namespaces` +/// struct for typed errors of method [`get_namespaces`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetNamespacesError { @@ -59,7 +59,7 @@ pub enum GetNamespacesError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `post_namespace` +/// struct for typed errors of method [`post_namespace`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PostNamespaceError { @@ -72,10 +72,11 @@ pub enum PostNamespaceError { pub async fn create_namespace(configuration: &configuration::Configuration, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result<(), Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/namespace", configuration.base_path); + let local_var_uri_str = format!("{}/namespace", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -87,13 +88,13 @@ pub async fn create_namespace(configuration: &configuration::Configuration, regi if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -118,10 +119,11 @@ pub async fn create_namespace(configuration: &configuration::Configuration, regi } pub async fn delete_namespace(configuration: &configuration::Configuration, namespace_name: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result<(), Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/namespace/{namespaceName}", configuration.base_path, namespaceName=crate::apis::urlencode(namespace_name)); + let local_var_uri_str = format!("{}/namespace/{namespaceName}", local_var_configuration.base_path, namespaceName=crate::apis::urlencode(namespace_name)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::DELETE, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -133,13 +135,13 @@ pub async fn delete_namespace(configuration: &configuration::Configuration, name if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -164,10 +166,11 @@ pub async fn delete_namespace(configuration: &configuration::Configuration, name } pub async fn get_namespace(configuration: &configuration::Configuration, namespace_name: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/namespace/{namespaceName}", configuration.base_path, namespaceName=crate::apis::urlencode(namespace_name)); + let local_var_uri_str = format!("{}/namespace/{namespaceName}", local_var_configuration.base_path, namespaceName=crate::apis::urlencode(namespace_name)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -191,7 +194,7 @@ pub async fn get_namespace(configuration: &configuration::Configuration, namespa if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -200,7 +203,7 @@ pub async fn get_namespace(configuration: &configuration::Configuration, namespa if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -225,10 +228,11 @@ pub async fn get_namespace(configuration: &configuration::Configuration, namespa } pub async fn get_namespaces(configuration: &configuration::Configuration, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result, Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/namespaces", configuration.base_path); + let local_var_uri_str = format!("{}/namespaces", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -252,7 +256,7 @@ pub async fn get_namespaces(configuration: &configuration::Configuration, region if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -261,7 +265,7 @@ pub async fn get_namespaces(configuration: &configuration::Configuration, region if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -285,11 +289,12 @@ pub async fn get_namespaces(configuration: &configuration::Configuration, region } } -pub async fn post_namespace(configuration: &configuration::Configuration, namespace_name: &str, namespace2: crate::models::Namespace, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result<(), Error> { +pub async fn post_namespace(configuration: &configuration::Configuration, namespace_name: &str, namespace2: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result<(), Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/namespace/{namespaceName}", configuration.base_path, namespaceName=crate::apis::urlencode(namespace_name)); + let local_var_uri_str = format!("{}/namespace/{namespaceName}", local_var_configuration.base_path, namespaceName=crate::apis::urlencode(namespace_name)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -301,13 +306,13 @@ pub async fn post_namespace(configuration: &configuration::Configuration, namesp if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), diff --git a/clients/rust/reqwest/v1/src/apis/nodes_api.rs b/clients/rust/reqwest/v1/src/apis/nodes_api.rs index a353242a..b7672ae8 100644 --- a/clients/rust/reqwest/v1/src/apis/nodes_api.rs +++ b/clients/rust/reqwest/v1/src/apis/nodes_api.rs @@ -15,7 +15,7 @@ use crate::apis::ResponseContent; use super::{Error, configuration}; -/// struct for typed errors of method `get_node` +/// struct for typed errors of method [`get_node`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetNodeError { @@ -26,7 +26,7 @@ pub enum GetNodeError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_node_allocations` +/// struct for typed errors of method [`get_node_allocations`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetNodeAllocationsError { @@ -37,7 +37,7 @@ pub enum GetNodeAllocationsError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_nodes` +/// struct for typed errors of method [`get_nodes`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetNodesError { @@ -48,7 +48,7 @@ pub enum GetNodesError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `update_node_drain` +/// struct for typed errors of method [`update_node_drain`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum UpdateNodeDrainError { @@ -59,7 +59,7 @@ pub enum UpdateNodeDrainError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `update_node_eligibility` +/// struct for typed errors of method [`update_node_eligibility`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum UpdateNodeEligibilityError { @@ -70,7 +70,7 @@ pub enum UpdateNodeEligibilityError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `update_node_purge` +/// struct for typed errors of method [`update_node_purge`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum UpdateNodePurgeError { @@ -83,10 +83,11 @@ pub enum UpdateNodePurgeError { pub async fn get_node(configuration: &configuration::Configuration, node_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/node/{nodeId}", configuration.base_path, nodeId=crate::apis::urlencode(node_id)); + let local_var_uri_str = format!("{}/node/{nodeId}", local_var_configuration.base_path, nodeId=crate::apis::urlencode(node_id)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -110,7 +111,7 @@ pub async fn get_node(configuration: &configuration::Configuration, node_id: &st if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -119,7 +120,7 @@ pub async fn get_node(configuration: &configuration::Configuration, node_id: &st if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -144,10 +145,11 @@ pub async fn get_node(configuration: &configuration::Configuration, node_id: &st } pub async fn get_node_allocations(configuration: &configuration::Configuration, node_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result, Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/node/{nodeId}/allocations", configuration.base_path, nodeId=crate::apis::urlencode(node_id)); + let local_var_uri_str = format!("{}/node/{nodeId}/allocations", local_var_configuration.base_path, nodeId=crate::apis::urlencode(node_id)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -171,7 +173,7 @@ pub async fn get_node_allocations(configuration: &configuration::Configuration, if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -180,7 +182,7 @@ pub async fn get_node_allocations(configuration: &configuration::Configuration, if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -205,10 +207,11 @@ pub async fn get_node_allocations(configuration: &configuration::Configuration, } pub async fn get_nodes(configuration: &configuration::Configuration, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, resources: Option) -> Result, Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/nodes", configuration.base_path); + let local_var_uri_str = format!("{}/nodes", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -235,7 +238,7 @@ pub async fn get_nodes(configuration: &configuration::Configuration, region: Opt if let Some(ref local_var_str) = resources { local_var_req_builder = local_var_req_builder.query(&[("resources", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -244,7 +247,7 @@ pub async fn get_nodes(configuration: &configuration::Configuration, region: Opt if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -268,11 +271,12 @@ pub async fn get_nodes(configuration: &configuration::Configuration, region: Opt } } -pub async fn update_node_drain(configuration: &configuration::Configuration, node_id: &str, node_update_drain_request: crate::models::NodeUpdateDrainRequest, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result> { +pub async fn update_node_drain(configuration: &configuration::Configuration, node_id: &str, node_update_drain_request: Option, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/node/{nodeId}/drain", configuration.base_path, nodeId=crate::apis::urlencode(node_id)); + let local_var_uri_str = format!("{}/node/{nodeId}/drain", local_var_configuration.base_path, nodeId=crate::apis::urlencode(node_id)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -296,7 +300,7 @@ pub async fn update_node_drain(configuration: &configuration::Configuration, nod if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -305,7 +309,7 @@ pub async fn update_node_drain(configuration: &configuration::Configuration, nod if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -330,11 +334,12 @@ pub async fn update_node_drain(configuration: &configuration::Configuration, nod } } -pub async fn update_node_eligibility(configuration: &configuration::Configuration, node_id: &str, node_update_eligibility_request: crate::models::NodeUpdateEligibilityRequest, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result> { +pub async fn update_node_eligibility(configuration: &configuration::Configuration, node_id: &str, node_update_eligibility_request: Option, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/node/{nodeId}/eligibility", configuration.base_path, nodeId=crate::apis::urlencode(node_id)); + let local_var_uri_str = format!("{}/node/{nodeId}/eligibility", local_var_configuration.base_path, nodeId=crate::apis::urlencode(node_id)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -358,7 +363,7 @@ pub async fn update_node_eligibility(configuration: &configuration::Configuratio if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -367,7 +372,7 @@ pub async fn update_node_eligibility(configuration: &configuration::Configuratio if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -393,10 +398,11 @@ pub async fn update_node_eligibility(configuration: &configuration::Configuratio } pub async fn update_node_purge(configuration: &configuration::Configuration, node_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/node/{nodeId}/purge", configuration.base_path, nodeId=crate::apis::urlencode(node_id)); + let local_var_uri_str = format!("{}/node/{nodeId}/purge", local_var_configuration.base_path, nodeId=crate::apis::urlencode(node_id)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -420,7 +426,7 @@ pub async fn update_node_purge(configuration: &configuration::Configuration, nod if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -429,7 +435,7 @@ pub async fn update_node_purge(configuration: &configuration::Configuration, nod if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), diff --git a/clients/rust/reqwest/v1/src/apis/operator_api.rs b/clients/rust/reqwest/v1/src/apis/operator_api.rs index c7cdbdb3..413cc199 100644 --- a/clients/rust/reqwest/v1/src/apis/operator_api.rs +++ b/clients/rust/reqwest/v1/src/apis/operator_api.rs @@ -15,7 +15,7 @@ use crate::apis::ResponseContent; use super::{Error, configuration}; -/// struct for typed errors of method `delete_operator_raft_peer` +/// struct for typed errors of method [`delete_operator_raft_peer`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum DeleteOperatorRaftPeerError { @@ -26,7 +26,7 @@ pub enum DeleteOperatorRaftPeerError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_operator_autopilot_configuration` +/// struct for typed errors of method [`get_operator_autopilot_configuration`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetOperatorAutopilotConfigurationError { @@ -37,7 +37,7 @@ pub enum GetOperatorAutopilotConfigurationError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_operator_autopilot_health` +/// struct for typed errors of method [`get_operator_autopilot_health`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetOperatorAutopilotHealthError { @@ -48,7 +48,7 @@ pub enum GetOperatorAutopilotHealthError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_operator_raft_configuration` +/// struct for typed errors of method [`get_operator_raft_configuration`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetOperatorRaftConfigurationError { @@ -59,7 +59,7 @@ pub enum GetOperatorRaftConfigurationError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_operator_scheduler_configuration` +/// struct for typed errors of method [`get_operator_scheduler_configuration`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetOperatorSchedulerConfigurationError { @@ -70,7 +70,7 @@ pub enum GetOperatorSchedulerConfigurationError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `post_operator_scheduler_configuration` +/// struct for typed errors of method [`post_operator_scheduler_configuration`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PostOperatorSchedulerConfigurationError { @@ -81,7 +81,7 @@ pub enum PostOperatorSchedulerConfigurationError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `put_operator_autopilot_configuration` +/// struct for typed errors of method [`put_operator_autopilot_configuration`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PutOperatorAutopilotConfigurationError { @@ -94,10 +94,11 @@ pub enum PutOperatorAutopilotConfigurationError { pub async fn delete_operator_raft_peer(configuration: &configuration::Configuration, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result<(), Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/operator/raft/peer", configuration.base_path); + let local_var_uri_str = format!("{}/operator/raft/peer", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::DELETE, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -109,13 +110,13 @@ pub async fn delete_operator_raft_peer(configuration: &configuration::Configurat if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -140,10 +141,11 @@ pub async fn delete_operator_raft_peer(configuration: &configuration::Configurat } pub async fn get_operator_autopilot_configuration(configuration: &configuration::Configuration, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/operator/autopilot/configuration", configuration.base_path); + let local_var_uri_str = format!("{}/operator/autopilot/configuration", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -167,7 +169,7 @@ pub async fn get_operator_autopilot_configuration(configuration: &configuration: if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -176,7 +178,7 @@ pub async fn get_operator_autopilot_configuration(configuration: &configuration: if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -201,10 +203,11 @@ pub async fn get_operator_autopilot_configuration(configuration: &configuration: } pub async fn get_operator_autopilot_health(configuration: &configuration::Configuration, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/operator/autopilot/health", configuration.base_path); + let local_var_uri_str = format!("{}/operator/autopilot/health", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -228,7 +231,7 @@ pub async fn get_operator_autopilot_health(configuration: &configuration::Config if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -237,7 +240,7 @@ pub async fn get_operator_autopilot_health(configuration: &configuration::Config if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -262,10 +265,11 @@ pub async fn get_operator_autopilot_health(configuration: &configuration::Config } pub async fn get_operator_raft_configuration(configuration: &configuration::Configuration, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/operator/raft/configuration", configuration.base_path); + let local_var_uri_str = format!("{}/operator/raft/configuration", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -289,7 +293,7 @@ pub async fn get_operator_raft_configuration(configuration: &configuration::Conf if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -298,7 +302,7 @@ pub async fn get_operator_raft_configuration(configuration: &configuration::Conf if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -323,10 +327,11 @@ pub async fn get_operator_raft_configuration(configuration: &configuration::Conf } pub async fn get_operator_scheduler_configuration(configuration: &configuration::Configuration, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/operator/scheduler/configuration", configuration.base_path); + let local_var_uri_str = format!("{}/operator/scheduler/configuration", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -350,7 +355,7 @@ pub async fn get_operator_scheduler_configuration(configuration: &configuration: if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -359,7 +364,7 @@ pub async fn get_operator_scheduler_configuration(configuration: &configuration: if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -383,11 +388,12 @@ pub async fn get_operator_scheduler_configuration(configuration: &configuration: } } -pub async fn post_operator_scheduler_configuration(configuration: &configuration::Configuration, scheduler_configuration: crate::models::SchedulerConfiguration, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { +pub async fn post_operator_scheduler_configuration(configuration: &configuration::Configuration, scheduler_configuration: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/operator/scheduler/configuration", configuration.base_path); + let local_var_uri_str = format!("{}/operator/scheduler/configuration", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -399,13 +405,13 @@ pub async fn post_operator_scheduler_configuration(configuration: &configuration if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -430,11 +436,12 @@ pub async fn post_operator_scheduler_configuration(configuration: &configuration } } -pub async fn put_operator_autopilot_configuration(configuration: &configuration::Configuration, autopilot_configuration: crate::models::AutopilotConfiguration, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { +pub async fn put_operator_autopilot_configuration(configuration: &configuration::Configuration, autopilot_configuration: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/operator/autopilot/configuration", configuration.base_path); + let local_var_uri_str = format!("{}/operator/autopilot/configuration", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::PUT, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -446,13 +453,13 @@ pub async fn put_operator_autopilot_configuration(configuration: &configuration: if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), diff --git a/clients/rust/reqwest/v1/src/apis/plugins_api.rs b/clients/rust/reqwest/v1/src/apis/plugins_api.rs index b912536d..36cae929 100644 --- a/clients/rust/reqwest/v1/src/apis/plugins_api.rs +++ b/clients/rust/reqwest/v1/src/apis/plugins_api.rs @@ -15,7 +15,7 @@ use crate::apis::ResponseContent; use super::{Error, configuration}; -/// struct for typed errors of method `get_plugin_csi` +/// struct for typed errors of method [`get_plugin_csi`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetPluginCsiError { @@ -26,7 +26,7 @@ pub enum GetPluginCsiError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_plugins` +/// struct for typed errors of method [`get_plugins`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetPluginsError { @@ -39,10 +39,11 @@ pub enum GetPluginsError { pub async fn get_plugin_csi(configuration: &configuration::Configuration, plugin_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result, Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/plugin/csi/{pluginID}", configuration.base_path, pluginID=crate::apis::urlencode(plugin_id)); + let local_var_uri_str = format!("{}/plugin/csi/{pluginID}", local_var_configuration.base_path, pluginID=crate::apis::urlencode(plugin_id)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -66,7 +67,7 @@ pub async fn get_plugin_csi(configuration: &configuration::Configuration, plugin if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -75,7 +76,7 @@ pub async fn get_plugin_csi(configuration: &configuration::Configuration, plugin if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -100,10 +101,11 @@ pub async fn get_plugin_csi(configuration: &configuration::Configuration, plugin } pub async fn get_plugins(configuration: &configuration::Configuration, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result, Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/plugins", configuration.base_path); + let local_var_uri_str = format!("{}/plugins", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -127,7 +129,7 @@ pub async fn get_plugins(configuration: &configuration::Configuration, region: O if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -136,7 +138,7 @@ pub async fn get_plugins(configuration: &configuration::Configuration, region: O if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), diff --git a/clients/rust/reqwest/v1/src/apis/regions_api.rs b/clients/rust/reqwest/v1/src/apis/regions_api.rs index 4e4a9cd8..2e604061 100644 --- a/clients/rust/reqwest/v1/src/apis/regions_api.rs +++ b/clients/rust/reqwest/v1/src/apis/regions_api.rs @@ -15,7 +15,7 @@ use crate::apis::ResponseContent; use super::{Error, configuration}; -/// struct for typed errors of method `get_regions` +/// struct for typed errors of method [`get_regions`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetRegionsError { @@ -28,16 +28,17 @@ pub enum GetRegionsError { pub async fn get_regions(configuration: &configuration::Configuration, ) -> Result, Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/regions", configuration.base_path); + let local_var_uri_str = format!("{}/regions", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), diff --git a/clients/rust/reqwest/v1/src/apis/scaling_api.rs b/clients/rust/reqwest/v1/src/apis/scaling_api.rs index aee7e24a..3719d78f 100644 --- a/clients/rust/reqwest/v1/src/apis/scaling_api.rs +++ b/clients/rust/reqwest/v1/src/apis/scaling_api.rs @@ -15,7 +15,7 @@ use crate::apis::ResponseContent; use super::{Error, configuration}; -/// struct for typed errors of method `get_scaling_policies` +/// struct for typed errors of method [`get_scaling_policies`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetScalingPoliciesError { @@ -26,7 +26,7 @@ pub enum GetScalingPoliciesError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_scaling_policy` +/// struct for typed errors of method [`get_scaling_policy`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetScalingPolicyError { @@ -39,10 +39,11 @@ pub enum GetScalingPolicyError { pub async fn get_scaling_policies(configuration: &configuration::Configuration, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result, Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/scaling/policies", configuration.base_path); + let local_var_uri_str = format!("{}/scaling/policies", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -66,7 +67,7 @@ pub async fn get_scaling_policies(configuration: &configuration::Configuration, if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -75,7 +76,7 @@ pub async fn get_scaling_policies(configuration: &configuration::Configuration, if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -100,10 +101,11 @@ pub async fn get_scaling_policies(configuration: &configuration::Configuration, } pub async fn get_scaling_policy(configuration: &configuration::Configuration, policy_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/scaling/policy/{policyID}", configuration.base_path, policyID=crate::apis::urlencode(policy_id)); + let local_var_uri_str = format!("{}/scaling/policy/{policyID}", local_var_configuration.base_path, policyID=crate::apis::urlencode(policy_id)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -127,7 +129,7 @@ pub async fn get_scaling_policy(configuration: &configuration::Configuration, po if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -136,7 +138,7 @@ pub async fn get_scaling_policy(configuration: &configuration::Configuration, po if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), diff --git a/clients/rust/reqwest/v1/src/apis/search_api.rs b/clients/rust/reqwest/v1/src/apis/search_api.rs index b3bc9b6e..273d19cf 100644 --- a/clients/rust/reqwest/v1/src/apis/search_api.rs +++ b/clients/rust/reqwest/v1/src/apis/search_api.rs @@ -15,7 +15,7 @@ use crate::apis::ResponseContent; use super::{Error, configuration}; -/// struct for typed errors of method `get_fuzzy_search` +/// struct for typed errors of method [`get_fuzzy_search`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetFuzzySearchError { @@ -26,7 +26,7 @@ pub enum GetFuzzySearchError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_search` +/// struct for typed errors of method [`get_search`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetSearchError { @@ -38,11 +38,12 @@ pub enum GetSearchError { } -pub async fn get_fuzzy_search(configuration: &configuration::Configuration, fuzzy_search_request: crate::models::FuzzySearchRequest, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result> { +pub async fn get_fuzzy_search(configuration: &configuration::Configuration, fuzzy_search_request: Option, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/search/fuzzy", configuration.base_path); + let local_var_uri_str = format!("{}/search/fuzzy", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -66,7 +67,7 @@ pub async fn get_fuzzy_search(configuration: &configuration::Configuration, fuzz if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -75,7 +76,7 @@ pub async fn get_fuzzy_search(configuration: &configuration::Configuration, fuzz if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -100,11 +101,12 @@ pub async fn get_fuzzy_search(configuration: &configuration::Configuration, fuzz } } -pub async fn get_search(configuration: &configuration::Configuration, search_request: crate::models::SearchRequest, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result> { +pub async fn get_search(configuration: &configuration::Configuration, search_request: Option, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/search", configuration.base_path); + let local_var_uri_str = format!("{}/search", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -128,7 +130,7 @@ pub async fn get_search(configuration: &configuration::Configuration, search_req if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -137,7 +139,7 @@ pub async fn get_search(configuration: &configuration::Configuration, search_req if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), diff --git a/clients/rust/reqwest/v1/src/apis/status_api.rs b/clients/rust/reqwest/v1/src/apis/status_api.rs index 775c9e9d..0af352ac 100644 --- a/clients/rust/reqwest/v1/src/apis/status_api.rs +++ b/clients/rust/reqwest/v1/src/apis/status_api.rs @@ -15,7 +15,7 @@ use crate::apis::ResponseContent; use super::{Error, configuration}; -/// struct for typed errors of method `get_status_leader` +/// struct for typed errors of method [`get_status_leader`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetStatusLeaderError { @@ -26,7 +26,7 @@ pub enum GetStatusLeaderError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_status_peers` +/// struct for typed errors of method [`get_status_peers`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetStatusPeersError { @@ -39,10 +39,11 @@ pub enum GetStatusPeersError { pub async fn get_status_leader(configuration: &configuration::Configuration, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/status/leader", configuration.base_path); + let local_var_uri_str = format!("{}/status/leader", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -66,7 +67,7 @@ pub async fn get_status_leader(configuration: &configuration::Configuration, reg if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -75,7 +76,7 @@ pub async fn get_status_leader(configuration: &configuration::Configuration, reg if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -100,10 +101,11 @@ pub async fn get_status_leader(configuration: &configuration::Configuration, reg } pub async fn get_status_peers(configuration: &configuration::Configuration, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result, Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/status/peers", configuration.base_path); + let local_var_uri_str = format!("{}/status/peers", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -127,7 +129,7 @@ pub async fn get_status_peers(configuration: &configuration::Configuration, regi if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -136,7 +138,7 @@ pub async fn get_status_peers(configuration: &configuration::Configuration, regi if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), diff --git a/clients/rust/reqwest/v1/src/apis/system_api.rs b/clients/rust/reqwest/v1/src/apis/system_api.rs index ece86d7b..da01437d 100644 --- a/clients/rust/reqwest/v1/src/apis/system_api.rs +++ b/clients/rust/reqwest/v1/src/apis/system_api.rs @@ -15,7 +15,7 @@ use crate::apis::ResponseContent; use super::{Error, configuration}; -/// struct for typed errors of method `put_system_gc` +/// struct for typed errors of method [`put_system_gc`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PutSystemGcError { @@ -26,7 +26,7 @@ pub enum PutSystemGcError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `put_system_reconcile_summaries` +/// struct for typed errors of method [`put_system_reconcile_summaries`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PutSystemReconcileSummariesError { @@ -39,10 +39,11 @@ pub enum PutSystemReconcileSummariesError { pub async fn put_system_gc(configuration: &configuration::Configuration, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result<(), Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/system/gc", configuration.base_path); + let local_var_uri_str = format!("{}/system/gc", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::PUT, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -54,13 +55,13 @@ pub async fn put_system_gc(configuration: &configuration::Configuration, region: if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -85,10 +86,11 @@ pub async fn put_system_gc(configuration: &configuration::Configuration, region: } pub async fn put_system_reconcile_summaries(configuration: &configuration::Configuration, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result<(), Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/system/reconcile/summaries", configuration.base_path); + let local_var_uri_str = format!("{}/system/reconcile/summaries", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::PUT, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -100,13 +102,13 @@ pub async fn put_system_reconcile_summaries(configuration: &configuration::Confi if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), diff --git a/clients/rust/reqwest/v1/src/apis/volumes_api.rs b/clients/rust/reqwest/v1/src/apis/volumes_api.rs index 69ed0194..71d4a271 100644 --- a/clients/rust/reqwest/v1/src/apis/volumes_api.rs +++ b/clients/rust/reqwest/v1/src/apis/volumes_api.rs @@ -15,7 +15,7 @@ use crate::apis::ResponseContent; use super::{Error, configuration}; -/// struct for typed errors of method `create_volume` +/// struct for typed errors of method [`create_volume`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum CreateVolumeError { @@ -26,7 +26,7 @@ pub enum CreateVolumeError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `delete_snapshot` +/// struct for typed errors of method [`delete_snapshot`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum DeleteSnapshotError { @@ -37,7 +37,7 @@ pub enum DeleteSnapshotError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `delete_volume_registration` +/// struct for typed errors of method [`delete_volume_registration`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum DeleteVolumeRegistrationError { @@ -48,7 +48,7 @@ pub enum DeleteVolumeRegistrationError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `detach_or_delete_volume` +/// struct for typed errors of method [`detach_or_delete_volume`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum DetachOrDeleteVolumeError { @@ -59,7 +59,7 @@ pub enum DetachOrDeleteVolumeError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_external_volumes` +/// struct for typed errors of method [`get_external_volumes`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetExternalVolumesError { @@ -70,7 +70,7 @@ pub enum GetExternalVolumesError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_snapshots` +/// struct for typed errors of method [`get_snapshots`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetSnapshotsError { @@ -81,7 +81,7 @@ pub enum GetSnapshotsError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_volume` +/// struct for typed errors of method [`get_volume`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetVolumeError { @@ -92,7 +92,7 @@ pub enum GetVolumeError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `get_volumes` +/// struct for typed errors of method [`get_volumes`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum GetVolumesError { @@ -103,7 +103,7 @@ pub enum GetVolumesError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `post_snapshot` +/// struct for typed errors of method [`post_snapshot`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PostSnapshotError { @@ -114,7 +114,7 @@ pub enum PostSnapshotError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `post_volume` +/// struct for typed errors of method [`post_volume`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PostVolumeError { @@ -125,7 +125,7 @@ pub enum PostVolumeError { UnknownValue(serde_json::Value), } -/// struct for typed errors of method `post_volume_registration` +/// struct for typed errors of method [`post_volume_registration`] #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(untagged)] pub enum PostVolumeRegistrationError { @@ -137,11 +137,12 @@ pub enum PostVolumeRegistrationError { } -pub async fn create_volume(configuration: &configuration::Configuration, volume_id: &str, action: &str, csi_volume_create_request: crate::models::CsiVolumeCreateRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result<(), Error> { +pub async fn create_volume(configuration: &configuration::Configuration, volume_id: &str, action: &str, csi_volume_create_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result<(), Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/volume/csi/{volumeId}/{action}", configuration.base_path, volumeId=crate::apis::urlencode(volume_id), action=crate::apis::urlencode(action)); + let local_var_uri_str = format!("{}/volume/csi/{volumeId}/{action}", local_var_configuration.base_path, volumeId=crate::apis::urlencode(volume_id), action=crate::apis::urlencode(action)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -153,13 +154,13 @@ pub async fn create_volume(configuration: &configuration::Configuration, volume_ if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -185,10 +186,11 @@ pub async fn create_volume(configuration: &configuration::Configuration, volume_ } pub async fn delete_snapshot(configuration: &configuration::Configuration, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>, plugin_id: Option<&str>, snapshot_id: Option<&str>) -> Result<(), Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/volumes/snapshot", configuration.base_path); + let local_var_uri_str = format!("{}/volumes/snapshot", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::DELETE, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -206,13 +208,13 @@ pub async fn delete_snapshot(configuration: &configuration::Configuration, regio if let Some(ref local_var_str) = snapshot_id { local_var_req_builder = local_var_req_builder.query(&[("snapshot_id", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -237,10 +239,11 @@ pub async fn delete_snapshot(configuration: &configuration::Configuration, regio } pub async fn delete_volume_registration(configuration: &configuration::Configuration, volume_id: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>, force: Option<&str>) -> Result<(), Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/volume/csi/{volumeId}", configuration.base_path, volumeId=crate::apis::urlencode(volume_id)); + let local_var_uri_str = format!("{}/volume/csi/{volumeId}", local_var_configuration.base_path, volumeId=crate::apis::urlencode(volume_id)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::DELETE, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -255,13 +258,13 @@ pub async fn delete_volume_registration(configuration: &configuration::Configura if let Some(ref local_var_str) = force { local_var_req_builder = local_var_req_builder.query(&[("force", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -286,10 +289,11 @@ pub async fn delete_volume_registration(configuration: &configuration::Configura } pub async fn detach_or_delete_volume(configuration: &configuration::Configuration, volume_id: &str, action: &str, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>, node: Option<&str>) -> Result<(), Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/volume/csi/{volumeId}/{action}", configuration.base_path, volumeId=crate::apis::urlencode(volume_id), action=crate::apis::urlencode(action)); + let local_var_uri_str = format!("{}/volume/csi/{volumeId}/{action}", local_var_configuration.base_path, volumeId=crate::apis::urlencode(volume_id), action=crate::apis::urlencode(action)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::DELETE, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -304,13 +308,13 @@ pub async fn detach_or_delete_volume(configuration: &configuration::Configuratio if let Some(ref local_var_str) = node { local_var_req_builder = local_var_req_builder.query(&[("node", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -335,10 +339,11 @@ pub async fn detach_or_delete_volume(configuration: &configuration::Configuratio } pub async fn get_external_volumes(configuration: &configuration::Configuration, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, plugin_id: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/volumes/external", configuration.base_path); + let local_var_uri_str = format!("{}/volumes/external", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -365,7 +370,7 @@ pub async fn get_external_volumes(configuration: &configuration::Configuration, if let Some(ref local_var_str) = plugin_id { local_var_req_builder = local_var_req_builder.query(&[("plugin_id", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -374,7 +379,7 @@ pub async fn get_external_volumes(configuration: &configuration::Configuration, if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -399,10 +404,11 @@ pub async fn get_external_volumes(configuration: &configuration::Configuration, } pub async fn get_snapshots(configuration: &configuration::Configuration, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, plugin_id: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/volumes/snapshot", configuration.base_path); + let local_var_uri_str = format!("{}/volumes/snapshot", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -429,7 +435,7 @@ pub async fn get_snapshots(configuration: &configuration::Configuration, region: if let Some(ref local_var_str) = plugin_id { local_var_req_builder = local_var_req_builder.query(&[("plugin_id", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -438,7 +444,7 @@ pub async fn get_snapshots(configuration: &configuration::Configuration, region: if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -463,10 +469,11 @@ pub async fn get_snapshots(configuration: &configuration::Configuration, region: } pub async fn get_volume(configuration: &configuration::Configuration, volume_id: &str, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/volume/csi/{volumeId}", configuration.base_path, volumeId=crate::apis::urlencode(volume_id)); + let local_var_uri_str = format!("{}/volume/csi/{volumeId}", local_var_configuration.base_path, volumeId=crate::apis::urlencode(volume_id)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -490,7 +497,7 @@ pub async fn get_volume(configuration: &configuration::Configuration, volume_id: if let Some(ref local_var_str) = next_token { local_var_req_builder = local_var_req_builder.query(&[("next_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -499,7 +506,7 @@ pub async fn get_volume(configuration: &configuration::Configuration, volume_id: if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -524,10 +531,11 @@ pub async fn get_volume(configuration: &configuration::Configuration, volume_id: } pub async fn get_volumes(configuration: &configuration::Configuration, region: Option<&str>, namespace: Option<&str>, index: Option, wait: Option<&str>, stale: Option<&str>, prefix: Option<&str>, x_nomad_token: Option<&str>, per_page: Option, next_token: Option<&str>, node_id: Option<&str>, plugin_id: Option<&str>, _type: Option<&str>) -> Result, Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/volumes", configuration.base_path); + let local_var_uri_str = format!("{}/volumes", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::GET, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -560,7 +568,7 @@ pub async fn get_volumes(configuration: &configuration::Configuration, region: O if let Some(ref local_var_str) = _type { local_var_req_builder = local_var_req_builder.query(&[("type", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = index { @@ -569,7 +577,7 @@ pub async fn get_volumes(configuration: &configuration::Configuration, region: O if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -593,11 +601,12 @@ pub async fn get_volumes(configuration: &configuration::Configuration, region: O } } -pub async fn post_snapshot(configuration: &configuration::Configuration, csi_snapshot_create_request: crate::models::CsiSnapshotCreateRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { +pub async fn post_snapshot(configuration: &configuration::Configuration, csi_snapshot_create_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/volumes/snapshot", configuration.base_path); + let local_var_uri_str = format!("{}/volumes/snapshot", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -609,13 +618,13 @@ pub async fn post_snapshot(configuration: &configuration::Configuration, csi_sna if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -640,11 +649,12 @@ pub async fn post_snapshot(configuration: &configuration::Configuration, csi_sna } } -pub async fn post_volume(configuration: &configuration::Configuration, csi_volume_register_request: crate::models::CsiVolumeRegisterRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result<(), Error> { +pub async fn post_volume(configuration: &configuration::Configuration, csi_volume_register_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result<(), Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/volumes", configuration.base_path); + let local_var_uri_str = format!("{}/volumes", local_var_configuration.base_path); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -656,13 +666,13 @@ pub async fn post_volume(configuration: &configuration::Configuration, csi_volum if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), @@ -687,11 +697,12 @@ pub async fn post_volume(configuration: &configuration::Configuration, csi_volum } } -pub async fn post_volume_registration(configuration: &configuration::Configuration, volume_id: &str, csi_volume_register_request: crate::models::CsiVolumeRegisterRequest, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result<(), Error> { +pub async fn post_volume_registration(configuration: &configuration::Configuration, volume_id: &str, csi_volume_register_request: Option, region: Option<&str>, namespace: Option<&str>, x_nomad_token: Option<&str>, idempotency_token: Option<&str>) -> Result<(), Error> { + let local_var_configuration = configuration; - let local_var_client = &configuration.client; + let local_var_client = &local_var_configuration.client; - let local_var_uri_str = format!("{}/volume/csi/{volumeId}", configuration.base_path, volumeId=crate::apis::urlencode(volume_id)); + let local_var_uri_str = format!("{}/volume/csi/{volumeId}", local_var_configuration.base_path, volumeId=crate::apis::urlencode(volume_id)); let mut local_var_req_builder = local_var_client.request(reqwest::Method::POST, local_var_uri_str.as_str()); if let Some(ref local_var_str) = region { @@ -703,13 +714,13 @@ pub async fn post_volume_registration(configuration: &configuration::Configurati if let Some(ref local_var_str) = idempotency_token { local_var_req_builder = local_var_req_builder.query(&[("idempotency_token", &local_var_str.to_string())]); } - if let Some(ref local_var_user_agent) = configuration.user_agent { + if let Some(ref local_var_user_agent) = local_var_configuration.user_agent { local_var_req_builder = local_var_req_builder.header(reqwest::header::USER_AGENT, local_var_user_agent.clone()); } if let Some(local_var_param_value) = x_nomad_token { local_var_req_builder = local_var_req_builder.header("X-Nomad-Token", local_var_param_value.to_string()); } - if let Some(ref local_var_apikey) = configuration.api_key { + if let Some(ref local_var_apikey) = local_var_configuration.api_key { let local_var_key = local_var_apikey.key.clone(); let local_var_value = match local_var_apikey.prefix { Some(ref local_var_prefix) => format!("{} {}", local_var_prefix, local_var_key), diff --git a/clients/rust/reqwest/v1/src/models/acl_policy.rs b/clients/rust/reqwest/v1/src/models/acl_policy.rs index b1edcdce..ce66dd76 100644 --- a/clients/rust/reqwest/v1/src/models/acl_policy.rs +++ b/clients/rust/reqwest/v1/src/models/acl_policy.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AclPolicy { #[serde(rename = "CreateIndex", skip_serializing_if = "Option::is_none")] pub create_index: Option, diff --git a/clients/rust/reqwest/v1/src/models/acl_policy_list_stub.rs b/clients/rust/reqwest/v1/src/models/acl_policy_list_stub.rs index 60c0f2ae..f8d48327 100644 --- a/clients/rust/reqwest/v1/src/models/acl_policy_list_stub.rs +++ b/clients/rust/reqwest/v1/src/models/acl_policy_list_stub.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AclPolicyListStub { #[serde(rename = "CreateIndex", skip_serializing_if = "Option::is_none")] pub create_index: Option, diff --git a/clients/rust/reqwest/v1/src/models/acl_token.rs b/clients/rust/reqwest/v1/src/models/acl_token.rs index 28a3f488..ada8823c 100644 --- a/clients/rust/reqwest/v1/src/models/acl_token.rs +++ b/clients/rust/reqwest/v1/src/models/acl_token.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AclToken { #[serde(rename = "AccessorID", skip_serializing_if = "Option::is_none")] pub accessor_id: Option, diff --git a/clients/rust/reqwest/v1/src/models/acl_token_list_stub.rs b/clients/rust/reqwest/v1/src/models/acl_token_list_stub.rs index dd25ec2a..79bb61f5 100644 --- a/clients/rust/reqwest/v1/src/models/acl_token_list_stub.rs +++ b/clients/rust/reqwest/v1/src/models/acl_token_list_stub.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AclTokenListStub { #[serde(rename = "AccessorID", skip_serializing_if = "Option::is_none")] pub accessor_id: Option, diff --git a/clients/rust/reqwest/v1/src/models/affinity.rs b/clients/rust/reqwest/v1/src/models/affinity.rs index 7c461060..aa2d7661 100644 --- a/clients/rust/reqwest/v1/src/models/affinity.rs +++ b/clients/rust/reqwest/v1/src/models/affinity.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Affinity { #[serde(rename = "LTarget", skip_serializing_if = "Option::is_none")] pub l_target: Option, diff --git a/clients/rust/reqwest/v1/src/models/alloc_deployment_status.rs b/clients/rust/reqwest/v1/src/models/alloc_deployment_status.rs index 4db2f6b4..e1874884 100644 --- a/clients/rust/reqwest/v1/src/models/alloc_deployment_status.rs +++ b/clients/rust/reqwest/v1/src/models/alloc_deployment_status.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AllocDeploymentStatus { #[serde(rename = "Canary", skip_serializing_if = "Option::is_none")] pub canary: Option, diff --git a/clients/rust/reqwest/v1/src/models/alloc_stop_response.rs b/clients/rust/reqwest/v1/src/models/alloc_stop_response.rs index 6bd1b9d0..5a28972b 100644 --- a/clients/rust/reqwest/v1/src/models/alloc_stop_response.rs +++ b/clients/rust/reqwest/v1/src/models/alloc_stop_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AllocStopResponse { #[serde(rename = "EvalID", skip_serializing_if = "Option::is_none")] pub eval_id: Option, diff --git a/clients/rust/reqwest/v1/src/models/allocated_cpu_resources.rs b/clients/rust/reqwest/v1/src/models/allocated_cpu_resources.rs index 9bf06cf1..167729ec 100644 --- a/clients/rust/reqwest/v1/src/models/allocated_cpu_resources.rs +++ b/clients/rust/reqwest/v1/src/models/allocated_cpu_resources.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AllocatedCpuResources { #[serde(rename = "CpuShares", skip_serializing_if = "Option::is_none")] pub cpu_shares: Option, diff --git a/clients/rust/reqwest/v1/src/models/allocated_device_resource.rs b/clients/rust/reqwest/v1/src/models/allocated_device_resource.rs index dd91af8a..bdcfb8b6 100644 --- a/clients/rust/reqwest/v1/src/models/allocated_device_resource.rs +++ b/clients/rust/reqwest/v1/src/models/allocated_device_resource.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AllocatedDeviceResource { #[serde(rename = "DeviceIDs", skip_serializing_if = "Option::is_none")] pub device_ids: Option>, diff --git a/clients/rust/reqwest/v1/src/models/allocated_memory_resources.rs b/clients/rust/reqwest/v1/src/models/allocated_memory_resources.rs index eb82f5b0..43763d9e 100644 --- a/clients/rust/reqwest/v1/src/models/allocated_memory_resources.rs +++ b/clients/rust/reqwest/v1/src/models/allocated_memory_resources.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AllocatedMemoryResources { #[serde(rename = "MemoryMB", skip_serializing_if = "Option::is_none")] pub memory_mb: Option, diff --git a/clients/rust/reqwest/v1/src/models/allocated_resources.rs b/clients/rust/reqwest/v1/src/models/allocated_resources.rs index d67f31ab..af4e57dd 100644 --- a/clients/rust/reqwest/v1/src/models/allocated_resources.rs +++ b/clients/rust/reqwest/v1/src/models/allocated_resources.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AllocatedResources { #[serde(rename = "Shared", skip_serializing_if = "Option::is_none")] pub shared: Option>, diff --git a/clients/rust/reqwest/v1/src/models/allocated_shared_resources.rs b/clients/rust/reqwest/v1/src/models/allocated_shared_resources.rs index 7b11065f..67de7da2 100644 --- a/clients/rust/reqwest/v1/src/models/allocated_shared_resources.rs +++ b/clients/rust/reqwest/v1/src/models/allocated_shared_resources.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AllocatedSharedResources { #[serde(rename = "DiskMB", skip_serializing_if = "Option::is_none")] pub disk_mb: Option, diff --git a/clients/rust/reqwest/v1/src/models/allocated_task_resources.rs b/clients/rust/reqwest/v1/src/models/allocated_task_resources.rs index 0757bfdd..4e08c81a 100644 --- a/clients/rust/reqwest/v1/src/models/allocated_task_resources.rs +++ b/clients/rust/reqwest/v1/src/models/allocated_task_resources.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AllocatedTaskResources { #[serde(rename = "Cpu", skip_serializing_if = "Option::is_none")] pub cpu: Option>, diff --git a/clients/rust/reqwest/v1/src/models/allocation.rs b/clients/rust/reqwest/v1/src/models/allocation.rs index 22157a77..0dadd7a6 100644 --- a/clients/rust/reqwest/v1/src/models/allocation.rs +++ b/clients/rust/reqwest/v1/src/models/allocation.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Allocation { #[serde(rename = "AllocModifyIndex", skip_serializing_if = "Option::is_none")] pub alloc_modify_index: Option, diff --git a/clients/rust/reqwest/v1/src/models/allocation_list_stub.rs b/clients/rust/reqwest/v1/src/models/allocation_list_stub.rs index a325595f..0c0365ce 100644 --- a/clients/rust/reqwest/v1/src/models/allocation_list_stub.rs +++ b/clients/rust/reqwest/v1/src/models/allocation_list_stub.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AllocationListStub { #[serde(rename = "AllocatedResources", skip_serializing_if = "Option::is_none")] pub allocated_resources: Option>, diff --git a/clients/rust/reqwest/v1/src/models/allocation_metric.rs b/clients/rust/reqwest/v1/src/models/allocation_metric.rs index b0691234..f03bdf20 100644 --- a/clients/rust/reqwest/v1/src/models/allocation_metric.rs +++ b/clients/rust/reqwest/v1/src/models/allocation_metric.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AllocationMetric { #[serde(rename = "AllocationTime", skip_serializing_if = "Option::is_none")] pub allocation_time: Option, diff --git a/clients/rust/reqwest/v1/src/models/attribute.rs b/clients/rust/reqwest/v1/src/models/attribute.rs index 5bdca899..6a907906 100644 --- a/clients/rust/reqwest/v1/src/models/attribute.rs +++ b/clients/rust/reqwest/v1/src/models/attribute.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Attribute { #[serde(rename = "Bool", skip_serializing_if = "Option::is_none")] pub bool: Option, diff --git a/clients/rust/reqwest/v1/src/models/autopilot_configuration.rs b/clients/rust/reqwest/v1/src/models/autopilot_configuration.rs index 4b1845ee..c722e4bb 100644 --- a/clients/rust/reqwest/v1/src/models/autopilot_configuration.rs +++ b/clients/rust/reqwest/v1/src/models/autopilot_configuration.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct AutopilotConfiguration { #[serde(rename = "CleanupDeadServers", skip_serializing_if = "Option::is_none")] pub cleanup_dead_servers: Option, diff --git a/clients/rust/reqwest/v1/src/models/check_restart.rs b/clients/rust/reqwest/v1/src/models/check_restart.rs index 8d2e24c9..df2a4d0c 100644 --- a/clients/rust/reqwest/v1/src/models/check_restart.rs +++ b/clients/rust/reqwest/v1/src/models/check_restart.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CheckRestart { #[serde(rename = "Grace", skip_serializing_if = "Option::is_none")] pub grace: Option, diff --git a/clients/rust/reqwest/v1/src/models/constraint.rs b/clients/rust/reqwest/v1/src/models/constraint.rs index e589b7ff..f1a9a200 100644 --- a/clients/rust/reqwest/v1/src/models/constraint.rs +++ b/clients/rust/reqwest/v1/src/models/constraint.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Constraint { #[serde(rename = "LTarget", skip_serializing_if = "Option::is_none")] pub l_target: Option, diff --git a/clients/rust/reqwest/v1/src/models/consul.rs b/clients/rust/reqwest/v1/src/models/consul.rs index d4046804..3405eaf5 100644 --- a/clients/rust/reqwest/v1/src/models/consul.rs +++ b/clients/rust/reqwest/v1/src/models/consul.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Consul { #[serde(rename = "Namespace", skip_serializing_if = "Option::is_none")] pub namespace: Option, diff --git a/clients/rust/reqwest/v1/src/models/consul_connect.rs b/clients/rust/reqwest/v1/src/models/consul_connect.rs index 5ab97898..7386665b 100644 --- a/clients/rust/reqwest/v1/src/models/consul_connect.rs +++ b/clients/rust/reqwest/v1/src/models/consul_connect.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulConnect { #[serde(rename = "Gateway", skip_serializing_if = "Option::is_none")] pub gateway: Option>, diff --git a/clients/rust/reqwest/v1/src/models/consul_expose_config.rs b/clients/rust/reqwest/v1/src/models/consul_expose_config.rs index 2bd8d3b7..0028c731 100644 --- a/clients/rust/reqwest/v1/src/models/consul_expose_config.rs +++ b/clients/rust/reqwest/v1/src/models/consul_expose_config.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulExposeConfig { #[serde(rename = "Path", skip_serializing_if = "Option::is_none")] pub path: Option>, diff --git a/clients/rust/reqwest/v1/src/models/consul_expose_path.rs b/clients/rust/reqwest/v1/src/models/consul_expose_path.rs index 77f8ba79..ed3743a0 100644 --- a/clients/rust/reqwest/v1/src/models/consul_expose_path.rs +++ b/clients/rust/reqwest/v1/src/models/consul_expose_path.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulExposePath { #[serde(rename = "ListenerPort", skip_serializing_if = "Option::is_none")] pub listener_port: Option, diff --git a/clients/rust/reqwest/v1/src/models/consul_gateway.rs b/clients/rust/reqwest/v1/src/models/consul_gateway.rs index 7e11dbda..2160cf5e 100644 --- a/clients/rust/reqwest/v1/src/models/consul_gateway.rs +++ b/clients/rust/reqwest/v1/src/models/consul_gateway.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulGateway { #[serde(rename = "Ingress", skip_serializing_if = "Option::is_none")] pub ingress: Option>, diff --git a/clients/rust/reqwest/v1/src/models/consul_gateway_bind_address.rs b/clients/rust/reqwest/v1/src/models/consul_gateway_bind_address.rs index 251958fb..e8f5c5cd 100644 --- a/clients/rust/reqwest/v1/src/models/consul_gateway_bind_address.rs +++ b/clients/rust/reqwest/v1/src/models/consul_gateway_bind_address.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulGatewayBindAddress { #[serde(rename = "Address", skip_serializing_if = "Option::is_none")] pub address: Option, diff --git a/clients/rust/reqwest/v1/src/models/consul_gateway_proxy.rs b/clients/rust/reqwest/v1/src/models/consul_gateway_proxy.rs index d532b976..4393868c 100644 --- a/clients/rust/reqwest/v1/src/models/consul_gateway_proxy.rs +++ b/clients/rust/reqwest/v1/src/models/consul_gateway_proxy.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulGatewayProxy { #[serde(rename = "Config", skip_serializing_if = "Option::is_none")] pub config: Option<::std::collections::HashMap>, diff --git a/clients/rust/reqwest/v1/src/models/consul_gateway_tls_config.rs b/clients/rust/reqwest/v1/src/models/consul_gateway_tls_config.rs index 03f8bddb..08b80130 100644 --- a/clients/rust/reqwest/v1/src/models/consul_gateway_tls_config.rs +++ b/clients/rust/reqwest/v1/src/models/consul_gateway_tls_config.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulGatewayTlsConfig { #[serde(rename = "CipherSuites", skip_serializing_if = "Option::is_none")] pub cipher_suites: Option>, diff --git a/clients/rust/reqwest/v1/src/models/consul_ingress_config_entry.rs b/clients/rust/reqwest/v1/src/models/consul_ingress_config_entry.rs index 1e77961e..211df97d 100644 --- a/clients/rust/reqwest/v1/src/models/consul_ingress_config_entry.rs +++ b/clients/rust/reqwest/v1/src/models/consul_ingress_config_entry.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulIngressConfigEntry { #[serde(rename = "Listeners", skip_serializing_if = "Option::is_none")] pub listeners: Option>, diff --git a/clients/rust/reqwest/v1/src/models/consul_ingress_listener.rs b/clients/rust/reqwest/v1/src/models/consul_ingress_listener.rs index 1115ec15..09f1f0e9 100644 --- a/clients/rust/reqwest/v1/src/models/consul_ingress_listener.rs +++ b/clients/rust/reqwest/v1/src/models/consul_ingress_listener.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulIngressListener { #[serde(rename = "Port", skip_serializing_if = "Option::is_none")] pub port: Option, diff --git a/clients/rust/reqwest/v1/src/models/consul_ingress_service.rs b/clients/rust/reqwest/v1/src/models/consul_ingress_service.rs index 29d04c12..be497f8b 100644 --- a/clients/rust/reqwest/v1/src/models/consul_ingress_service.rs +++ b/clients/rust/reqwest/v1/src/models/consul_ingress_service.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulIngressService { #[serde(rename = "Hosts", skip_serializing_if = "Option::is_none")] pub hosts: Option>, diff --git a/clients/rust/reqwest/v1/src/models/consul_linked_service.rs b/clients/rust/reqwest/v1/src/models/consul_linked_service.rs index 9ae03e92..ee9d6e7f 100644 --- a/clients/rust/reqwest/v1/src/models/consul_linked_service.rs +++ b/clients/rust/reqwest/v1/src/models/consul_linked_service.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulLinkedService { #[serde(rename = "CAFile", skip_serializing_if = "Option::is_none")] pub ca_file: Option, diff --git a/clients/rust/reqwest/v1/src/models/consul_mesh_gateway.rs b/clients/rust/reqwest/v1/src/models/consul_mesh_gateway.rs index bac5dacd..564423f5 100644 --- a/clients/rust/reqwest/v1/src/models/consul_mesh_gateway.rs +++ b/clients/rust/reqwest/v1/src/models/consul_mesh_gateway.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulMeshGateway { #[serde(rename = "Mode", skip_serializing_if = "Option::is_none")] pub mode: Option, diff --git a/clients/rust/reqwest/v1/src/models/consul_proxy.rs b/clients/rust/reqwest/v1/src/models/consul_proxy.rs index 9c5dbf05..8ffec7ad 100644 --- a/clients/rust/reqwest/v1/src/models/consul_proxy.rs +++ b/clients/rust/reqwest/v1/src/models/consul_proxy.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulProxy { #[serde(rename = "Config", skip_serializing_if = "Option::is_none")] pub config: Option<::std::collections::HashMap>, diff --git a/clients/rust/reqwest/v1/src/models/consul_sidecar_service.rs b/clients/rust/reqwest/v1/src/models/consul_sidecar_service.rs index 3253287b..390a5b93 100644 --- a/clients/rust/reqwest/v1/src/models/consul_sidecar_service.rs +++ b/clients/rust/reqwest/v1/src/models/consul_sidecar_service.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulSidecarService { #[serde(rename = "DisableDefaultTCPCheck", skip_serializing_if = "Option::is_none")] pub disable_default_tcp_check: Option, diff --git a/clients/rust/reqwest/v1/src/models/consul_terminating_config_entry.rs b/clients/rust/reqwest/v1/src/models/consul_terminating_config_entry.rs index 053e343a..15fcf040 100644 --- a/clients/rust/reqwest/v1/src/models/consul_terminating_config_entry.rs +++ b/clients/rust/reqwest/v1/src/models/consul_terminating_config_entry.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulTerminatingConfigEntry { #[serde(rename = "Services", skip_serializing_if = "Option::is_none")] pub services: Option>, diff --git a/clients/rust/reqwest/v1/src/models/consul_upstream.rs b/clients/rust/reqwest/v1/src/models/consul_upstream.rs index 0ce4f520..cde3e6bb 100644 --- a/clients/rust/reqwest/v1/src/models/consul_upstream.rs +++ b/clients/rust/reqwest/v1/src/models/consul_upstream.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ConsulUpstream { #[serde(rename = "Datacenter", skip_serializing_if = "Option::is_none")] pub datacenter: Option, diff --git a/clients/rust/reqwest/v1/src/models/csi_controller_info.rs b/clients/rust/reqwest/v1/src/models/csi_controller_info.rs index 1e834ebf..2e5549cd 100644 --- a/clients/rust/reqwest/v1/src/models/csi_controller_info.rs +++ b/clients/rust/reqwest/v1/src/models/csi_controller_info.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiControllerInfo { #[serde(rename = "SupportsAttachDetach", skip_serializing_if = "Option::is_none")] pub supports_attach_detach: Option, diff --git a/clients/rust/reqwest/v1/src/models/csi_info.rs b/clients/rust/reqwest/v1/src/models/csi_info.rs index d0ce4e8e..a8cac8e5 100644 --- a/clients/rust/reqwest/v1/src/models/csi_info.rs +++ b/clients/rust/reqwest/v1/src/models/csi_info.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiInfo { #[serde(rename = "AllocID", skip_serializing_if = "Option::is_none")] pub alloc_id: Option, diff --git a/clients/rust/reqwest/v1/src/models/csi_mount_options.rs b/clients/rust/reqwest/v1/src/models/csi_mount_options.rs index 8e1ab73f..98968f57 100644 --- a/clients/rust/reqwest/v1/src/models/csi_mount_options.rs +++ b/clients/rust/reqwest/v1/src/models/csi_mount_options.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiMountOptions { #[serde(rename = "FSType", skip_serializing_if = "Option::is_none")] pub fs_type: Option, diff --git a/clients/rust/reqwest/v1/src/models/csi_node_info.rs b/clients/rust/reqwest/v1/src/models/csi_node_info.rs index 81546ec6..33ed8813 100644 --- a/clients/rust/reqwest/v1/src/models/csi_node_info.rs +++ b/clients/rust/reqwest/v1/src/models/csi_node_info.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiNodeInfo { #[serde(rename = "AccessibleTopology", skip_serializing_if = "Option::is_none")] pub accessible_topology: Option>, diff --git a/clients/rust/reqwest/v1/src/models/csi_plugin.rs b/clients/rust/reqwest/v1/src/models/csi_plugin.rs index ef86360c..f92e7a32 100644 --- a/clients/rust/reqwest/v1/src/models/csi_plugin.rs +++ b/clients/rust/reqwest/v1/src/models/csi_plugin.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiPlugin { #[serde(rename = "Allocations", skip_serializing_if = "Option::is_none")] pub allocations: Option>, diff --git a/clients/rust/reqwest/v1/src/models/csi_plugin_list_stub.rs b/clients/rust/reqwest/v1/src/models/csi_plugin_list_stub.rs index da6cf41c..9e973a9a 100644 --- a/clients/rust/reqwest/v1/src/models/csi_plugin_list_stub.rs +++ b/clients/rust/reqwest/v1/src/models/csi_plugin_list_stub.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiPluginListStub { #[serde(rename = "ControllerRequired", skip_serializing_if = "Option::is_none")] pub controller_required: Option, diff --git a/clients/rust/reqwest/v1/src/models/csi_snapshot.rs b/clients/rust/reqwest/v1/src/models/csi_snapshot.rs index c9c3b508..10ee1dae 100644 --- a/clients/rust/reqwest/v1/src/models/csi_snapshot.rs +++ b/clients/rust/reqwest/v1/src/models/csi_snapshot.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiSnapshot { #[serde(rename = "CreateTime", skip_serializing_if = "Option::is_none")] pub create_time: Option, diff --git a/clients/rust/reqwest/v1/src/models/csi_snapshot_create_request.rs b/clients/rust/reqwest/v1/src/models/csi_snapshot_create_request.rs index b2a4d147..164e005e 100644 --- a/clients/rust/reqwest/v1/src/models/csi_snapshot_create_request.rs +++ b/clients/rust/reqwest/v1/src/models/csi_snapshot_create_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiSnapshotCreateRequest { #[serde(rename = "Namespace", skip_serializing_if = "Option::is_none")] pub namespace: Option, diff --git a/clients/rust/reqwest/v1/src/models/csi_snapshot_create_response.rs b/clients/rust/reqwest/v1/src/models/csi_snapshot_create_response.rs index 86ca0e45..ba5e49b4 100644 --- a/clients/rust/reqwest/v1/src/models/csi_snapshot_create_response.rs +++ b/clients/rust/reqwest/v1/src/models/csi_snapshot_create_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiSnapshotCreateResponse { #[serde(rename = "KnownLeader", skip_serializing_if = "Option::is_none")] pub known_leader: Option, diff --git a/clients/rust/reqwest/v1/src/models/csi_snapshot_list_response.rs b/clients/rust/reqwest/v1/src/models/csi_snapshot_list_response.rs index 6513c969..48b3dde5 100644 --- a/clients/rust/reqwest/v1/src/models/csi_snapshot_list_response.rs +++ b/clients/rust/reqwest/v1/src/models/csi_snapshot_list_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiSnapshotListResponse { #[serde(rename = "KnownLeader", skip_serializing_if = "Option::is_none")] pub known_leader: Option, diff --git a/clients/rust/reqwest/v1/src/models/csi_topology.rs b/clients/rust/reqwest/v1/src/models/csi_topology.rs index 4b1b2e2e..da47f855 100644 --- a/clients/rust/reqwest/v1/src/models/csi_topology.rs +++ b/clients/rust/reqwest/v1/src/models/csi_topology.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiTopology { #[serde(rename = "Segments", skip_serializing_if = "Option::is_none")] pub segments: Option<::std::collections::HashMap>, diff --git a/clients/rust/reqwest/v1/src/models/csi_topology_request.rs b/clients/rust/reqwest/v1/src/models/csi_topology_request.rs index 1162efa3..9fca6d73 100644 --- a/clients/rust/reqwest/v1/src/models/csi_topology_request.rs +++ b/clients/rust/reqwest/v1/src/models/csi_topology_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiTopologyRequest { #[serde(rename = "Preferred", skip_serializing_if = "Option::is_none")] pub preferred: Option>, diff --git a/clients/rust/reqwest/v1/src/models/csi_volume.rs b/clients/rust/reqwest/v1/src/models/csi_volume.rs index 78e0310f..781b1d33 100644 --- a/clients/rust/reqwest/v1/src/models/csi_volume.rs +++ b/clients/rust/reqwest/v1/src/models/csi_volume.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiVolume { #[serde(rename = "AccessMode", skip_serializing_if = "Option::is_none")] pub access_mode: Option, diff --git a/clients/rust/reqwest/v1/src/models/csi_volume_capability.rs b/clients/rust/reqwest/v1/src/models/csi_volume_capability.rs index 667ad365..e78567ee 100644 --- a/clients/rust/reqwest/v1/src/models/csi_volume_capability.rs +++ b/clients/rust/reqwest/v1/src/models/csi_volume_capability.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiVolumeCapability { #[serde(rename = "AccessMode", skip_serializing_if = "Option::is_none")] pub access_mode: Option, diff --git a/clients/rust/reqwest/v1/src/models/csi_volume_create_request.rs b/clients/rust/reqwest/v1/src/models/csi_volume_create_request.rs index 82ad1ac4..e684ba5c 100644 --- a/clients/rust/reqwest/v1/src/models/csi_volume_create_request.rs +++ b/clients/rust/reqwest/v1/src/models/csi_volume_create_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiVolumeCreateRequest { #[serde(rename = "Namespace", skip_serializing_if = "Option::is_none")] pub namespace: Option, diff --git a/clients/rust/reqwest/v1/src/models/csi_volume_external_stub.rs b/clients/rust/reqwest/v1/src/models/csi_volume_external_stub.rs index c3296192..7e5aef87 100644 --- a/clients/rust/reqwest/v1/src/models/csi_volume_external_stub.rs +++ b/clients/rust/reqwest/v1/src/models/csi_volume_external_stub.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiVolumeExternalStub { #[serde(rename = "CapacityBytes", skip_serializing_if = "Option::is_none")] pub capacity_bytes: Option, diff --git a/clients/rust/reqwest/v1/src/models/csi_volume_list_external_response.rs b/clients/rust/reqwest/v1/src/models/csi_volume_list_external_response.rs index 16fb143f..d9f350b2 100644 --- a/clients/rust/reqwest/v1/src/models/csi_volume_list_external_response.rs +++ b/clients/rust/reqwest/v1/src/models/csi_volume_list_external_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiVolumeListExternalResponse { #[serde(rename = "NextToken", skip_serializing_if = "Option::is_none")] pub next_token: Option, diff --git a/clients/rust/reqwest/v1/src/models/csi_volume_list_stub.rs b/clients/rust/reqwest/v1/src/models/csi_volume_list_stub.rs index 82ac6b5a..5de566cb 100644 --- a/clients/rust/reqwest/v1/src/models/csi_volume_list_stub.rs +++ b/clients/rust/reqwest/v1/src/models/csi_volume_list_stub.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiVolumeListStub { #[serde(rename = "AccessMode", skip_serializing_if = "Option::is_none")] pub access_mode: Option, diff --git a/clients/rust/reqwest/v1/src/models/csi_volume_register_request.rs b/clients/rust/reqwest/v1/src/models/csi_volume_register_request.rs index 429344d8..db9e1ce6 100644 --- a/clients/rust/reqwest/v1/src/models/csi_volume_register_request.rs +++ b/clients/rust/reqwest/v1/src/models/csi_volume_register_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct CsiVolumeRegisterRequest { #[serde(rename = "Namespace", skip_serializing_if = "Option::is_none")] pub namespace: Option, diff --git a/clients/rust/reqwest/v1/src/models/deployment.rs b/clients/rust/reqwest/v1/src/models/deployment.rs index c920b2ff..ebd5ddd5 100644 --- a/clients/rust/reqwest/v1/src/models/deployment.rs +++ b/clients/rust/reqwest/v1/src/models/deployment.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Deployment { #[serde(rename = "CreateIndex", skip_serializing_if = "Option::is_none")] pub create_index: Option, diff --git a/clients/rust/reqwest/v1/src/models/deployment_alloc_health_request.rs b/clients/rust/reqwest/v1/src/models/deployment_alloc_health_request.rs index 63b8f71f..9ba87dc1 100644 --- a/clients/rust/reqwest/v1/src/models/deployment_alloc_health_request.rs +++ b/clients/rust/reqwest/v1/src/models/deployment_alloc_health_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct DeploymentAllocHealthRequest { #[serde(rename = "DeploymentID", skip_serializing_if = "Option::is_none")] pub deployment_id: Option, diff --git a/clients/rust/reqwest/v1/src/models/deployment_pause_request.rs b/clients/rust/reqwest/v1/src/models/deployment_pause_request.rs index 56de42e6..1d899133 100644 --- a/clients/rust/reqwest/v1/src/models/deployment_pause_request.rs +++ b/clients/rust/reqwest/v1/src/models/deployment_pause_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct DeploymentPauseRequest { #[serde(rename = "DeploymentID", skip_serializing_if = "Option::is_none")] pub deployment_id: Option, diff --git a/clients/rust/reqwest/v1/src/models/deployment_promote_request.rs b/clients/rust/reqwest/v1/src/models/deployment_promote_request.rs index 255b0941..b27ca50c 100644 --- a/clients/rust/reqwest/v1/src/models/deployment_promote_request.rs +++ b/clients/rust/reqwest/v1/src/models/deployment_promote_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct DeploymentPromoteRequest { #[serde(rename = "All", skip_serializing_if = "Option::is_none")] pub all: Option, diff --git a/clients/rust/reqwest/v1/src/models/deployment_state.rs b/clients/rust/reqwest/v1/src/models/deployment_state.rs index d83bc5d9..31662709 100644 --- a/clients/rust/reqwest/v1/src/models/deployment_state.rs +++ b/clients/rust/reqwest/v1/src/models/deployment_state.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct DeploymentState { #[serde(rename = "AutoRevert", skip_serializing_if = "Option::is_none")] pub auto_revert: Option, diff --git a/clients/rust/reqwest/v1/src/models/deployment_unblock_request.rs b/clients/rust/reqwest/v1/src/models/deployment_unblock_request.rs index 6cf4d6a6..9408cb19 100644 --- a/clients/rust/reqwest/v1/src/models/deployment_unblock_request.rs +++ b/clients/rust/reqwest/v1/src/models/deployment_unblock_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct DeploymentUnblockRequest { #[serde(rename = "DeploymentID", skip_serializing_if = "Option::is_none")] pub deployment_id: Option, diff --git a/clients/rust/reqwest/v1/src/models/deployment_update_response.rs b/clients/rust/reqwest/v1/src/models/deployment_update_response.rs index 6e32f600..aea37898 100644 --- a/clients/rust/reqwest/v1/src/models/deployment_update_response.rs +++ b/clients/rust/reqwest/v1/src/models/deployment_update_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct DeploymentUpdateResponse { #[serde(rename = "DeploymentModifyIndex", skip_serializing_if = "Option::is_none")] pub deployment_modify_index: Option, diff --git a/clients/rust/reqwest/v1/src/models/desired_transition.rs b/clients/rust/reqwest/v1/src/models/desired_transition.rs index 5f9c818b..c271d376 100644 --- a/clients/rust/reqwest/v1/src/models/desired_transition.rs +++ b/clients/rust/reqwest/v1/src/models/desired_transition.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct DesiredTransition { #[serde(rename = "Migrate", skip_serializing_if = "Option::is_none")] pub migrate: Option, diff --git a/clients/rust/reqwest/v1/src/models/desired_updates.rs b/clients/rust/reqwest/v1/src/models/desired_updates.rs index e5e594d3..87b632ea 100644 --- a/clients/rust/reqwest/v1/src/models/desired_updates.rs +++ b/clients/rust/reqwest/v1/src/models/desired_updates.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct DesiredUpdates { #[serde(rename = "Canary", skip_serializing_if = "Option::is_none")] pub canary: Option, diff --git a/clients/rust/reqwest/v1/src/models/dispatch_payload_config.rs b/clients/rust/reqwest/v1/src/models/dispatch_payload_config.rs index b0b75cb3..ba7df09b 100644 --- a/clients/rust/reqwest/v1/src/models/dispatch_payload_config.rs +++ b/clients/rust/reqwest/v1/src/models/dispatch_payload_config.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct DispatchPayloadConfig { #[serde(rename = "File", skip_serializing_if = "Option::is_none")] pub file: Option, diff --git a/clients/rust/reqwest/v1/src/models/dns_config.rs b/clients/rust/reqwest/v1/src/models/dns_config.rs index 6ff654f9..de93dbb0 100644 --- a/clients/rust/reqwest/v1/src/models/dns_config.rs +++ b/clients/rust/reqwest/v1/src/models/dns_config.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct DnsConfig { #[serde(rename = "Options", skip_serializing_if = "Option::is_none")] pub options: Option>, diff --git a/clients/rust/reqwest/v1/src/models/drain_metadata.rs b/clients/rust/reqwest/v1/src/models/drain_metadata.rs index e6189e22..a0e5a01c 100644 --- a/clients/rust/reqwest/v1/src/models/drain_metadata.rs +++ b/clients/rust/reqwest/v1/src/models/drain_metadata.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct DrainMetadata { #[serde(rename = "AccessorID", skip_serializing_if = "Option::is_none")] pub accessor_id: Option, diff --git a/clients/rust/reqwest/v1/src/models/drain_spec.rs b/clients/rust/reqwest/v1/src/models/drain_spec.rs index 98b34280..d386c2ca 100644 --- a/clients/rust/reqwest/v1/src/models/drain_spec.rs +++ b/clients/rust/reqwest/v1/src/models/drain_spec.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct DrainSpec { #[serde(rename = "Deadline", skip_serializing_if = "Option::is_none")] pub deadline: Option, diff --git a/clients/rust/reqwest/v1/src/models/drain_strategy.rs b/clients/rust/reqwest/v1/src/models/drain_strategy.rs index 612cf7f5..0d0d215d 100644 --- a/clients/rust/reqwest/v1/src/models/drain_strategy.rs +++ b/clients/rust/reqwest/v1/src/models/drain_strategy.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct DrainStrategy { #[serde(rename = "Deadline", skip_serializing_if = "Option::is_none")] pub deadline: Option, diff --git a/clients/rust/reqwest/v1/src/models/driver_info.rs b/clients/rust/reqwest/v1/src/models/driver_info.rs index 6db78592..95b5ee7b 100644 --- a/clients/rust/reqwest/v1/src/models/driver_info.rs +++ b/clients/rust/reqwest/v1/src/models/driver_info.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct DriverInfo { #[serde(rename = "Attributes", skip_serializing_if = "Option::is_none")] pub attributes: Option<::std::collections::HashMap>, diff --git a/clients/rust/reqwest/v1/src/models/ephemeral_disk.rs b/clients/rust/reqwest/v1/src/models/ephemeral_disk.rs index 525a6c27..d1750c86 100644 --- a/clients/rust/reqwest/v1/src/models/ephemeral_disk.rs +++ b/clients/rust/reqwest/v1/src/models/ephemeral_disk.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct EphemeralDisk { #[serde(rename = "Migrate", skip_serializing_if = "Option::is_none")] pub migrate: Option, diff --git a/clients/rust/reqwest/v1/src/models/eval_options.rs b/clients/rust/reqwest/v1/src/models/eval_options.rs index 58193f02..5fc78282 100644 --- a/clients/rust/reqwest/v1/src/models/eval_options.rs +++ b/clients/rust/reqwest/v1/src/models/eval_options.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct EvalOptions { #[serde(rename = "ForceReschedule", skip_serializing_if = "Option::is_none")] pub force_reschedule: Option, diff --git a/clients/rust/reqwest/v1/src/models/evaluation.rs b/clients/rust/reqwest/v1/src/models/evaluation.rs index e7b59192..1d46d711 100644 --- a/clients/rust/reqwest/v1/src/models/evaluation.rs +++ b/clients/rust/reqwest/v1/src/models/evaluation.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Evaluation { #[serde(rename = "AnnotatePlan", skip_serializing_if = "Option::is_none")] pub annotate_plan: Option, diff --git a/clients/rust/reqwest/v1/src/models/evaluation_stub.rs b/clients/rust/reqwest/v1/src/models/evaluation_stub.rs index a4a57ffb..05d8d031 100644 --- a/clients/rust/reqwest/v1/src/models/evaluation_stub.rs +++ b/clients/rust/reqwest/v1/src/models/evaluation_stub.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct EvaluationStub { #[serde(rename = "BlockedEval", skip_serializing_if = "Option::is_none")] pub blocked_eval: Option, diff --git a/clients/rust/reqwest/v1/src/models/field_diff.rs b/clients/rust/reqwest/v1/src/models/field_diff.rs index 7668562d..9efe4aee 100644 --- a/clients/rust/reqwest/v1/src/models/field_diff.rs +++ b/clients/rust/reqwest/v1/src/models/field_diff.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct FieldDiff { #[serde(rename = "Annotations", skip_serializing_if = "Option::is_none")] pub annotations: Option>, diff --git a/clients/rust/reqwest/v1/src/models/fuzzy_match.rs b/clients/rust/reqwest/v1/src/models/fuzzy_match.rs index 1f27edd6..16487382 100644 --- a/clients/rust/reqwest/v1/src/models/fuzzy_match.rs +++ b/clients/rust/reqwest/v1/src/models/fuzzy_match.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct FuzzyMatch { #[serde(rename = "ID", skip_serializing_if = "Option::is_none")] pub ID: Option, diff --git a/clients/rust/reqwest/v1/src/models/fuzzy_search_request.rs b/clients/rust/reqwest/v1/src/models/fuzzy_search_request.rs index 90410ed0..41721f80 100644 --- a/clients/rust/reqwest/v1/src/models/fuzzy_search_request.rs +++ b/clients/rust/reqwest/v1/src/models/fuzzy_search_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct FuzzySearchRequest { #[serde(rename = "AllowStale", skip_serializing_if = "Option::is_none")] pub allow_stale: Option, diff --git a/clients/rust/reqwest/v1/src/models/fuzzy_search_response.rs b/clients/rust/reqwest/v1/src/models/fuzzy_search_response.rs index 338dc6c9..aec16d1a 100644 --- a/clients/rust/reqwest/v1/src/models/fuzzy_search_response.rs +++ b/clients/rust/reqwest/v1/src/models/fuzzy_search_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct FuzzySearchResponse { #[serde(rename = "KnownLeader", skip_serializing_if = "Option::is_none")] pub known_leader: Option, diff --git a/clients/rust/reqwest/v1/src/models/gauge_value.rs b/clients/rust/reqwest/v1/src/models/gauge_value.rs index e0968c24..f49a9eb7 100644 --- a/clients/rust/reqwest/v1/src/models/gauge_value.rs +++ b/clients/rust/reqwest/v1/src/models/gauge_value.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct GaugeValue { #[serde(rename = "Labels", skip_serializing_if = "Option::is_none")] pub labels: Option<::std::collections::HashMap>, diff --git a/clients/rust/reqwest/v1/src/models/host_network_info.rs b/clients/rust/reqwest/v1/src/models/host_network_info.rs index cf6039f2..f019d608 100644 --- a/clients/rust/reqwest/v1/src/models/host_network_info.rs +++ b/clients/rust/reqwest/v1/src/models/host_network_info.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct HostNetworkInfo { #[serde(rename = "CIDR", skip_serializing_if = "Option::is_none")] pub CIDR: Option, diff --git a/clients/rust/reqwest/v1/src/models/host_volume_info.rs b/clients/rust/reqwest/v1/src/models/host_volume_info.rs index ab73c447..a52a0ce6 100644 --- a/clients/rust/reqwest/v1/src/models/host_volume_info.rs +++ b/clients/rust/reqwest/v1/src/models/host_volume_info.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct HostVolumeInfo { #[serde(rename = "Path", skip_serializing_if = "Option::is_none")] pub path: Option, diff --git a/clients/rust/reqwest/v1/src/models/job.rs b/clients/rust/reqwest/v1/src/models/job.rs index 1997fb32..5ef536d9 100644 --- a/clients/rust/reqwest/v1/src/models/job.rs +++ b/clients/rust/reqwest/v1/src/models/job.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Job { #[serde(rename = "Affinities", skip_serializing_if = "Option::is_none")] pub affinities: Option>, diff --git a/clients/rust/reqwest/v1/src/models/job_children_summary.rs b/clients/rust/reqwest/v1/src/models/job_children_summary.rs index 3aef86ee..394fab5a 100644 --- a/clients/rust/reqwest/v1/src/models/job_children_summary.rs +++ b/clients/rust/reqwest/v1/src/models/job_children_summary.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobChildrenSummary { #[serde(rename = "Dead", skip_serializing_if = "Option::is_none")] pub dead: Option, diff --git a/clients/rust/reqwest/v1/src/models/job_deregister_response.rs b/clients/rust/reqwest/v1/src/models/job_deregister_response.rs index 066f961c..22e03aad 100644 --- a/clients/rust/reqwest/v1/src/models/job_deregister_response.rs +++ b/clients/rust/reqwest/v1/src/models/job_deregister_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobDeregisterResponse { #[serde(rename = "EvalCreateIndex", skip_serializing_if = "Option::is_none")] pub eval_create_index: Option, diff --git a/clients/rust/reqwest/v1/src/models/job_diff.rs b/clients/rust/reqwest/v1/src/models/job_diff.rs index 34aa3def..64aba342 100644 --- a/clients/rust/reqwest/v1/src/models/job_diff.rs +++ b/clients/rust/reqwest/v1/src/models/job_diff.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobDiff { #[serde(rename = "Fields", skip_serializing_if = "Option::is_none")] pub fields: Option>, diff --git a/clients/rust/reqwest/v1/src/models/job_dispatch_request.rs b/clients/rust/reqwest/v1/src/models/job_dispatch_request.rs index c08ce8d5..79ac5f87 100644 --- a/clients/rust/reqwest/v1/src/models/job_dispatch_request.rs +++ b/clients/rust/reqwest/v1/src/models/job_dispatch_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobDispatchRequest { #[serde(rename = "JobID", skip_serializing_if = "Option::is_none")] pub job_id: Option, diff --git a/clients/rust/reqwest/v1/src/models/job_dispatch_response.rs b/clients/rust/reqwest/v1/src/models/job_dispatch_response.rs index 6c9b527b..a3b96d14 100644 --- a/clients/rust/reqwest/v1/src/models/job_dispatch_response.rs +++ b/clients/rust/reqwest/v1/src/models/job_dispatch_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobDispatchResponse { #[serde(rename = "DispatchedJobID", skip_serializing_if = "Option::is_none")] pub dispatched_job_id: Option, diff --git a/clients/rust/reqwest/v1/src/models/job_evaluate_request.rs b/clients/rust/reqwest/v1/src/models/job_evaluate_request.rs index 52bbcf19..7f718ecf 100644 --- a/clients/rust/reqwest/v1/src/models/job_evaluate_request.rs +++ b/clients/rust/reqwest/v1/src/models/job_evaluate_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobEvaluateRequest { #[serde(rename = "EvalOptions", skip_serializing_if = "Option::is_none")] pub eval_options: Option>, diff --git a/clients/rust/reqwest/v1/src/models/job_list_stub.rs b/clients/rust/reqwest/v1/src/models/job_list_stub.rs index 021aeb8e..60356a0a 100644 --- a/clients/rust/reqwest/v1/src/models/job_list_stub.rs +++ b/clients/rust/reqwest/v1/src/models/job_list_stub.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobListStub { #[serde(rename = "CreateIndex", skip_serializing_if = "Option::is_none")] pub create_index: Option, diff --git a/clients/rust/reqwest/v1/src/models/job_plan_request.rs b/clients/rust/reqwest/v1/src/models/job_plan_request.rs index ec1198f7..468f3e30 100644 --- a/clients/rust/reqwest/v1/src/models/job_plan_request.rs +++ b/clients/rust/reqwest/v1/src/models/job_plan_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobPlanRequest { #[serde(rename = "Diff", skip_serializing_if = "Option::is_none")] pub diff: Option, diff --git a/clients/rust/reqwest/v1/src/models/job_plan_response.rs b/clients/rust/reqwest/v1/src/models/job_plan_response.rs index 01f1452f..a29d5a35 100644 --- a/clients/rust/reqwest/v1/src/models/job_plan_response.rs +++ b/clients/rust/reqwest/v1/src/models/job_plan_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobPlanResponse { #[serde(rename = "Annotations", skip_serializing_if = "Option::is_none")] pub annotations: Option>, diff --git a/clients/rust/reqwest/v1/src/models/job_register_request.rs b/clients/rust/reqwest/v1/src/models/job_register_request.rs index 464d71a1..5037c6c4 100644 --- a/clients/rust/reqwest/v1/src/models/job_register_request.rs +++ b/clients/rust/reqwest/v1/src/models/job_register_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobRegisterRequest { #[serde(rename = "EnforceIndex", skip_serializing_if = "Option::is_none")] pub enforce_index: Option, diff --git a/clients/rust/reqwest/v1/src/models/job_register_response.rs b/clients/rust/reqwest/v1/src/models/job_register_response.rs index cafa8935..2f36349c 100644 --- a/clients/rust/reqwest/v1/src/models/job_register_response.rs +++ b/clients/rust/reqwest/v1/src/models/job_register_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobRegisterResponse { #[serde(rename = "EvalCreateIndex", skip_serializing_if = "Option::is_none")] pub eval_create_index: Option, diff --git a/clients/rust/reqwest/v1/src/models/job_revert_request.rs b/clients/rust/reqwest/v1/src/models/job_revert_request.rs index abf3eafb..ff6fd7fe 100644 --- a/clients/rust/reqwest/v1/src/models/job_revert_request.rs +++ b/clients/rust/reqwest/v1/src/models/job_revert_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobRevertRequest { #[serde(rename = "ConsulToken", skip_serializing_if = "Option::is_none")] pub consul_token: Option, diff --git a/clients/rust/reqwest/v1/src/models/job_scale_status_response.rs b/clients/rust/reqwest/v1/src/models/job_scale_status_response.rs index 832cdb76..c1ef689c 100644 --- a/clients/rust/reqwest/v1/src/models/job_scale_status_response.rs +++ b/clients/rust/reqwest/v1/src/models/job_scale_status_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobScaleStatusResponse { #[serde(rename = "JobCreateIndex", skip_serializing_if = "Option::is_none")] pub job_create_index: Option, diff --git a/clients/rust/reqwest/v1/src/models/job_stability_request.rs b/clients/rust/reqwest/v1/src/models/job_stability_request.rs index 721999c0..eba77f55 100644 --- a/clients/rust/reqwest/v1/src/models/job_stability_request.rs +++ b/clients/rust/reqwest/v1/src/models/job_stability_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobStabilityRequest { #[serde(rename = "JobID", skip_serializing_if = "Option::is_none")] pub job_id: Option, diff --git a/clients/rust/reqwest/v1/src/models/job_stability_response.rs b/clients/rust/reqwest/v1/src/models/job_stability_response.rs index 70cdfe79..90818bb5 100644 --- a/clients/rust/reqwest/v1/src/models/job_stability_response.rs +++ b/clients/rust/reqwest/v1/src/models/job_stability_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobStabilityResponse { #[serde(rename = "Index", skip_serializing_if = "Option::is_none")] pub index: Option, diff --git a/clients/rust/reqwest/v1/src/models/job_summary.rs b/clients/rust/reqwest/v1/src/models/job_summary.rs index c558db84..a1d1bc0c 100644 --- a/clients/rust/reqwest/v1/src/models/job_summary.rs +++ b/clients/rust/reqwest/v1/src/models/job_summary.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobSummary { #[serde(rename = "Children", skip_serializing_if = "Option::is_none")] pub children: Option>, diff --git a/clients/rust/reqwest/v1/src/models/job_validate_request.rs b/clients/rust/reqwest/v1/src/models/job_validate_request.rs index 1935983e..1214d6a4 100644 --- a/clients/rust/reqwest/v1/src/models/job_validate_request.rs +++ b/clients/rust/reqwest/v1/src/models/job_validate_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobValidateRequest { #[serde(rename = "Job", skip_serializing_if = "Option::is_none")] pub job: Option>, diff --git a/clients/rust/reqwest/v1/src/models/job_validate_response.rs b/clients/rust/reqwest/v1/src/models/job_validate_response.rs index f64fb559..35271063 100644 --- a/clients/rust/reqwest/v1/src/models/job_validate_response.rs +++ b/clients/rust/reqwest/v1/src/models/job_validate_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobValidateResponse { #[serde(rename = "DriverConfigValidated", skip_serializing_if = "Option::is_none")] pub driver_config_validated: Option, diff --git a/clients/rust/reqwest/v1/src/models/job_versions_response.rs b/clients/rust/reqwest/v1/src/models/job_versions_response.rs index c9200046..bc025570 100644 --- a/clients/rust/reqwest/v1/src/models/job_versions_response.rs +++ b/clients/rust/reqwest/v1/src/models/job_versions_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobVersionsResponse { #[serde(rename = "Diffs", skip_serializing_if = "Option::is_none")] pub diffs: Option>, diff --git a/clients/rust/reqwest/v1/src/models/jobs_parse_request.rs b/clients/rust/reqwest/v1/src/models/jobs_parse_request.rs index cb7c4a16..27e0a57d 100644 --- a/clients/rust/reqwest/v1/src/models/jobs_parse_request.rs +++ b/clients/rust/reqwest/v1/src/models/jobs_parse_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct JobsParseRequest { #[serde(rename = "Canonicalize", skip_serializing_if = "Option::is_none")] pub canonicalize: Option, diff --git a/clients/rust/reqwest/v1/src/models/log_config.rs b/clients/rust/reqwest/v1/src/models/log_config.rs index 78262385..6752b071 100644 --- a/clients/rust/reqwest/v1/src/models/log_config.rs +++ b/clients/rust/reqwest/v1/src/models/log_config.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct LogConfig { #[serde(rename = "MaxFileSizeMB", skip_serializing_if = "Option::is_none")] pub max_file_size_mb: Option, diff --git a/clients/rust/reqwest/v1/src/models/metrics_summary.rs b/clients/rust/reqwest/v1/src/models/metrics_summary.rs index 5517ce36..1e36191b 100644 --- a/clients/rust/reqwest/v1/src/models/metrics_summary.rs +++ b/clients/rust/reqwest/v1/src/models/metrics_summary.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct MetricsSummary { #[serde(rename = "Counters", skip_serializing_if = "Option::is_none")] pub counters: Option>, diff --git a/clients/rust/reqwest/v1/src/models/migrate_strategy.rs b/clients/rust/reqwest/v1/src/models/migrate_strategy.rs index d019b33c..b7c08158 100644 --- a/clients/rust/reqwest/v1/src/models/migrate_strategy.rs +++ b/clients/rust/reqwest/v1/src/models/migrate_strategy.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct MigrateStrategy { #[serde(rename = "HealthCheck", skip_serializing_if = "Option::is_none")] pub health_check: Option, diff --git a/clients/rust/reqwest/v1/src/models/multiregion.rs b/clients/rust/reqwest/v1/src/models/multiregion.rs index 447b7284..db3be120 100644 --- a/clients/rust/reqwest/v1/src/models/multiregion.rs +++ b/clients/rust/reqwest/v1/src/models/multiregion.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Multiregion { #[serde(rename = "Regions", skip_serializing_if = "Option::is_none")] pub regions: Option>, diff --git a/clients/rust/reqwest/v1/src/models/multiregion_region.rs b/clients/rust/reqwest/v1/src/models/multiregion_region.rs index db9b42fd..44528842 100644 --- a/clients/rust/reqwest/v1/src/models/multiregion_region.rs +++ b/clients/rust/reqwest/v1/src/models/multiregion_region.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct MultiregionRegion { #[serde(rename = "Count", skip_serializing_if = "Option::is_none")] pub count: Option, diff --git a/clients/rust/reqwest/v1/src/models/multiregion_strategy.rs b/clients/rust/reqwest/v1/src/models/multiregion_strategy.rs index 94c02c74..12bb3db9 100644 --- a/clients/rust/reqwest/v1/src/models/multiregion_strategy.rs +++ b/clients/rust/reqwest/v1/src/models/multiregion_strategy.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct MultiregionStrategy { #[serde(rename = "MaxParallel", skip_serializing_if = "Option::is_none")] pub max_parallel: Option, diff --git a/clients/rust/reqwest/v1/src/models/namespace.rs b/clients/rust/reqwest/v1/src/models/namespace.rs index fdb5d38c..6fbdd447 100644 --- a/clients/rust/reqwest/v1/src/models/namespace.rs +++ b/clients/rust/reqwest/v1/src/models/namespace.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Namespace { #[serde(rename = "Capabilities", skip_serializing_if = "Option::is_none")] pub capabilities: Option>, diff --git a/clients/rust/reqwest/v1/src/models/namespace_capabilities.rs b/clients/rust/reqwest/v1/src/models/namespace_capabilities.rs index fc3cf7c2..23e03414 100644 --- a/clients/rust/reqwest/v1/src/models/namespace_capabilities.rs +++ b/clients/rust/reqwest/v1/src/models/namespace_capabilities.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NamespaceCapabilities { #[serde(rename = "DisabledTaskDrivers", skip_serializing_if = "Option::is_none")] pub disabled_task_drivers: Option>, diff --git a/clients/rust/reqwest/v1/src/models/network_resource.rs b/clients/rust/reqwest/v1/src/models/network_resource.rs index 66181d40..11f10228 100644 --- a/clients/rust/reqwest/v1/src/models/network_resource.rs +++ b/clients/rust/reqwest/v1/src/models/network_resource.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NetworkResource { #[serde(rename = "CIDR", skip_serializing_if = "Option::is_none")] pub CIDR: Option, diff --git a/clients/rust/reqwest/v1/src/models/node.rs b/clients/rust/reqwest/v1/src/models/node.rs index 71730728..954cd664 100644 --- a/clients/rust/reqwest/v1/src/models/node.rs +++ b/clients/rust/reqwest/v1/src/models/node.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Node { #[serde(rename = "Attributes", skip_serializing_if = "Option::is_none")] pub attributes: Option<::std::collections::HashMap>, diff --git a/clients/rust/reqwest/v1/src/models/node_cpu_resources.rs b/clients/rust/reqwest/v1/src/models/node_cpu_resources.rs index 6d659f86..11cb141a 100644 --- a/clients/rust/reqwest/v1/src/models/node_cpu_resources.rs +++ b/clients/rust/reqwest/v1/src/models/node_cpu_resources.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeCpuResources { #[serde(rename = "CpuShares", skip_serializing_if = "Option::is_none")] pub cpu_shares: Option, diff --git a/clients/rust/reqwest/v1/src/models/node_device.rs b/clients/rust/reqwest/v1/src/models/node_device.rs index ddb9de8a..df6ec5d8 100644 --- a/clients/rust/reqwest/v1/src/models/node_device.rs +++ b/clients/rust/reqwest/v1/src/models/node_device.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeDevice { #[serde(rename = "HealthDescription", skip_serializing_if = "Option::is_none")] pub health_description: Option, diff --git a/clients/rust/reqwest/v1/src/models/node_device_locality.rs b/clients/rust/reqwest/v1/src/models/node_device_locality.rs index 54ee328e..31be2375 100644 --- a/clients/rust/reqwest/v1/src/models/node_device_locality.rs +++ b/clients/rust/reqwest/v1/src/models/node_device_locality.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeDeviceLocality { #[serde(rename = "PciBusID", skip_serializing_if = "Option::is_none")] pub pci_bus_id: Option, diff --git a/clients/rust/reqwest/v1/src/models/node_device_resource.rs b/clients/rust/reqwest/v1/src/models/node_device_resource.rs index 563e1a08..4b6c4b7b 100644 --- a/clients/rust/reqwest/v1/src/models/node_device_resource.rs +++ b/clients/rust/reqwest/v1/src/models/node_device_resource.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeDeviceResource { #[serde(rename = "Attributes", skip_serializing_if = "Option::is_none")] pub attributes: Option<::std::collections::HashMap>, diff --git a/clients/rust/reqwest/v1/src/models/node_disk_resources.rs b/clients/rust/reqwest/v1/src/models/node_disk_resources.rs index 4fd94746..c1f1ae51 100644 --- a/clients/rust/reqwest/v1/src/models/node_disk_resources.rs +++ b/clients/rust/reqwest/v1/src/models/node_disk_resources.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeDiskResources { #[serde(rename = "DiskMB", skip_serializing_if = "Option::is_none")] pub disk_mb: Option, diff --git a/clients/rust/reqwest/v1/src/models/node_drain_update_response.rs b/clients/rust/reqwest/v1/src/models/node_drain_update_response.rs index 3890fdcf..3c7eae06 100644 --- a/clients/rust/reqwest/v1/src/models/node_drain_update_response.rs +++ b/clients/rust/reqwest/v1/src/models/node_drain_update_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeDrainUpdateResponse { #[serde(rename = "EvalCreateIndex", skip_serializing_if = "Option::is_none")] pub eval_create_index: Option, diff --git a/clients/rust/reqwest/v1/src/models/node_eligibility_update_response.rs b/clients/rust/reqwest/v1/src/models/node_eligibility_update_response.rs index 6b1883e5..7b1f3d29 100644 --- a/clients/rust/reqwest/v1/src/models/node_eligibility_update_response.rs +++ b/clients/rust/reqwest/v1/src/models/node_eligibility_update_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeEligibilityUpdateResponse { #[serde(rename = "EvalCreateIndex", skip_serializing_if = "Option::is_none")] pub eval_create_index: Option, diff --git a/clients/rust/reqwest/v1/src/models/node_event.rs b/clients/rust/reqwest/v1/src/models/node_event.rs index e7db09a8..9ad18755 100644 --- a/clients/rust/reqwest/v1/src/models/node_event.rs +++ b/clients/rust/reqwest/v1/src/models/node_event.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeEvent { #[serde(rename = "CreateIndex", skip_serializing_if = "Option::is_none")] pub create_index: Option, diff --git a/clients/rust/reqwest/v1/src/models/node_list_stub.rs b/clients/rust/reqwest/v1/src/models/node_list_stub.rs index 7fb4f792..456812fc 100644 --- a/clients/rust/reqwest/v1/src/models/node_list_stub.rs +++ b/clients/rust/reqwest/v1/src/models/node_list_stub.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeListStub { #[serde(rename = "Address", skip_serializing_if = "Option::is_none")] pub address: Option, diff --git a/clients/rust/reqwest/v1/src/models/node_memory_resources.rs b/clients/rust/reqwest/v1/src/models/node_memory_resources.rs index 49160a17..c13e4ad7 100644 --- a/clients/rust/reqwest/v1/src/models/node_memory_resources.rs +++ b/clients/rust/reqwest/v1/src/models/node_memory_resources.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeMemoryResources { #[serde(rename = "MemoryMB", skip_serializing_if = "Option::is_none")] pub memory_mb: Option, diff --git a/clients/rust/reqwest/v1/src/models/node_purge_response.rs b/clients/rust/reqwest/v1/src/models/node_purge_response.rs index a867284f..3807e6f9 100644 --- a/clients/rust/reqwest/v1/src/models/node_purge_response.rs +++ b/clients/rust/reqwest/v1/src/models/node_purge_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodePurgeResponse { #[serde(rename = "EvalCreateIndex", skip_serializing_if = "Option::is_none")] pub eval_create_index: Option, diff --git a/clients/rust/reqwest/v1/src/models/node_reserved_cpu_resources.rs b/clients/rust/reqwest/v1/src/models/node_reserved_cpu_resources.rs index 1e0e4e67..32d52d26 100644 --- a/clients/rust/reqwest/v1/src/models/node_reserved_cpu_resources.rs +++ b/clients/rust/reqwest/v1/src/models/node_reserved_cpu_resources.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeReservedCpuResources { #[serde(rename = "CpuShares", skip_serializing_if = "Option::is_none")] pub cpu_shares: Option, diff --git a/clients/rust/reqwest/v1/src/models/node_reserved_disk_resources.rs b/clients/rust/reqwest/v1/src/models/node_reserved_disk_resources.rs index 1534f9e4..0dbf2571 100644 --- a/clients/rust/reqwest/v1/src/models/node_reserved_disk_resources.rs +++ b/clients/rust/reqwest/v1/src/models/node_reserved_disk_resources.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeReservedDiskResources { #[serde(rename = "DiskMB", skip_serializing_if = "Option::is_none")] pub disk_mb: Option, diff --git a/clients/rust/reqwest/v1/src/models/node_reserved_memory_resources.rs b/clients/rust/reqwest/v1/src/models/node_reserved_memory_resources.rs index dfd32fbf..c1c5e854 100644 --- a/clients/rust/reqwest/v1/src/models/node_reserved_memory_resources.rs +++ b/clients/rust/reqwest/v1/src/models/node_reserved_memory_resources.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeReservedMemoryResources { #[serde(rename = "MemoryMB", skip_serializing_if = "Option::is_none")] pub memory_mb: Option, diff --git a/clients/rust/reqwest/v1/src/models/node_reserved_network_resources.rs b/clients/rust/reqwest/v1/src/models/node_reserved_network_resources.rs index 8450b9c8..59cf6eb7 100644 --- a/clients/rust/reqwest/v1/src/models/node_reserved_network_resources.rs +++ b/clients/rust/reqwest/v1/src/models/node_reserved_network_resources.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeReservedNetworkResources { #[serde(rename = "ReservedHostPorts", skip_serializing_if = "Option::is_none")] pub reserved_host_ports: Option, diff --git a/clients/rust/reqwest/v1/src/models/node_reserved_resources.rs b/clients/rust/reqwest/v1/src/models/node_reserved_resources.rs index 90c28a7c..3a8c21cf 100644 --- a/clients/rust/reqwest/v1/src/models/node_reserved_resources.rs +++ b/clients/rust/reqwest/v1/src/models/node_reserved_resources.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeReservedResources { #[serde(rename = "Cpu", skip_serializing_if = "Option::is_none")] pub cpu: Option>, diff --git a/clients/rust/reqwest/v1/src/models/node_resources.rs b/clients/rust/reqwest/v1/src/models/node_resources.rs index b44fe892..0fcab6c6 100644 --- a/clients/rust/reqwest/v1/src/models/node_resources.rs +++ b/clients/rust/reqwest/v1/src/models/node_resources.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeResources { #[serde(rename = "Cpu", skip_serializing_if = "Option::is_none")] pub cpu: Option>, diff --git a/clients/rust/reqwest/v1/src/models/node_score_meta.rs b/clients/rust/reqwest/v1/src/models/node_score_meta.rs index 8127dde7..71148895 100644 --- a/clients/rust/reqwest/v1/src/models/node_score_meta.rs +++ b/clients/rust/reqwest/v1/src/models/node_score_meta.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeScoreMeta { #[serde(rename = "NodeID", skip_serializing_if = "Option::is_none")] pub node_id: Option, diff --git a/clients/rust/reqwest/v1/src/models/node_update_drain_request.rs b/clients/rust/reqwest/v1/src/models/node_update_drain_request.rs index b75884bf..b411a3e5 100644 --- a/clients/rust/reqwest/v1/src/models/node_update_drain_request.rs +++ b/clients/rust/reqwest/v1/src/models/node_update_drain_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeUpdateDrainRequest { #[serde(rename = "DrainSpec", skip_serializing_if = "Option::is_none")] pub drain_spec: Option>, diff --git a/clients/rust/reqwest/v1/src/models/node_update_eligibility_request.rs b/clients/rust/reqwest/v1/src/models/node_update_eligibility_request.rs index 6b949861..680442c1 100644 --- a/clients/rust/reqwest/v1/src/models/node_update_eligibility_request.rs +++ b/clients/rust/reqwest/v1/src/models/node_update_eligibility_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct NodeUpdateEligibilityRequest { #[serde(rename = "Eligibility", skip_serializing_if = "Option::is_none")] pub eligibility: Option, diff --git a/clients/rust/reqwest/v1/src/models/object_diff.rs b/clients/rust/reqwest/v1/src/models/object_diff.rs index 26463ec2..bbe14e66 100644 --- a/clients/rust/reqwest/v1/src/models/object_diff.rs +++ b/clients/rust/reqwest/v1/src/models/object_diff.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ObjectDiff { #[serde(rename = "Fields", skip_serializing_if = "Option::is_none")] pub fields: Option>, diff --git a/clients/rust/reqwest/v1/src/models/one_time_token.rs b/clients/rust/reqwest/v1/src/models/one_time_token.rs index 8b934321..c9c8c4ce 100644 --- a/clients/rust/reqwest/v1/src/models/one_time_token.rs +++ b/clients/rust/reqwest/v1/src/models/one_time_token.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct OneTimeToken { #[serde(rename = "AccessorID", skip_serializing_if = "Option::is_none")] pub accessor_id: Option, diff --git a/clients/rust/reqwest/v1/src/models/one_time_token_exchange_request.rs b/clients/rust/reqwest/v1/src/models/one_time_token_exchange_request.rs index 0fdb3257..8c760752 100644 --- a/clients/rust/reqwest/v1/src/models/one_time_token_exchange_request.rs +++ b/clients/rust/reqwest/v1/src/models/one_time_token_exchange_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct OneTimeTokenExchangeRequest { #[serde(rename = "OneTimeSecretID", skip_serializing_if = "Option::is_none")] pub one_time_secret_id: Option, diff --git a/clients/rust/reqwest/v1/src/models/operator_health_reply.rs b/clients/rust/reqwest/v1/src/models/operator_health_reply.rs index 22725303..7bc863e7 100644 --- a/clients/rust/reqwest/v1/src/models/operator_health_reply.rs +++ b/clients/rust/reqwest/v1/src/models/operator_health_reply.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct OperatorHealthReply { #[serde(rename = "FailureTolerance", skip_serializing_if = "Option::is_none")] pub failure_tolerance: Option, diff --git a/clients/rust/reqwest/v1/src/models/parameterized_job_config.rs b/clients/rust/reqwest/v1/src/models/parameterized_job_config.rs index 6c7f0178..56f0d7a0 100644 --- a/clients/rust/reqwest/v1/src/models/parameterized_job_config.rs +++ b/clients/rust/reqwest/v1/src/models/parameterized_job_config.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ParameterizedJobConfig { #[serde(rename = "MetaOptional", skip_serializing_if = "Option::is_none")] pub meta_optional: Option>, diff --git a/clients/rust/reqwest/v1/src/models/periodic_config.rs b/clients/rust/reqwest/v1/src/models/periodic_config.rs index 483855f8..c8c59f4f 100644 --- a/clients/rust/reqwest/v1/src/models/periodic_config.rs +++ b/clients/rust/reqwest/v1/src/models/periodic_config.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct PeriodicConfig { #[serde(rename = "Enabled", skip_serializing_if = "Option::is_none")] pub enabled: Option, diff --git a/clients/rust/reqwest/v1/src/models/periodic_force_response.rs b/clients/rust/reqwest/v1/src/models/periodic_force_response.rs index 5f599595..4f926192 100644 --- a/clients/rust/reqwest/v1/src/models/periodic_force_response.rs +++ b/clients/rust/reqwest/v1/src/models/periodic_force_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct PeriodicForceResponse { #[serde(rename = "EvalCreateIndex", skip_serializing_if = "Option::is_none")] pub eval_create_index: Option, diff --git a/clients/rust/reqwest/v1/src/models/plan_annotations.rs b/clients/rust/reqwest/v1/src/models/plan_annotations.rs index f440fa2f..377f48f3 100644 --- a/clients/rust/reqwest/v1/src/models/plan_annotations.rs +++ b/clients/rust/reqwest/v1/src/models/plan_annotations.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct PlanAnnotations { #[serde(rename = "DesiredTGUpdates", skip_serializing_if = "Option::is_none")] pub desired_tg_updates: Option<::std::collections::HashMap>, diff --git a/clients/rust/reqwest/v1/src/models/point_value.rs b/clients/rust/reqwest/v1/src/models/point_value.rs index 7728b192..07fdd851 100644 --- a/clients/rust/reqwest/v1/src/models/point_value.rs +++ b/clients/rust/reqwest/v1/src/models/point_value.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct PointValue { #[serde(rename = "Name", skip_serializing_if = "Option::is_none")] pub name: Option, diff --git a/clients/rust/reqwest/v1/src/models/port.rs b/clients/rust/reqwest/v1/src/models/port.rs index e8d15352..236a2d59 100644 --- a/clients/rust/reqwest/v1/src/models/port.rs +++ b/clients/rust/reqwest/v1/src/models/port.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Port { #[serde(rename = "HostNetwork", skip_serializing_if = "Option::is_none")] pub host_network: Option, diff --git a/clients/rust/reqwest/v1/src/models/port_mapping.rs b/clients/rust/reqwest/v1/src/models/port_mapping.rs index 4709ee2f..d3cafffd 100644 --- a/clients/rust/reqwest/v1/src/models/port_mapping.rs +++ b/clients/rust/reqwest/v1/src/models/port_mapping.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct PortMapping { #[serde(rename = "HostIP", skip_serializing_if = "Option::is_none")] pub host_ip: Option, diff --git a/clients/rust/reqwest/v1/src/models/preemption_config.rs b/clients/rust/reqwest/v1/src/models/preemption_config.rs index 6eec6854..1a96db40 100644 --- a/clients/rust/reqwest/v1/src/models/preemption_config.rs +++ b/clients/rust/reqwest/v1/src/models/preemption_config.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct PreemptionConfig { #[serde(rename = "BatchSchedulerEnabled", skip_serializing_if = "Option::is_none")] pub batch_scheduler_enabled: Option, diff --git a/clients/rust/reqwest/v1/src/models/quota_limit.rs b/clients/rust/reqwest/v1/src/models/quota_limit.rs index 0c7dfd5a..d41a1e4e 100644 --- a/clients/rust/reqwest/v1/src/models/quota_limit.rs +++ b/clients/rust/reqwest/v1/src/models/quota_limit.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct QuotaLimit { #[serde(rename = "Hash", skip_serializing_if = "Option::is_none")] pub hash: Option, diff --git a/clients/rust/reqwest/v1/src/models/quota_spec.rs b/clients/rust/reqwest/v1/src/models/quota_spec.rs index f9a315d9..32272cad 100644 --- a/clients/rust/reqwest/v1/src/models/quota_spec.rs +++ b/clients/rust/reqwest/v1/src/models/quota_spec.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct QuotaSpec { #[serde(rename = "CreateIndex", skip_serializing_if = "Option::is_none")] pub create_index: Option, diff --git a/clients/rust/reqwest/v1/src/models/raft_configuration.rs b/clients/rust/reqwest/v1/src/models/raft_configuration.rs index b01115ea..db42e2bd 100644 --- a/clients/rust/reqwest/v1/src/models/raft_configuration.rs +++ b/clients/rust/reqwest/v1/src/models/raft_configuration.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct RaftConfiguration { #[serde(rename = "Index", skip_serializing_if = "Option::is_none")] pub index: Option, diff --git a/clients/rust/reqwest/v1/src/models/raft_server.rs b/clients/rust/reqwest/v1/src/models/raft_server.rs index f1a78882..07ec13d7 100644 --- a/clients/rust/reqwest/v1/src/models/raft_server.rs +++ b/clients/rust/reqwest/v1/src/models/raft_server.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct RaftServer { #[serde(rename = "Address", skip_serializing_if = "Option::is_none")] pub address: Option, diff --git a/clients/rust/reqwest/v1/src/models/requested_device.rs b/clients/rust/reqwest/v1/src/models/requested_device.rs index f2213fa6..de6cb04c 100644 --- a/clients/rust/reqwest/v1/src/models/requested_device.rs +++ b/clients/rust/reqwest/v1/src/models/requested_device.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct RequestedDevice { #[serde(rename = "Affinities", skip_serializing_if = "Option::is_none")] pub affinities: Option>, diff --git a/clients/rust/reqwest/v1/src/models/reschedule_event.rs b/clients/rust/reqwest/v1/src/models/reschedule_event.rs index d5615627..26e9ecaf 100644 --- a/clients/rust/reqwest/v1/src/models/reschedule_event.rs +++ b/clients/rust/reqwest/v1/src/models/reschedule_event.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct RescheduleEvent { #[serde(rename = "PrevAllocID", skip_serializing_if = "Option::is_none")] pub prev_alloc_id: Option, diff --git a/clients/rust/reqwest/v1/src/models/reschedule_policy.rs b/clients/rust/reqwest/v1/src/models/reschedule_policy.rs index 03605e72..c25fd990 100644 --- a/clients/rust/reqwest/v1/src/models/reschedule_policy.rs +++ b/clients/rust/reqwest/v1/src/models/reschedule_policy.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ReschedulePolicy { #[serde(rename = "Attempts", skip_serializing_if = "Option::is_none")] pub attempts: Option, diff --git a/clients/rust/reqwest/v1/src/models/reschedule_tracker.rs b/clients/rust/reqwest/v1/src/models/reschedule_tracker.rs index 35c345c9..0044b8f9 100644 --- a/clients/rust/reqwest/v1/src/models/reschedule_tracker.rs +++ b/clients/rust/reqwest/v1/src/models/reschedule_tracker.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct RescheduleTracker { #[serde(rename = "Events", skip_serializing_if = "Option::is_none")] pub events: Option>, diff --git a/clients/rust/reqwest/v1/src/models/resources.rs b/clients/rust/reqwest/v1/src/models/resources.rs index fa8748ce..7ec869fd 100644 --- a/clients/rust/reqwest/v1/src/models/resources.rs +++ b/clients/rust/reqwest/v1/src/models/resources.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Resources { #[serde(rename = "CPU", skip_serializing_if = "Option::is_none")] pub CPU: Option, diff --git a/clients/rust/reqwest/v1/src/models/restart_policy.rs b/clients/rust/reqwest/v1/src/models/restart_policy.rs index fd1c23e8..040c61da 100644 --- a/clients/rust/reqwest/v1/src/models/restart_policy.rs +++ b/clients/rust/reqwest/v1/src/models/restart_policy.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct RestartPolicy { #[serde(rename = "Attempts", skip_serializing_if = "Option::is_none")] pub attempts: Option, diff --git a/clients/rust/reqwest/v1/src/models/sampled_value.rs b/clients/rust/reqwest/v1/src/models/sampled_value.rs index f9d0e92f..1cd8effd 100644 --- a/clients/rust/reqwest/v1/src/models/sampled_value.rs +++ b/clients/rust/reqwest/v1/src/models/sampled_value.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct SampledValue { #[serde(rename = "Count", skip_serializing_if = "Option::is_none")] pub count: Option, diff --git a/clients/rust/reqwest/v1/src/models/scaling_event.rs b/clients/rust/reqwest/v1/src/models/scaling_event.rs index d3329490..6096f50f 100644 --- a/clients/rust/reqwest/v1/src/models/scaling_event.rs +++ b/clients/rust/reqwest/v1/src/models/scaling_event.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ScalingEvent { #[serde(rename = "Count", skip_serializing_if = "Option::is_none")] pub count: Option, diff --git a/clients/rust/reqwest/v1/src/models/scaling_policy.rs b/clients/rust/reqwest/v1/src/models/scaling_policy.rs index f335fc19..5b8aa77b 100644 --- a/clients/rust/reqwest/v1/src/models/scaling_policy.rs +++ b/clients/rust/reqwest/v1/src/models/scaling_policy.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ScalingPolicy { #[serde(rename = "CreateIndex", skip_serializing_if = "Option::is_none")] pub create_index: Option, diff --git a/clients/rust/reqwest/v1/src/models/scaling_policy_list_stub.rs b/clients/rust/reqwest/v1/src/models/scaling_policy_list_stub.rs index b8745212..ffcc501f 100644 --- a/clients/rust/reqwest/v1/src/models/scaling_policy_list_stub.rs +++ b/clients/rust/reqwest/v1/src/models/scaling_policy_list_stub.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ScalingPolicyListStub { #[serde(rename = "CreateIndex", skip_serializing_if = "Option::is_none")] pub create_index: Option, diff --git a/clients/rust/reqwest/v1/src/models/scaling_request.rs b/clients/rust/reqwest/v1/src/models/scaling_request.rs index 6fb2d030..e4fccd6b 100644 --- a/clients/rust/reqwest/v1/src/models/scaling_request.rs +++ b/clients/rust/reqwest/v1/src/models/scaling_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ScalingRequest { #[serde(rename = "Count", skip_serializing_if = "Option::is_none")] pub count: Option, diff --git a/clients/rust/reqwest/v1/src/models/scheduler_configuration.rs b/clients/rust/reqwest/v1/src/models/scheduler_configuration.rs index 584a7ad2..6b7c9efd 100644 --- a/clients/rust/reqwest/v1/src/models/scheduler_configuration.rs +++ b/clients/rust/reqwest/v1/src/models/scheduler_configuration.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct SchedulerConfiguration { #[serde(rename = "CreateIndex", skip_serializing_if = "Option::is_none")] pub create_index: Option, diff --git a/clients/rust/reqwest/v1/src/models/scheduler_configuration_response.rs b/clients/rust/reqwest/v1/src/models/scheduler_configuration_response.rs index db372329..0ece22fb 100644 --- a/clients/rust/reqwest/v1/src/models/scheduler_configuration_response.rs +++ b/clients/rust/reqwest/v1/src/models/scheduler_configuration_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct SchedulerConfigurationResponse { #[serde(rename = "KnownLeader", skip_serializing_if = "Option::is_none")] pub known_leader: Option, diff --git a/clients/rust/reqwest/v1/src/models/scheduler_set_configuration_response.rs b/clients/rust/reqwest/v1/src/models/scheduler_set_configuration_response.rs index db11ba13..6206afb0 100644 --- a/clients/rust/reqwest/v1/src/models/scheduler_set_configuration_response.rs +++ b/clients/rust/reqwest/v1/src/models/scheduler_set_configuration_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct SchedulerSetConfigurationResponse { #[serde(rename = "LastIndex", skip_serializing_if = "Option::is_none")] pub last_index: Option, diff --git a/clients/rust/reqwest/v1/src/models/search_request.rs b/clients/rust/reqwest/v1/src/models/search_request.rs index da833972..a2462caf 100644 --- a/clients/rust/reqwest/v1/src/models/search_request.rs +++ b/clients/rust/reqwest/v1/src/models/search_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct SearchRequest { #[serde(rename = "AllowStale", skip_serializing_if = "Option::is_none")] pub allow_stale: Option, diff --git a/clients/rust/reqwest/v1/src/models/search_response.rs b/clients/rust/reqwest/v1/src/models/search_response.rs index 8b83cd5f..b8445de2 100644 --- a/clients/rust/reqwest/v1/src/models/search_response.rs +++ b/clients/rust/reqwest/v1/src/models/search_response.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct SearchResponse { #[serde(rename = "KnownLeader", skip_serializing_if = "Option::is_none")] pub known_leader: Option, diff --git a/clients/rust/reqwest/v1/src/models/server_health.rs b/clients/rust/reqwest/v1/src/models/server_health.rs index dd923155..96d2e352 100644 --- a/clients/rust/reqwest/v1/src/models/server_health.rs +++ b/clients/rust/reqwest/v1/src/models/server_health.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ServerHealth { #[serde(rename = "Address", skip_serializing_if = "Option::is_none")] pub address: Option, diff --git a/clients/rust/reqwest/v1/src/models/service.rs b/clients/rust/reqwest/v1/src/models/service.rs index 76e7bb86..dfe67a33 100644 --- a/clients/rust/reqwest/v1/src/models/service.rs +++ b/clients/rust/reqwest/v1/src/models/service.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Service { #[serde(rename = "Address", skip_serializing_if = "Option::is_none")] pub address: Option, diff --git a/clients/rust/reqwest/v1/src/models/service_check.rs b/clients/rust/reqwest/v1/src/models/service_check.rs index e0e304e3..e8d9f474 100644 --- a/clients/rust/reqwest/v1/src/models/service_check.rs +++ b/clients/rust/reqwest/v1/src/models/service_check.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ServiceCheck { #[serde(rename = "AddressMode", skip_serializing_if = "Option::is_none")] pub address_mode: Option, diff --git a/clients/rust/reqwest/v1/src/models/service_registration.rs b/clients/rust/reqwest/v1/src/models/service_registration.rs index 9f15a556..907aeff3 100644 --- a/clients/rust/reqwest/v1/src/models/service_registration.rs +++ b/clients/rust/reqwest/v1/src/models/service_registration.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct ServiceRegistration { #[serde(rename = "Address", skip_serializing_if = "Option::is_none")] pub address: Option, diff --git a/clients/rust/reqwest/v1/src/models/sidecar_task.rs b/clients/rust/reqwest/v1/src/models/sidecar_task.rs index 0bad40aa..58bf3a24 100644 --- a/clients/rust/reqwest/v1/src/models/sidecar_task.rs +++ b/clients/rust/reqwest/v1/src/models/sidecar_task.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct SidecarTask { #[serde(rename = "Config", skip_serializing_if = "Option::is_none")] pub config: Option<::std::collections::HashMap>, diff --git a/clients/rust/reqwest/v1/src/models/spread.rs b/clients/rust/reqwest/v1/src/models/spread.rs index 89ccc74a..63f3aade 100644 --- a/clients/rust/reqwest/v1/src/models/spread.rs +++ b/clients/rust/reqwest/v1/src/models/spread.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Spread { #[serde(rename = "Attribute", skip_serializing_if = "Option::is_none")] pub attribute: Option, diff --git a/clients/rust/reqwest/v1/src/models/spread_target.rs b/clients/rust/reqwest/v1/src/models/spread_target.rs index 68cb4597..de972446 100644 --- a/clients/rust/reqwest/v1/src/models/spread_target.rs +++ b/clients/rust/reqwest/v1/src/models/spread_target.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct SpreadTarget { #[serde(rename = "Percent", skip_serializing_if = "Option::is_none")] pub percent: Option, diff --git a/clients/rust/reqwest/v1/src/models/task.rs b/clients/rust/reqwest/v1/src/models/task.rs index f6f0f161..5e3d2c30 100644 --- a/clients/rust/reqwest/v1/src/models/task.rs +++ b/clients/rust/reqwest/v1/src/models/task.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Task { #[serde(rename = "Affinities", skip_serializing_if = "Option::is_none")] pub affinities: Option>, diff --git a/clients/rust/reqwest/v1/src/models/task_artifact.rs b/clients/rust/reqwest/v1/src/models/task_artifact.rs index 08809484..5e76d837 100644 --- a/clients/rust/reqwest/v1/src/models/task_artifact.rs +++ b/clients/rust/reqwest/v1/src/models/task_artifact.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct TaskArtifact { #[serde(rename = "GetterHeaders", skip_serializing_if = "Option::is_none")] pub getter_headers: Option<::std::collections::HashMap>, diff --git a/clients/rust/reqwest/v1/src/models/task_csi_plugin_config.rs b/clients/rust/reqwest/v1/src/models/task_csi_plugin_config.rs index 476ec727..62261cee 100644 --- a/clients/rust/reqwest/v1/src/models/task_csi_plugin_config.rs +++ b/clients/rust/reqwest/v1/src/models/task_csi_plugin_config.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct TaskCsiPluginConfig { #[serde(rename = "HealthTimeout", skip_serializing_if = "Option::is_none")] pub health_timeout: Option, diff --git a/clients/rust/reqwest/v1/src/models/task_diff.rs b/clients/rust/reqwest/v1/src/models/task_diff.rs index e07a72e6..fd002c91 100644 --- a/clients/rust/reqwest/v1/src/models/task_diff.rs +++ b/clients/rust/reqwest/v1/src/models/task_diff.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct TaskDiff { #[serde(rename = "Annotations", skip_serializing_if = "Option::is_none")] pub annotations: Option>, diff --git a/clients/rust/reqwest/v1/src/models/task_event.rs b/clients/rust/reqwest/v1/src/models/task_event.rs index d47309dd..4a165c38 100644 --- a/clients/rust/reqwest/v1/src/models/task_event.rs +++ b/clients/rust/reqwest/v1/src/models/task_event.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct TaskEvent { #[serde(rename = "Details", skip_serializing_if = "Option::is_none")] pub details: Option<::std::collections::HashMap>, diff --git a/clients/rust/reqwest/v1/src/models/task_group.rs b/clients/rust/reqwest/v1/src/models/task_group.rs index e13346e8..b7939a22 100644 --- a/clients/rust/reqwest/v1/src/models/task_group.rs +++ b/clients/rust/reqwest/v1/src/models/task_group.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct TaskGroup { #[serde(rename = "Affinities", skip_serializing_if = "Option::is_none")] pub affinities: Option>, diff --git a/clients/rust/reqwest/v1/src/models/task_group_diff.rs b/clients/rust/reqwest/v1/src/models/task_group_diff.rs index 8c4cd60f..7e4904e4 100644 --- a/clients/rust/reqwest/v1/src/models/task_group_diff.rs +++ b/clients/rust/reqwest/v1/src/models/task_group_diff.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct TaskGroupDiff { #[serde(rename = "Fields", skip_serializing_if = "Option::is_none")] pub fields: Option>, diff --git a/clients/rust/reqwest/v1/src/models/task_group_scale_status.rs b/clients/rust/reqwest/v1/src/models/task_group_scale_status.rs index 933ba155..68555593 100644 --- a/clients/rust/reqwest/v1/src/models/task_group_scale_status.rs +++ b/clients/rust/reqwest/v1/src/models/task_group_scale_status.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct TaskGroupScaleStatus { #[serde(rename = "Desired", skip_serializing_if = "Option::is_none")] pub desired: Option, diff --git a/clients/rust/reqwest/v1/src/models/task_group_summary.rs b/clients/rust/reqwest/v1/src/models/task_group_summary.rs index 2dc5a6d6..7350e3d9 100644 --- a/clients/rust/reqwest/v1/src/models/task_group_summary.rs +++ b/clients/rust/reqwest/v1/src/models/task_group_summary.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct TaskGroupSummary { #[serde(rename = "Complete", skip_serializing_if = "Option::is_none")] pub complete: Option, diff --git a/clients/rust/reqwest/v1/src/models/task_handle.rs b/clients/rust/reqwest/v1/src/models/task_handle.rs index 90dbf3d1..1df196eb 100644 --- a/clients/rust/reqwest/v1/src/models/task_handle.rs +++ b/clients/rust/reqwest/v1/src/models/task_handle.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct TaskHandle { #[serde(rename = "DriverState", skip_serializing_if = "Option::is_none")] pub driver_state: Option, diff --git a/clients/rust/reqwest/v1/src/models/task_lifecycle.rs b/clients/rust/reqwest/v1/src/models/task_lifecycle.rs index daa669fa..ec95a9f8 100644 --- a/clients/rust/reqwest/v1/src/models/task_lifecycle.rs +++ b/clients/rust/reqwest/v1/src/models/task_lifecycle.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct TaskLifecycle { #[serde(rename = "Hook", skip_serializing_if = "Option::is_none")] pub hook: Option, diff --git a/clients/rust/reqwest/v1/src/models/task_state.rs b/clients/rust/reqwest/v1/src/models/task_state.rs index 5143b7fd..be48aa0b 100644 --- a/clients/rust/reqwest/v1/src/models/task_state.rs +++ b/clients/rust/reqwest/v1/src/models/task_state.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct TaskState { #[serde(rename = "Events", skip_serializing_if = "Option::is_none")] pub events: Option>, diff --git a/clients/rust/reqwest/v1/src/models/template.rs b/clients/rust/reqwest/v1/src/models/template.rs index 37789b7c..10f842aa 100644 --- a/clients/rust/reqwest/v1/src/models/template.rs +++ b/clients/rust/reqwest/v1/src/models/template.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Template { #[serde(rename = "ChangeMode", skip_serializing_if = "Option::is_none")] pub change_mode: Option, diff --git a/clients/rust/reqwest/v1/src/models/update_strategy.rs b/clients/rust/reqwest/v1/src/models/update_strategy.rs index 7791201e..2966118a 100644 --- a/clients/rust/reqwest/v1/src/models/update_strategy.rs +++ b/clients/rust/reqwest/v1/src/models/update_strategy.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct UpdateStrategy { #[serde(rename = "AutoPromote", skip_serializing_if = "Option::is_none")] pub auto_promote: Option, diff --git a/clients/rust/reqwest/v1/src/models/vault.rs b/clients/rust/reqwest/v1/src/models/vault.rs index 74ede05d..780d4697 100644 --- a/clients/rust/reqwest/v1/src/models/vault.rs +++ b/clients/rust/reqwest/v1/src/models/vault.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct Vault { #[serde(rename = "ChangeMode", skip_serializing_if = "Option::is_none")] pub change_mode: Option, diff --git a/clients/rust/reqwest/v1/src/models/volume_mount.rs b/clients/rust/reqwest/v1/src/models/volume_mount.rs index e106c185..71132ecc 100644 --- a/clients/rust/reqwest/v1/src/models/volume_mount.rs +++ b/clients/rust/reqwest/v1/src/models/volume_mount.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct VolumeMount { #[serde(rename = "Destination", skip_serializing_if = "Option::is_none")] pub destination: Option, diff --git a/clients/rust/reqwest/v1/src/models/volume_request.rs b/clients/rust/reqwest/v1/src/models/volume_request.rs index fb8178fd..0c53df00 100644 --- a/clients/rust/reqwest/v1/src/models/volume_request.rs +++ b/clients/rust/reqwest/v1/src/models/volume_request.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct VolumeRequest { #[serde(rename = "AccessMode", skip_serializing_if = "Option::is_none")] pub access_mode: Option, diff --git a/clients/rust/reqwest/v1/src/models/wait_config.rs b/clients/rust/reqwest/v1/src/models/wait_config.rs index b11bfba4..ec763d88 100644 --- a/clients/rust/reqwest/v1/src/models/wait_config.rs +++ b/clients/rust/reqwest/v1/src/models/wait_config.rs @@ -11,7 +11,7 @@ -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)] pub struct WaitConfig { #[serde(rename = "Max", skip_serializing_if = "Option::is_none")] pub max: Option, diff --git a/clients/typescript/v1/.openapi-generator/FILES b/clients/typescript/v1/.openapi-generator/FILES index d4d4ecff..9e3accd2 100644 --- a/clients/typescript/v1/.openapi-generator/FILES +++ b/clients/typescript/v1/.openapi-generator/FILES @@ -1,5 +1,22 @@ .gitignore +ACLApi.md +AllocationsApi.md +DeploymentsApi.md +EnterpriseApi.md +EvaluationsApi.md +JobsApi.md +MetricsApi.md +NamespacesApi.md +NodesApi.md +OperatorApi.md +PluginsApi.md README.md +RegionsApi.md +ScalingApi.md +SearchApi.md +StatusApi.md +SystemApi.md +VolumesApi.md apis/ACLApi.ts apis/AllocationsApi.ts apis/DeploymentsApi.ts diff --git a/clients/typescript/v1/.openapi-generator/VERSION b/clients/typescript/v1/.openapi-generator/VERSION index 7cbea073..1e20ec35 100644 --- a/clients/typescript/v1/.openapi-generator/VERSION +++ b/clients/typescript/v1/.openapi-generator/VERSION @@ -1 +1 @@ -5.2.0 \ No newline at end of file +5.4.0 \ No newline at end of file diff --git a/clients/typescript/v1/ACLApi.md b/clients/typescript/v1/ACLApi.md new file mode 100644 index 00000000..f68b7286 --- /dev/null +++ b/clients/typescript/v1/ACLApi.md @@ -0,0 +1,935 @@ +# nomad-client.ACLApi + +All URIs are relative to *https://127.0.0.1:4646/v1* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**deleteACLPolicy**](ACLApi.md#deleteACLPolicy) | **DELETE** /acl/policy/{policyName} | +[**deleteACLToken**](ACLApi.md#deleteACLToken) | **DELETE** /acl/token/{tokenAccessor} | +[**getACLPolicies**](ACLApi.md#getACLPolicies) | **GET** /acl/policies | +[**getACLPolicy**](ACLApi.md#getACLPolicy) | **GET** /acl/policy/{policyName} | +[**getACLToken**](ACLApi.md#getACLToken) | **GET** /acl/token/{tokenAccessor} | +[**getACLTokenSelf**](ACLApi.md#getACLTokenSelf) | **GET** /acl/token | +[**getACLTokens**](ACLApi.md#getACLTokens) | **GET** /acl/tokens | +[**postACLBootstrap**](ACLApi.md#postACLBootstrap) | **POST** /acl/bootstrap | +[**postACLPolicy**](ACLApi.md#postACLPolicy) | **POST** /acl/policy/{policyName} | +[**postACLToken**](ACLApi.md#postACLToken) | **POST** /acl/token/{tokenAccessor} | +[**postACLTokenOnetime**](ACLApi.md#postACLTokenOnetime) | **POST** /acl/token/onetime | +[**postACLTokenOnetimeExchange**](ACLApi.md#postACLTokenOnetimeExchange) | **POST** /acl/token/onetime/exchange | + + +# **deleteACLPolicy** +> void deleteACLPolicy() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.ACLApi(configuration); + +let body:nomad-client.ACLApiDeleteACLPolicyRequest = { + // string | The ACL policy name. + policyName: "policyName_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.deleteACLPolicy(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policyName** | [**string**] | The ACL policy name. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**void** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: Not defined + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **deleteACLToken** +> void deleteACLToken() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.ACLApi(configuration); + +let body:nomad-client.ACLApiDeleteACLTokenRequest = { + // string | The token accessor ID. + tokenAccessor: "tokenAccessor_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.deleteACLToken(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **tokenAccessor** | [**string**] | The token accessor ID. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**void** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: Not defined + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getACLPolicies** +> Array getACLPolicies() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.ACLApi(configuration); + +let body:nomad-client.ACLApiGetACLPoliciesRequest = { + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getACLPolicies(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**Array** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getACLPolicy** +> ACLPolicy getACLPolicy() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.ACLApi(configuration); + +let body:nomad-client.ACLApiGetACLPolicyRequest = { + // string | The ACL policy name. + policyName: "policyName_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getACLPolicy(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policyName** | [**string**] | The ACL policy name. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**ACLPolicy** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getACLToken** +> ACLToken getACLToken() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.ACLApi(configuration); + +let body:nomad-client.ACLApiGetACLTokenRequest = { + // string | The token accessor ID. + tokenAccessor: "tokenAccessor_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getACLToken(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **tokenAccessor** | [**string**] | The token accessor ID. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**ACLToken** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getACLTokenSelf** +> ACLToken getACLTokenSelf() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.ACLApi(configuration); + +let body:nomad-client.ACLApiGetACLTokenSelfRequest = { + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getACLTokenSelf(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**ACLToken** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getACLTokens** +> Array getACLTokens() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.ACLApi(configuration); + +let body:nomad-client.ACLApiGetACLTokensRequest = { + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getACLTokens(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**Array** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **postACLBootstrap** +> ACLToken postACLBootstrap() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.ACLApi(configuration); + +let body:nomad-client.ACLApiPostACLBootstrapRequest = { + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.postACLBootstrap(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**ACLToken** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **postACLPolicy** +> void postACLPolicy(aCLPolicy) + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.ACLApi(configuration); + +let body:nomad-client.ACLApiPostACLPolicyRequest = { + // string | The ACL policy name. + policyName: "policyName_example", + // ACLPolicy + aCLPolicy: { + createIndex: 0, + description: "description_example", + modifyIndex: 0, + name: "name_example", + rules: "rules_example", + }, + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.postACLPolicy(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **aCLPolicy** | **ACLPolicy**| | + **policyName** | [**string**] | The ACL policy name. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**void** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: Not defined + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **postACLToken** +> ACLToken postACLToken(aCLToken) + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.ACLApi(configuration); + +let body:nomad-client.ACLApiPostACLTokenRequest = { + // string | The token accessor ID. + tokenAccessor: "tokenAccessor_example", + // ACLToken + aCLToken: { + accessorID: "accessorID_example", + createIndex: 0, + createTime: new Date('1970-01-01T00:00:00.00Z'), + global: true, + modifyIndex: 0, + name: "name_example", + policies: [ + "policies_example", + ], + secretID: "secretID_example", + type: "type_example", + }, + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.postACLToken(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **aCLToken** | **ACLToken**| | + **tokenAccessor** | [**string**] | The token accessor ID. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**ACLToken** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **postACLTokenOnetime** +> OneTimeToken postACLTokenOnetime() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.ACLApi(configuration); + +let body:nomad-client.ACLApiPostACLTokenOnetimeRequest = { + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.postACLTokenOnetime(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**OneTimeToken** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **postACLTokenOnetimeExchange** +> ACLToken postACLTokenOnetimeExchange(oneTimeTokenExchangeRequest) + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.ACLApi(configuration); + +let body:nomad-client.ACLApiPostACLTokenOnetimeExchangeRequest = { + // OneTimeTokenExchangeRequest + oneTimeTokenExchangeRequest: { + oneTimeSecretID: "oneTimeSecretID_example", + }, + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.postACLTokenOnetimeExchange(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **oneTimeTokenExchangeRequest** | **OneTimeTokenExchangeRequest**| | + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**ACLToken** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + + diff --git a/clients/typescript/v1/AllocationsApi.md b/clients/typescript/v1/AllocationsApi.md new file mode 100644 index 00000000..7bd143bf --- /dev/null +++ b/clients/typescript/v1/AllocationsApi.md @@ -0,0 +1,355 @@ +# nomad-client.AllocationsApi + +All URIs are relative to *https://127.0.0.1:4646/v1* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**getAllocation**](AllocationsApi.md#getAllocation) | **GET** /allocation/{allocID} | +[**getAllocationServices**](AllocationsApi.md#getAllocationServices) | **GET** /allocation/{allocID}/services | +[**getAllocations**](AllocationsApi.md#getAllocations) | **GET** /allocations | +[**postAllocationStop**](AllocationsApi.md#postAllocationStop) | **POST** /allocation/{allocID}/stop | + + +# **getAllocation** +> Allocation getAllocation() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.AllocationsApi(configuration); + +let body:nomad-client.AllocationsApiGetAllocationRequest = { + // string | Allocation ID. + allocID: "allocID_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getAllocation(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **allocID** | [**string**] | Allocation ID. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**Allocation** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getAllocationServices** +> Array getAllocationServices() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.AllocationsApi(configuration); + +let body:nomad-client.AllocationsApiGetAllocationServicesRequest = { + // string | Allocation ID. + allocID: "allocID_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getAllocationServices(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **allocID** | [**string**] | Allocation ID. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**Array** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getAllocations** +> Array getAllocations() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.AllocationsApi(configuration); + +let body:nomad-client.AllocationsApiGetAllocationsRequest = { + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", + // boolean | Flag indicating whether to include resources in response. (optional) + resources: true, + // boolean | Flag indicating whether to include task states in response. (optional) + taskStates: true, +}; + +apiInstance.getAllocations(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + **resources** | [**boolean**] | Flag indicating whether to include resources in response. | (optional) defaults to undefined + **taskStates** | [**boolean**] | Flag indicating whether to include task states in response. | (optional) defaults to undefined + + +### Return type + +**Array** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **postAllocationStop** +> AllocStopResponse postAllocationStop() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.AllocationsApi(configuration); + +let body:nomad-client.AllocationsApiPostAllocationStopRequest = { + // string | Allocation ID. + allocID: "allocID_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", + // boolean | Flag indicating whether to delay shutdown when requesting an allocation stop. (optional) + noShutdownDelay: true, +}; + +apiInstance.postAllocationStop(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **allocID** | [**string**] | Allocation ID. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + **noShutdownDelay** | [**boolean**] | Flag indicating whether to delay shutdown when requesting an allocation stop. | (optional) defaults to undefined + + +### Return type + +**AllocStopResponse** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + + diff --git a/clients/typescript/v1/DeploymentsApi.md b/clients/typescript/v1/DeploymentsApi.md new file mode 100644 index 00000000..d41d8687 --- /dev/null +++ b/clients/typescript/v1/DeploymentsApi.md @@ -0,0 +1,654 @@ +# nomad-client.DeploymentsApi + +All URIs are relative to *https://127.0.0.1:4646/v1* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**getDeployment**](DeploymentsApi.md#getDeployment) | **GET** /deployment/{deploymentID} | +[**getDeploymentAllocations**](DeploymentsApi.md#getDeploymentAllocations) | **GET** /deployment/allocations/{deploymentID} | +[**getDeployments**](DeploymentsApi.md#getDeployments) | **GET** /deployments | +[**postDeploymentAllocationHealth**](DeploymentsApi.md#postDeploymentAllocationHealth) | **POST** /deployment/allocation-health/{deploymentID} | +[**postDeploymentFail**](DeploymentsApi.md#postDeploymentFail) | **POST** /deployment/fail/{deploymentID} | +[**postDeploymentPause**](DeploymentsApi.md#postDeploymentPause) | **POST** /deployment/pause/{deploymentID} | +[**postDeploymentPromote**](DeploymentsApi.md#postDeploymentPromote) | **POST** /deployment/promote/{deploymentID} | +[**postDeploymentUnblock**](DeploymentsApi.md#postDeploymentUnblock) | **POST** /deployment/unblock/{deploymentID} | + + +# **getDeployment** +> Deployment getDeployment() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.DeploymentsApi(configuration); + +let body:nomad-client.DeploymentsApiGetDeploymentRequest = { + // string | Deployment ID. + deploymentID: "deploymentID_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getDeployment(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **deploymentID** | [**string**] | Deployment ID. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**Deployment** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getDeploymentAllocations** +> Array getDeploymentAllocations() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.DeploymentsApi(configuration); + +let body:nomad-client.DeploymentsApiGetDeploymentAllocationsRequest = { + // string | Deployment ID. + deploymentID: "deploymentID_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getDeploymentAllocations(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **deploymentID** | [**string**] | Deployment ID. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**Array** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getDeployments** +> Array getDeployments() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.DeploymentsApi(configuration); + +let body:nomad-client.DeploymentsApiGetDeploymentsRequest = { + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getDeployments(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**Array** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **postDeploymentAllocationHealth** +> DeploymentUpdateResponse postDeploymentAllocationHealth(deploymentAllocHealthRequest) + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.DeploymentsApi(configuration); + +let body:nomad-client.DeploymentsApiPostDeploymentAllocationHealthRequest = { + // string | Deployment ID. + deploymentID: "deploymentID_example", + // DeploymentAllocHealthRequest + deploymentAllocHealthRequest: { + deploymentID: "deploymentID_example", + healthyAllocationIDs: [ + "healthyAllocationIDs_example", + ], + namespace: "namespace_example", + region: "region_example", + secretID: "secretID_example", + unhealthyAllocationIDs: [ + "unhealthyAllocationIDs_example", + ], + }, + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.postDeploymentAllocationHealth(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **deploymentAllocHealthRequest** | **DeploymentAllocHealthRequest**| | + **deploymentID** | [**string**] | Deployment ID. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**DeploymentUpdateResponse** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **postDeploymentFail** +> DeploymentUpdateResponse postDeploymentFail() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.DeploymentsApi(configuration); + +let body:nomad-client.DeploymentsApiPostDeploymentFailRequest = { + // string | Deployment ID. + deploymentID: "deploymentID_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.postDeploymentFail(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **deploymentID** | [**string**] | Deployment ID. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**DeploymentUpdateResponse** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **postDeploymentPause** +> DeploymentUpdateResponse postDeploymentPause(deploymentPauseRequest) + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.DeploymentsApi(configuration); + +let body:nomad-client.DeploymentsApiPostDeploymentPauseRequest = { + // string | Deployment ID. + deploymentID: "deploymentID_example", + // DeploymentPauseRequest + deploymentPauseRequest: { + deploymentID: "deploymentID_example", + namespace: "namespace_example", + pause: true, + region: "region_example", + secretID: "secretID_example", + }, + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.postDeploymentPause(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **deploymentPauseRequest** | **DeploymentPauseRequest**| | + **deploymentID** | [**string**] | Deployment ID. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**DeploymentUpdateResponse** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **postDeploymentPromote** +> DeploymentUpdateResponse postDeploymentPromote(deploymentPromoteRequest) + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.DeploymentsApi(configuration); + +let body:nomad-client.DeploymentsApiPostDeploymentPromoteRequest = { + // string | Deployment ID. + deploymentID: "deploymentID_example", + // DeploymentPromoteRequest + deploymentPromoteRequest: { + all: true, + deploymentID: "deploymentID_example", + groups: [ + "groups_example", + ], + namespace: "namespace_example", + region: "region_example", + secretID: "secretID_example", + }, + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.postDeploymentPromote(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **deploymentPromoteRequest** | **DeploymentPromoteRequest**| | + **deploymentID** | [**string**] | Deployment ID. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**DeploymentUpdateResponse** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **postDeploymentUnblock** +> DeploymentUpdateResponse postDeploymentUnblock(deploymentUnblockRequest) + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.DeploymentsApi(configuration); + +let body:nomad-client.DeploymentsApiPostDeploymentUnblockRequest = { + // string | Deployment ID. + deploymentID: "deploymentID_example", + // DeploymentUnblockRequest + deploymentUnblockRequest: { + deploymentID: "deploymentID_example", + namespace: "namespace_example", + region: "region_example", + secretID: "secretID_example", + }, + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.postDeploymentUnblock(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **deploymentUnblockRequest** | **DeploymentUnblockRequest**| | + **deploymentID** | [**string**] | Deployment ID. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**DeploymentUpdateResponse** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + + diff --git a/clients/typescript/v1/EnterpriseApi.md b/clients/typescript/v1/EnterpriseApi.md new file mode 100644 index 00000000..bcda79dc --- /dev/null +++ b/clients/typescript/v1/EnterpriseApi.md @@ -0,0 +1,543 @@ +# nomad-client.EnterpriseApi + +All URIs are relative to *https://127.0.0.1:4646/v1* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**createQuotaSpec**](EnterpriseApi.md#createQuotaSpec) | **POST** /quota | +[**deleteQuotaSpec**](EnterpriseApi.md#deleteQuotaSpec) | **DELETE** /quota/{specName} | +[**getQuotaSpec**](EnterpriseApi.md#getQuotaSpec) | **GET** /quota/{specName} | +[**getQuotas**](EnterpriseApi.md#getQuotas) | **GET** /quotas | +[**postQuotaSpec**](EnterpriseApi.md#postQuotaSpec) | **POST** /quota/{specName} | + + +# **createQuotaSpec** +> void createQuotaSpec(quotaSpec) + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.EnterpriseApi(configuration); + +let body:nomad-client.EnterpriseApiCreateQuotaSpecRequest = { + // QuotaSpec + quotaSpec: { + createIndex: 0, + description: "description_example", + limits: [ + { + hash: 'YQ==', + region: "region_example", + regionLimit: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + }, + ], + modifyIndex: 0, + name: "name_example", + }, + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.createQuotaSpec(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **quotaSpec** | **QuotaSpec**| | + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**void** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: Not defined + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **deleteQuotaSpec** +> void deleteQuotaSpec() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.EnterpriseApi(configuration); + +let body:nomad-client.EnterpriseApiDeleteQuotaSpecRequest = { + // string | The quota spec identifier. + specName: "specName_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.deleteQuotaSpec(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **specName** | [**string**] | The quota spec identifier. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**void** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: Not defined + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getQuotaSpec** +> QuotaSpec getQuotaSpec() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.EnterpriseApi(configuration); + +let body:nomad-client.EnterpriseApiGetQuotaSpecRequest = { + // string | The quota spec identifier. + specName: "specName_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getQuotaSpec(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **specName** | [**string**] | The quota spec identifier. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**QuotaSpec** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getQuotas** +> Array getQuotas() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.EnterpriseApi(configuration); + +let body:nomad-client.EnterpriseApiGetQuotasRequest = { + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getQuotas(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**Array** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **postQuotaSpec** +> void postQuotaSpec(quotaSpec) + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.EnterpriseApi(configuration); + +let body:nomad-client.EnterpriseApiPostQuotaSpecRequest = { + // string | The quota spec identifier. + specName: "specName_example", + // QuotaSpec + quotaSpec: { + createIndex: 0, + description: "description_example", + limits: [ + { + hash: 'YQ==', + region: "region_example", + regionLimit: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + }, + ], + modifyIndex: 0, + name: "name_example", + }, + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.postQuotaSpec(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **quotaSpec** | **QuotaSpec**| | + **specName** | [**string**] | The quota spec identifier. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**void** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: Not defined + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + + diff --git a/clients/typescript/v1/EvaluationsApi.md b/clients/typescript/v1/EvaluationsApi.md new file mode 100644 index 00000000..3c68e388 --- /dev/null +++ b/clients/typescript/v1/EvaluationsApi.md @@ -0,0 +1,261 @@ +# nomad-client.EvaluationsApi + +All URIs are relative to *https://127.0.0.1:4646/v1* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**getEvaluation**](EvaluationsApi.md#getEvaluation) | **GET** /evaluation/{evalID} | +[**getEvaluationAllocations**](EvaluationsApi.md#getEvaluationAllocations) | **GET** /evaluation/{evalID}/allocations | +[**getEvaluations**](EvaluationsApi.md#getEvaluations) | **GET** /evaluations | + + +# **getEvaluation** +> Evaluation getEvaluation() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.EvaluationsApi(configuration); + +let body:nomad-client.EvaluationsApiGetEvaluationRequest = { + // string | Evaluation ID. + evalID: "evalID_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getEvaluation(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **evalID** | [**string**] | Evaluation ID. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**Evaluation** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getEvaluationAllocations** +> Array getEvaluationAllocations() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.EvaluationsApi(configuration); + +let body:nomad-client.EvaluationsApiGetEvaluationAllocationsRequest = { + // string | Evaluation ID. + evalID: "evalID_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getEvaluationAllocations(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **evalID** | [**string**] | Evaluation ID. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**Array** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getEvaluations** +> Array getEvaluations() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.EvaluationsApi(configuration); + +let body:nomad-client.EvaluationsApiGetEvaluationsRequest = { + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getEvaluations(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**Array** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + + diff --git a/clients/typescript/v1/JobsApi.md b/clients/typescript/v1/JobsApi.md new file mode 100644 index 00000000..161f69ad --- /dev/null +++ b/clients/typescript/v1/JobsApi.md @@ -0,0 +1,5547 @@ +# nomad-client.JobsApi + +All URIs are relative to *https://127.0.0.1:4646/v1* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**deleteJob**](JobsApi.md#deleteJob) | **DELETE** /job/{jobName} | +[**getJob**](JobsApi.md#getJob) | **GET** /job/{jobName} | +[**getJobAllocations**](JobsApi.md#getJobAllocations) | **GET** /job/{jobName}/allocations | +[**getJobDeployment**](JobsApi.md#getJobDeployment) | **GET** /job/{jobName}/deployment | +[**getJobDeployments**](JobsApi.md#getJobDeployments) | **GET** /job/{jobName}/deployments | +[**getJobEvaluations**](JobsApi.md#getJobEvaluations) | **GET** /job/{jobName}/evaluations | +[**getJobScaleStatus**](JobsApi.md#getJobScaleStatus) | **GET** /job/{jobName}/scale | +[**getJobSummary**](JobsApi.md#getJobSummary) | **GET** /job/{jobName}/summary | +[**getJobVersions**](JobsApi.md#getJobVersions) | **GET** /job/{jobName}/versions | +[**getJobs**](JobsApi.md#getJobs) | **GET** /jobs | +[**postJob**](JobsApi.md#postJob) | **POST** /job/{jobName} | +[**postJobDispatch**](JobsApi.md#postJobDispatch) | **POST** /job/{jobName}/dispatch | +[**postJobEvaluate**](JobsApi.md#postJobEvaluate) | **POST** /job/{jobName}/evaluate | +[**postJobParse**](JobsApi.md#postJobParse) | **POST** /jobs/parse | +[**postJobPeriodicForce**](JobsApi.md#postJobPeriodicForce) | **POST** /job/{jobName}/periodic/force | +[**postJobPlan**](JobsApi.md#postJobPlan) | **POST** /job/{jobName}/plan | +[**postJobRevert**](JobsApi.md#postJobRevert) | **POST** /job/{jobName}/revert | +[**postJobScalingRequest**](JobsApi.md#postJobScalingRequest) | **POST** /job/{jobName}/scale | +[**postJobStability**](JobsApi.md#postJobStability) | **POST** /job/{jobName}/stable | +[**postJobValidateRequest**](JobsApi.md#postJobValidateRequest) | **POST** /validate/job | +[**registerJob**](JobsApi.md#registerJob) | **POST** /jobs | + + +# **deleteJob** +> JobDeregisterResponse deleteJob() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.JobsApi(configuration); + +let body:nomad-client.JobsApiDeleteJobRequest = { + // string | The job identifier. + jobName: "jobName_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", + // boolean | Boolean flag indicating whether to purge allocations of the job after deleting. (optional) + purge: true, + // boolean | Boolean flag indicating whether the operation should apply to all instances of the job globally. (optional) + global: true, +}; + +apiInstance.deleteJob(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **jobName** | [**string**] | The job identifier. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + **purge** | [**boolean**] | Boolean flag indicating whether to purge allocations of the job after deleting. | (optional) defaults to undefined + **global** | [**boolean**] | Boolean flag indicating whether the operation should apply to all instances of the job globally. | (optional) defaults to undefined + + +### Return type + +**JobDeregisterResponse** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getJob** +> Job getJob() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.JobsApi(configuration); + +let body:nomad-client.JobsApiGetJobRequest = { + // string | The job identifier. + jobName: "jobName_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getJob(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **jobName** | [**string**] | The job identifier. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**Job** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getJobAllocations** +> Array getJobAllocations() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.JobsApi(configuration); + +let body:nomad-client.JobsApiGetJobAllocationsRequest = { + // string | The job identifier. + jobName: "jobName_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", + // boolean | Specifies whether the list of allocations should include allocations from a previously registered job with the same ID. This is possible if the job is deregistered and reregistered. (optional) + all: true, +}; + +apiInstance.getJobAllocations(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **jobName** | [**string**] | The job identifier. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + **all** | [**boolean**] | Specifies whether the list of allocations should include allocations from a previously registered job with the same ID. This is possible if the job is deregistered and reregistered. | (optional) defaults to undefined + + +### Return type + +**Array** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getJobDeployment** +> Deployment getJobDeployment() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.JobsApi(configuration); + +let body:nomad-client.JobsApiGetJobDeploymentRequest = { + // string | The job identifier. + jobName: "jobName_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getJobDeployment(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **jobName** | [**string**] | The job identifier. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**Deployment** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getJobDeployments** +> Array getJobDeployments() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.JobsApi(configuration); + +let body:nomad-client.JobsApiGetJobDeploymentsRequest = { + // string | The job identifier. + jobName: "jobName_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", + // number | Flag indicating whether to constrain by job creation index or not. (optional) + all: 1, +}; + +apiInstance.getJobDeployments(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **jobName** | [**string**] | The job identifier. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + **all** | [**number**] | Flag indicating whether to constrain by job creation index or not. | (optional) defaults to undefined + + +### Return type + +**Array** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getJobEvaluations** +> Array getJobEvaluations() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.JobsApi(configuration); + +let body:nomad-client.JobsApiGetJobEvaluationsRequest = { + // string | The job identifier. + jobName: "jobName_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getJobEvaluations(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **jobName** | [**string**] | The job identifier. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**Array** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getJobScaleStatus** +> JobScaleStatusResponse getJobScaleStatus() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.JobsApi(configuration); + +let body:nomad-client.JobsApiGetJobScaleStatusRequest = { + // string | The job identifier. + jobName: "jobName_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getJobScaleStatus(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **jobName** | [**string**] | The job identifier. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**JobScaleStatusResponse** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getJobSummary** +> JobSummary getJobSummary() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.JobsApi(configuration); + +let body:nomad-client.JobsApiGetJobSummaryRequest = { + // string | The job identifier. + jobName: "jobName_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getJobSummary(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **jobName** | [**string**] | The job identifier. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**JobSummary** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getJobVersions** +> JobVersionsResponse getJobVersions() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.JobsApi(configuration); + +let body:nomad-client.JobsApiGetJobVersionsRequest = { + // string | The job identifier. + jobName: "jobName_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", + // boolean | Boolean flag indicating whether to compute job diffs. (optional) + diffs: true, +}; + +apiInstance.getJobVersions(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **jobName** | [**string**] | The job identifier. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + **diffs** | [**boolean**] | Boolean flag indicating whether to compute job diffs. | (optional) defaults to undefined + + +### Return type + +**JobVersionsResponse** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getJobs** +> Array getJobs() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.JobsApi(configuration); + +let body:nomad-client.JobsApiGetJobsRequest = { + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getJobs(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**Array** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **postJob** +> JobRegisterResponse postJob(jobRegisterRequest) + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.JobsApi(configuration); + +let body:nomad-client.JobsApiPostJobRequest = { + // string | The job identifier. + jobName: "jobName_example", + // JobRegisterRequest + jobRegisterRequest: { + enforceIndex: true, + evalPriority: 1, + job: { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + allAtOnce: true, + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + consulNamespace: "consulNamespace_example", + consulToken: "consulToken_example", + createIndex: 0, + datacenters: [ + "datacenters_example", + ], + dispatchIdempotencyToken: "dispatchIdempotencyToken_example", + dispatched: true, + ID: "ID_example", + jobModifyIndex: 0, + meta: { + "key": "key_example", + }, + migrate: { + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + }, + modifyIndex: 0, + multiregion: { + regions: [ + { + count: 1, + datacenters: [ + "datacenters_example", + ], + meta: { + "key": "key_example", + }, + name: "name_example", + }, + ], + strategy: { + maxParallel: 1, + onFailure: "onFailure_example", + }, + }, + name: "name_example", + namespace: "namespace_example", + nomadTokenID: "nomadTokenID_example", + parameterizedJob: { + metaOptional: [ + "metaOptional_example", + ], + metaRequired: [ + "metaRequired_example", + ], + payload: "payload_example", + }, + parentID: "parentID_example", + payload: 'YQ==', + periodic: { + enabled: true, + prohibitOverlap: true, + spec: "spec_example", + specType: "specType_example", + timeZone: "timeZone_example", + }, + priority: 1, + region: "region_example", + reschedule: { + attempts: 1, + delay: 1, + delayFunction: "delayFunction_example", + interval: 1, + maxDelay: 1, + unlimited: true, + }, + spreads: [ + { + attribute: "attribute_example", + spreadTarget: [ + { + percent: 0, + value: "value_example", + }, + ], + weight: -128, + }, + ], + stable: true, + status: "status_example", + statusDescription: "statusDescription_example", + stop: true, + submitTime: 1, + taskGroups: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + consul: { + namespace: "namespace_example", + }, + count: 1, + ephemeralDisk: { + migrate: true, + sizeMB: 1, + sticky: true, + }, + maxClientDisconnect: 1, + meta: { + "key": "key_example", + }, + migrate: { + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + }, + name: "name_example", + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + reschedulePolicy: { + attempts: 1, + delay: 1, + delayFunction: "delayFunction_example", + interval: 1, + maxDelay: 1, + unlimited: true, + }, + restartPolicy: { + attempts: 1, + delay: 1, + interval: 1, + mode: "mode_example", + }, + scaling: { + createIndex: 0, + enabled: true, + ID: "ID_example", + max: 1, + min: 1, + modifyIndex: 0, + namespace: "namespace_example", + policy: { + "key": null, + }, + target: { + "key": "key_example", + }, + type: "type_example", + }, + services: [ + { + address: "address_example", + addressMode: "addressMode_example", + canaryMeta: { + "key": "key_example", + }, + canaryTags: [ + "canaryTags_example", + ], + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + checks: [ + { + addressMode: "addressMode_example", + advertise: "advertise_example", + args: [ + "args_example", + ], + body: "body_example", + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + command: "command_example", + expose: true, + failuresBeforeCritical: 1, + gRPCService: "gRPCService_example", + gRPCUseTLS: true, + header: { + "key": [ + "key_example", + ], + }, + initialStatus: "initialStatus_example", + interval: 1, + method: "method_example", + name: "name_example", + onUpdate: "onUpdate_example", + path: "path_example", + portLabel: "portLabel_example", + protocol: "protocol_example", + successBeforePassing: 1, + tLSSkipVerify: true, + taskName: "taskName_example", + timeout: 1, + type: "type_example", + }, + ], + connect: { + gateway: { + ingress: { + listeners: [ + { + port: 1, + protocol: "protocol_example", + services: [ + { + hosts: [ + "hosts_example", + ], + name: "name_example", + }, + ], + }, + ], + TLS: { + cipherSuites: [ + "cipherSuites_example", + ], + enabled: true, + tLSMaxVersion: "tLSMaxVersion_example", + tLSMinVersion: "tLSMinVersion_example", + }, + }, + mesh: null, + proxy: { + config: { + "key": null, + }, + connectTimeout: 1, + envoyDNSDiscoveryType: "envoyDNSDiscoveryType_example", + envoyGatewayBindAddresses: { + "key": { + address: "address_example", + name: "name_example", + port: 1, + }, + }, + envoyGatewayBindTaggedAddresses: true, + envoyGatewayNoDefaultBind: true, + }, + terminating: { + services: [ + { + cAFile: "cAFile_example", + certFile: "certFile_example", + keyFile: "keyFile_example", + name: "name_example", + SNI: "SNI_example", + }, + ], + }, + }, + _native: true, + sidecarService: { + disableDefaultTCPCheck: true, + port: "port_example", + proxy: { + config: { + "key": null, + }, + exposeConfig: { + path: [ + { + listenerPort: "listenerPort_example", + localPathPort: 1, + path: "path_example", + protocol: "protocol_example", + }, + ], + }, + localServiceAddress: "localServiceAddress_example", + localServicePort: 1, + upstreams: [ + { + datacenter: "datacenter_example", + destinationName: "destinationName_example", + destinationNamespace: "destinationNamespace_example", + localBindAddress: "localBindAddress_example", + localBindPort: 1, + meshGateway: { + mode: "mode_example", + }, + }, + ], + }, + tags: [ + "tags_example", + ], + }, + sidecarTask: { + config: { + "key": null, + }, + driver: "driver_example", + env: { + "key": "key_example", + }, + killSignal: "killSignal_example", + killTimeout: 1, + logConfig: { + maxFileSizeMB: 1, + maxFiles: 1, + }, + meta: { + "key": "key_example", + }, + name: "name_example", + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + shutdownDelay: 1, + user: "user_example", + }, + }, + enableTagOverride: true, + meta: { + "key": "key_example", + }, + name: "name_example", + onUpdate: "onUpdate_example", + portLabel: "portLabel_example", + provider: "provider_example", + taggedAddresses: { + "key": "key_example", + }, + tags: [ + "tags_example", + ], + taskName: "taskName_example", + }, + ], + shutdownDelay: 1, + spreads: [ + { + attribute: "attribute_example", + spreadTarget: [ + { + percent: 0, + value: "value_example", + }, + ], + weight: -128, + }, + ], + stopAfterClientDisconnect: 1, + tasks: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + artifacts: [ + { + getterHeaders: { + "key": "key_example", + }, + getterMode: "getterMode_example", + getterOptions: { + "key": "key_example", + }, + getterSource: "getterSource_example", + relativeDest: "relativeDest_example", + }, + ], + cSIPluginConfig: { + healthTimeout: 1, + ID: "ID_example", + mountDir: "mountDir_example", + type: "type_example", + }, + config: { + "key": null, + }, + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + dispatchPayload: { + file: "file_example", + }, + driver: "driver_example", + env: { + "key": "key_example", + }, + killSignal: "killSignal_example", + killTimeout: 1, + kind: "kind_example", + leader: true, + lifecycle: { + hook: "hook_example", + sidecar: true, + }, + logConfig: { + maxFileSizeMB: 1, + maxFiles: 1, + }, + meta: { + "key": "key_example", + }, + name: "name_example", + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + restartPolicy: { + attempts: 1, + delay: 1, + interval: 1, + mode: "mode_example", + }, + scalingPolicies: [ + { + createIndex: 0, + enabled: true, + ID: "ID_example", + max: 1, + min: 1, + modifyIndex: 0, + namespace: "namespace_example", + policy: { + "key": null, + }, + target: { + "key": "key_example", + }, + type: "type_example", + }, + ], + services: [ + { + address: "address_example", + addressMode: "addressMode_example", + canaryMeta: { + "key": "key_example", + }, + canaryTags: [ + "canaryTags_example", + ], + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + checks: [ + { + addressMode: "addressMode_example", + advertise: "advertise_example", + args: [ + "args_example", + ], + body: "body_example", + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + command: "command_example", + expose: true, + failuresBeforeCritical: 1, + gRPCService: "gRPCService_example", + gRPCUseTLS: true, + header: { + "key": [ + "key_example", + ], + }, + initialStatus: "initialStatus_example", + interval: 1, + method: "method_example", + name: "name_example", + onUpdate: "onUpdate_example", + path: "path_example", + portLabel: "portLabel_example", + protocol: "protocol_example", + successBeforePassing: 1, + tLSSkipVerify: true, + taskName: "taskName_example", + timeout: 1, + type: "type_example", + }, + ], + connect: { + gateway: { + ingress: { + listeners: [ + { + port: 1, + protocol: "protocol_example", + services: [ + { + hosts: [ + "hosts_example", + ], + name: "name_example", + }, + ], + }, + ], + TLS: { + cipherSuites: [ + "cipherSuites_example", + ], + enabled: true, + tLSMaxVersion: "tLSMaxVersion_example", + tLSMinVersion: "tLSMinVersion_example", + }, + }, + mesh: null, + proxy: { + config: { + "key": null, + }, + connectTimeout: 1, + envoyDNSDiscoveryType: "envoyDNSDiscoveryType_example", + envoyGatewayBindAddresses: { + "key": { + address: "address_example", + name: "name_example", + port: 1, + }, + }, + envoyGatewayBindTaggedAddresses: true, + envoyGatewayNoDefaultBind: true, + }, + terminating: { + services: [ + { + cAFile: "cAFile_example", + certFile: "certFile_example", + keyFile: "keyFile_example", + name: "name_example", + SNI: "SNI_example", + }, + ], + }, + }, + _native: true, + sidecarService: { + disableDefaultTCPCheck: true, + port: "port_example", + proxy: { + config: { + "key": null, + }, + exposeConfig: { + path: [ + { + listenerPort: "listenerPort_example", + localPathPort: 1, + path: "path_example", + protocol: "protocol_example", + }, + ], + }, + localServiceAddress: "localServiceAddress_example", + localServicePort: 1, + upstreams: [ + { + datacenter: "datacenter_example", + destinationName: "destinationName_example", + destinationNamespace: "destinationNamespace_example", + localBindAddress: "localBindAddress_example", + localBindPort: 1, + meshGateway: { + mode: "mode_example", + }, + }, + ], + }, + tags: [ + "tags_example", + ], + }, + sidecarTask: { + config: { + "key": null, + }, + driver: "driver_example", + env: { + "key": "key_example", + }, + killSignal: "killSignal_example", + killTimeout: 1, + logConfig: { + maxFileSizeMB: 1, + maxFiles: 1, + }, + meta: { + "key": "key_example", + }, + name: "name_example", + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + shutdownDelay: 1, + user: "user_example", + }, + }, + enableTagOverride: true, + meta: { + "key": "key_example", + }, + name: "name_example", + onUpdate: "onUpdate_example", + portLabel: "portLabel_example", + provider: "provider_example", + taggedAddresses: { + "key": "key_example", + }, + tags: [ + "tags_example", + ], + taskName: "taskName_example", + }, + ], + shutdownDelay: 1, + templates: [ + { + changeMode: "changeMode_example", + changeSignal: "changeSignal_example", + destPath: "destPath_example", + embeddedTmpl: "embeddedTmpl_example", + envvars: true, + leftDelim: "leftDelim_example", + perms: "perms_example", + rightDelim: "rightDelim_example", + sourcePath: "sourcePath_example", + splay: 1, + vaultGrace: 1, + wait: { + max: 1, + min: 1, + }, + }, + ], + user: "user_example", + vault: { + changeMode: "changeMode_example", + changeSignal: "changeSignal_example", + env: true, + namespace: "namespace_example", + policies: [ + "policies_example", + ], + }, + volumeMounts: [ + { + destination: "destination_example", + propagationMode: "propagationMode_example", + readOnly: true, + volume: "volume_example", + }, + ], + }, + ], + update: { + autoPromote: true, + autoRevert: true, + canary: 1, + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + progressDeadline: 1, + stagger: 1, + }, + volumes: { + "key": { + accessMode: "accessMode_example", + attachmentMode: "attachmentMode_example", + mountOptions: { + fSType: "fSType_example", + mountFlags: [ + "mountFlags_example", + ], + }, + name: "name_example", + perAlloc: true, + readOnly: true, + source: "source_example", + type: "type_example", + }, + }, + }, + ], + type: "type_example", + update: { + autoPromote: true, + autoRevert: true, + canary: 1, + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + progressDeadline: 1, + stagger: 1, + }, + vaultNamespace: "vaultNamespace_example", + vaultToken: "vaultToken_example", + version: 0, + }, + jobModifyIndex: 0, + namespace: "namespace_example", + policyOverride: true, + preserveCounts: true, + region: "region_example", + secretID: "secretID_example", + }, + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.postJob(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **jobRegisterRequest** | **JobRegisterRequest**| | + **jobName** | [**string**] | The job identifier. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**JobRegisterResponse** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **postJobDispatch** +> JobDispatchResponse postJobDispatch(jobDispatchRequest) + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.JobsApi(configuration); + +let body:nomad-client.JobsApiPostJobDispatchRequest = { + // string | The job identifier. + jobName: "jobName_example", + // JobDispatchRequest + jobDispatchRequest: { + jobID: "jobID_example", + meta: { + "key": "key_example", + }, + payload: 'YQ==', + }, + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.postJobDispatch(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **jobDispatchRequest** | **JobDispatchRequest**| | + **jobName** | [**string**] | The job identifier. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**JobDispatchResponse** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **postJobEvaluate** +> JobRegisterResponse postJobEvaluate(jobEvaluateRequest) + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.JobsApi(configuration); + +let body:nomad-client.JobsApiPostJobEvaluateRequest = { + // string | The job identifier. + jobName: "jobName_example", + // JobEvaluateRequest + jobEvaluateRequest: { + evalOptions: { + forceReschedule: true, + }, + jobID: "jobID_example", + namespace: "namespace_example", + region: "region_example", + secretID: "secretID_example", + }, + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.postJobEvaluate(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **jobEvaluateRequest** | **JobEvaluateRequest**| | + **jobName** | [**string**] | The job identifier. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**JobRegisterResponse** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **postJobParse** +> Job postJobParse(jobsParseRequest) + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.JobsApi(configuration); + +let body:nomad-client.JobsApiPostJobParseRequest = { + // JobsParseRequest + jobsParseRequest: { + canonicalize: true, + jobHCL: "jobHCL_example", + hclv1: true, + }, +}; + +apiInstance.postJobParse(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **jobsParseRequest** | **JobsParseRequest**| | + + +### Return type + +**Job** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **postJobPeriodicForce** +> PeriodicForceResponse postJobPeriodicForce() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.JobsApi(configuration); + +let body:nomad-client.JobsApiPostJobPeriodicForceRequest = { + // string | The job identifier. + jobName: "jobName_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.postJobPeriodicForce(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **jobName** | [**string**] | The job identifier. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**PeriodicForceResponse** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **postJobPlan** +> JobPlanResponse postJobPlan(jobPlanRequest) + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.JobsApi(configuration); + +let body:nomad-client.JobsApiPostJobPlanRequest = { + // string | The job identifier. + jobName: "jobName_example", + // JobPlanRequest + jobPlanRequest: { + diff: true, + job: { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + allAtOnce: true, + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + consulNamespace: "consulNamespace_example", + consulToken: "consulToken_example", + createIndex: 0, + datacenters: [ + "datacenters_example", + ], + dispatchIdempotencyToken: "dispatchIdempotencyToken_example", + dispatched: true, + ID: "ID_example", + jobModifyIndex: 0, + meta: { + "key": "key_example", + }, + migrate: { + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + }, + modifyIndex: 0, + multiregion: { + regions: [ + { + count: 1, + datacenters: [ + "datacenters_example", + ], + meta: { + "key": "key_example", + }, + name: "name_example", + }, + ], + strategy: { + maxParallel: 1, + onFailure: "onFailure_example", + }, + }, + name: "name_example", + namespace: "namespace_example", + nomadTokenID: "nomadTokenID_example", + parameterizedJob: { + metaOptional: [ + "metaOptional_example", + ], + metaRequired: [ + "metaRequired_example", + ], + payload: "payload_example", + }, + parentID: "parentID_example", + payload: 'YQ==', + periodic: { + enabled: true, + prohibitOverlap: true, + spec: "spec_example", + specType: "specType_example", + timeZone: "timeZone_example", + }, + priority: 1, + region: "region_example", + reschedule: { + attempts: 1, + delay: 1, + delayFunction: "delayFunction_example", + interval: 1, + maxDelay: 1, + unlimited: true, + }, + spreads: [ + { + attribute: "attribute_example", + spreadTarget: [ + { + percent: 0, + value: "value_example", + }, + ], + weight: -128, + }, + ], + stable: true, + status: "status_example", + statusDescription: "statusDescription_example", + stop: true, + submitTime: 1, + taskGroups: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + consul: { + namespace: "namespace_example", + }, + count: 1, + ephemeralDisk: { + migrate: true, + sizeMB: 1, + sticky: true, + }, + maxClientDisconnect: 1, + meta: { + "key": "key_example", + }, + migrate: { + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + }, + name: "name_example", + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + reschedulePolicy: { + attempts: 1, + delay: 1, + delayFunction: "delayFunction_example", + interval: 1, + maxDelay: 1, + unlimited: true, + }, + restartPolicy: { + attempts: 1, + delay: 1, + interval: 1, + mode: "mode_example", + }, + scaling: { + createIndex: 0, + enabled: true, + ID: "ID_example", + max: 1, + min: 1, + modifyIndex: 0, + namespace: "namespace_example", + policy: { + "key": null, + }, + target: { + "key": "key_example", + }, + type: "type_example", + }, + services: [ + { + address: "address_example", + addressMode: "addressMode_example", + canaryMeta: { + "key": "key_example", + }, + canaryTags: [ + "canaryTags_example", + ], + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + checks: [ + { + addressMode: "addressMode_example", + advertise: "advertise_example", + args: [ + "args_example", + ], + body: "body_example", + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + command: "command_example", + expose: true, + failuresBeforeCritical: 1, + gRPCService: "gRPCService_example", + gRPCUseTLS: true, + header: { + "key": [ + "key_example", + ], + }, + initialStatus: "initialStatus_example", + interval: 1, + method: "method_example", + name: "name_example", + onUpdate: "onUpdate_example", + path: "path_example", + portLabel: "portLabel_example", + protocol: "protocol_example", + successBeforePassing: 1, + tLSSkipVerify: true, + taskName: "taskName_example", + timeout: 1, + type: "type_example", + }, + ], + connect: { + gateway: { + ingress: { + listeners: [ + { + port: 1, + protocol: "protocol_example", + services: [ + { + hosts: [ + "hosts_example", + ], + name: "name_example", + }, + ], + }, + ], + TLS: { + cipherSuites: [ + "cipherSuites_example", + ], + enabled: true, + tLSMaxVersion: "tLSMaxVersion_example", + tLSMinVersion: "tLSMinVersion_example", + }, + }, + mesh: null, + proxy: { + config: { + "key": null, + }, + connectTimeout: 1, + envoyDNSDiscoveryType: "envoyDNSDiscoveryType_example", + envoyGatewayBindAddresses: { + "key": { + address: "address_example", + name: "name_example", + port: 1, + }, + }, + envoyGatewayBindTaggedAddresses: true, + envoyGatewayNoDefaultBind: true, + }, + terminating: { + services: [ + { + cAFile: "cAFile_example", + certFile: "certFile_example", + keyFile: "keyFile_example", + name: "name_example", + SNI: "SNI_example", + }, + ], + }, + }, + _native: true, + sidecarService: { + disableDefaultTCPCheck: true, + port: "port_example", + proxy: { + config: { + "key": null, + }, + exposeConfig: { + path: [ + { + listenerPort: "listenerPort_example", + localPathPort: 1, + path: "path_example", + protocol: "protocol_example", + }, + ], + }, + localServiceAddress: "localServiceAddress_example", + localServicePort: 1, + upstreams: [ + { + datacenter: "datacenter_example", + destinationName: "destinationName_example", + destinationNamespace: "destinationNamespace_example", + localBindAddress: "localBindAddress_example", + localBindPort: 1, + meshGateway: { + mode: "mode_example", + }, + }, + ], + }, + tags: [ + "tags_example", + ], + }, + sidecarTask: { + config: { + "key": null, + }, + driver: "driver_example", + env: { + "key": "key_example", + }, + killSignal: "killSignal_example", + killTimeout: 1, + logConfig: { + maxFileSizeMB: 1, + maxFiles: 1, + }, + meta: { + "key": "key_example", + }, + name: "name_example", + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + shutdownDelay: 1, + user: "user_example", + }, + }, + enableTagOverride: true, + meta: { + "key": "key_example", + }, + name: "name_example", + onUpdate: "onUpdate_example", + portLabel: "portLabel_example", + provider: "provider_example", + taggedAddresses: { + "key": "key_example", + }, + tags: [ + "tags_example", + ], + taskName: "taskName_example", + }, + ], + shutdownDelay: 1, + spreads: [ + { + attribute: "attribute_example", + spreadTarget: [ + { + percent: 0, + value: "value_example", + }, + ], + weight: -128, + }, + ], + stopAfterClientDisconnect: 1, + tasks: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + artifacts: [ + { + getterHeaders: { + "key": "key_example", + }, + getterMode: "getterMode_example", + getterOptions: { + "key": "key_example", + }, + getterSource: "getterSource_example", + relativeDest: "relativeDest_example", + }, + ], + cSIPluginConfig: { + healthTimeout: 1, + ID: "ID_example", + mountDir: "mountDir_example", + type: "type_example", + }, + config: { + "key": null, + }, + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + dispatchPayload: { + file: "file_example", + }, + driver: "driver_example", + env: { + "key": "key_example", + }, + killSignal: "killSignal_example", + killTimeout: 1, + kind: "kind_example", + leader: true, + lifecycle: { + hook: "hook_example", + sidecar: true, + }, + logConfig: { + maxFileSizeMB: 1, + maxFiles: 1, + }, + meta: { + "key": "key_example", + }, + name: "name_example", + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + restartPolicy: { + attempts: 1, + delay: 1, + interval: 1, + mode: "mode_example", + }, + scalingPolicies: [ + { + createIndex: 0, + enabled: true, + ID: "ID_example", + max: 1, + min: 1, + modifyIndex: 0, + namespace: "namespace_example", + policy: { + "key": null, + }, + target: { + "key": "key_example", + }, + type: "type_example", + }, + ], + services: [ + { + address: "address_example", + addressMode: "addressMode_example", + canaryMeta: { + "key": "key_example", + }, + canaryTags: [ + "canaryTags_example", + ], + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + checks: [ + { + addressMode: "addressMode_example", + advertise: "advertise_example", + args: [ + "args_example", + ], + body: "body_example", + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + command: "command_example", + expose: true, + failuresBeforeCritical: 1, + gRPCService: "gRPCService_example", + gRPCUseTLS: true, + header: { + "key": [ + "key_example", + ], + }, + initialStatus: "initialStatus_example", + interval: 1, + method: "method_example", + name: "name_example", + onUpdate: "onUpdate_example", + path: "path_example", + portLabel: "portLabel_example", + protocol: "protocol_example", + successBeforePassing: 1, + tLSSkipVerify: true, + taskName: "taskName_example", + timeout: 1, + type: "type_example", + }, + ], + connect: { + gateway: { + ingress: { + listeners: [ + { + port: 1, + protocol: "protocol_example", + services: [ + { + hosts: [ + "hosts_example", + ], + name: "name_example", + }, + ], + }, + ], + TLS: { + cipherSuites: [ + "cipherSuites_example", + ], + enabled: true, + tLSMaxVersion: "tLSMaxVersion_example", + tLSMinVersion: "tLSMinVersion_example", + }, + }, + mesh: null, + proxy: { + config: { + "key": null, + }, + connectTimeout: 1, + envoyDNSDiscoveryType: "envoyDNSDiscoveryType_example", + envoyGatewayBindAddresses: { + "key": { + address: "address_example", + name: "name_example", + port: 1, + }, + }, + envoyGatewayBindTaggedAddresses: true, + envoyGatewayNoDefaultBind: true, + }, + terminating: { + services: [ + { + cAFile: "cAFile_example", + certFile: "certFile_example", + keyFile: "keyFile_example", + name: "name_example", + SNI: "SNI_example", + }, + ], + }, + }, + _native: true, + sidecarService: { + disableDefaultTCPCheck: true, + port: "port_example", + proxy: { + config: { + "key": null, + }, + exposeConfig: { + path: [ + { + listenerPort: "listenerPort_example", + localPathPort: 1, + path: "path_example", + protocol: "protocol_example", + }, + ], + }, + localServiceAddress: "localServiceAddress_example", + localServicePort: 1, + upstreams: [ + { + datacenter: "datacenter_example", + destinationName: "destinationName_example", + destinationNamespace: "destinationNamespace_example", + localBindAddress: "localBindAddress_example", + localBindPort: 1, + meshGateway: { + mode: "mode_example", + }, + }, + ], + }, + tags: [ + "tags_example", + ], + }, + sidecarTask: { + config: { + "key": null, + }, + driver: "driver_example", + env: { + "key": "key_example", + }, + killSignal: "killSignal_example", + killTimeout: 1, + logConfig: { + maxFileSizeMB: 1, + maxFiles: 1, + }, + meta: { + "key": "key_example", + }, + name: "name_example", + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + shutdownDelay: 1, + user: "user_example", + }, + }, + enableTagOverride: true, + meta: { + "key": "key_example", + }, + name: "name_example", + onUpdate: "onUpdate_example", + portLabel: "portLabel_example", + provider: "provider_example", + taggedAddresses: { + "key": "key_example", + }, + tags: [ + "tags_example", + ], + taskName: "taskName_example", + }, + ], + shutdownDelay: 1, + templates: [ + { + changeMode: "changeMode_example", + changeSignal: "changeSignal_example", + destPath: "destPath_example", + embeddedTmpl: "embeddedTmpl_example", + envvars: true, + leftDelim: "leftDelim_example", + perms: "perms_example", + rightDelim: "rightDelim_example", + sourcePath: "sourcePath_example", + splay: 1, + vaultGrace: 1, + wait: { + max: 1, + min: 1, + }, + }, + ], + user: "user_example", + vault: { + changeMode: "changeMode_example", + changeSignal: "changeSignal_example", + env: true, + namespace: "namespace_example", + policies: [ + "policies_example", + ], + }, + volumeMounts: [ + { + destination: "destination_example", + propagationMode: "propagationMode_example", + readOnly: true, + volume: "volume_example", + }, + ], + }, + ], + update: { + autoPromote: true, + autoRevert: true, + canary: 1, + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + progressDeadline: 1, + stagger: 1, + }, + volumes: { + "key": { + accessMode: "accessMode_example", + attachmentMode: "attachmentMode_example", + mountOptions: { + fSType: "fSType_example", + mountFlags: [ + "mountFlags_example", + ], + }, + name: "name_example", + perAlloc: true, + readOnly: true, + source: "source_example", + type: "type_example", + }, + }, + }, + ], + type: "type_example", + update: { + autoPromote: true, + autoRevert: true, + canary: 1, + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + progressDeadline: 1, + stagger: 1, + }, + vaultNamespace: "vaultNamespace_example", + vaultToken: "vaultToken_example", + version: 0, + }, + namespace: "namespace_example", + policyOverride: true, + region: "region_example", + secretID: "secretID_example", + }, + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.postJobPlan(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **jobPlanRequest** | **JobPlanRequest**| | + **jobName** | [**string**] | The job identifier. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**JobPlanResponse** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **postJobRevert** +> JobRegisterResponse postJobRevert(jobRevertRequest) + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.JobsApi(configuration); + +let body:nomad-client.JobsApiPostJobRevertRequest = { + // string | The job identifier. + jobName: "jobName_example", + // JobRevertRequest + jobRevertRequest: { + consulToken: "consulToken_example", + enforcePriorVersion: 0, + jobID: "jobID_example", + jobVersion: 0, + namespace: "namespace_example", + region: "region_example", + secretID: "secretID_example", + vaultToken: "vaultToken_example", + }, + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.postJobRevert(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **jobRevertRequest** | **JobRevertRequest**| | + **jobName** | [**string**] | The job identifier. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**JobRegisterResponse** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **postJobScalingRequest** +> JobRegisterResponse postJobScalingRequest(scalingRequest) + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.JobsApi(configuration); + +let body:nomad-client.JobsApiPostJobScalingRequestRequest = { + // string | The job identifier. + jobName: "jobName_example", + // ScalingRequest + scalingRequest: { + count: 1, + error: true, + message: "message_example", + meta: { + "key": null, + }, + namespace: "namespace_example", + policyOverride: true, + region: "region_example", + secretID: "secretID_example", + target: { + "key": "key_example", + }, + }, + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.postJobScalingRequest(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **scalingRequest** | **ScalingRequest**| | + **jobName** | [**string**] | The job identifier. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**JobRegisterResponse** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **postJobStability** +> JobStabilityResponse postJobStability(jobStabilityRequest) + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.JobsApi(configuration); + +let body:nomad-client.JobsApiPostJobStabilityRequest = { + // string | The job identifier. + jobName: "jobName_example", + // JobStabilityRequest + jobStabilityRequest: { + jobID: "jobID_example", + jobVersion: 0, + namespace: "namespace_example", + region: "region_example", + secretID: "secretID_example", + stable: true, + }, + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.postJobStability(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **jobStabilityRequest** | **JobStabilityRequest**| | + **jobName** | [**string**] | The job identifier. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**JobStabilityResponse** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **postJobValidateRequest** +> JobValidateResponse postJobValidateRequest(jobValidateRequest) + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.JobsApi(configuration); + +let body:nomad-client.JobsApiPostJobValidateRequestRequest = { + // JobValidateRequest + jobValidateRequest: { + job: { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + allAtOnce: true, + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + consulNamespace: "consulNamespace_example", + consulToken: "consulToken_example", + createIndex: 0, + datacenters: [ + "datacenters_example", + ], + dispatchIdempotencyToken: "dispatchIdempotencyToken_example", + dispatched: true, + ID: "ID_example", + jobModifyIndex: 0, + meta: { + "key": "key_example", + }, + migrate: { + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + }, + modifyIndex: 0, + multiregion: { + regions: [ + { + count: 1, + datacenters: [ + "datacenters_example", + ], + meta: { + "key": "key_example", + }, + name: "name_example", + }, + ], + strategy: { + maxParallel: 1, + onFailure: "onFailure_example", + }, + }, + name: "name_example", + namespace: "namespace_example", + nomadTokenID: "nomadTokenID_example", + parameterizedJob: { + metaOptional: [ + "metaOptional_example", + ], + metaRequired: [ + "metaRequired_example", + ], + payload: "payload_example", + }, + parentID: "parentID_example", + payload: 'YQ==', + periodic: { + enabled: true, + prohibitOverlap: true, + spec: "spec_example", + specType: "specType_example", + timeZone: "timeZone_example", + }, + priority: 1, + region: "region_example", + reschedule: { + attempts: 1, + delay: 1, + delayFunction: "delayFunction_example", + interval: 1, + maxDelay: 1, + unlimited: true, + }, + spreads: [ + { + attribute: "attribute_example", + spreadTarget: [ + { + percent: 0, + value: "value_example", + }, + ], + weight: -128, + }, + ], + stable: true, + status: "status_example", + statusDescription: "statusDescription_example", + stop: true, + submitTime: 1, + taskGroups: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + consul: { + namespace: "namespace_example", + }, + count: 1, + ephemeralDisk: { + migrate: true, + sizeMB: 1, + sticky: true, + }, + maxClientDisconnect: 1, + meta: { + "key": "key_example", + }, + migrate: { + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + }, + name: "name_example", + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + reschedulePolicy: { + attempts: 1, + delay: 1, + delayFunction: "delayFunction_example", + interval: 1, + maxDelay: 1, + unlimited: true, + }, + restartPolicy: { + attempts: 1, + delay: 1, + interval: 1, + mode: "mode_example", + }, + scaling: { + createIndex: 0, + enabled: true, + ID: "ID_example", + max: 1, + min: 1, + modifyIndex: 0, + namespace: "namespace_example", + policy: { + "key": null, + }, + target: { + "key": "key_example", + }, + type: "type_example", + }, + services: [ + { + address: "address_example", + addressMode: "addressMode_example", + canaryMeta: { + "key": "key_example", + }, + canaryTags: [ + "canaryTags_example", + ], + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + checks: [ + { + addressMode: "addressMode_example", + advertise: "advertise_example", + args: [ + "args_example", + ], + body: "body_example", + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + command: "command_example", + expose: true, + failuresBeforeCritical: 1, + gRPCService: "gRPCService_example", + gRPCUseTLS: true, + header: { + "key": [ + "key_example", + ], + }, + initialStatus: "initialStatus_example", + interval: 1, + method: "method_example", + name: "name_example", + onUpdate: "onUpdate_example", + path: "path_example", + portLabel: "portLabel_example", + protocol: "protocol_example", + successBeforePassing: 1, + tLSSkipVerify: true, + taskName: "taskName_example", + timeout: 1, + type: "type_example", + }, + ], + connect: { + gateway: { + ingress: { + listeners: [ + { + port: 1, + protocol: "protocol_example", + services: [ + { + hosts: [ + "hosts_example", + ], + name: "name_example", + }, + ], + }, + ], + TLS: { + cipherSuites: [ + "cipherSuites_example", + ], + enabled: true, + tLSMaxVersion: "tLSMaxVersion_example", + tLSMinVersion: "tLSMinVersion_example", + }, + }, + mesh: null, + proxy: { + config: { + "key": null, + }, + connectTimeout: 1, + envoyDNSDiscoveryType: "envoyDNSDiscoveryType_example", + envoyGatewayBindAddresses: { + "key": { + address: "address_example", + name: "name_example", + port: 1, + }, + }, + envoyGatewayBindTaggedAddresses: true, + envoyGatewayNoDefaultBind: true, + }, + terminating: { + services: [ + { + cAFile: "cAFile_example", + certFile: "certFile_example", + keyFile: "keyFile_example", + name: "name_example", + SNI: "SNI_example", + }, + ], + }, + }, + _native: true, + sidecarService: { + disableDefaultTCPCheck: true, + port: "port_example", + proxy: { + config: { + "key": null, + }, + exposeConfig: { + path: [ + { + listenerPort: "listenerPort_example", + localPathPort: 1, + path: "path_example", + protocol: "protocol_example", + }, + ], + }, + localServiceAddress: "localServiceAddress_example", + localServicePort: 1, + upstreams: [ + { + datacenter: "datacenter_example", + destinationName: "destinationName_example", + destinationNamespace: "destinationNamespace_example", + localBindAddress: "localBindAddress_example", + localBindPort: 1, + meshGateway: { + mode: "mode_example", + }, + }, + ], + }, + tags: [ + "tags_example", + ], + }, + sidecarTask: { + config: { + "key": null, + }, + driver: "driver_example", + env: { + "key": "key_example", + }, + killSignal: "killSignal_example", + killTimeout: 1, + logConfig: { + maxFileSizeMB: 1, + maxFiles: 1, + }, + meta: { + "key": "key_example", + }, + name: "name_example", + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + shutdownDelay: 1, + user: "user_example", + }, + }, + enableTagOverride: true, + meta: { + "key": "key_example", + }, + name: "name_example", + onUpdate: "onUpdate_example", + portLabel: "portLabel_example", + provider: "provider_example", + taggedAddresses: { + "key": "key_example", + }, + tags: [ + "tags_example", + ], + taskName: "taskName_example", + }, + ], + shutdownDelay: 1, + spreads: [ + { + attribute: "attribute_example", + spreadTarget: [ + { + percent: 0, + value: "value_example", + }, + ], + weight: -128, + }, + ], + stopAfterClientDisconnect: 1, + tasks: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + artifacts: [ + { + getterHeaders: { + "key": "key_example", + }, + getterMode: "getterMode_example", + getterOptions: { + "key": "key_example", + }, + getterSource: "getterSource_example", + relativeDest: "relativeDest_example", + }, + ], + cSIPluginConfig: { + healthTimeout: 1, + ID: "ID_example", + mountDir: "mountDir_example", + type: "type_example", + }, + config: { + "key": null, + }, + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + dispatchPayload: { + file: "file_example", + }, + driver: "driver_example", + env: { + "key": "key_example", + }, + killSignal: "killSignal_example", + killTimeout: 1, + kind: "kind_example", + leader: true, + lifecycle: { + hook: "hook_example", + sidecar: true, + }, + logConfig: { + maxFileSizeMB: 1, + maxFiles: 1, + }, + meta: { + "key": "key_example", + }, + name: "name_example", + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + restartPolicy: { + attempts: 1, + delay: 1, + interval: 1, + mode: "mode_example", + }, + scalingPolicies: [ + { + createIndex: 0, + enabled: true, + ID: "ID_example", + max: 1, + min: 1, + modifyIndex: 0, + namespace: "namespace_example", + policy: { + "key": null, + }, + target: { + "key": "key_example", + }, + type: "type_example", + }, + ], + services: [ + { + address: "address_example", + addressMode: "addressMode_example", + canaryMeta: { + "key": "key_example", + }, + canaryTags: [ + "canaryTags_example", + ], + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + checks: [ + { + addressMode: "addressMode_example", + advertise: "advertise_example", + args: [ + "args_example", + ], + body: "body_example", + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + command: "command_example", + expose: true, + failuresBeforeCritical: 1, + gRPCService: "gRPCService_example", + gRPCUseTLS: true, + header: { + "key": [ + "key_example", + ], + }, + initialStatus: "initialStatus_example", + interval: 1, + method: "method_example", + name: "name_example", + onUpdate: "onUpdate_example", + path: "path_example", + portLabel: "portLabel_example", + protocol: "protocol_example", + successBeforePassing: 1, + tLSSkipVerify: true, + taskName: "taskName_example", + timeout: 1, + type: "type_example", + }, + ], + connect: { + gateway: { + ingress: { + listeners: [ + { + port: 1, + protocol: "protocol_example", + services: [ + { + hosts: [ + "hosts_example", + ], + name: "name_example", + }, + ], + }, + ], + TLS: { + cipherSuites: [ + "cipherSuites_example", + ], + enabled: true, + tLSMaxVersion: "tLSMaxVersion_example", + tLSMinVersion: "tLSMinVersion_example", + }, + }, + mesh: null, + proxy: { + config: { + "key": null, + }, + connectTimeout: 1, + envoyDNSDiscoveryType: "envoyDNSDiscoveryType_example", + envoyGatewayBindAddresses: { + "key": { + address: "address_example", + name: "name_example", + port: 1, + }, + }, + envoyGatewayBindTaggedAddresses: true, + envoyGatewayNoDefaultBind: true, + }, + terminating: { + services: [ + { + cAFile: "cAFile_example", + certFile: "certFile_example", + keyFile: "keyFile_example", + name: "name_example", + SNI: "SNI_example", + }, + ], + }, + }, + _native: true, + sidecarService: { + disableDefaultTCPCheck: true, + port: "port_example", + proxy: { + config: { + "key": null, + }, + exposeConfig: { + path: [ + { + listenerPort: "listenerPort_example", + localPathPort: 1, + path: "path_example", + protocol: "protocol_example", + }, + ], + }, + localServiceAddress: "localServiceAddress_example", + localServicePort: 1, + upstreams: [ + { + datacenter: "datacenter_example", + destinationName: "destinationName_example", + destinationNamespace: "destinationNamespace_example", + localBindAddress: "localBindAddress_example", + localBindPort: 1, + meshGateway: { + mode: "mode_example", + }, + }, + ], + }, + tags: [ + "tags_example", + ], + }, + sidecarTask: { + config: { + "key": null, + }, + driver: "driver_example", + env: { + "key": "key_example", + }, + killSignal: "killSignal_example", + killTimeout: 1, + logConfig: { + maxFileSizeMB: 1, + maxFiles: 1, + }, + meta: { + "key": "key_example", + }, + name: "name_example", + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + shutdownDelay: 1, + user: "user_example", + }, + }, + enableTagOverride: true, + meta: { + "key": "key_example", + }, + name: "name_example", + onUpdate: "onUpdate_example", + portLabel: "portLabel_example", + provider: "provider_example", + taggedAddresses: { + "key": "key_example", + }, + tags: [ + "tags_example", + ], + taskName: "taskName_example", + }, + ], + shutdownDelay: 1, + templates: [ + { + changeMode: "changeMode_example", + changeSignal: "changeSignal_example", + destPath: "destPath_example", + embeddedTmpl: "embeddedTmpl_example", + envvars: true, + leftDelim: "leftDelim_example", + perms: "perms_example", + rightDelim: "rightDelim_example", + sourcePath: "sourcePath_example", + splay: 1, + vaultGrace: 1, + wait: { + max: 1, + min: 1, + }, + }, + ], + user: "user_example", + vault: { + changeMode: "changeMode_example", + changeSignal: "changeSignal_example", + env: true, + namespace: "namespace_example", + policies: [ + "policies_example", + ], + }, + volumeMounts: [ + { + destination: "destination_example", + propagationMode: "propagationMode_example", + readOnly: true, + volume: "volume_example", + }, + ], + }, + ], + update: { + autoPromote: true, + autoRevert: true, + canary: 1, + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + progressDeadline: 1, + stagger: 1, + }, + volumes: { + "key": { + accessMode: "accessMode_example", + attachmentMode: "attachmentMode_example", + mountOptions: { + fSType: "fSType_example", + mountFlags: [ + "mountFlags_example", + ], + }, + name: "name_example", + perAlloc: true, + readOnly: true, + source: "source_example", + type: "type_example", + }, + }, + }, + ], + type: "type_example", + update: { + autoPromote: true, + autoRevert: true, + canary: 1, + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + progressDeadline: 1, + stagger: 1, + }, + vaultNamespace: "vaultNamespace_example", + vaultToken: "vaultToken_example", + version: 0, + }, + namespace: "namespace_example", + region: "region_example", + secretID: "secretID_example", + }, + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.postJobValidateRequest(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **jobValidateRequest** | **JobValidateRequest**| | + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**JobValidateResponse** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **registerJob** +> JobRegisterResponse registerJob(jobRegisterRequest) + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.JobsApi(configuration); + +let body:nomad-client.JobsApiRegisterJobRequest = { + // JobRegisterRequest + jobRegisterRequest: { + enforceIndex: true, + evalPriority: 1, + job: { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + allAtOnce: true, + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + consulNamespace: "consulNamespace_example", + consulToken: "consulToken_example", + createIndex: 0, + datacenters: [ + "datacenters_example", + ], + dispatchIdempotencyToken: "dispatchIdempotencyToken_example", + dispatched: true, + ID: "ID_example", + jobModifyIndex: 0, + meta: { + "key": "key_example", + }, + migrate: { + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + }, + modifyIndex: 0, + multiregion: { + regions: [ + { + count: 1, + datacenters: [ + "datacenters_example", + ], + meta: { + "key": "key_example", + }, + name: "name_example", + }, + ], + strategy: { + maxParallel: 1, + onFailure: "onFailure_example", + }, + }, + name: "name_example", + namespace: "namespace_example", + nomadTokenID: "nomadTokenID_example", + parameterizedJob: { + metaOptional: [ + "metaOptional_example", + ], + metaRequired: [ + "metaRequired_example", + ], + payload: "payload_example", + }, + parentID: "parentID_example", + payload: 'YQ==', + periodic: { + enabled: true, + prohibitOverlap: true, + spec: "spec_example", + specType: "specType_example", + timeZone: "timeZone_example", + }, + priority: 1, + region: "region_example", + reschedule: { + attempts: 1, + delay: 1, + delayFunction: "delayFunction_example", + interval: 1, + maxDelay: 1, + unlimited: true, + }, + spreads: [ + { + attribute: "attribute_example", + spreadTarget: [ + { + percent: 0, + value: "value_example", + }, + ], + weight: -128, + }, + ], + stable: true, + status: "status_example", + statusDescription: "statusDescription_example", + stop: true, + submitTime: 1, + taskGroups: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + consul: { + namespace: "namespace_example", + }, + count: 1, + ephemeralDisk: { + migrate: true, + sizeMB: 1, + sticky: true, + }, + maxClientDisconnect: 1, + meta: { + "key": "key_example", + }, + migrate: { + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + }, + name: "name_example", + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + reschedulePolicy: { + attempts: 1, + delay: 1, + delayFunction: "delayFunction_example", + interval: 1, + maxDelay: 1, + unlimited: true, + }, + restartPolicy: { + attempts: 1, + delay: 1, + interval: 1, + mode: "mode_example", + }, + scaling: { + createIndex: 0, + enabled: true, + ID: "ID_example", + max: 1, + min: 1, + modifyIndex: 0, + namespace: "namespace_example", + policy: { + "key": null, + }, + target: { + "key": "key_example", + }, + type: "type_example", + }, + services: [ + { + address: "address_example", + addressMode: "addressMode_example", + canaryMeta: { + "key": "key_example", + }, + canaryTags: [ + "canaryTags_example", + ], + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + checks: [ + { + addressMode: "addressMode_example", + advertise: "advertise_example", + args: [ + "args_example", + ], + body: "body_example", + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + command: "command_example", + expose: true, + failuresBeforeCritical: 1, + gRPCService: "gRPCService_example", + gRPCUseTLS: true, + header: { + "key": [ + "key_example", + ], + }, + initialStatus: "initialStatus_example", + interval: 1, + method: "method_example", + name: "name_example", + onUpdate: "onUpdate_example", + path: "path_example", + portLabel: "portLabel_example", + protocol: "protocol_example", + successBeforePassing: 1, + tLSSkipVerify: true, + taskName: "taskName_example", + timeout: 1, + type: "type_example", + }, + ], + connect: { + gateway: { + ingress: { + listeners: [ + { + port: 1, + protocol: "protocol_example", + services: [ + { + hosts: [ + "hosts_example", + ], + name: "name_example", + }, + ], + }, + ], + TLS: { + cipherSuites: [ + "cipherSuites_example", + ], + enabled: true, + tLSMaxVersion: "tLSMaxVersion_example", + tLSMinVersion: "tLSMinVersion_example", + }, + }, + mesh: null, + proxy: { + config: { + "key": null, + }, + connectTimeout: 1, + envoyDNSDiscoveryType: "envoyDNSDiscoveryType_example", + envoyGatewayBindAddresses: { + "key": { + address: "address_example", + name: "name_example", + port: 1, + }, + }, + envoyGatewayBindTaggedAddresses: true, + envoyGatewayNoDefaultBind: true, + }, + terminating: { + services: [ + { + cAFile: "cAFile_example", + certFile: "certFile_example", + keyFile: "keyFile_example", + name: "name_example", + SNI: "SNI_example", + }, + ], + }, + }, + _native: true, + sidecarService: { + disableDefaultTCPCheck: true, + port: "port_example", + proxy: { + config: { + "key": null, + }, + exposeConfig: { + path: [ + { + listenerPort: "listenerPort_example", + localPathPort: 1, + path: "path_example", + protocol: "protocol_example", + }, + ], + }, + localServiceAddress: "localServiceAddress_example", + localServicePort: 1, + upstreams: [ + { + datacenter: "datacenter_example", + destinationName: "destinationName_example", + destinationNamespace: "destinationNamespace_example", + localBindAddress: "localBindAddress_example", + localBindPort: 1, + meshGateway: { + mode: "mode_example", + }, + }, + ], + }, + tags: [ + "tags_example", + ], + }, + sidecarTask: { + config: { + "key": null, + }, + driver: "driver_example", + env: { + "key": "key_example", + }, + killSignal: "killSignal_example", + killTimeout: 1, + logConfig: { + maxFileSizeMB: 1, + maxFiles: 1, + }, + meta: { + "key": "key_example", + }, + name: "name_example", + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + shutdownDelay: 1, + user: "user_example", + }, + }, + enableTagOverride: true, + meta: { + "key": "key_example", + }, + name: "name_example", + onUpdate: "onUpdate_example", + portLabel: "portLabel_example", + provider: "provider_example", + taggedAddresses: { + "key": "key_example", + }, + tags: [ + "tags_example", + ], + taskName: "taskName_example", + }, + ], + shutdownDelay: 1, + spreads: [ + { + attribute: "attribute_example", + spreadTarget: [ + { + percent: 0, + value: "value_example", + }, + ], + weight: -128, + }, + ], + stopAfterClientDisconnect: 1, + tasks: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + artifacts: [ + { + getterHeaders: { + "key": "key_example", + }, + getterMode: "getterMode_example", + getterOptions: { + "key": "key_example", + }, + getterSource: "getterSource_example", + relativeDest: "relativeDest_example", + }, + ], + cSIPluginConfig: { + healthTimeout: 1, + ID: "ID_example", + mountDir: "mountDir_example", + type: "type_example", + }, + config: { + "key": null, + }, + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + dispatchPayload: { + file: "file_example", + }, + driver: "driver_example", + env: { + "key": "key_example", + }, + killSignal: "killSignal_example", + killTimeout: 1, + kind: "kind_example", + leader: true, + lifecycle: { + hook: "hook_example", + sidecar: true, + }, + logConfig: { + maxFileSizeMB: 1, + maxFiles: 1, + }, + meta: { + "key": "key_example", + }, + name: "name_example", + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + restartPolicy: { + attempts: 1, + delay: 1, + interval: 1, + mode: "mode_example", + }, + scalingPolicies: [ + { + createIndex: 0, + enabled: true, + ID: "ID_example", + max: 1, + min: 1, + modifyIndex: 0, + namespace: "namespace_example", + policy: { + "key": null, + }, + target: { + "key": "key_example", + }, + type: "type_example", + }, + ], + services: [ + { + address: "address_example", + addressMode: "addressMode_example", + canaryMeta: { + "key": "key_example", + }, + canaryTags: [ + "canaryTags_example", + ], + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + checks: [ + { + addressMode: "addressMode_example", + advertise: "advertise_example", + args: [ + "args_example", + ], + body: "body_example", + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + command: "command_example", + expose: true, + failuresBeforeCritical: 1, + gRPCService: "gRPCService_example", + gRPCUseTLS: true, + header: { + "key": [ + "key_example", + ], + }, + initialStatus: "initialStatus_example", + interval: 1, + method: "method_example", + name: "name_example", + onUpdate: "onUpdate_example", + path: "path_example", + portLabel: "portLabel_example", + protocol: "protocol_example", + successBeforePassing: 1, + tLSSkipVerify: true, + taskName: "taskName_example", + timeout: 1, + type: "type_example", + }, + ], + connect: { + gateway: { + ingress: { + listeners: [ + { + port: 1, + protocol: "protocol_example", + services: [ + { + hosts: [ + "hosts_example", + ], + name: "name_example", + }, + ], + }, + ], + TLS: { + cipherSuites: [ + "cipherSuites_example", + ], + enabled: true, + tLSMaxVersion: "tLSMaxVersion_example", + tLSMinVersion: "tLSMinVersion_example", + }, + }, + mesh: null, + proxy: { + config: { + "key": null, + }, + connectTimeout: 1, + envoyDNSDiscoveryType: "envoyDNSDiscoveryType_example", + envoyGatewayBindAddresses: { + "key": { + address: "address_example", + name: "name_example", + port: 1, + }, + }, + envoyGatewayBindTaggedAddresses: true, + envoyGatewayNoDefaultBind: true, + }, + terminating: { + services: [ + { + cAFile: "cAFile_example", + certFile: "certFile_example", + keyFile: "keyFile_example", + name: "name_example", + SNI: "SNI_example", + }, + ], + }, + }, + _native: true, + sidecarService: { + disableDefaultTCPCheck: true, + port: "port_example", + proxy: { + config: { + "key": null, + }, + exposeConfig: { + path: [ + { + listenerPort: "listenerPort_example", + localPathPort: 1, + path: "path_example", + protocol: "protocol_example", + }, + ], + }, + localServiceAddress: "localServiceAddress_example", + localServicePort: 1, + upstreams: [ + { + datacenter: "datacenter_example", + destinationName: "destinationName_example", + destinationNamespace: "destinationNamespace_example", + localBindAddress: "localBindAddress_example", + localBindPort: 1, + meshGateway: { + mode: "mode_example", + }, + }, + ], + }, + tags: [ + "tags_example", + ], + }, + sidecarTask: { + config: { + "key": null, + }, + driver: "driver_example", + env: { + "key": "key_example", + }, + killSignal: "killSignal_example", + killTimeout: 1, + logConfig: { + maxFileSizeMB: 1, + maxFiles: 1, + }, + meta: { + "key": "key_example", + }, + name: "name_example", + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + shutdownDelay: 1, + user: "user_example", + }, + }, + enableTagOverride: true, + meta: { + "key": "key_example", + }, + name: "name_example", + onUpdate: "onUpdate_example", + portLabel: "portLabel_example", + provider: "provider_example", + taggedAddresses: { + "key": "key_example", + }, + tags: [ + "tags_example", + ], + taskName: "taskName_example", + }, + ], + shutdownDelay: 1, + templates: [ + { + changeMode: "changeMode_example", + changeSignal: "changeSignal_example", + destPath: "destPath_example", + embeddedTmpl: "embeddedTmpl_example", + envvars: true, + leftDelim: "leftDelim_example", + perms: "perms_example", + rightDelim: "rightDelim_example", + sourcePath: "sourcePath_example", + splay: 1, + vaultGrace: 1, + wait: { + max: 1, + min: 1, + }, + }, + ], + user: "user_example", + vault: { + changeMode: "changeMode_example", + changeSignal: "changeSignal_example", + env: true, + namespace: "namespace_example", + policies: [ + "policies_example", + ], + }, + volumeMounts: [ + { + destination: "destination_example", + propagationMode: "propagationMode_example", + readOnly: true, + volume: "volume_example", + }, + ], + }, + ], + update: { + autoPromote: true, + autoRevert: true, + canary: 1, + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + progressDeadline: 1, + stagger: 1, + }, + volumes: { + "key": { + accessMode: "accessMode_example", + attachmentMode: "attachmentMode_example", + mountOptions: { + fSType: "fSType_example", + mountFlags: [ + "mountFlags_example", + ], + }, + name: "name_example", + perAlloc: true, + readOnly: true, + source: "source_example", + type: "type_example", + }, + }, + }, + ], + type: "type_example", + update: { + autoPromote: true, + autoRevert: true, + canary: 1, + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + progressDeadline: 1, + stagger: 1, + }, + vaultNamespace: "vaultNamespace_example", + vaultToken: "vaultToken_example", + version: 0, + }, + jobModifyIndex: 0, + namespace: "namespace_example", + policyOverride: true, + preserveCounts: true, + region: "region_example", + secretID: "secretID_example", + }, + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.registerJob(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **jobRegisterRequest** | **JobRegisterRequest**| | + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**JobRegisterResponse** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + + diff --git a/clients/typescript/v1/MetricsApi.md b/clients/typescript/v1/MetricsApi.md new file mode 100644 index 00000000..49ce354c --- /dev/null +++ b/clients/typescript/v1/MetricsApi.md @@ -0,0 +1,67 @@ +# nomad-client.MetricsApi + +All URIs are relative to *https://127.0.0.1:4646/v1* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**getMetricsSummary**](MetricsApi.md#getMetricsSummary) | **GET** /metrics | + + +# **getMetricsSummary** +> MetricsSummary getMetricsSummary() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.MetricsApi(configuration); + +let body:nomad-client.MetricsApiGetMetricsSummaryRequest = { + // string | The format the user requested for the metrics summary (e.g. prometheus) (optional) + format: "format_example", +}; + +apiInstance.getMetricsSummary(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **format** | [**string**] | The format the user requested for the metrics summary (e.g. prometheus) | (optional) defaults to undefined + + +### Return type + +**MetricsSummary** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + + diff --git a/clients/typescript/v1/NamespacesApi.md b/clients/typescript/v1/NamespacesApi.md new file mode 100644 index 00000000..b9d514a1 --- /dev/null +++ b/clients/typescript/v1/NamespacesApi.md @@ -0,0 +1,403 @@ +# nomad-client.NamespacesApi + +All URIs are relative to *https://127.0.0.1:4646/v1* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**createNamespace**](NamespacesApi.md#createNamespace) | **POST** /namespace | +[**deleteNamespace**](NamespacesApi.md#deleteNamespace) | **DELETE** /namespace/{namespaceName} | +[**getNamespace**](NamespacesApi.md#getNamespace) | **GET** /namespace/{namespaceName} | +[**getNamespaces**](NamespacesApi.md#getNamespaces) | **GET** /namespaces | +[**postNamespace**](NamespacesApi.md#postNamespace) | **POST** /namespace/{namespaceName} | + + +# **createNamespace** +> void createNamespace() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.NamespacesApi(configuration); + +let body:nomad-client.NamespacesApiCreateNamespaceRequest = { + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.createNamespace(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**void** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: Not defined + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **deleteNamespace** +> void deleteNamespace() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.NamespacesApi(configuration); + +let body:nomad-client.NamespacesApiDeleteNamespaceRequest = { + // string | The namespace identifier. + namespaceName: "namespaceName_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.deleteNamespace(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **namespaceName** | [**string**] | The namespace identifier. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**void** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: Not defined + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getNamespace** +> Namespace getNamespace() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.NamespacesApi(configuration); + +let body:nomad-client.NamespacesApiGetNamespaceRequest = { + // string | The namespace identifier. + namespaceName: "namespaceName_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getNamespace(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **namespaceName** | [**string**] | The namespace identifier. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**Namespace** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getNamespaces** +> Array getNamespaces() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.NamespacesApi(configuration); + +let body:nomad-client.NamespacesApiGetNamespacesRequest = { + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getNamespaces(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**Array** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **postNamespace** +> void postNamespace(namespace2) + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.NamespacesApi(configuration); + +let body:nomad-client.NamespacesApiPostNamespaceRequest = { + // string | The namespace identifier. + namespaceName: "namespaceName_example", + // Namespace + namespace2: { + capabilities: { + disabledTaskDrivers: [ + "disabledTaskDrivers_example", + ], + enabledTaskDrivers: [ + "enabledTaskDrivers_example", + ], + }, + createIndex: 0, + description: "description_example", + meta: { + "key": "key_example", + }, + modifyIndex: 0, + name: "name_example", + quota: "quota_example", + }, + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.postNamespace(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **namespace2** | **Namespace**| | + **namespaceName** | [**string**] | The namespace identifier. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**void** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: Not defined + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + + diff --git a/clients/typescript/v1/NodesApi.md b/clients/typescript/v1/NodesApi.md new file mode 100644 index 00000000..9bb589ee --- /dev/null +++ b/clients/typescript/v1/NodesApi.md @@ -0,0 +1,538 @@ +# nomad-client.NodesApi + +All URIs are relative to *https://127.0.0.1:4646/v1* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**getNode**](NodesApi.md#getNode) | **GET** /node/{nodeId} | +[**getNodeAllocations**](NodesApi.md#getNodeAllocations) | **GET** /node/{nodeId}/allocations | +[**getNodes**](NodesApi.md#getNodes) | **GET** /nodes | +[**updateNodeDrain**](NodesApi.md#updateNodeDrain) | **POST** /node/{nodeId}/drain | +[**updateNodeEligibility**](NodesApi.md#updateNodeEligibility) | **POST** /node/{nodeId}/eligibility | +[**updateNodePurge**](NodesApi.md#updateNodePurge) | **POST** /node/{nodeId}/purge | + + +# **getNode** +> Node getNode() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.NodesApi(configuration); + +let body:nomad-client.NodesApiGetNodeRequest = { + // string | The ID of the node. + nodeId: "nodeId_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getNode(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **nodeId** | [**string**] | The ID of the node. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**Node** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getNodeAllocations** +> Array getNodeAllocations() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.NodesApi(configuration); + +let body:nomad-client.NodesApiGetNodeAllocationsRequest = { + // string | The ID of the node. + nodeId: "nodeId_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getNodeAllocations(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **nodeId** | [**string**] | The ID of the node. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**Array** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getNodes** +> Array getNodes() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.NodesApi(configuration); + +let body:nomad-client.NodesApiGetNodesRequest = { + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", + // boolean | Whether or not to include the NodeResources and ReservedResources fields in the response. (optional) + resources: true, +}; + +apiInstance.getNodes(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + **resources** | [**boolean**] | Whether or not to include the NodeResources and ReservedResources fields in the response. | (optional) defaults to undefined + + +### Return type + +**Array** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **updateNodeDrain** +> NodeDrainUpdateResponse updateNodeDrain(nodeUpdateDrainRequest) + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.NodesApi(configuration); + +let body:nomad-client.NodesApiUpdateNodeDrainRequest = { + // string | The ID of the node. + nodeId: "nodeId_example", + // NodeUpdateDrainRequest + nodeUpdateDrainRequest: { + drainSpec: { + deadline: 1, + ignoreSystemJobs: true, + }, + markEligible: true, + meta: { + "key": "key_example", + }, + nodeID: "nodeID_example", + }, + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.updateNodeDrain(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **nodeUpdateDrainRequest** | **NodeUpdateDrainRequest**| | + **nodeId** | [**string**] | The ID of the node. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**NodeDrainUpdateResponse** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **updateNodeEligibility** +> NodeEligibilityUpdateResponse updateNodeEligibility(nodeUpdateEligibilityRequest) + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.NodesApi(configuration); + +let body:nomad-client.NodesApiUpdateNodeEligibilityRequest = { + // string | The ID of the node. + nodeId: "nodeId_example", + // NodeUpdateEligibilityRequest + nodeUpdateEligibilityRequest: { + eligibility: "eligibility_example", + nodeID: "nodeID_example", + }, + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.updateNodeEligibility(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **nodeUpdateEligibilityRequest** | **NodeUpdateEligibilityRequest**| | + **nodeId** | [**string**] | The ID of the node. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**NodeEligibilityUpdateResponse** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **updateNodePurge** +> NodePurgeResponse updateNodePurge() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.NodesApi(configuration); + +let body:nomad-client.NodesApiUpdateNodePurgeRequest = { + // string | The ID of the node. + nodeId: "nodeId_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.updateNodePurge(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **nodeId** | [**string**] | The ID of the node. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**NodePurgeResponse** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + + diff --git a/clients/typescript/v1/OperatorApi.md b/clients/typescript/v1/OperatorApi.md new file mode 100644 index 00000000..9dbe63aa --- /dev/null +++ b/clients/typescript/v1/OperatorApi.md @@ -0,0 +1,568 @@ +# nomad-client.OperatorApi + +All URIs are relative to *https://127.0.0.1:4646/v1* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**deleteOperatorRaftPeer**](OperatorApi.md#deleteOperatorRaftPeer) | **DELETE** /operator/raft/peer | +[**getOperatorAutopilotConfiguration**](OperatorApi.md#getOperatorAutopilotConfiguration) | **GET** /operator/autopilot/configuration | +[**getOperatorAutopilotHealth**](OperatorApi.md#getOperatorAutopilotHealth) | **GET** /operator/autopilot/health | +[**getOperatorRaftConfiguration**](OperatorApi.md#getOperatorRaftConfiguration) | **GET** /operator/raft/configuration | +[**getOperatorSchedulerConfiguration**](OperatorApi.md#getOperatorSchedulerConfiguration) | **GET** /operator/scheduler/configuration | +[**postOperatorSchedulerConfiguration**](OperatorApi.md#postOperatorSchedulerConfiguration) | **POST** /operator/scheduler/configuration | +[**putOperatorAutopilotConfiguration**](OperatorApi.md#putOperatorAutopilotConfiguration) | **PUT** /operator/autopilot/configuration | + + +# **deleteOperatorRaftPeer** +> void deleteOperatorRaftPeer() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.OperatorApi(configuration); + +let body:nomad-client.OperatorApiDeleteOperatorRaftPeerRequest = { + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.deleteOperatorRaftPeer(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**void** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: Not defined + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getOperatorAutopilotConfiguration** +> AutopilotConfiguration getOperatorAutopilotConfiguration() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.OperatorApi(configuration); + +let body:nomad-client.OperatorApiGetOperatorAutopilotConfigurationRequest = { + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getOperatorAutopilotConfiguration(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**AutopilotConfiguration** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getOperatorAutopilotHealth** +> OperatorHealthReply getOperatorAutopilotHealth() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.OperatorApi(configuration); + +let body:nomad-client.OperatorApiGetOperatorAutopilotHealthRequest = { + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getOperatorAutopilotHealth(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**OperatorHealthReply** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getOperatorRaftConfiguration** +> RaftConfiguration getOperatorRaftConfiguration() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.OperatorApi(configuration); + +let body:nomad-client.OperatorApiGetOperatorRaftConfigurationRequest = { + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getOperatorRaftConfiguration(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**RaftConfiguration** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getOperatorSchedulerConfiguration** +> SchedulerConfigurationResponse getOperatorSchedulerConfiguration() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.OperatorApi(configuration); + +let body:nomad-client.OperatorApiGetOperatorSchedulerConfigurationRequest = { + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getOperatorSchedulerConfiguration(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**SchedulerConfigurationResponse** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **postOperatorSchedulerConfiguration** +> SchedulerSetConfigurationResponse postOperatorSchedulerConfiguration(schedulerConfiguration) + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.OperatorApi(configuration); + +let body:nomad-client.OperatorApiPostOperatorSchedulerConfigurationRequest = { + // SchedulerConfiguration + schedulerConfiguration: { + createIndex: 0, + memoryOversubscriptionEnabled: true, + modifyIndex: 0, + pauseEvalBroker: true, + preemptionConfig: { + batchSchedulerEnabled: true, + serviceSchedulerEnabled: true, + sysBatchSchedulerEnabled: true, + systemSchedulerEnabled: true, + }, + rejectJobRegistration: true, + schedulerAlgorithm: "schedulerAlgorithm_example", + }, + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.postOperatorSchedulerConfiguration(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **schedulerConfiguration** | **SchedulerConfiguration**| | + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**SchedulerSetConfigurationResponse** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **putOperatorAutopilotConfiguration** +> boolean putOperatorAutopilotConfiguration(autopilotConfiguration) + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.OperatorApi(configuration); + +let body:nomad-client.OperatorApiPutOperatorAutopilotConfigurationRequest = { + // AutopilotConfiguration + autopilotConfiguration: { + cleanupDeadServers: true, + createIndex: 0, + disableUpgradeMigration: true, + enableCustomUpgrades: true, + enableRedundancyZones: true, + lastContactThreshold: "lastContactThreshold_example", + maxTrailingLogs: 0, + minQuorum: 0, + modifyIndex: 0, + serverStabilizationTime: "serverStabilizationTime_example", + }, + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.putOperatorAutopilotConfiguration(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **autopilotConfiguration** | **AutopilotConfiguration**| | + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**boolean** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + + diff --git a/clients/typescript/v1/PluginsApi.md b/clients/typescript/v1/PluginsApi.md new file mode 100644 index 00000000..0812d38a --- /dev/null +++ b/clients/typescript/v1/PluginsApi.md @@ -0,0 +1,176 @@ +# nomad-client.PluginsApi + +All URIs are relative to *https://127.0.0.1:4646/v1* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**getPluginCSI**](PluginsApi.md#getPluginCSI) | **GET** /plugin/csi/{pluginID} | +[**getPlugins**](PluginsApi.md#getPlugins) | **GET** /plugins | + + +# **getPluginCSI** +> Array getPluginCSI() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.PluginsApi(configuration); + +let body:nomad-client.PluginsApiGetPluginCSIRequest = { + // string | The CSI plugin identifier. + pluginID: "pluginID_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getPluginCSI(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pluginID** | [**string**] | The CSI plugin identifier. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**Array** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getPlugins** +> Array getPlugins() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.PluginsApi(configuration); + +let body:nomad-client.PluginsApiGetPluginsRequest = { + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getPlugins(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**Array** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + + diff --git a/clients/typescript/v1/README.md b/clients/typescript/v1/README.md index 6937ef9e..55d39465 100644 --- a/clients/typescript/v1/README.md +++ b/clients/typescript/v1/README.md @@ -1,6 +1,6 @@ ## @ -This generator creates TypeScript/JavaScript client that utilizes fetch-api. +This generator creates TypeScript/JavaScript client that utilizes fetch-api. ### Building diff --git a/clients/typescript/v1/RegionsApi.md b/clients/typescript/v1/RegionsApi.md new file mode 100644 index 00000000..6267a33d --- /dev/null +++ b/clients/typescript/v1/RegionsApi.md @@ -0,0 +1,61 @@ +# nomad-client.RegionsApi + +All URIs are relative to *https://127.0.0.1:4646/v1* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**getRegions**](RegionsApi.md#getRegions) | **GET** /regions | + + +# **getRegions** +> Array getRegions() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.RegionsApi(configuration); + +let body:any = {}; + +apiInstance.getRegions(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters +This endpoint does not need any parameter. + + +### Return type + +**Array** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + + diff --git a/clients/typescript/v1/ScalingApi.md b/clients/typescript/v1/ScalingApi.md new file mode 100644 index 00000000..8bcdd408 --- /dev/null +++ b/clients/typescript/v1/ScalingApi.md @@ -0,0 +1,176 @@ +# nomad-client.ScalingApi + +All URIs are relative to *https://127.0.0.1:4646/v1* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**getScalingPolicies**](ScalingApi.md#getScalingPolicies) | **GET** /scaling/policies | +[**getScalingPolicy**](ScalingApi.md#getScalingPolicy) | **GET** /scaling/policy/{policyID} | + + +# **getScalingPolicies** +> Array getScalingPolicies() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.ScalingApi(configuration); + +let body:nomad-client.ScalingApiGetScalingPoliciesRequest = { + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getScalingPolicies(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**Array** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getScalingPolicy** +> ScalingPolicy getScalingPolicy() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.ScalingApi(configuration); + +let body:nomad-client.ScalingApiGetScalingPolicyRequest = { + // string | The scaling policy identifier. + policyID: "policyID_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getScalingPolicy(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **policyID** | [**string**] | The scaling policy identifier. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**ScalingPolicy** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + + diff --git a/clients/typescript/v1/SearchApi.md b/clients/typescript/v1/SearchApi.md new file mode 100644 index 00000000..5c54ccf5 --- /dev/null +++ b/clients/typescript/v1/SearchApi.md @@ -0,0 +1,218 @@ +# nomad-client.SearchApi + +All URIs are relative to *https://127.0.0.1:4646/v1* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**getFuzzySearch**](SearchApi.md#getFuzzySearch) | **POST** /search/fuzzy | +[**getSearch**](SearchApi.md#getSearch) | **POST** /search | + + +# **getFuzzySearch** +> FuzzySearchResponse getFuzzySearch(fuzzySearchRequest) + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.SearchApi(configuration); + +let body:nomad-client.SearchApiGetFuzzySearchRequest = { + // FuzzySearchRequest + fuzzySearchRequest: { + allowStale: true, + authToken: "authToken_example", + context: "context_example", + filter: "filter_example", + headers: { + "key": "key_example", + }, + namespace: "namespace_example", + nextToken: "nextToken_example", + params: { + "key": "key_example", + }, + perPage: 1, + prefix: "prefix_example", + region: "region_example", + reverse: true, + text: "text_example", + waitIndex: 0, + waitTime: 1, + }, + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getFuzzySearch(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **fuzzySearchRequest** | **FuzzySearchRequest**| | + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**FuzzySearchResponse** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getSearch** +> SearchResponse getSearch(searchRequest) + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.SearchApi(configuration); + +let body:nomad-client.SearchApiGetSearchRequest = { + // SearchRequest + searchRequest: { + allowStale: true, + authToken: "authToken_example", + context: "context_example", + filter: "filter_example", + headers: { + "key": "key_example", + }, + namespace: "namespace_example", + nextToken: "nextToken_example", + params: { + "key": "key_example", + }, + perPage: 1, + prefix: "prefix_example", + region: "region_example", + reverse: true, + waitIndex: 0, + waitTime: 1, + }, + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getSearch(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **searchRequest** | **SearchRequest**| | + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**SearchResponse** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + + diff --git a/clients/typescript/v1/StatusApi.md b/clients/typescript/v1/StatusApi.md new file mode 100644 index 00000000..e3de423d --- /dev/null +++ b/clients/typescript/v1/StatusApi.md @@ -0,0 +1,173 @@ +# nomad-client.StatusApi + +All URIs are relative to *https://127.0.0.1:4646/v1* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**getStatusLeader**](StatusApi.md#getStatusLeader) | **GET** /status/leader | +[**getStatusPeers**](StatusApi.md#getStatusPeers) | **GET** /status/peers | + + +# **getStatusLeader** +> string getStatusLeader() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.StatusApi(configuration); + +let body:nomad-client.StatusApiGetStatusLeaderRequest = { + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getStatusLeader(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**string** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getStatusPeers** +> Array getStatusPeers() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.StatusApi(configuration); + +let body:nomad-client.StatusApiGetStatusPeersRequest = { + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getStatusPeers(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**Array** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + + diff --git a/clients/typescript/v1/SystemApi.md b/clients/typescript/v1/SystemApi.md new file mode 100644 index 00000000..d01a810f --- /dev/null +++ b/clients/typescript/v1/SystemApi.md @@ -0,0 +1,143 @@ +# nomad-client.SystemApi + +All URIs are relative to *https://127.0.0.1:4646/v1* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**putSystemGC**](SystemApi.md#putSystemGC) | **PUT** /system/gc | +[**putSystemReconcileSummaries**](SystemApi.md#putSystemReconcileSummaries) | **PUT** /system/reconcile/summaries | + + +# **putSystemGC** +> void putSystemGC() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.SystemApi(configuration); + +let body:nomad-client.SystemApiPutSystemGCRequest = { + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.putSystemGC(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**void** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: Not defined + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **putSystemReconcileSummaries** +> void putSystemReconcileSummaries() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.SystemApi(configuration); + +let body:nomad-client.SystemApiPutSystemReconcileSummariesRequest = { + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.putSystemReconcileSummaries(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**void** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: Not defined + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | - | +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + + diff --git a/clients/typescript/v1/VolumesApi.md b/clients/typescript/v1/VolumesApi.md new file mode 100644 index 00000000..81ce134f --- /dev/null +++ b/clients/typescript/v1/VolumesApi.md @@ -0,0 +1,10110 @@ +# nomad-client.VolumesApi + +All URIs are relative to *https://127.0.0.1:4646/v1* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**createVolume**](VolumesApi.md#createVolume) | **POST** /volume/csi/{volumeId}/{action} | +[**deleteSnapshot**](VolumesApi.md#deleteSnapshot) | **DELETE** /volumes/snapshot | +[**deleteVolumeRegistration**](VolumesApi.md#deleteVolumeRegistration) | **DELETE** /volume/csi/{volumeId} | +[**detachOrDeleteVolume**](VolumesApi.md#detachOrDeleteVolume) | **DELETE** /volume/csi/{volumeId}/{action} | +[**getExternalVolumes**](VolumesApi.md#getExternalVolumes) | **GET** /volumes/external | +[**getSnapshots**](VolumesApi.md#getSnapshots) | **GET** /volumes/snapshot | +[**getVolume**](VolumesApi.md#getVolume) | **GET** /volume/csi/{volumeId} | +[**getVolumes**](VolumesApi.md#getVolumes) | **GET** /volumes | +[**postSnapshot**](VolumesApi.md#postSnapshot) | **POST** /volumes/snapshot | +[**postVolume**](VolumesApi.md#postVolume) | **POST** /volumes | +[**postVolumeRegistration**](VolumesApi.md#postVolumeRegistration) | **POST** /volume/csi/{volumeId} | + + +# **createVolume** +> void createVolume(cSIVolumeCreateRequest) + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.VolumesApi(configuration); + +let body:nomad-client.VolumesApiCreateVolumeRequest = { + // string | Volume unique identifier. + volumeId: "volumeId_example", + // string | The action to perform on the Volume (create, detach, delete). + action: "action_example", + // CSIVolumeCreateRequest + cSIVolumeCreateRequest: { + namespace: "namespace_example", + region: "region_example", + secretID: "secretID_example", + volumes: [ + { + accessMode: "accessMode_example", + allocations: [ + { + allocatedResources: { + shared: { + diskMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + ports: [ + { + hostIP: "hostIP_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + tasks: { + "key": { + cpu: { + cpuShares: 1, + }, + devices: [ + { + deviceIDs: [ + "deviceIDs_example", + ], + name: "name_example", + type: "type_example", + vendor: "vendor_example", + }, + ], + memory: { + memoryMB: 1, + memoryMaxMB: 1, + }, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + }, + }, + clientDescription: "clientDescription_example", + clientStatus: "clientStatus_example", + createIndex: 0, + createTime: 1, + deploymentStatus: { + canary: true, + healthy: true, + modifyIndex: 0, + timestamp: new Date('1970-01-01T00:00:00.00Z'), + }, + desiredDescription: "desiredDescription_example", + desiredStatus: "desiredStatus_example", + evalID: "evalID_example", + followupEvalID: "followupEvalID_example", + ID: "ID_example", + jobID: "jobID_example", + jobType: "jobType_example", + jobVersion: 0, + modifyIndex: 0, + modifyTime: 1, + name: "name_example", + namespace: "namespace_example", + nodeID: "nodeID_example", + nodeName: "nodeName_example", + preemptedAllocations: [ + "preemptedAllocations_example", + ], + preemptedByAllocation: "preemptedByAllocation_example", + rescheduleTracker: { + events: [ + { + prevAllocID: "prevAllocID_example", + prevNodeID: "prevNodeID_example", + rescheduleTime: 1, + }, + ], + }, + taskGroup: "taskGroup_example", + taskStates: { + "key": { + events: [ + { + details: { + "key": "key_example", + }, + diskLimit: 1, + diskSize: 1, + displayMessage: "displayMessage_example", + downloadError: "downloadError_example", + driverError: "driverError_example", + driverMessage: "driverMessage_example", + exitCode: 1, + failedSibling: "failedSibling_example", + failsTask: true, + genericSource: "genericSource_example", + killError: "killError_example", + killReason: "killReason_example", + killTimeout: 1, + message: "message_example", + restartReason: "restartReason_example", + setupError: "setupError_example", + signal: 1, + startDelay: 1, + taskSignal: "taskSignal_example", + taskSignalReason: "taskSignalReason_example", + time: 1, + type: "type_example", + validationError: "validationError_example", + vaultError: "vaultError_example", + }, + ], + failed: true, + finishedAt: new Date('1970-01-01T00:00:00.00Z'), + lastRestart: new Date('1970-01-01T00:00:00.00Z'), + restarts: 0, + startedAt: new Date('1970-01-01T00:00:00.00Z'), + state: "state_example", + taskHandle: { + driverState: 'YQ==', + version: 1, + }, + }, + }, + }, + ], + attachmentMode: "attachmentMode_example", + capacity: 1, + cloneID: "cloneID_example", + context: { + "key": "key_example", + }, + controllerRequired: true, + controllersExpected: 1, + controllersHealthy: 1, + createIndex: 0, + externalID: "externalID_example", + ID: "ID_example", + modifyIndex: 0, + mountOptions: { + fSType: "fSType_example", + mountFlags: [ + "mountFlags_example", + ], + }, + name: "name_example", + namespace: "namespace_example", + nodesExpected: 1, + nodesHealthy: 1, + parameters: { + "key": "key_example", + }, + pluginID: "pluginID_example", + provider: "provider_example", + providerVersion: "providerVersion_example", + readAllocs: { + "key": { + allocModifyIndex: 0, + allocatedResources: { + shared: { + diskMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + ports: [ + { + hostIP: "hostIP_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + tasks: { + "key": { + cpu: { + cpuShares: 1, + }, + devices: [ + { + deviceIDs: [ + "deviceIDs_example", + ], + name: "name_example", + type: "type_example", + vendor: "vendor_example", + }, + ], + memory: { + memoryMB: 1, + memoryMaxMB: 1, + }, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + }, + }, + clientDescription: "clientDescription_example", + clientStatus: "clientStatus_example", + createIndex: 0, + createTime: 1, + deploymentID: "deploymentID_example", + deploymentStatus: { + canary: true, + healthy: true, + modifyIndex: 0, + timestamp: new Date('1970-01-01T00:00:00.00Z'), + }, + desiredDescription: "desiredDescription_example", + desiredStatus: "desiredStatus_example", + desiredTransition: { + migrate: true, + reschedule: true, + }, + evalID: "evalID_example", + followupEvalID: "followupEvalID_example", + ID: "ID_example", + job: { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + allAtOnce: true, + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + consulNamespace: "consulNamespace_example", + consulToken: "consulToken_example", + createIndex: 0, + datacenters: [ + "datacenters_example", + ], + dispatchIdempotencyToken: "dispatchIdempotencyToken_example", + dispatched: true, + ID: "ID_example", + jobModifyIndex: 0, + meta: { + "key": "key_example", + }, + migrate: { + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + }, + modifyIndex: 0, + multiregion: { + regions: [ + { + count: 1, + datacenters: [ + "datacenters_example", + ], + meta: { + "key": "key_example", + }, + name: "name_example", + }, + ], + strategy: { + maxParallel: 1, + onFailure: "onFailure_example", + }, + }, + name: "name_example", + namespace: "namespace_example", + nomadTokenID: "nomadTokenID_example", + parameterizedJob: { + metaOptional: [ + "metaOptional_example", + ], + metaRequired: [ + "metaRequired_example", + ], + payload: "payload_example", + }, + parentID: "parentID_example", + payload: 'YQ==', + periodic: { + enabled: true, + prohibitOverlap: true, + spec: "spec_example", + specType: "specType_example", + timeZone: "timeZone_example", + }, + priority: 1, + region: "region_example", + reschedule: { + attempts: 1, + delay: 1, + delayFunction: "delayFunction_example", + interval: 1, + maxDelay: 1, + unlimited: true, + }, + spreads: [ + { + attribute: "attribute_example", + spreadTarget: [ + { + percent: 0, + value: "value_example", + }, + ], + weight: -128, + }, + ], + stable: true, + status: "status_example", + statusDescription: "statusDescription_example", + stop: true, + submitTime: 1, + taskGroups: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + consul: { + namespace: "namespace_example", + }, + count: 1, + ephemeralDisk: { + migrate: true, + sizeMB: 1, + sticky: true, + }, + maxClientDisconnect: 1, + meta: { + "key": "key_example", + }, + migrate: { + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + }, + name: "name_example", + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + reschedulePolicy: { + attempts: 1, + delay: 1, + delayFunction: "delayFunction_example", + interval: 1, + maxDelay: 1, + unlimited: true, + }, + restartPolicy: { + attempts: 1, + delay: 1, + interval: 1, + mode: "mode_example", + }, + scaling: { + createIndex: 0, + enabled: true, + ID: "ID_example", + max: 1, + min: 1, + modifyIndex: 0, + namespace: "namespace_example", + policy: { + "key": null, + }, + target: { + "key": "key_example", + }, + type: "type_example", + }, + services: [ + { + address: "address_example", + addressMode: "addressMode_example", + canaryMeta: { + "key": "key_example", + }, + canaryTags: [ + "canaryTags_example", + ], + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + checks: [ + { + addressMode: "addressMode_example", + advertise: "advertise_example", + args: [ + "args_example", + ], + body: "body_example", + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + command: "command_example", + expose: true, + failuresBeforeCritical: 1, + gRPCService: "gRPCService_example", + gRPCUseTLS: true, + header: { + "key": [ + "key_example", + ], + }, + initialStatus: "initialStatus_example", + interval: 1, + method: "method_example", + name: "name_example", + onUpdate: "onUpdate_example", + path: "path_example", + portLabel: "portLabel_example", + protocol: "protocol_example", + successBeforePassing: 1, + tLSSkipVerify: true, + taskName: "taskName_example", + timeout: 1, + type: "type_example", + }, + ], + connect: { + gateway: { + ingress: { + listeners: [ + { + port: 1, + protocol: "protocol_example", + services: [ + { + hosts: [ + "hosts_example", + ], + name: "name_example", + }, + ], + }, + ], + TLS: { + cipherSuites: [ + "cipherSuites_example", + ], + enabled: true, + tLSMaxVersion: "tLSMaxVersion_example", + tLSMinVersion: "tLSMinVersion_example", + }, + }, + mesh: null, + proxy: { + config: { + "key": null, + }, + connectTimeout: 1, + envoyDNSDiscoveryType: "envoyDNSDiscoveryType_example", + envoyGatewayBindAddresses: { + "key": { + address: "address_example", + name: "name_example", + port: 1, + }, + }, + envoyGatewayBindTaggedAddresses: true, + envoyGatewayNoDefaultBind: true, + }, + terminating: { + services: [ + { + cAFile: "cAFile_example", + certFile: "certFile_example", + keyFile: "keyFile_example", + name: "name_example", + SNI: "SNI_example", + }, + ], + }, + }, + _native: true, + sidecarService: { + disableDefaultTCPCheck: true, + port: "port_example", + proxy: { + config: { + "key": null, + }, + exposeConfig: { + path: [ + { + listenerPort: "listenerPort_example", + localPathPort: 1, + path: "path_example", + protocol: "protocol_example", + }, + ], + }, + localServiceAddress: "localServiceAddress_example", + localServicePort: 1, + upstreams: [ + { + datacenter: "datacenter_example", + destinationName: "destinationName_example", + destinationNamespace: "destinationNamespace_example", + localBindAddress: "localBindAddress_example", + localBindPort: 1, + meshGateway: { + mode: "mode_example", + }, + }, + ], + }, + tags: [ + "tags_example", + ], + }, + sidecarTask: { + config: { + "key": null, + }, + driver: "driver_example", + env: { + "key": "key_example", + }, + killSignal: "killSignal_example", + killTimeout: 1, + logConfig: { + maxFileSizeMB: 1, + maxFiles: 1, + }, + meta: { + "key": "key_example", + }, + name: "name_example", + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + shutdownDelay: 1, + user: "user_example", + }, + }, + enableTagOverride: true, + meta: { + "key": "key_example", + }, + name: "name_example", + onUpdate: "onUpdate_example", + portLabel: "portLabel_example", + provider: "provider_example", + taggedAddresses: { + "key": "key_example", + }, + tags: [ + "tags_example", + ], + taskName: "taskName_example", + }, + ], + shutdownDelay: 1, + spreads: [ + { + attribute: "attribute_example", + spreadTarget: [ + { + percent: 0, + value: "value_example", + }, + ], + weight: -128, + }, + ], + stopAfterClientDisconnect: 1, + tasks: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + artifacts: [ + { + getterHeaders: { + "key": "key_example", + }, + getterMode: "getterMode_example", + getterOptions: { + "key": "key_example", + }, + getterSource: "getterSource_example", + relativeDest: "relativeDest_example", + }, + ], + cSIPluginConfig: { + healthTimeout: 1, + ID: "ID_example", + mountDir: "mountDir_example", + type: "type_example", + }, + config: { + "key": null, + }, + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + dispatchPayload: { + file: "file_example", + }, + driver: "driver_example", + env: { + "key": "key_example", + }, + killSignal: "killSignal_example", + killTimeout: 1, + kind: "kind_example", + leader: true, + lifecycle: { + hook: "hook_example", + sidecar: true, + }, + logConfig: { + maxFileSizeMB: 1, + maxFiles: 1, + }, + meta: { + "key": "key_example", + }, + name: "name_example", + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + restartPolicy: { + attempts: 1, + delay: 1, + interval: 1, + mode: "mode_example", + }, + scalingPolicies: [ + { + createIndex: 0, + enabled: true, + ID: "ID_example", + max: 1, + min: 1, + modifyIndex: 0, + namespace: "namespace_example", + policy: { + "key": null, + }, + target: { + "key": "key_example", + }, + type: "type_example", + }, + ], + services: [ + { + address: "address_example", + addressMode: "addressMode_example", + canaryMeta: { + "key": "key_example", + }, + canaryTags: [ + "canaryTags_example", + ], + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + checks: [ + { + addressMode: "addressMode_example", + advertise: "advertise_example", + args: [ + "args_example", + ], + body: "body_example", + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + command: "command_example", + expose: true, + failuresBeforeCritical: 1, + gRPCService: "gRPCService_example", + gRPCUseTLS: true, + header: { + "key": [ + "key_example", + ], + }, + initialStatus: "initialStatus_example", + interval: 1, + method: "method_example", + name: "name_example", + onUpdate: "onUpdate_example", + path: "path_example", + portLabel: "portLabel_example", + protocol: "protocol_example", + successBeforePassing: 1, + tLSSkipVerify: true, + taskName: "taskName_example", + timeout: 1, + type: "type_example", + }, + ], + connect: { + gateway: { + ingress: { + listeners: [ + { + port: 1, + protocol: "protocol_example", + services: [ + { + hosts: [ + "hosts_example", + ], + name: "name_example", + }, + ], + }, + ], + TLS: { + cipherSuites: [ + "cipherSuites_example", + ], + enabled: true, + tLSMaxVersion: "tLSMaxVersion_example", + tLSMinVersion: "tLSMinVersion_example", + }, + }, + mesh: null, + proxy: { + config: { + "key": null, + }, + connectTimeout: 1, + envoyDNSDiscoveryType: "envoyDNSDiscoveryType_example", + envoyGatewayBindAddresses: { + "key": { + address: "address_example", + name: "name_example", + port: 1, + }, + }, + envoyGatewayBindTaggedAddresses: true, + envoyGatewayNoDefaultBind: true, + }, + terminating: { + services: [ + { + cAFile: "cAFile_example", + certFile: "certFile_example", + keyFile: "keyFile_example", + name: "name_example", + SNI: "SNI_example", + }, + ], + }, + }, + _native: true, + sidecarService: { + disableDefaultTCPCheck: true, + port: "port_example", + proxy: { + config: { + "key": null, + }, + exposeConfig: { + path: [ + { + listenerPort: "listenerPort_example", + localPathPort: 1, + path: "path_example", + protocol: "protocol_example", + }, + ], + }, + localServiceAddress: "localServiceAddress_example", + localServicePort: 1, + upstreams: [ + { + datacenter: "datacenter_example", + destinationName: "destinationName_example", + destinationNamespace: "destinationNamespace_example", + localBindAddress: "localBindAddress_example", + localBindPort: 1, + meshGateway: { + mode: "mode_example", + }, + }, + ], + }, + tags: [ + "tags_example", + ], + }, + sidecarTask: { + config: { + "key": null, + }, + driver: "driver_example", + env: { + "key": "key_example", + }, + killSignal: "killSignal_example", + killTimeout: 1, + logConfig: { + maxFileSizeMB: 1, + maxFiles: 1, + }, + meta: { + "key": "key_example", + }, + name: "name_example", + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + shutdownDelay: 1, + user: "user_example", + }, + }, + enableTagOverride: true, + meta: { + "key": "key_example", + }, + name: "name_example", + onUpdate: "onUpdate_example", + portLabel: "portLabel_example", + provider: "provider_example", + taggedAddresses: { + "key": "key_example", + }, + tags: [ + "tags_example", + ], + taskName: "taskName_example", + }, + ], + shutdownDelay: 1, + templates: [ + { + changeMode: "changeMode_example", + changeSignal: "changeSignal_example", + destPath: "destPath_example", + embeddedTmpl: "embeddedTmpl_example", + envvars: true, + leftDelim: "leftDelim_example", + perms: "perms_example", + rightDelim: "rightDelim_example", + sourcePath: "sourcePath_example", + splay: 1, + vaultGrace: 1, + wait: { + max: 1, + min: 1, + }, + }, + ], + user: "user_example", + vault: { + changeMode: "changeMode_example", + changeSignal: "changeSignal_example", + env: true, + namespace: "namespace_example", + policies: [ + "policies_example", + ], + }, + volumeMounts: [ + { + destination: "destination_example", + propagationMode: "propagationMode_example", + readOnly: true, + volume: "volume_example", + }, + ], + }, + ], + update: { + autoPromote: true, + autoRevert: true, + canary: 1, + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + progressDeadline: 1, + stagger: 1, + }, + volumes: { + "key": { + accessMode: "accessMode_example", + attachmentMode: "attachmentMode_example", + mountOptions: { + fSType: "fSType_example", + mountFlags: [ + "mountFlags_example", + ], + }, + name: "name_example", + perAlloc: true, + readOnly: true, + source: "source_example", + type: "type_example", + }, + }, + }, + ], + type: "type_example", + update: { + autoPromote: true, + autoRevert: true, + canary: 1, + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + progressDeadline: 1, + stagger: 1, + }, + vaultNamespace: "vaultNamespace_example", + vaultToken: "vaultToken_example", + version: 0, + }, + jobID: "jobID_example", + metrics: { + allocationTime: 1, + classExhausted: { + "key": 1, + }, + classFiltered: { + "key": 1, + }, + coalescedFailures: 1, + constraintFiltered: { + "key": 1, + }, + dimensionExhausted: { + "key": 1, + }, + nodesAvailable: { + "key": 1, + }, + nodesEvaluated: 1, + nodesExhausted: 1, + nodesFiltered: 1, + quotaExhausted: [ + "quotaExhausted_example", + ], + resourcesExhausted: { + "key": { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + }, + scoreMetaData: [ + { + nodeID: "nodeID_example", + normScore: 3.14, + scores: { + "key": 3.14, + }, + }, + ], + scores: { + "key": 3.14, + }, + }, + modifyIndex: 0, + modifyTime: 1, + name: "name_example", + namespace: "namespace_example", + nextAllocation: "nextAllocation_example", + nodeID: "nodeID_example", + nodeName: "nodeName_example", + preemptedAllocations: [ + "preemptedAllocations_example", + ], + preemptedByAllocation: "preemptedByAllocation_example", + previousAllocation: "previousAllocation_example", + rescheduleTracker: { + events: [ + { + prevAllocID: "prevAllocID_example", + prevNodeID: "prevNodeID_example", + rescheduleTime: 1, + }, + ], + }, + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + services: { + "key": "key_example", + }, + taskGroup: "taskGroup_example", + taskResources: { + "key": { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + }, + taskStates: { + "key": { + events: [ + { + details: { + "key": "key_example", + }, + diskLimit: 1, + diskSize: 1, + displayMessage: "displayMessage_example", + downloadError: "downloadError_example", + driverError: "driverError_example", + driverMessage: "driverMessage_example", + exitCode: 1, + failedSibling: "failedSibling_example", + failsTask: true, + genericSource: "genericSource_example", + killError: "killError_example", + killReason: "killReason_example", + killTimeout: 1, + message: "message_example", + restartReason: "restartReason_example", + setupError: "setupError_example", + signal: 1, + startDelay: 1, + taskSignal: "taskSignal_example", + taskSignalReason: "taskSignalReason_example", + time: 1, + type: "type_example", + validationError: "validationError_example", + vaultError: "vaultError_example", + }, + ], + failed: true, + finishedAt: new Date('1970-01-01T00:00:00.00Z'), + lastRestart: new Date('1970-01-01T00:00:00.00Z'), + restarts: 0, + startedAt: new Date('1970-01-01T00:00:00.00Z'), + state: "state_example", + taskHandle: { + driverState: 'YQ==', + version: 1, + }, + }, + }, + }, + }, + requestedCapabilities: [ + { + accessMode: "accessMode_example", + attachmentMode: "attachmentMode_example", + }, + ], + requestedCapacityMax: 1, + requestedCapacityMin: 1, + requestedTopologies: { + preferred: [ + { + segments: { + "key": "key_example", + }, + }, + ], + required: [ + { + segments: { + "key": "key_example", + }, + }, + ], + }, + resourceExhausted: new Date('1970-01-01T00:00:00.00Z'), + schedulable: true, + secrets: { + "key": "key_example", + }, + snapshotID: "snapshotID_example", + topologies: [ + { + segments: { + "key": "key_example", + }, + }, + ], + writeAllocs: { + "key": { + allocModifyIndex: 0, + allocatedResources: { + shared: { + diskMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + ports: [ + { + hostIP: "hostIP_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + tasks: { + "key": { + cpu: { + cpuShares: 1, + }, + devices: [ + { + deviceIDs: [ + "deviceIDs_example", + ], + name: "name_example", + type: "type_example", + vendor: "vendor_example", + }, + ], + memory: { + memoryMB: 1, + memoryMaxMB: 1, + }, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + }, + }, + clientDescription: "clientDescription_example", + clientStatus: "clientStatus_example", + createIndex: 0, + createTime: 1, + deploymentID: "deploymentID_example", + deploymentStatus: { + canary: true, + healthy: true, + modifyIndex: 0, + timestamp: new Date('1970-01-01T00:00:00.00Z'), + }, + desiredDescription: "desiredDescription_example", + desiredStatus: "desiredStatus_example", + desiredTransition: { + migrate: true, + reschedule: true, + }, + evalID: "evalID_example", + followupEvalID: "followupEvalID_example", + ID: "ID_example", + job: { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + allAtOnce: true, + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + consulNamespace: "consulNamespace_example", + consulToken: "consulToken_example", + createIndex: 0, + datacenters: [ + "datacenters_example", + ], + dispatchIdempotencyToken: "dispatchIdempotencyToken_example", + dispatched: true, + ID: "ID_example", + jobModifyIndex: 0, + meta: { + "key": "key_example", + }, + migrate: { + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + }, + modifyIndex: 0, + multiregion: { + regions: [ + { + count: 1, + datacenters: [ + "datacenters_example", + ], + meta: { + "key": "key_example", + }, + name: "name_example", + }, + ], + strategy: { + maxParallel: 1, + onFailure: "onFailure_example", + }, + }, + name: "name_example", + namespace: "namespace_example", + nomadTokenID: "nomadTokenID_example", + parameterizedJob: { + metaOptional: [ + "metaOptional_example", + ], + metaRequired: [ + "metaRequired_example", + ], + payload: "payload_example", + }, + parentID: "parentID_example", + payload: 'YQ==', + periodic: { + enabled: true, + prohibitOverlap: true, + spec: "spec_example", + specType: "specType_example", + timeZone: "timeZone_example", + }, + priority: 1, + region: "region_example", + reschedule: { + attempts: 1, + delay: 1, + delayFunction: "delayFunction_example", + interval: 1, + maxDelay: 1, + unlimited: true, + }, + spreads: [ + { + attribute: "attribute_example", + spreadTarget: [ + { + percent: 0, + value: "value_example", + }, + ], + weight: -128, + }, + ], + stable: true, + status: "status_example", + statusDescription: "statusDescription_example", + stop: true, + submitTime: 1, + taskGroups: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + consul: { + namespace: "namespace_example", + }, + count: 1, + ephemeralDisk: { + migrate: true, + sizeMB: 1, + sticky: true, + }, + maxClientDisconnect: 1, + meta: { + "key": "key_example", + }, + migrate: { + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + }, + name: "name_example", + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + reschedulePolicy: { + attempts: 1, + delay: 1, + delayFunction: "delayFunction_example", + interval: 1, + maxDelay: 1, + unlimited: true, + }, + restartPolicy: { + attempts: 1, + delay: 1, + interval: 1, + mode: "mode_example", + }, + scaling: { + createIndex: 0, + enabled: true, + ID: "ID_example", + max: 1, + min: 1, + modifyIndex: 0, + namespace: "namespace_example", + policy: { + "key": null, + }, + target: { + "key": "key_example", + }, + type: "type_example", + }, + services: [ + { + address: "address_example", + addressMode: "addressMode_example", + canaryMeta: { + "key": "key_example", + }, + canaryTags: [ + "canaryTags_example", + ], + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + checks: [ + { + addressMode: "addressMode_example", + advertise: "advertise_example", + args: [ + "args_example", + ], + body: "body_example", + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + command: "command_example", + expose: true, + failuresBeforeCritical: 1, + gRPCService: "gRPCService_example", + gRPCUseTLS: true, + header: { + "key": [ + "key_example", + ], + }, + initialStatus: "initialStatus_example", + interval: 1, + method: "method_example", + name: "name_example", + onUpdate: "onUpdate_example", + path: "path_example", + portLabel: "portLabel_example", + protocol: "protocol_example", + successBeforePassing: 1, + tLSSkipVerify: true, + taskName: "taskName_example", + timeout: 1, + type: "type_example", + }, + ], + connect: { + gateway: { + ingress: { + listeners: [ + { + port: 1, + protocol: "protocol_example", + services: [ + { + hosts: [ + "hosts_example", + ], + name: "name_example", + }, + ], + }, + ], + TLS: { + cipherSuites: [ + "cipherSuites_example", + ], + enabled: true, + tLSMaxVersion: "tLSMaxVersion_example", + tLSMinVersion: "tLSMinVersion_example", + }, + }, + mesh: null, + proxy: { + config: { + "key": null, + }, + connectTimeout: 1, + envoyDNSDiscoveryType: "envoyDNSDiscoveryType_example", + envoyGatewayBindAddresses: { + "key": { + address: "address_example", + name: "name_example", + port: 1, + }, + }, + envoyGatewayBindTaggedAddresses: true, + envoyGatewayNoDefaultBind: true, + }, + terminating: { + services: [ + { + cAFile: "cAFile_example", + certFile: "certFile_example", + keyFile: "keyFile_example", + name: "name_example", + SNI: "SNI_example", + }, + ], + }, + }, + _native: true, + sidecarService: { + disableDefaultTCPCheck: true, + port: "port_example", + proxy: { + config: { + "key": null, + }, + exposeConfig: { + path: [ + { + listenerPort: "listenerPort_example", + localPathPort: 1, + path: "path_example", + protocol: "protocol_example", + }, + ], + }, + localServiceAddress: "localServiceAddress_example", + localServicePort: 1, + upstreams: [ + { + datacenter: "datacenter_example", + destinationName: "destinationName_example", + destinationNamespace: "destinationNamespace_example", + localBindAddress: "localBindAddress_example", + localBindPort: 1, + meshGateway: { + mode: "mode_example", + }, + }, + ], + }, + tags: [ + "tags_example", + ], + }, + sidecarTask: { + config: { + "key": null, + }, + driver: "driver_example", + env: { + "key": "key_example", + }, + killSignal: "killSignal_example", + killTimeout: 1, + logConfig: { + maxFileSizeMB: 1, + maxFiles: 1, + }, + meta: { + "key": "key_example", + }, + name: "name_example", + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + shutdownDelay: 1, + user: "user_example", + }, + }, + enableTagOverride: true, + meta: { + "key": "key_example", + }, + name: "name_example", + onUpdate: "onUpdate_example", + portLabel: "portLabel_example", + provider: "provider_example", + taggedAddresses: { + "key": "key_example", + }, + tags: [ + "tags_example", + ], + taskName: "taskName_example", + }, + ], + shutdownDelay: 1, + spreads: [ + { + attribute: "attribute_example", + spreadTarget: [ + { + percent: 0, + value: "value_example", + }, + ], + weight: -128, + }, + ], + stopAfterClientDisconnect: 1, + tasks: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + artifacts: [ + { + getterHeaders: { + "key": "key_example", + }, + getterMode: "getterMode_example", + getterOptions: { + "key": "key_example", + }, + getterSource: "getterSource_example", + relativeDest: "relativeDest_example", + }, + ], + cSIPluginConfig: { + healthTimeout: 1, + ID: "ID_example", + mountDir: "mountDir_example", + type: "type_example", + }, + config: { + "key": null, + }, + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + dispatchPayload: { + file: "file_example", + }, + driver: "driver_example", + env: { + "key": "key_example", + }, + killSignal: "killSignal_example", + killTimeout: 1, + kind: "kind_example", + leader: true, + lifecycle: { + hook: "hook_example", + sidecar: true, + }, + logConfig: { + maxFileSizeMB: 1, + maxFiles: 1, + }, + meta: { + "key": "key_example", + }, + name: "name_example", + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + restartPolicy: { + attempts: 1, + delay: 1, + interval: 1, + mode: "mode_example", + }, + scalingPolicies: [ + { + createIndex: 0, + enabled: true, + ID: "ID_example", + max: 1, + min: 1, + modifyIndex: 0, + namespace: "namespace_example", + policy: { + "key": null, + }, + target: { + "key": "key_example", + }, + type: "type_example", + }, + ], + services: [ + { + address: "address_example", + addressMode: "addressMode_example", + canaryMeta: { + "key": "key_example", + }, + canaryTags: [ + "canaryTags_example", + ], + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + checks: [ + { + addressMode: "addressMode_example", + advertise: "advertise_example", + args: [ + "args_example", + ], + body: "body_example", + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + command: "command_example", + expose: true, + failuresBeforeCritical: 1, + gRPCService: "gRPCService_example", + gRPCUseTLS: true, + header: { + "key": [ + "key_example", + ], + }, + initialStatus: "initialStatus_example", + interval: 1, + method: "method_example", + name: "name_example", + onUpdate: "onUpdate_example", + path: "path_example", + portLabel: "portLabel_example", + protocol: "protocol_example", + successBeforePassing: 1, + tLSSkipVerify: true, + taskName: "taskName_example", + timeout: 1, + type: "type_example", + }, + ], + connect: { + gateway: { + ingress: { + listeners: [ + { + port: 1, + protocol: "protocol_example", + services: [ + { + hosts: [ + "hosts_example", + ], + name: "name_example", + }, + ], + }, + ], + TLS: { + cipherSuites: [ + "cipherSuites_example", + ], + enabled: true, + tLSMaxVersion: "tLSMaxVersion_example", + tLSMinVersion: "tLSMinVersion_example", + }, + }, + mesh: null, + proxy: { + config: { + "key": null, + }, + connectTimeout: 1, + envoyDNSDiscoveryType: "envoyDNSDiscoveryType_example", + envoyGatewayBindAddresses: { + "key": { + address: "address_example", + name: "name_example", + port: 1, + }, + }, + envoyGatewayBindTaggedAddresses: true, + envoyGatewayNoDefaultBind: true, + }, + terminating: { + services: [ + { + cAFile: "cAFile_example", + certFile: "certFile_example", + keyFile: "keyFile_example", + name: "name_example", + SNI: "SNI_example", + }, + ], + }, + }, + _native: true, + sidecarService: { + disableDefaultTCPCheck: true, + port: "port_example", + proxy: { + config: { + "key": null, + }, + exposeConfig: { + path: [ + { + listenerPort: "listenerPort_example", + localPathPort: 1, + path: "path_example", + protocol: "protocol_example", + }, + ], + }, + localServiceAddress: "localServiceAddress_example", + localServicePort: 1, + upstreams: [ + { + datacenter: "datacenter_example", + destinationName: "destinationName_example", + destinationNamespace: "destinationNamespace_example", + localBindAddress: "localBindAddress_example", + localBindPort: 1, + meshGateway: { + mode: "mode_example", + }, + }, + ], + }, + tags: [ + "tags_example", + ], + }, + sidecarTask: { + config: { + "key": null, + }, + driver: "driver_example", + env: { + "key": "key_example", + }, + killSignal: "killSignal_example", + killTimeout: 1, + logConfig: { + maxFileSizeMB: 1, + maxFiles: 1, + }, + meta: { + "key": "key_example", + }, + name: "name_example", + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + shutdownDelay: 1, + user: "user_example", + }, + }, + enableTagOverride: true, + meta: { + "key": "key_example", + }, + name: "name_example", + onUpdate: "onUpdate_example", + portLabel: "portLabel_example", + provider: "provider_example", + taggedAddresses: { + "key": "key_example", + }, + tags: [ + "tags_example", + ], + taskName: "taskName_example", + }, + ], + shutdownDelay: 1, + templates: [ + { + changeMode: "changeMode_example", + changeSignal: "changeSignal_example", + destPath: "destPath_example", + embeddedTmpl: "embeddedTmpl_example", + envvars: true, + leftDelim: "leftDelim_example", + perms: "perms_example", + rightDelim: "rightDelim_example", + sourcePath: "sourcePath_example", + splay: 1, + vaultGrace: 1, + wait: { + max: 1, + min: 1, + }, + }, + ], + user: "user_example", + vault: { + changeMode: "changeMode_example", + changeSignal: "changeSignal_example", + env: true, + namespace: "namespace_example", + policies: [ + "policies_example", + ], + }, + volumeMounts: [ + { + destination: "destination_example", + propagationMode: "propagationMode_example", + readOnly: true, + volume: "volume_example", + }, + ], + }, + ], + update: { + autoPromote: true, + autoRevert: true, + canary: 1, + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + progressDeadline: 1, + stagger: 1, + }, + volumes: { + "key": { + accessMode: "accessMode_example", + attachmentMode: "attachmentMode_example", + mountOptions: { + fSType: "fSType_example", + mountFlags: [ + "mountFlags_example", + ], + }, + name: "name_example", + perAlloc: true, + readOnly: true, + source: "source_example", + type: "type_example", + }, + }, + }, + ], + type: "type_example", + update: { + autoPromote: true, + autoRevert: true, + canary: 1, + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + progressDeadline: 1, + stagger: 1, + }, + vaultNamespace: "vaultNamespace_example", + vaultToken: "vaultToken_example", + version: 0, + }, + jobID: "jobID_example", + metrics: { + allocationTime: 1, + classExhausted: { + "key": 1, + }, + classFiltered: { + "key": 1, + }, + coalescedFailures: 1, + constraintFiltered: { + "key": 1, + }, + dimensionExhausted: { + "key": 1, + }, + nodesAvailable: { + "key": 1, + }, + nodesEvaluated: 1, + nodesExhausted: 1, + nodesFiltered: 1, + quotaExhausted: [ + "quotaExhausted_example", + ], + resourcesExhausted: { + "key": { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + }, + scoreMetaData: [ + { + nodeID: "nodeID_example", + normScore: 3.14, + scores: { + "key": 3.14, + }, + }, + ], + scores: { + "key": 3.14, + }, + }, + modifyIndex: 0, + modifyTime: 1, + name: "name_example", + namespace: "namespace_example", + nextAllocation: "nextAllocation_example", + nodeID: "nodeID_example", + nodeName: "nodeName_example", + preemptedAllocations: [ + "preemptedAllocations_example", + ], + preemptedByAllocation: "preemptedByAllocation_example", + previousAllocation: "previousAllocation_example", + rescheduleTracker: { + events: [ + { + prevAllocID: "prevAllocID_example", + prevNodeID: "prevNodeID_example", + rescheduleTime: 1, + }, + ], + }, + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + services: { + "key": "key_example", + }, + taskGroup: "taskGroup_example", + taskResources: { + "key": { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + }, + taskStates: { + "key": { + events: [ + { + details: { + "key": "key_example", + }, + diskLimit: 1, + diskSize: 1, + displayMessage: "displayMessage_example", + downloadError: "downloadError_example", + driverError: "driverError_example", + driverMessage: "driverMessage_example", + exitCode: 1, + failedSibling: "failedSibling_example", + failsTask: true, + genericSource: "genericSource_example", + killError: "killError_example", + killReason: "killReason_example", + killTimeout: 1, + message: "message_example", + restartReason: "restartReason_example", + setupError: "setupError_example", + signal: 1, + startDelay: 1, + taskSignal: "taskSignal_example", + taskSignalReason: "taskSignalReason_example", + time: 1, + type: "type_example", + validationError: "validationError_example", + vaultError: "vaultError_example", + }, + ], + failed: true, + finishedAt: new Date('1970-01-01T00:00:00.00Z'), + lastRestart: new Date('1970-01-01T00:00:00.00Z'), + restarts: 0, + startedAt: new Date('1970-01-01T00:00:00.00Z'), + state: "state_example", + taskHandle: { + driverState: 'YQ==', + version: 1, + }, + }, + }, + }, + }, + }, + ], + }, + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.createVolume(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **cSIVolumeCreateRequest** | **CSIVolumeCreateRequest**| | + **volumeId** | [**string**] | Volume unique identifier. | defaults to undefined + **action** | [**string**] | The action to perform on the Volume (create, detach, delete). | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**void** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: Not defined + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **deleteSnapshot** +> void deleteSnapshot() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.VolumesApi(configuration); + +let body:nomad-client.VolumesApiDeleteSnapshotRequest = { + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", + // string | Filters volume lists by plugin ID. (optional) + pluginId: "plugin_id_example", + // string | The ID of the snapshot to target. (optional) + snapshotId: "snapshot_id_example", +}; + +apiInstance.deleteSnapshot(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + **pluginId** | [**string**] | Filters volume lists by plugin ID. | (optional) defaults to undefined + **snapshotId** | [**string**] | The ID of the snapshot to target. | (optional) defaults to undefined + + +### Return type + +**void** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: Not defined + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **deleteVolumeRegistration** +> void deleteVolumeRegistration() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.VolumesApi(configuration); + +let body:nomad-client.VolumesApiDeleteVolumeRegistrationRequest = { + // string | Volume unique identifier. + volumeId: "volumeId_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", + // string | Used to force the de-registration of a volume. (optional) + force: "force_example", +}; + +apiInstance.deleteVolumeRegistration(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **volumeId** | [**string**] | Volume unique identifier. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + **force** | [**string**] | Used to force the de-registration of a volume. | (optional) defaults to undefined + + +### Return type + +**void** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: Not defined + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **detachOrDeleteVolume** +> void detachOrDeleteVolume() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.VolumesApi(configuration); + +let body:nomad-client.VolumesApiDetachOrDeleteVolumeRequest = { + // string | Volume unique identifier. + volumeId: "volumeId_example", + // string | The action to perform on the Volume (create, detach, delete). + action: "action_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", + // string | Specifies node to target volume operation for. (optional) + node: "node_example", +}; + +apiInstance.detachOrDeleteVolume(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **volumeId** | [**string**] | Volume unique identifier. | defaults to undefined + **action** | [**string**] | The action to perform on the Volume (create, detach, delete). | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + **node** | [**string**] | Specifies node to target volume operation for. | (optional) defaults to undefined + + +### Return type + +**void** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: Not defined + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getExternalVolumes** +> CSIVolumeListExternalResponse getExternalVolumes() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.VolumesApi(configuration); + +let body:nomad-client.VolumesApiGetExternalVolumesRequest = { + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", + // string | Filters volume lists by plugin ID. (optional) + pluginId: "plugin_id_example", +}; + +apiInstance.getExternalVolumes(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + **pluginId** | [**string**] | Filters volume lists by plugin ID. | (optional) defaults to undefined + + +### Return type + +**CSIVolumeListExternalResponse** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getSnapshots** +> CSISnapshotListResponse getSnapshots() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.VolumesApi(configuration); + +let body:nomad-client.VolumesApiGetSnapshotsRequest = { + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", + // string | Filters volume lists by plugin ID. (optional) + pluginId: "plugin_id_example", +}; + +apiInstance.getSnapshots(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + **pluginId** | [**string**] | Filters volume lists by plugin ID. | (optional) defaults to undefined + + +### Return type + +**CSISnapshotListResponse** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getVolume** +> CSIVolume getVolume() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.VolumesApi(configuration); + +let body:nomad-client.VolumesApiGetVolumeRequest = { + // string | Volume unique identifier. + volumeId: "volumeId_example", + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", +}; + +apiInstance.getVolume(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **volumeId** | [**string**] | Volume unique identifier. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + + +### Return type + +**CSIVolume** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **getVolumes** +> Array getVolumes() + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.VolumesApi(configuration); + +let body:nomad-client.VolumesApiGetVolumesRequest = { + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // number | If set, wait until query exceeds given index. Must be provided with WaitParam. (optional) + index: 1, + // string | Provided with IndexParam to wait for change. (optional) + wait: "wait_example", + // string | If present, results will include stale reads. (optional) + stale: "stale_example", + // string | Constrains results to jobs that start with the defined prefix (optional) + prefix: "prefix_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // number | Maximum number of results to return. (optional) + perPage: 1, + // string | Indicates where to start paging for queries that support pagination. (optional) + nextToken: "next_token_example", + // string | Filters volume lists by node ID. (optional) + nodeId: "node_id_example", + // string | Filters volume lists by plugin ID. (optional) + pluginId: "plugin_id_example", + // string | Filters volume lists to a specific type. (optional) + type: "type_example", +}; + +apiInstance.getVolumes(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **index** | [**number**] | If set, wait until query exceeds given index. Must be provided with WaitParam. | (optional) defaults to undefined + **wait** | [**string**] | Provided with IndexParam to wait for change. | (optional) defaults to undefined + **stale** | [**string**] | If present, results will include stale reads. | (optional) defaults to undefined + **prefix** | [**string**] | Constrains results to jobs that start with the defined prefix | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **perPage** | [**number**] | Maximum number of results to return. | (optional) defaults to undefined + **nextToken** | [**string**] | Indicates where to start paging for queries that support pagination. | (optional) defaults to undefined + **nodeId** | [**string**] | Filters volume lists by node ID. | (optional) defaults to undefined + **pluginId** | [**string**] | Filters volume lists by plugin ID. | (optional) defaults to undefined + **type** | [**string**] | Filters volume lists to a specific type. | (optional) defaults to undefined + + +### Return type + +**Array** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **postSnapshot** +> CSISnapshotCreateResponse postSnapshot(cSISnapshotCreateRequest) + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.VolumesApi(configuration); + +let body:nomad-client.VolumesApiPostSnapshotRequest = { + // CSISnapshotCreateRequest + cSISnapshotCreateRequest: { + namespace: "namespace_example", + region: "region_example", + secretID: "secretID_example", + snapshots: [ + { + createTime: 1, + externalSourceVolumeID: "externalSourceVolumeID_example", + ID: "ID_example", + isReady: true, + name: "name_example", + parameters: { + "key": "key_example", + }, + pluginID: "pluginID_example", + secrets: { + "key": "key_example", + }, + sizeBytes: 1, + sourceVolumeID: "sourceVolumeID_example", + }, + ], + }, + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.postSnapshot(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **cSISnapshotCreateRequest** | **CSISnapshotCreateRequest**| | + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**CSISnapshotCreateResponse** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **postVolume** +> void postVolume(cSIVolumeRegisterRequest) + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.VolumesApi(configuration); + +let body:nomad-client.VolumesApiPostVolumeRequest = { + // CSIVolumeRegisterRequest + cSIVolumeRegisterRequest: { + namespace: "namespace_example", + region: "region_example", + secretID: "secretID_example", + volumes: [ + { + accessMode: "accessMode_example", + allocations: [ + { + allocatedResources: { + shared: { + diskMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + ports: [ + { + hostIP: "hostIP_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + tasks: { + "key": { + cpu: { + cpuShares: 1, + }, + devices: [ + { + deviceIDs: [ + "deviceIDs_example", + ], + name: "name_example", + type: "type_example", + vendor: "vendor_example", + }, + ], + memory: { + memoryMB: 1, + memoryMaxMB: 1, + }, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + }, + }, + clientDescription: "clientDescription_example", + clientStatus: "clientStatus_example", + createIndex: 0, + createTime: 1, + deploymentStatus: { + canary: true, + healthy: true, + modifyIndex: 0, + timestamp: new Date('1970-01-01T00:00:00.00Z'), + }, + desiredDescription: "desiredDescription_example", + desiredStatus: "desiredStatus_example", + evalID: "evalID_example", + followupEvalID: "followupEvalID_example", + ID: "ID_example", + jobID: "jobID_example", + jobType: "jobType_example", + jobVersion: 0, + modifyIndex: 0, + modifyTime: 1, + name: "name_example", + namespace: "namespace_example", + nodeID: "nodeID_example", + nodeName: "nodeName_example", + preemptedAllocations: [ + "preemptedAllocations_example", + ], + preemptedByAllocation: "preemptedByAllocation_example", + rescheduleTracker: { + events: [ + { + prevAllocID: "prevAllocID_example", + prevNodeID: "prevNodeID_example", + rescheduleTime: 1, + }, + ], + }, + taskGroup: "taskGroup_example", + taskStates: { + "key": { + events: [ + { + details: { + "key": "key_example", + }, + diskLimit: 1, + diskSize: 1, + displayMessage: "displayMessage_example", + downloadError: "downloadError_example", + driverError: "driverError_example", + driverMessage: "driverMessage_example", + exitCode: 1, + failedSibling: "failedSibling_example", + failsTask: true, + genericSource: "genericSource_example", + killError: "killError_example", + killReason: "killReason_example", + killTimeout: 1, + message: "message_example", + restartReason: "restartReason_example", + setupError: "setupError_example", + signal: 1, + startDelay: 1, + taskSignal: "taskSignal_example", + taskSignalReason: "taskSignalReason_example", + time: 1, + type: "type_example", + validationError: "validationError_example", + vaultError: "vaultError_example", + }, + ], + failed: true, + finishedAt: new Date('1970-01-01T00:00:00.00Z'), + lastRestart: new Date('1970-01-01T00:00:00.00Z'), + restarts: 0, + startedAt: new Date('1970-01-01T00:00:00.00Z'), + state: "state_example", + taskHandle: { + driverState: 'YQ==', + version: 1, + }, + }, + }, + }, + ], + attachmentMode: "attachmentMode_example", + capacity: 1, + cloneID: "cloneID_example", + context: { + "key": "key_example", + }, + controllerRequired: true, + controllersExpected: 1, + controllersHealthy: 1, + createIndex: 0, + externalID: "externalID_example", + ID: "ID_example", + modifyIndex: 0, + mountOptions: { + fSType: "fSType_example", + mountFlags: [ + "mountFlags_example", + ], + }, + name: "name_example", + namespace: "namespace_example", + nodesExpected: 1, + nodesHealthy: 1, + parameters: { + "key": "key_example", + }, + pluginID: "pluginID_example", + provider: "provider_example", + providerVersion: "providerVersion_example", + readAllocs: { + "key": { + allocModifyIndex: 0, + allocatedResources: { + shared: { + diskMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + ports: [ + { + hostIP: "hostIP_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + tasks: { + "key": { + cpu: { + cpuShares: 1, + }, + devices: [ + { + deviceIDs: [ + "deviceIDs_example", + ], + name: "name_example", + type: "type_example", + vendor: "vendor_example", + }, + ], + memory: { + memoryMB: 1, + memoryMaxMB: 1, + }, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + }, + }, + clientDescription: "clientDescription_example", + clientStatus: "clientStatus_example", + createIndex: 0, + createTime: 1, + deploymentID: "deploymentID_example", + deploymentStatus: { + canary: true, + healthy: true, + modifyIndex: 0, + timestamp: new Date('1970-01-01T00:00:00.00Z'), + }, + desiredDescription: "desiredDescription_example", + desiredStatus: "desiredStatus_example", + desiredTransition: { + migrate: true, + reschedule: true, + }, + evalID: "evalID_example", + followupEvalID: "followupEvalID_example", + ID: "ID_example", + job: { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + allAtOnce: true, + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + consulNamespace: "consulNamespace_example", + consulToken: "consulToken_example", + createIndex: 0, + datacenters: [ + "datacenters_example", + ], + dispatchIdempotencyToken: "dispatchIdempotencyToken_example", + dispatched: true, + ID: "ID_example", + jobModifyIndex: 0, + meta: { + "key": "key_example", + }, + migrate: { + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + }, + modifyIndex: 0, + multiregion: { + regions: [ + { + count: 1, + datacenters: [ + "datacenters_example", + ], + meta: { + "key": "key_example", + }, + name: "name_example", + }, + ], + strategy: { + maxParallel: 1, + onFailure: "onFailure_example", + }, + }, + name: "name_example", + namespace: "namespace_example", + nomadTokenID: "nomadTokenID_example", + parameterizedJob: { + metaOptional: [ + "metaOptional_example", + ], + metaRequired: [ + "metaRequired_example", + ], + payload: "payload_example", + }, + parentID: "parentID_example", + payload: 'YQ==', + periodic: { + enabled: true, + prohibitOverlap: true, + spec: "spec_example", + specType: "specType_example", + timeZone: "timeZone_example", + }, + priority: 1, + region: "region_example", + reschedule: { + attempts: 1, + delay: 1, + delayFunction: "delayFunction_example", + interval: 1, + maxDelay: 1, + unlimited: true, + }, + spreads: [ + { + attribute: "attribute_example", + spreadTarget: [ + { + percent: 0, + value: "value_example", + }, + ], + weight: -128, + }, + ], + stable: true, + status: "status_example", + statusDescription: "statusDescription_example", + stop: true, + submitTime: 1, + taskGroups: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + consul: { + namespace: "namespace_example", + }, + count: 1, + ephemeralDisk: { + migrate: true, + sizeMB: 1, + sticky: true, + }, + maxClientDisconnect: 1, + meta: { + "key": "key_example", + }, + migrate: { + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + }, + name: "name_example", + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + reschedulePolicy: { + attempts: 1, + delay: 1, + delayFunction: "delayFunction_example", + interval: 1, + maxDelay: 1, + unlimited: true, + }, + restartPolicy: { + attempts: 1, + delay: 1, + interval: 1, + mode: "mode_example", + }, + scaling: { + createIndex: 0, + enabled: true, + ID: "ID_example", + max: 1, + min: 1, + modifyIndex: 0, + namespace: "namespace_example", + policy: { + "key": null, + }, + target: { + "key": "key_example", + }, + type: "type_example", + }, + services: [ + { + address: "address_example", + addressMode: "addressMode_example", + canaryMeta: { + "key": "key_example", + }, + canaryTags: [ + "canaryTags_example", + ], + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + checks: [ + { + addressMode: "addressMode_example", + advertise: "advertise_example", + args: [ + "args_example", + ], + body: "body_example", + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + command: "command_example", + expose: true, + failuresBeforeCritical: 1, + gRPCService: "gRPCService_example", + gRPCUseTLS: true, + header: { + "key": [ + "key_example", + ], + }, + initialStatus: "initialStatus_example", + interval: 1, + method: "method_example", + name: "name_example", + onUpdate: "onUpdate_example", + path: "path_example", + portLabel: "portLabel_example", + protocol: "protocol_example", + successBeforePassing: 1, + tLSSkipVerify: true, + taskName: "taskName_example", + timeout: 1, + type: "type_example", + }, + ], + connect: { + gateway: { + ingress: { + listeners: [ + { + port: 1, + protocol: "protocol_example", + services: [ + { + hosts: [ + "hosts_example", + ], + name: "name_example", + }, + ], + }, + ], + TLS: { + cipherSuites: [ + "cipherSuites_example", + ], + enabled: true, + tLSMaxVersion: "tLSMaxVersion_example", + tLSMinVersion: "tLSMinVersion_example", + }, + }, + mesh: null, + proxy: { + config: { + "key": null, + }, + connectTimeout: 1, + envoyDNSDiscoveryType: "envoyDNSDiscoveryType_example", + envoyGatewayBindAddresses: { + "key": { + address: "address_example", + name: "name_example", + port: 1, + }, + }, + envoyGatewayBindTaggedAddresses: true, + envoyGatewayNoDefaultBind: true, + }, + terminating: { + services: [ + { + cAFile: "cAFile_example", + certFile: "certFile_example", + keyFile: "keyFile_example", + name: "name_example", + SNI: "SNI_example", + }, + ], + }, + }, + _native: true, + sidecarService: { + disableDefaultTCPCheck: true, + port: "port_example", + proxy: { + config: { + "key": null, + }, + exposeConfig: { + path: [ + { + listenerPort: "listenerPort_example", + localPathPort: 1, + path: "path_example", + protocol: "protocol_example", + }, + ], + }, + localServiceAddress: "localServiceAddress_example", + localServicePort: 1, + upstreams: [ + { + datacenter: "datacenter_example", + destinationName: "destinationName_example", + destinationNamespace: "destinationNamespace_example", + localBindAddress: "localBindAddress_example", + localBindPort: 1, + meshGateway: { + mode: "mode_example", + }, + }, + ], + }, + tags: [ + "tags_example", + ], + }, + sidecarTask: { + config: { + "key": null, + }, + driver: "driver_example", + env: { + "key": "key_example", + }, + killSignal: "killSignal_example", + killTimeout: 1, + logConfig: { + maxFileSizeMB: 1, + maxFiles: 1, + }, + meta: { + "key": "key_example", + }, + name: "name_example", + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + shutdownDelay: 1, + user: "user_example", + }, + }, + enableTagOverride: true, + meta: { + "key": "key_example", + }, + name: "name_example", + onUpdate: "onUpdate_example", + portLabel: "portLabel_example", + provider: "provider_example", + taggedAddresses: { + "key": "key_example", + }, + tags: [ + "tags_example", + ], + taskName: "taskName_example", + }, + ], + shutdownDelay: 1, + spreads: [ + { + attribute: "attribute_example", + spreadTarget: [ + { + percent: 0, + value: "value_example", + }, + ], + weight: -128, + }, + ], + stopAfterClientDisconnect: 1, + tasks: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + artifacts: [ + { + getterHeaders: { + "key": "key_example", + }, + getterMode: "getterMode_example", + getterOptions: { + "key": "key_example", + }, + getterSource: "getterSource_example", + relativeDest: "relativeDest_example", + }, + ], + cSIPluginConfig: { + healthTimeout: 1, + ID: "ID_example", + mountDir: "mountDir_example", + type: "type_example", + }, + config: { + "key": null, + }, + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + dispatchPayload: { + file: "file_example", + }, + driver: "driver_example", + env: { + "key": "key_example", + }, + killSignal: "killSignal_example", + killTimeout: 1, + kind: "kind_example", + leader: true, + lifecycle: { + hook: "hook_example", + sidecar: true, + }, + logConfig: { + maxFileSizeMB: 1, + maxFiles: 1, + }, + meta: { + "key": "key_example", + }, + name: "name_example", + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + restartPolicy: { + attempts: 1, + delay: 1, + interval: 1, + mode: "mode_example", + }, + scalingPolicies: [ + { + createIndex: 0, + enabled: true, + ID: "ID_example", + max: 1, + min: 1, + modifyIndex: 0, + namespace: "namespace_example", + policy: { + "key": null, + }, + target: { + "key": "key_example", + }, + type: "type_example", + }, + ], + services: [ + { + address: "address_example", + addressMode: "addressMode_example", + canaryMeta: { + "key": "key_example", + }, + canaryTags: [ + "canaryTags_example", + ], + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + checks: [ + { + addressMode: "addressMode_example", + advertise: "advertise_example", + args: [ + "args_example", + ], + body: "body_example", + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + command: "command_example", + expose: true, + failuresBeforeCritical: 1, + gRPCService: "gRPCService_example", + gRPCUseTLS: true, + header: { + "key": [ + "key_example", + ], + }, + initialStatus: "initialStatus_example", + interval: 1, + method: "method_example", + name: "name_example", + onUpdate: "onUpdate_example", + path: "path_example", + portLabel: "portLabel_example", + protocol: "protocol_example", + successBeforePassing: 1, + tLSSkipVerify: true, + taskName: "taskName_example", + timeout: 1, + type: "type_example", + }, + ], + connect: { + gateway: { + ingress: { + listeners: [ + { + port: 1, + protocol: "protocol_example", + services: [ + { + hosts: [ + "hosts_example", + ], + name: "name_example", + }, + ], + }, + ], + TLS: { + cipherSuites: [ + "cipherSuites_example", + ], + enabled: true, + tLSMaxVersion: "tLSMaxVersion_example", + tLSMinVersion: "tLSMinVersion_example", + }, + }, + mesh: null, + proxy: { + config: { + "key": null, + }, + connectTimeout: 1, + envoyDNSDiscoveryType: "envoyDNSDiscoveryType_example", + envoyGatewayBindAddresses: { + "key": { + address: "address_example", + name: "name_example", + port: 1, + }, + }, + envoyGatewayBindTaggedAddresses: true, + envoyGatewayNoDefaultBind: true, + }, + terminating: { + services: [ + { + cAFile: "cAFile_example", + certFile: "certFile_example", + keyFile: "keyFile_example", + name: "name_example", + SNI: "SNI_example", + }, + ], + }, + }, + _native: true, + sidecarService: { + disableDefaultTCPCheck: true, + port: "port_example", + proxy: { + config: { + "key": null, + }, + exposeConfig: { + path: [ + { + listenerPort: "listenerPort_example", + localPathPort: 1, + path: "path_example", + protocol: "protocol_example", + }, + ], + }, + localServiceAddress: "localServiceAddress_example", + localServicePort: 1, + upstreams: [ + { + datacenter: "datacenter_example", + destinationName: "destinationName_example", + destinationNamespace: "destinationNamespace_example", + localBindAddress: "localBindAddress_example", + localBindPort: 1, + meshGateway: { + mode: "mode_example", + }, + }, + ], + }, + tags: [ + "tags_example", + ], + }, + sidecarTask: { + config: { + "key": null, + }, + driver: "driver_example", + env: { + "key": "key_example", + }, + killSignal: "killSignal_example", + killTimeout: 1, + logConfig: { + maxFileSizeMB: 1, + maxFiles: 1, + }, + meta: { + "key": "key_example", + }, + name: "name_example", + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + shutdownDelay: 1, + user: "user_example", + }, + }, + enableTagOverride: true, + meta: { + "key": "key_example", + }, + name: "name_example", + onUpdate: "onUpdate_example", + portLabel: "portLabel_example", + provider: "provider_example", + taggedAddresses: { + "key": "key_example", + }, + tags: [ + "tags_example", + ], + taskName: "taskName_example", + }, + ], + shutdownDelay: 1, + templates: [ + { + changeMode: "changeMode_example", + changeSignal: "changeSignal_example", + destPath: "destPath_example", + embeddedTmpl: "embeddedTmpl_example", + envvars: true, + leftDelim: "leftDelim_example", + perms: "perms_example", + rightDelim: "rightDelim_example", + sourcePath: "sourcePath_example", + splay: 1, + vaultGrace: 1, + wait: { + max: 1, + min: 1, + }, + }, + ], + user: "user_example", + vault: { + changeMode: "changeMode_example", + changeSignal: "changeSignal_example", + env: true, + namespace: "namespace_example", + policies: [ + "policies_example", + ], + }, + volumeMounts: [ + { + destination: "destination_example", + propagationMode: "propagationMode_example", + readOnly: true, + volume: "volume_example", + }, + ], + }, + ], + update: { + autoPromote: true, + autoRevert: true, + canary: 1, + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + progressDeadline: 1, + stagger: 1, + }, + volumes: { + "key": { + accessMode: "accessMode_example", + attachmentMode: "attachmentMode_example", + mountOptions: { + fSType: "fSType_example", + mountFlags: [ + "mountFlags_example", + ], + }, + name: "name_example", + perAlloc: true, + readOnly: true, + source: "source_example", + type: "type_example", + }, + }, + }, + ], + type: "type_example", + update: { + autoPromote: true, + autoRevert: true, + canary: 1, + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + progressDeadline: 1, + stagger: 1, + }, + vaultNamespace: "vaultNamespace_example", + vaultToken: "vaultToken_example", + version: 0, + }, + jobID: "jobID_example", + metrics: { + allocationTime: 1, + classExhausted: { + "key": 1, + }, + classFiltered: { + "key": 1, + }, + coalescedFailures: 1, + constraintFiltered: { + "key": 1, + }, + dimensionExhausted: { + "key": 1, + }, + nodesAvailable: { + "key": 1, + }, + nodesEvaluated: 1, + nodesExhausted: 1, + nodesFiltered: 1, + quotaExhausted: [ + "quotaExhausted_example", + ], + resourcesExhausted: { + "key": { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + }, + scoreMetaData: [ + { + nodeID: "nodeID_example", + normScore: 3.14, + scores: { + "key": 3.14, + }, + }, + ], + scores: { + "key": 3.14, + }, + }, + modifyIndex: 0, + modifyTime: 1, + name: "name_example", + namespace: "namespace_example", + nextAllocation: "nextAllocation_example", + nodeID: "nodeID_example", + nodeName: "nodeName_example", + preemptedAllocations: [ + "preemptedAllocations_example", + ], + preemptedByAllocation: "preemptedByAllocation_example", + previousAllocation: "previousAllocation_example", + rescheduleTracker: { + events: [ + { + prevAllocID: "prevAllocID_example", + prevNodeID: "prevNodeID_example", + rescheduleTime: 1, + }, + ], + }, + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + services: { + "key": "key_example", + }, + taskGroup: "taskGroup_example", + taskResources: { + "key": { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + }, + taskStates: { + "key": { + events: [ + { + details: { + "key": "key_example", + }, + diskLimit: 1, + diskSize: 1, + displayMessage: "displayMessage_example", + downloadError: "downloadError_example", + driverError: "driverError_example", + driverMessage: "driverMessage_example", + exitCode: 1, + failedSibling: "failedSibling_example", + failsTask: true, + genericSource: "genericSource_example", + killError: "killError_example", + killReason: "killReason_example", + killTimeout: 1, + message: "message_example", + restartReason: "restartReason_example", + setupError: "setupError_example", + signal: 1, + startDelay: 1, + taskSignal: "taskSignal_example", + taskSignalReason: "taskSignalReason_example", + time: 1, + type: "type_example", + validationError: "validationError_example", + vaultError: "vaultError_example", + }, + ], + failed: true, + finishedAt: new Date('1970-01-01T00:00:00.00Z'), + lastRestart: new Date('1970-01-01T00:00:00.00Z'), + restarts: 0, + startedAt: new Date('1970-01-01T00:00:00.00Z'), + state: "state_example", + taskHandle: { + driverState: 'YQ==', + version: 1, + }, + }, + }, + }, + }, + requestedCapabilities: [ + { + accessMode: "accessMode_example", + attachmentMode: "attachmentMode_example", + }, + ], + requestedCapacityMax: 1, + requestedCapacityMin: 1, + requestedTopologies: { + preferred: [ + { + segments: { + "key": "key_example", + }, + }, + ], + required: [ + { + segments: { + "key": "key_example", + }, + }, + ], + }, + resourceExhausted: new Date('1970-01-01T00:00:00.00Z'), + schedulable: true, + secrets: { + "key": "key_example", + }, + snapshotID: "snapshotID_example", + topologies: [ + { + segments: { + "key": "key_example", + }, + }, + ], + writeAllocs: { + "key": { + allocModifyIndex: 0, + allocatedResources: { + shared: { + diskMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + ports: [ + { + hostIP: "hostIP_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + tasks: { + "key": { + cpu: { + cpuShares: 1, + }, + devices: [ + { + deviceIDs: [ + "deviceIDs_example", + ], + name: "name_example", + type: "type_example", + vendor: "vendor_example", + }, + ], + memory: { + memoryMB: 1, + memoryMaxMB: 1, + }, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + }, + }, + clientDescription: "clientDescription_example", + clientStatus: "clientStatus_example", + createIndex: 0, + createTime: 1, + deploymentID: "deploymentID_example", + deploymentStatus: { + canary: true, + healthy: true, + modifyIndex: 0, + timestamp: new Date('1970-01-01T00:00:00.00Z'), + }, + desiredDescription: "desiredDescription_example", + desiredStatus: "desiredStatus_example", + desiredTransition: { + migrate: true, + reschedule: true, + }, + evalID: "evalID_example", + followupEvalID: "followupEvalID_example", + ID: "ID_example", + job: { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + allAtOnce: true, + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + consulNamespace: "consulNamespace_example", + consulToken: "consulToken_example", + createIndex: 0, + datacenters: [ + "datacenters_example", + ], + dispatchIdempotencyToken: "dispatchIdempotencyToken_example", + dispatched: true, + ID: "ID_example", + jobModifyIndex: 0, + meta: { + "key": "key_example", + }, + migrate: { + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + }, + modifyIndex: 0, + multiregion: { + regions: [ + { + count: 1, + datacenters: [ + "datacenters_example", + ], + meta: { + "key": "key_example", + }, + name: "name_example", + }, + ], + strategy: { + maxParallel: 1, + onFailure: "onFailure_example", + }, + }, + name: "name_example", + namespace: "namespace_example", + nomadTokenID: "nomadTokenID_example", + parameterizedJob: { + metaOptional: [ + "metaOptional_example", + ], + metaRequired: [ + "metaRequired_example", + ], + payload: "payload_example", + }, + parentID: "parentID_example", + payload: 'YQ==', + periodic: { + enabled: true, + prohibitOverlap: true, + spec: "spec_example", + specType: "specType_example", + timeZone: "timeZone_example", + }, + priority: 1, + region: "region_example", + reschedule: { + attempts: 1, + delay: 1, + delayFunction: "delayFunction_example", + interval: 1, + maxDelay: 1, + unlimited: true, + }, + spreads: [ + { + attribute: "attribute_example", + spreadTarget: [ + { + percent: 0, + value: "value_example", + }, + ], + weight: -128, + }, + ], + stable: true, + status: "status_example", + statusDescription: "statusDescription_example", + stop: true, + submitTime: 1, + taskGroups: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + consul: { + namespace: "namespace_example", + }, + count: 1, + ephemeralDisk: { + migrate: true, + sizeMB: 1, + sticky: true, + }, + maxClientDisconnect: 1, + meta: { + "key": "key_example", + }, + migrate: { + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + }, + name: "name_example", + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + reschedulePolicy: { + attempts: 1, + delay: 1, + delayFunction: "delayFunction_example", + interval: 1, + maxDelay: 1, + unlimited: true, + }, + restartPolicy: { + attempts: 1, + delay: 1, + interval: 1, + mode: "mode_example", + }, + scaling: { + createIndex: 0, + enabled: true, + ID: "ID_example", + max: 1, + min: 1, + modifyIndex: 0, + namespace: "namespace_example", + policy: { + "key": null, + }, + target: { + "key": "key_example", + }, + type: "type_example", + }, + services: [ + { + address: "address_example", + addressMode: "addressMode_example", + canaryMeta: { + "key": "key_example", + }, + canaryTags: [ + "canaryTags_example", + ], + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + checks: [ + { + addressMode: "addressMode_example", + advertise: "advertise_example", + args: [ + "args_example", + ], + body: "body_example", + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + command: "command_example", + expose: true, + failuresBeforeCritical: 1, + gRPCService: "gRPCService_example", + gRPCUseTLS: true, + header: { + "key": [ + "key_example", + ], + }, + initialStatus: "initialStatus_example", + interval: 1, + method: "method_example", + name: "name_example", + onUpdate: "onUpdate_example", + path: "path_example", + portLabel: "portLabel_example", + protocol: "protocol_example", + successBeforePassing: 1, + tLSSkipVerify: true, + taskName: "taskName_example", + timeout: 1, + type: "type_example", + }, + ], + connect: { + gateway: { + ingress: { + listeners: [ + { + port: 1, + protocol: "protocol_example", + services: [ + { + hosts: [ + "hosts_example", + ], + name: "name_example", + }, + ], + }, + ], + TLS: { + cipherSuites: [ + "cipherSuites_example", + ], + enabled: true, + tLSMaxVersion: "tLSMaxVersion_example", + tLSMinVersion: "tLSMinVersion_example", + }, + }, + mesh: null, + proxy: { + config: { + "key": null, + }, + connectTimeout: 1, + envoyDNSDiscoveryType: "envoyDNSDiscoveryType_example", + envoyGatewayBindAddresses: { + "key": { + address: "address_example", + name: "name_example", + port: 1, + }, + }, + envoyGatewayBindTaggedAddresses: true, + envoyGatewayNoDefaultBind: true, + }, + terminating: { + services: [ + { + cAFile: "cAFile_example", + certFile: "certFile_example", + keyFile: "keyFile_example", + name: "name_example", + SNI: "SNI_example", + }, + ], + }, + }, + _native: true, + sidecarService: { + disableDefaultTCPCheck: true, + port: "port_example", + proxy: { + config: { + "key": null, + }, + exposeConfig: { + path: [ + { + listenerPort: "listenerPort_example", + localPathPort: 1, + path: "path_example", + protocol: "protocol_example", + }, + ], + }, + localServiceAddress: "localServiceAddress_example", + localServicePort: 1, + upstreams: [ + { + datacenter: "datacenter_example", + destinationName: "destinationName_example", + destinationNamespace: "destinationNamespace_example", + localBindAddress: "localBindAddress_example", + localBindPort: 1, + meshGateway: { + mode: "mode_example", + }, + }, + ], + }, + tags: [ + "tags_example", + ], + }, + sidecarTask: { + config: { + "key": null, + }, + driver: "driver_example", + env: { + "key": "key_example", + }, + killSignal: "killSignal_example", + killTimeout: 1, + logConfig: { + maxFileSizeMB: 1, + maxFiles: 1, + }, + meta: { + "key": "key_example", + }, + name: "name_example", + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + shutdownDelay: 1, + user: "user_example", + }, + }, + enableTagOverride: true, + meta: { + "key": "key_example", + }, + name: "name_example", + onUpdate: "onUpdate_example", + portLabel: "portLabel_example", + provider: "provider_example", + taggedAddresses: { + "key": "key_example", + }, + tags: [ + "tags_example", + ], + taskName: "taskName_example", + }, + ], + shutdownDelay: 1, + spreads: [ + { + attribute: "attribute_example", + spreadTarget: [ + { + percent: 0, + value: "value_example", + }, + ], + weight: -128, + }, + ], + stopAfterClientDisconnect: 1, + tasks: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + artifacts: [ + { + getterHeaders: { + "key": "key_example", + }, + getterMode: "getterMode_example", + getterOptions: { + "key": "key_example", + }, + getterSource: "getterSource_example", + relativeDest: "relativeDest_example", + }, + ], + cSIPluginConfig: { + healthTimeout: 1, + ID: "ID_example", + mountDir: "mountDir_example", + type: "type_example", + }, + config: { + "key": null, + }, + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + dispatchPayload: { + file: "file_example", + }, + driver: "driver_example", + env: { + "key": "key_example", + }, + killSignal: "killSignal_example", + killTimeout: 1, + kind: "kind_example", + leader: true, + lifecycle: { + hook: "hook_example", + sidecar: true, + }, + logConfig: { + maxFileSizeMB: 1, + maxFiles: 1, + }, + meta: { + "key": "key_example", + }, + name: "name_example", + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + restartPolicy: { + attempts: 1, + delay: 1, + interval: 1, + mode: "mode_example", + }, + scalingPolicies: [ + { + createIndex: 0, + enabled: true, + ID: "ID_example", + max: 1, + min: 1, + modifyIndex: 0, + namespace: "namespace_example", + policy: { + "key": null, + }, + target: { + "key": "key_example", + }, + type: "type_example", + }, + ], + services: [ + { + address: "address_example", + addressMode: "addressMode_example", + canaryMeta: { + "key": "key_example", + }, + canaryTags: [ + "canaryTags_example", + ], + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + checks: [ + { + addressMode: "addressMode_example", + advertise: "advertise_example", + args: [ + "args_example", + ], + body: "body_example", + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + command: "command_example", + expose: true, + failuresBeforeCritical: 1, + gRPCService: "gRPCService_example", + gRPCUseTLS: true, + header: { + "key": [ + "key_example", + ], + }, + initialStatus: "initialStatus_example", + interval: 1, + method: "method_example", + name: "name_example", + onUpdate: "onUpdate_example", + path: "path_example", + portLabel: "portLabel_example", + protocol: "protocol_example", + successBeforePassing: 1, + tLSSkipVerify: true, + taskName: "taskName_example", + timeout: 1, + type: "type_example", + }, + ], + connect: { + gateway: { + ingress: { + listeners: [ + { + port: 1, + protocol: "protocol_example", + services: [ + { + hosts: [ + "hosts_example", + ], + name: "name_example", + }, + ], + }, + ], + TLS: { + cipherSuites: [ + "cipherSuites_example", + ], + enabled: true, + tLSMaxVersion: "tLSMaxVersion_example", + tLSMinVersion: "tLSMinVersion_example", + }, + }, + mesh: null, + proxy: { + config: { + "key": null, + }, + connectTimeout: 1, + envoyDNSDiscoveryType: "envoyDNSDiscoveryType_example", + envoyGatewayBindAddresses: { + "key": { + address: "address_example", + name: "name_example", + port: 1, + }, + }, + envoyGatewayBindTaggedAddresses: true, + envoyGatewayNoDefaultBind: true, + }, + terminating: { + services: [ + { + cAFile: "cAFile_example", + certFile: "certFile_example", + keyFile: "keyFile_example", + name: "name_example", + SNI: "SNI_example", + }, + ], + }, + }, + _native: true, + sidecarService: { + disableDefaultTCPCheck: true, + port: "port_example", + proxy: { + config: { + "key": null, + }, + exposeConfig: { + path: [ + { + listenerPort: "listenerPort_example", + localPathPort: 1, + path: "path_example", + protocol: "protocol_example", + }, + ], + }, + localServiceAddress: "localServiceAddress_example", + localServicePort: 1, + upstreams: [ + { + datacenter: "datacenter_example", + destinationName: "destinationName_example", + destinationNamespace: "destinationNamespace_example", + localBindAddress: "localBindAddress_example", + localBindPort: 1, + meshGateway: { + mode: "mode_example", + }, + }, + ], + }, + tags: [ + "tags_example", + ], + }, + sidecarTask: { + config: { + "key": null, + }, + driver: "driver_example", + env: { + "key": "key_example", + }, + killSignal: "killSignal_example", + killTimeout: 1, + logConfig: { + maxFileSizeMB: 1, + maxFiles: 1, + }, + meta: { + "key": "key_example", + }, + name: "name_example", + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + shutdownDelay: 1, + user: "user_example", + }, + }, + enableTagOverride: true, + meta: { + "key": "key_example", + }, + name: "name_example", + onUpdate: "onUpdate_example", + portLabel: "portLabel_example", + provider: "provider_example", + taggedAddresses: { + "key": "key_example", + }, + tags: [ + "tags_example", + ], + taskName: "taskName_example", + }, + ], + shutdownDelay: 1, + templates: [ + { + changeMode: "changeMode_example", + changeSignal: "changeSignal_example", + destPath: "destPath_example", + embeddedTmpl: "embeddedTmpl_example", + envvars: true, + leftDelim: "leftDelim_example", + perms: "perms_example", + rightDelim: "rightDelim_example", + sourcePath: "sourcePath_example", + splay: 1, + vaultGrace: 1, + wait: { + max: 1, + min: 1, + }, + }, + ], + user: "user_example", + vault: { + changeMode: "changeMode_example", + changeSignal: "changeSignal_example", + env: true, + namespace: "namespace_example", + policies: [ + "policies_example", + ], + }, + volumeMounts: [ + { + destination: "destination_example", + propagationMode: "propagationMode_example", + readOnly: true, + volume: "volume_example", + }, + ], + }, + ], + update: { + autoPromote: true, + autoRevert: true, + canary: 1, + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + progressDeadline: 1, + stagger: 1, + }, + volumes: { + "key": { + accessMode: "accessMode_example", + attachmentMode: "attachmentMode_example", + mountOptions: { + fSType: "fSType_example", + mountFlags: [ + "mountFlags_example", + ], + }, + name: "name_example", + perAlloc: true, + readOnly: true, + source: "source_example", + type: "type_example", + }, + }, + }, + ], + type: "type_example", + update: { + autoPromote: true, + autoRevert: true, + canary: 1, + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + progressDeadline: 1, + stagger: 1, + }, + vaultNamespace: "vaultNamespace_example", + vaultToken: "vaultToken_example", + version: 0, + }, + jobID: "jobID_example", + metrics: { + allocationTime: 1, + classExhausted: { + "key": 1, + }, + classFiltered: { + "key": 1, + }, + coalescedFailures: 1, + constraintFiltered: { + "key": 1, + }, + dimensionExhausted: { + "key": 1, + }, + nodesAvailable: { + "key": 1, + }, + nodesEvaluated: 1, + nodesExhausted: 1, + nodesFiltered: 1, + quotaExhausted: [ + "quotaExhausted_example", + ], + resourcesExhausted: { + "key": { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + }, + scoreMetaData: [ + { + nodeID: "nodeID_example", + normScore: 3.14, + scores: { + "key": 3.14, + }, + }, + ], + scores: { + "key": 3.14, + }, + }, + modifyIndex: 0, + modifyTime: 1, + name: "name_example", + namespace: "namespace_example", + nextAllocation: "nextAllocation_example", + nodeID: "nodeID_example", + nodeName: "nodeName_example", + preemptedAllocations: [ + "preemptedAllocations_example", + ], + preemptedByAllocation: "preemptedByAllocation_example", + previousAllocation: "previousAllocation_example", + rescheduleTracker: { + events: [ + { + prevAllocID: "prevAllocID_example", + prevNodeID: "prevNodeID_example", + rescheduleTime: 1, + }, + ], + }, + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + services: { + "key": "key_example", + }, + taskGroup: "taskGroup_example", + taskResources: { + "key": { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + }, + taskStates: { + "key": { + events: [ + { + details: { + "key": "key_example", + }, + diskLimit: 1, + diskSize: 1, + displayMessage: "displayMessage_example", + downloadError: "downloadError_example", + driverError: "driverError_example", + driverMessage: "driverMessage_example", + exitCode: 1, + failedSibling: "failedSibling_example", + failsTask: true, + genericSource: "genericSource_example", + killError: "killError_example", + killReason: "killReason_example", + killTimeout: 1, + message: "message_example", + restartReason: "restartReason_example", + setupError: "setupError_example", + signal: 1, + startDelay: 1, + taskSignal: "taskSignal_example", + taskSignalReason: "taskSignalReason_example", + time: 1, + type: "type_example", + validationError: "validationError_example", + vaultError: "vaultError_example", + }, + ], + failed: true, + finishedAt: new Date('1970-01-01T00:00:00.00Z'), + lastRestart: new Date('1970-01-01T00:00:00.00Z'), + restarts: 0, + startedAt: new Date('1970-01-01T00:00:00.00Z'), + state: "state_example", + taskHandle: { + driverState: 'YQ==', + version: 1, + }, + }, + }, + }, + }, + }, + ], + }, + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.postVolume(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **cSIVolumeRegisterRequest** | **CSIVolumeRegisterRequest**| | + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**void** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: Not defined + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
* X-Nomad-KnownLeader - Boolean indicating if there is a known cluster leader.
* X-Nomad-LastContact - The time in milliseconds that a server was last contacted by the leader node.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + +# **postVolumeRegistration** +> void postVolumeRegistration(cSIVolumeRegisterRequest) + + +### Example + + +```typescript +import { nomad-client } from ''; +import * as fs from 'fs'; + +const configuration = nomad-client.createConfiguration(); +const apiInstance = new nomad-client.VolumesApi(configuration); + +let body:nomad-client.VolumesApiPostVolumeRegistrationRequest = { + // string | Volume unique identifier. + volumeId: "volumeId_example", + // CSIVolumeRegisterRequest + cSIVolumeRegisterRequest: { + namespace: "namespace_example", + region: "region_example", + secretID: "secretID_example", + volumes: [ + { + accessMode: "accessMode_example", + allocations: [ + { + allocatedResources: { + shared: { + diskMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + ports: [ + { + hostIP: "hostIP_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + tasks: { + "key": { + cpu: { + cpuShares: 1, + }, + devices: [ + { + deviceIDs: [ + "deviceIDs_example", + ], + name: "name_example", + type: "type_example", + vendor: "vendor_example", + }, + ], + memory: { + memoryMB: 1, + memoryMaxMB: 1, + }, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + }, + }, + clientDescription: "clientDescription_example", + clientStatus: "clientStatus_example", + createIndex: 0, + createTime: 1, + deploymentStatus: { + canary: true, + healthy: true, + modifyIndex: 0, + timestamp: new Date('1970-01-01T00:00:00.00Z'), + }, + desiredDescription: "desiredDescription_example", + desiredStatus: "desiredStatus_example", + evalID: "evalID_example", + followupEvalID: "followupEvalID_example", + ID: "ID_example", + jobID: "jobID_example", + jobType: "jobType_example", + jobVersion: 0, + modifyIndex: 0, + modifyTime: 1, + name: "name_example", + namespace: "namespace_example", + nodeID: "nodeID_example", + nodeName: "nodeName_example", + preemptedAllocations: [ + "preemptedAllocations_example", + ], + preemptedByAllocation: "preemptedByAllocation_example", + rescheduleTracker: { + events: [ + { + prevAllocID: "prevAllocID_example", + prevNodeID: "prevNodeID_example", + rescheduleTime: 1, + }, + ], + }, + taskGroup: "taskGroup_example", + taskStates: { + "key": { + events: [ + { + details: { + "key": "key_example", + }, + diskLimit: 1, + diskSize: 1, + displayMessage: "displayMessage_example", + downloadError: "downloadError_example", + driverError: "driverError_example", + driverMessage: "driverMessage_example", + exitCode: 1, + failedSibling: "failedSibling_example", + failsTask: true, + genericSource: "genericSource_example", + killError: "killError_example", + killReason: "killReason_example", + killTimeout: 1, + message: "message_example", + restartReason: "restartReason_example", + setupError: "setupError_example", + signal: 1, + startDelay: 1, + taskSignal: "taskSignal_example", + taskSignalReason: "taskSignalReason_example", + time: 1, + type: "type_example", + validationError: "validationError_example", + vaultError: "vaultError_example", + }, + ], + failed: true, + finishedAt: new Date('1970-01-01T00:00:00.00Z'), + lastRestart: new Date('1970-01-01T00:00:00.00Z'), + restarts: 0, + startedAt: new Date('1970-01-01T00:00:00.00Z'), + state: "state_example", + taskHandle: { + driverState: 'YQ==', + version: 1, + }, + }, + }, + }, + ], + attachmentMode: "attachmentMode_example", + capacity: 1, + cloneID: "cloneID_example", + context: { + "key": "key_example", + }, + controllerRequired: true, + controllersExpected: 1, + controllersHealthy: 1, + createIndex: 0, + externalID: "externalID_example", + ID: "ID_example", + modifyIndex: 0, + mountOptions: { + fSType: "fSType_example", + mountFlags: [ + "mountFlags_example", + ], + }, + name: "name_example", + namespace: "namespace_example", + nodesExpected: 1, + nodesHealthy: 1, + parameters: { + "key": "key_example", + }, + pluginID: "pluginID_example", + provider: "provider_example", + providerVersion: "providerVersion_example", + readAllocs: { + "key": { + allocModifyIndex: 0, + allocatedResources: { + shared: { + diskMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + ports: [ + { + hostIP: "hostIP_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + tasks: { + "key": { + cpu: { + cpuShares: 1, + }, + devices: [ + { + deviceIDs: [ + "deviceIDs_example", + ], + name: "name_example", + type: "type_example", + vendor: "vendor_example", + }, + ], + memory: { + memoryMB: 1, + memoryMaxMB: 1, + }, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + }, + }, + clientDescription: "clientDescription_example", + clientStatus: "clientStatus_example", + createIndex: 0, + createTime: 1, + deploymentID: "deploymentID_example", + deploymentStatus: { + canary: true, + healthy: true, + modifyIndex: 0, + timestamp: new Date('1970-01-01T00:00:00.00Z'), + }, + desiredDescription: "desiredDescription_example", + desiredStatus: "desiredStatus_example", + desiredTransition: { + migrate: true, + reschedule: true, + }, + evalID: "evalID_example", + followupEvalID: "followupEvalID_example", + ID: "ID_example", + job: { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + allAtOnce: true, + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + consulNamespace: "consulNamespace_example", + consulToken: "consulToken_example", + createIndex: 0, + datacenters: [ + "datacenters_example", + ], + dispatchIdempotencyToken: "dispatchIdempotencyToken_example", + dispatched: true, + ID: "ID_example", + jobModifyIndex: 0, + meta: { + "key": "key_example", + }, + migrate: { + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + }, + modifyIndex: 0, + multiregion: { + regions: [ + { + count: 1, + datacenters: [ + "datacenters_example", + ], + meta: { + "key": "key_example", + }, + name: "name_example", + }, + ], + strategy: { + maxParallel: 1, + onFailure: "onFailure_example", + }, + }, + name: "name_example", + namespace: "namespace_example", + nomadTokenID: "nomadTokenID_example", + parameterizedJob: { + metaOptional: [ + "metaOptional_example", + ], + metaRequired: [ + "metaRequired_example", + ], + payload: "payload_example", + }, + parentID: "parentID_example", + payload: 'YQ==', + periodic: { + enabled: true, + prohibitOverlap: true, + spec: "spec_example", + specType: "specType_example", + timeZone: "timeZone_example", + }, + priority: 1, + region: "region_example", + reschedule: { + attempts: 1, + delay: 1, + delayFunction: "delayFunction_example", + interval: 1, + maxDelay: 1, + unlimited: true, + }, + spreads: [ + { + attribute: "attribute_example", + spreadTarget: [ + { + percent: 0, + value: "value_example", + }, + ], + weight: -128, + }, + ], + stable: true, + status: "status_example", + statusDescription: "statusDescription_example", + stop: true, + submitTime: 1, + taskGroups: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + consul: { + namespace: "namespace_example", + }, + count: 1, + ephemeralDisk: { + migrate: true, + sizeMB: 1, + sticky: true, + }, + maxClientDisconnect: 1, + meta: { + "key": "key_example", + }, + migrate: { + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + }, + name: "name_example", + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + reschedulePolicy: { + attempts: 1, + delay: 1, + delayFunction: "delayFunction_example", + interval: 1, + maxDelay: 1, + unlimited: true, + }, + restartPolicy: { + attempts: 1, + delay: 1, + interval: 1, + mode: "mode_example", + }, + scaling: { + createIndex: 0, + enabled: true, + ID: "ID_example", + max: 1, + min: 1, + modifyIndex: 0, + namespace: "namespace_example", + policy: { + "key": null, + }, + target: { + "key": "key_example", + }, + type: "type_example", + }, + services: [ + { + address: "address_example", + addressMode: "addressMode_example", + canaryMeta: { + "key": "key_example", + }, + canaryTags: [ + "canaryTags_example", + ], + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + checks: [ + { + addressMode: "addressMode_example", + advertise: "advertise_example", + args: [ + "args_example", + ], + body: "body_example", + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + command: "command_example", + expose: true, + failuresBeforeCritical: 1, + gRPCService: "gRPCService_example", + gRPCUseTLS: true, + header: { + "key": [ + "key_example", + ], + }, + initialStatus: "initialStatus_example", + interval: 1, + method: "method_example", + name: "name_example", + onUpdate: "onUpdate_example", + path: "path_example", + portLabel: "portLabel_example", + protocol: "protocol_example", + successBeforePassing: 1, + tLSSkipVerify: true, + taskName: "taskName_example", + timeout: 1, + type: "type_example", + }, + ], + connect: { + gateway: { + ingress: { + listeners: [ + { + port: 1, + protocol: "protocol_example", + services: [ + { + hosts: [ + "hosts_example", + ], + name: "name_example", + }, + ], + }, + ], + TLS: { + cipherSuites: [ + "cipherSuites_example", + ], + enabled: true, + tLSMaxVersion: "tLSMaxVersion_example", + tLSMinVersion: "tLSMinVersion_example", + }, + }, + mesh: null, + proxy: { + config: { + "key": null, + }, + connectTimeout: 1, + envoyDNSDiscoveryType: "envoyDNSDiscoveryType_example", + envoyGatewayBindAddresses: { + "key": { + address: "address_example", + name: "name_example", + port: 1, + }, + }, + envoyGatewayBindTaggedAddresses: true, + envoyGatewayNoDefaultBind: true, + }, + terminating: { + services: [ + { + cAFile: "cAFile_example", + certFile: "certFile_example", + keyFile: "keyFile_example", + name: "name_example", + SNI: "SNI_example", + }, + ], + }, + }, + _native: true, + sidecarService: { + disableDefaultTCPCheck: true, + port: "port_example", + proxy: { + config: { + "key": null, + }, + exposeConfig: { + path: [ + { + listenerPort: "listenerPort_example", + localPathPort: 1, + path: "path_example", + protocol: "protocol_example", + }, + ], + }, + localServiceAddress: "localServiceAddress_example", + localServicePort: 1, + upstreams: [ + { + datacenter: "datacenter_example", + destinationName: "destinationName_example", + destinationNamespace: "destinationNamespace_example", + localBindAddress: "localBindAddress_example", + localBindPort: 1, + meshGateway: { + mode: "mode_example", + }, + }, + ], + }, + tags: [ + "tags_example", + ], + }, + sidecarTask: { + config: { + "key": null, + }, + driver: "driver_example", + env: { + "key": "key_example", + }, + killSignal: "killSignal_example", + killTimeout: 1, + logConfig: { + maxFileSizeMB: 1, + maxFiles: 1, + }, + meta: { + "key": "key_example", + }, + name: "name_example", + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + shutdownDelay: 1, + user: "user_example", + }, + }, + enableTagOverride: true, + meta: { + "key": "key_example", + }, + name: "name_example", + onUpdate: "onUpdate_example", + portLabel: "portLabel_example", + provider: "provider_example", + taggedAddresses: { + "key": "key_example", + }, + tags: [ + "tags_example", + ], + taskName: "taskName_example", + }, + ], + shutdownDelay: 1, + spreads: [ + { + attribute: "attribute_example", + spreadTarget: [ + { + percent: 0, + value: "value_example", + }, + ], + weight: -128, + }, + ], + stopAfterClientDisconnect: 1, + tasks: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + artifacts: [ + { + getterHeaders: { + "key": "key_example", + }, + getterMode: "getterMode_example", + getterOptions: { + "key": "key_example", + }, + getterSource: "getterSource_example", + relativeDest: "relativeDest_example", + }, + ], + cSIPluginConfig: { + healthTimeout: 1, + ID: "ID_example", + mountDir: "mountDir_example", + type: "type_example", + }, + config: { + "key": null, + }, + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + dispatchPayload: { + file: "file_example", + }, + driver: "driver_example", + env: { + "key": "key_example", + }, + killSignal: "killSignal_example", + killTimeout: 1, + kind: "kind_example", + leader: true, + lifecycle: { + hook: "hook_example", + sidecar: true, + }, + logConfig: { + maxFileSizeMB: 1, + maxFiles: 1, + }, + meta: { + "key": "key_example", + }, + name: "name_example", + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + restartPolicy: { + attempts: 1, + delay: 1, + interval: 1, + mode: "mode_example", + }, + scalingPolicies: [ + { + createIndex: 0, + enabled: true, + ID: "ID_example", + max: 1, + min: 1, + modifyIndex: 0, + namespace: "namespace_example", + policy: { + "key": null, + }, + target: { + "key": "key_example", + }, + type: "type_example", + }, + ], + services: [ + { + address: "address_example", + addressMode: "addressMode_example", + canaryMeta: { + "key": "key_example", + }, + canaryTags: [ + "canaryTags_example", + ], + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + checks: [ + { + addressMode: "addressMode_example", + advertise: "advertise_example", + args: [ + "args_example", + ], + body: "body_example", + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + command: "command_example", + expose: true, + failuresBeforeCritical: 1, + gRPCService: "gRPCService_example", + gRPCUseTLS: true, + header: { + "key": [ + "key_example", + ], + }, + initialStatus: "initialStatus_example", + interval: 1, + method: "method_example", + name: "name_example", + onUpdate: "onUpdate_example", + path: "path_example", + portLabel: "portLabel_example", + protocol: "protocol_example", + successBeforePassing: 1, + tLSSkipVerify: true, + taskName: "taskName_example", + timeout: 1, + type: "type_example", + }, + ], + connect: { + gateway: { + ingress: { + listeners: [ + { + port: 1, + protocol: "protocol_example", + services: [ + { + hosts: [ + "hosts_example", + ], + name: "name_example", + }, + ], + }, + ], + TLS: { + cipherSuites: [ + "cipherSuites_example", + ], + enabled: true, + tLSMaxVersion: "tLSMaxVersion_example", + tLSMinVersion: "tLSMinVersion_example", + }, + }, + mesh: null, + proxy: { + config: { + "key": null, + }, + connectTimeout: 1, + envoyDNSDiscoveryType: "envoyDNSDiscoveryType_example", + envoyGatewayBindAddresses: { + "key": { + address: "address_example", + name: "name_example", + port: 1, + }, + }, + envoyGatewayBindTaggedAddresses: true, + envoyGatewayNoDefaultBind: true, + }, + terminating: { + services: [ + { + cAFile: "cAFile_example", + certFile: "certFile_example", + keyFile: "keyFile_example", + name: "name_example", + SNI: "SNI_example", + }, + ], + }, + }, + _native: true, + sidecarService: { + disableDefaultTCPCheck: true, + port: "port_example", + proxy: { + config: { + "key": null, + }, + exposeConfig: { + path: [ + { + listenerPort: "listenerPort_example", + localPathPort: 1, + path: "path_example", + protocol: "protocol_example", + }, + ], + }, + localServiceAddress: "localServiceAddress_example", + localServicePort: 1, + upstreams: [ + { + datacenter: "datacenter_example", + destinationName: "destinationName_example", + destinationNamespace: "destinationNamespace_example", + localBindAddress: "localBindAddress_example", + localBindPort: 1, + meshGateway: { + mode: "mode_example", + }, + }, + ], + }, + tags: [ + "tags_example", + ], + }, + sidecarTask: { + config: { + "key": null, + }, + driver: "driver_example", + env: { + "key": "key_example", + }, + killSignal: "killSignal_example", + killTimeout: 1, + logConfig: { + maxFileSizeMB: 1, + maxFiles: 1, + }, + meta: { + "key": "key_example", + }, + name: "name_example", + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + shutdownDelay: 1, + user: "user_example", + }, + }, + enableTagOverride: true, + meta: { + "key": "key_example", + }, + name: "name_example", + onUpdate: "onUpdate_example", + portLabel: "portLabel_example", + provider: "provider_example", + taggedAddresses: { + "key": "key_example", + }, + tags: [ + "tags_example", + ], + taskName: "taskName_example", + }, + ], + shutdownDelay: 1, + templates: [ + { + changeMode: "changeMode_example", + changeSignal: "changeSignal_example", + destPath: "destPath_example", + embeddedTmpl: "embeddedTmpl_example", + envvars: true, + leftDelim: "leftDelim_example", + perms: "perms_example", + rightDelim: "rightDelim_example", + sourcePath: "sourcePath_example", + splay: 1, + vaultGrace: 1, + wait: { + max: 1, + min: 1, + }, + }, + ], + user: "user_example", + vault: { + changeMode: "changeMode_example", + changeSignal: "changeSignal_example", + env: true, + namespace: "namespace_example", + policies: [ + "policies_example", + ], + }, + volumeMounts: [ + { + destination: "destination_example", + propagationMode: "propagationMode_example", + readOnly: true, + volume: "volume_example", + }, + ], + }, + ], + update: { + autoPromote: true, + autoRevert: true, + canary: 1, + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + progressDeadline: 1, + stagger: 1, + }, + volumes: { + "key": { + accessMode: "accessMode_example", + attachmentMode: "attachmentMode_example", + mountOptions: { + fSType: "fSType_example", + mountFlags: [ + "mountFlags_example", + ], + }, + name: "name_example", + perAlloc: true, + readOnly: true, + source: "source_example", + type: "type_example", + }, + }, + }, + ], + type: "type_example", + update: { + autoPromote: true, + autoRevert: true, + canary: 1, + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + progressDeadline: 1, + stagger: 1, + }, + vaultNamespace: "vaultNamespace_example", + vaultToken: "vaultToken_example", + version: 0, + }, + jobID: "jobID_example", + metrics: { + allocationTime: 1, + classExhausted: { + "key": 1, + }, + classFiltered: { + "key": 1, + }, + coalescedFailures: 1, + constraintFiltered: { + "key": 1, + }, + dimensionExhausted: { + "key": 1, + }, + nodesAvailable: { + "key": 1, + }, + nodesEvaluated: 1, + nodesExhausted: 1, + nodesFiltered: 1, + quotaExhausted: [ + "quotaExhausted_example", + ], + resourcesExhausted: { + "key": { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + }, + scoreMetaData: [ + { + nodeID: "nodeID_example", + normScore: 3.14, + scores: { + "key": 3.14, + }, + }, + ], + scores: { + "key": 3.14, + }, + }, + modifyIndex: 0, + modifyTime: 1, + name: "name_example", + namespace: "namespace_example", + nextAllocation: "nextAllocation_example", + nodeID: "nodeID_example", + nodeName: "nodeName_example", + preemptedAllocations: [ + "preemptedAllocations_example", + ], + preemptedByAllocation: "preemptedByAllocation_example", + previousAllocation: "previousAllocation_example", + rescheduleTracker: { + events: [ + { + prevAllocID: "prevAllocID_example", + prevNodeID: "prevNodeID_example", + rescheduleTime: 1, + }, + ], + }, + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + services: { + "key": "key_example", + }, + taskGroup: "taskGroup_example", + taskResources: { + "key": { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + }, + taskStates: { + "key": { + events: [ + { + details: { + "key": "key_example", + }, + diskLimit: 1, + diskSize: 1, + displayMessage: "displayMessage_example", + downloadError: "downloadError_example", + driverError: "driverError_example", + driverMessage: "driverMessage_example", + exitCode: 1, + failedSibling: "failedSibling_example", + failsTask: true, + genericSource: "genericSource_example", + killError: "killError_example", + killReason: "killReason_example", + killTimeout: 1, + message: "message_example", + restartReason: "restartReason_example", + setupError: "setupError_example", + signal: 1, + startDelay: 1, + taskSignal: "taskSignal_example", + taskSignalReason: "taskSignalReason_example", + time: 1, + type: "type_example", + validationError: "validationError_example", + vaultError: "vaultError_example", + }, + ], + failed: true, + finishedAt: new Date('1970-01-01T00:00:00.00Z'), + lastRestart: new Date('1970-01-01T00:00:00.00Z'), + restarts: 0, + startedAt: new Date('1970-01-01T00:00:00.00Z'), + state: "state_example", + taskHandle: { + driverState: 'YQ==', + version: 1, + }, + }, + }, + }, + }, + requestedCapabilities: [ + { + accessMode: "accessMode_example", + attachmentMode: "attachmentMode_example", + }, + ], + requestedCapacityMax: 1, + requestedCapacityMin: 1, + requestedTopologies: { + preferred: [ + { + segments: { + "key": "key_example", + }, + }, + ], + required: [ + { + segments: { + "key": "key_example", + }, + }, + ], + }, + resourceExhausted: new Date('1970-01-01T00:00:00.00Z'), + schedulable: true, + secrets: { + "key": "key_example", + }, + snapshotID: "snapshotID_example", + topologies: [ + { + segments: { + "key": "key_example", + }, + }, + ], + writeAllocs: { + "key": { + allocModifyIndex: 0, + allocatedResources: { + shared: { + diskMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + ports: [ + { + hostIP: "hostIP_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + tasks: { + "key": { + cpu: { + cpuShares: 1, + }, + devices: [ + { + deviceIDs: [ + "deviceIDs_example", + ], + name: "name_example", + type: "type_example", + vendor: "vendor_example", + }, + ], + memory: { + memoryMB: 1, + memoryMaxMB: 1, + }, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + }, + }, + clientDescription: "clientDescription_example", + clientStatus: "clientStatus_example", + createIndex: 0, + createTime: 1, + deploymentID: "deploymentID_example", + deploymentStatus: { + canary: true, + healthy: true, + modifyIndex: 0, + timestamp: new Date('1970-01-01T00:00:00.00Z'), + }, + desiredDescription: "desiredDescription_example", + desiredStatus: "desiredStatus_example", + desiredTransition: { + migrate: true, + reschedule: true, + }, + evalID: "evalID_example", + followupEvalID: "followupEvalID_example", + ID: "ID_example", + job: { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + allAtOnce: true, + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + consulNamespace: "consulNamespace_example", + consulToken: "consulToken_example", + createIndex: 0, + datacenters: [ + "datacenters_example", + ], + dispatchIdempotencyToken: "dispatchIdempotencyToken_example", + dispatched: true, + ID: "ID_example", + jobModifyIndex: 0, + meta: { + "key": "key_example", + }, + migrate: { + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + }, + modifyIndex: 0, + multiregion: { + regions: [ + { + count: 1, + datacenters: [ + "datacenters_example", + ], + meta: { + "key": "key_example", + }, + name: "name_example", + }, + ], + strategy: { + maxParallel: 1, + onFailure: "onFailure_example", + }, + }, + name: "name_example", + namespace: "namespace_example", + nomadTokenID: "nomadTokenID_example", + parameterizedJob: { + metaOptional: [ + "metaOptional_example", + ], + metaRequired: [ + "metaRequired_example", + ], + payload: "payload_example", + }, + parentID: "parentID_example", + payload: 'YQ==', + periodic: { + enabled: true, + prohibitOverlap: true, + spec: "spec_example", + specType: "specType_example", + timeZone: "timeZone_example", + }, + priority: 1, + region: "region_example", + reschedule: { + attempts: 1, + delay: 1, + delayFunction: "delayFunction_example", + interval: 1, + maxDelay: 1, + unlimited: true, + }, + spreads: [ + { + attribute: "attribute_example", + spreadTarget: [ + { + percent: 0, + value: "value_example", + }, + ], + weight: -128, + }, + ], + stable: true, + status: "status_example", + statusDescription: "statusDescription_example", + stop: true, + submitTime: 1, + taskGroups: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + consul: { + namespace: "namespace_example", + }, + count: 1, + ephemeralDisk: { + migrate: true, + sizeMB: 1, + sticky: true, + }, + maxClientDisconnect: 1, + meta: { + "key": "key_example", + }, + migrate: { + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + }, + name: "name_example", + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + reschedulePolicy: { + attempts: 1, + delay: 1, + delayFunction: "delayFunction_example", + interval: 1, + maxDelay: 1, + unlimited: true, + }, + restartPolicy: { + attempts: 1, + delay: 1, + interval: 1, + mode: "mode_example", + }, + scaling: { + createIndex: 0, + enabled: true, + ID: "ID_example", + max: 1, + min: 1, + modifyIndex: 0, + namespace: "namespace_example", + policy: { + "key": null, + }, + target: { + "key": "key_example", + }, + type: "type_example", + }, + services: [ + { + address: "address_example", + addressMode: "addressMode_example", + canaryMeta: { + "key": "key_example", + }, + canaryTags: [ + "canaryTags_example", + ], + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + checks: [ + { + addressMode: "addressMode_example", + advertise: "advertise_example", + args: [ + "args_example", + ], + body: "body_example", + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + command: "command_example", + expose: true, + failuresBeforeCritical: 1, + gRPCService: "gRPCService_example", + gRPCUseTLS: true, + header: { + "key": [ + "key_example", + ], + }, + initialStatus: "initialStatus_example", + interval: 1, + method: "method_example", + name: "name_example", + onUpdate: "onUpdate_example", + path: "path_example", + portLabel: "portLabel_example", + protocol: "protocol_example", + successBeforePassing: 1, + tLSSkipVerify: true, + taskName: "taskName_example", + timeout: 1, + type: "type_example", + }, + ], + connect: { + gateway: { + ingress: { + listeners: [ + { + port: 1, + protocol: "protocol_example", + services: [ + { + hosts: [ + "hosts_example", + ], + name: "name_example", + }, + ], + }, + ], + TLS: { + cipherSuites: [ + "cipherSuites_example", + ], + enabled: true, + tLSMaxVersion: "tLSMaxVersion_example", + tLSMinVersion: "tLSMinVersion_example", + }, + }, + mesh: null, + proxy: { + config: { + "key": null, + }, + connectTimeout: 1, + envoyDNSDiscoveryType: "envoyDNSDiscoveryType_example", + envoyGatewayBindAddresses: { + "key": { + address: "address_example", + name: "name_example", + port: 1, + }, + }, + envoyGatewayBindTaggedAddresses: true, + envoyGatewayNoDefaultBind: true, + }, + terminating: { + services: [ + { + cAFile: "cAFile_example", + certFile: "certFile_example", + keyFile: "keyFile_example", + name: "name_example", + SNI: "SNI_example", + }, + ], + }, + }, + _native: true, + sidecarService: { + disableDefaultTCPCheck: true, + port: "port_example", + proxy: { + config: { + "key": null, + }, + exposeConfig: { + path: [ + { + listenerPort: "listenerPort_example", + localPathPort: 1, + path: "path_example", + protocol: "protocol_example", + }, + ], + }, + localServiceAddress: "localServiceAddress_example", + localServicePort: 1, + upstreams: [ + { + datacenter: "datacenter_example", + destinationName: "destinationName_example", + destinationNamespace: "destinationNamespace_example", + localBindAddress: "localBindAddress_example", + localBindPort: 1, + meshGateway: { + mode: "mode_example", + }, + }, + ], + }, + tags: [ + "tags_example", + ], + }, + sidecarTask: { + config: { + "key": null, + }, + driver: "driver_example", + env: { + "key": "key_example", + }, + killSignal: "killSignal_example", + killTimeout: 1, + logConfig: { + maxFileSizeMB: 1, + maxFiles: 1, + }, + meta: { + "key": "key_example", + }, + name: "name_example", + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + shutdownDelay: 1, + user: "user_example", + }, + }, + enableTagOverride: true, + meta: { + "key": "key_example", + }, + name: "name_example", + onUpdate: "onUpdate_example", + portLabel: "portLabel_example", + provider: "provider_example", + taggedAddresses: { + "key": "key_example", + }, + tags: [ + "tags_example", + ], + taskName: "taskName_example", + }, + ], + shutdownDelay: 1, + spreads: [ + { + attribute: "attribute_example", + spreadTarget: [ + { + percent: 0, + value: "value_example", + }, + ], + weight: -128, + }, + ], + stopAfterClientDisconnect: 1, + tasks: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + artifacts: [ + { + getterHeaders: { + "key": "key_example", + }, + getterMode: "getterMode_example", + getterOptions: { + "key": "key_example", + }, + getterSource: "getterSource_example", + relativeDest: "relativeDest_example", + }, + ], + cSIPluginConfig: { + healthTimeout: 1, + ID: "ID_example", + mountDir: "mountDir_example", + type: "type_example", + }, + config: { + "key": null, + }, + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + dispatchPayload: { + file: "file_example", + }, + driver: "driver_example", + env: { + "key": "key_example", + }, + killSignal: "killSignal_example", + killTimeout: 1, + kind: "kind_example", + leader: true, + lifecycle: { + hook: "hook_example", + sidecar: true, + }, + logConfig: { + maxFileSizeMB: 1, + maxFiles: 1, + }, + meta: { + "key": "key_example", + }, + name: "name_example", + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + restartPolicy: { + attempts: 1, + delay: 1, + interval: 1, + mode: "mode_example", + }, + scalingPolicies: [ + { + createIndex: 0, + enabled: true, + ID: "ID_example", + max: 1, + min: 1, + modifyIndex: 0, + namespace: "namespace_example", + policy: { + "key": null, + }, + target: { + "key": "key_example", + }, + type: "type_example", + }, + ], + services: [ + { + address: "address_example", + addressMode: "addressMode_example", + canaryMeta: { + "key": "key_example", + }, + canaryTags: [ + "canaryTags_example", + ], + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + checks: [ + { + addressMode: "addressMode_example", + advertise: "advertise_example", + args: [ + "args_example", + ], + body: "body_example", + checkRestart: { + grace: 1, + ignoreWarnings: true, + limit: 1, + }, + command: "command_example", + expose: true, + failuresBeforeCritical: 1, + gRPCService: "gRPCService_example", + gRPCUseTLS: true, + header: { + "key": [ + "key_example", + ], + }, + initialStatus: "initialStatus_example", + interval: 1, + method: "method_example", + name: "name_example", + onUpdate: "onUpdate_example", + path: "path_example", + portLabel: "portLabel_example", + protocol: "protocol_example", + successBeforePassing: 1, + tLSSkipVerify: true, + taskName: "taskName_example", + timeout: 1, + type: "type_example", + }, + ], + connect: { + gateway: { + ingress: { + listeners: [ + { + port: 1, + protocol: "protocol_example", + services: [ + { + hosts: [ + "hosts_example", + ], + name: "name_example", + }, + ], + }, + ], + TLS: { + cipherSuites: [ + "cipherSuites_example", + ], + enabled: true, + tLSMaxVersion: "tLSMaxVersion_example", + tLSMinVersion: "tLSMinVersion_example", + }, + }, + mesh: null, + proxy: { + config: { + "key": null, + }, + connectTimeout: 1, + envoyDNSDiscoveryType: "envoyDNSDiscoveryType_example", + envoyGatewayBindAddresses: { + "key": { + address: "address_example", + name: "name_example", + port: 1, + }, + }, + envoyGatewayBindTaggedAddresses: true, + envoyGatewayNoDefaultBind: true, + }, + terminating: { + services: [ + { + cAFile: "cAFile_example", + certFile: "certFile_example", + keyFile: "keyFile_example", + name: "name_example", + SNI: "SNI_example", + }, + ], + }, + }, + _native: true, + sidecarService: { + disableDefaultTCPCheck: true, + port: "port_example", + proxy: { + config: { + "key": null, + }, + exposeConfig: { + path: [ + { + listenerPort: "listenerPort_example", + localPathPort: 1, + path: "path_example", + protocol: "protocol_example", + }, + ], + }, + localServiceAddress: "localServiceAddress_example", + localServicePort: 1, + upstreams: [ + { + datacenter: "datacenter_example", + destinationName: "destinationName_example", + destinationNamespace: "destinationNamespace_example", + localBindAddress: "localBindAddress_example", + localBindPort: 1, + meshGateway: { + mode: "mode_example", + }, + }, + ], + }, + tags: [ + "tags_example", + ], + }, + sidecarTask: { + config: { + "key": null, + }, + driver: "driver_example", + env: { + "key": "key_example", + }, + killSignal: "killSignal_example", + killTimeout: 1, + logConfig: { + maxFileSizeMB: 1, + maxFiles: 1, + }, + meta: { + "key": "key_example", + }, + name: "name_example", + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + shutdownDelay: 1, + user: "user_example", + }, + }, + enableTagOverride: true, + meta: { + "key": "key_example", + }, + name: "name_example", + onUpdate: "onUpdate_example", + portLabel: "portLabel_example", + provider: "provider_example", + taggedAddresses: { + "key": "key_example", + }, + tags: [ + "tags_example", + ], + taskName: "taskName_example", + }, + ], + shutdownDelay: 1, + templates: [ + { + changeMode: "changeMode_example", + changeSignal: "changeSignal_example", + destPath: "destPath_example", + embeddedTmpl: "embeddedTmpl_example", + envvars: true, + leftDelim: "leftDelim_example", + perms: "perms_example", + rightDelim: "rightDelim_example", + sourcePath: "sourcePath_example", + splay: 1, + vaultGrace: 1, + wait: { + max: 1, + min: 1, + }, + }, + ], + user: "user_example", + vault: { + changeMode: "changeMode_example", + changeSignal: "changeSignal_example", + env: true, + namespace: "namespace_example", + policies: [ + "policies_example", + ], + }, + volumeMounts: [ + { + destination: "destination_example", + propagationMode: "propagationMode_example", + readOnly: true, + volume: "volume_example", + }, + ], + }, + ], + update: { + autoPromote: true, + autoRevert: true, + canary: 1, + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + progressDeadline: 1, + stagger: 1, + }, + volumes: { + "key": { + accessMode: "accessMode_example", + attachmentMode: "attachmentMode_example", + mountOptions: { + fSType: "fSType_example", + mountFlags: [ + "mountFlags_example", + ], + }, + name: "name_example", + perAlloc: true, + readOnly: true, + source: "source_example", + type: "type_example", + }, + }, + }, + ], + type: "type_example", + update: { + autoPromote: true, + autoRevert: true, + canary: 1, + healthCheck: "healthCheck_example", + healthyDeadline: 1, + maxParallel: 1, + minHealthyTime: 1, + progressDeadline: 1, + stagger: 1, + }, + vaultNamespace: "vaultNamespace_example", + vaultToken: "vaultToken_example", + version: 0, + }, + jobID: "jobID_example", + metrics: { + allocationTime: 1, + classExhausted: { + "key": 1, + }, + classFiltered: { + "key": 1, + }, + coalescedFailures: 1, + constraintFiltered: { + "key": 1, + }, + dimensionExhausted: { + "key": 1, + }, + nodesAvailable: { + "key": 1, + }, + nodesEvaluated: 1, + nodesExhausted: 1, + nodesFiltered: 1, + quotaExhausted: [ + "quotaExhausted_example", + ], + resourcesExhausted: { + "key": { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + }, + scoreMetaData: [ + { + nodeID: "nodeID_example", + normScore: 3.14, + scores: { + "key": 3.14, + }, + }, + ], + scores: { + "key": 3.14, + }, + }, + modifyIndex: 0, + modifyTime: 1, + name: "name_example", + namespace: "namespace_example", + nextAllocation: "nextAllocation_example", + nodeID: "nodeID_example", + nodeName: "nodeName_example", + preemptedAllocations: [ + "preemptedAllocations_example", + ], + preemptedByAllocation: "preemptedByAllocation_example", + previousAllocation: "previousAllocation_example", + rescheduleTracker: { + events: [ + { + prevAllocID: "prevAllocID_example", + prevNodeID: "prevNodeID_example", + rescheduleTime: 1, + }, + ], + }, + resources: { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + services: { + "key": "key_example", + }, + taskGroup: "taskGroup_example", + taskResources: { + "key": { + CPU: 1, + cores: 1, + devices: [ + { + affinities: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + weight: -128, + }, + ], + constraints: [ + { + lTarget: "lTarget_example", + operand: "operand_example", + rTarget: "rTarget_example", + }, + ], + count: 0, + name: "name_example", + }, + ], + diskMB: 1, + IOPS: 1, + memoryMB: 1, + memoryMaxMB: 1, + networks: [ + { + CIDR: "CIDR_example", + DNS: { + options: [ + "options_example", + ], + searches: [ + "searches_example", + ], + servers: [ + "servers_example", + ], + }, + device: "device_example", + dynamicPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + hostname: "hostname_example", + IP: "IP_example", + mBits: 1, + mode: "mode_example", + reservedPorts: [ + { + hostNetwork: "hostNetwork_example", + label: "label_example", + to: 1, + value: 1, + }, + ], + }, + ], + }, + }, + taskStates: { + "key": { + events: [ + { + details: { + "key": "key_example", + }, + diskLimit: 1, + diskSize: 1, + displayMessage: "displayMessage_example", + downloadError: "downloadError_example", + driverError: "driverError_example", + driverMessage: "driverMessage_example", + exitCode: 1, + failedSibling: "failedSibling_example", + failsTask: true, + genericSource: "genericSource_example", + killError: "killError_example", + killReason: "killReason_example", + killTimeout: 1, + message: "message_example", + restartReason: "restartReason_example", + setupError: "setupError_example", + signal: 1, + startDelay: 1, + taskSignal: "taskSignal_example", + taskSignalReason: "taskSignalReason_example", + time: 1, + type: "type_example", + validationError: "validationError_example", + vaultError: "vaultError_example", + }, + ], + failed: true, + finishedAt: new Date('1970-01-01T00:00:00.00Z'), + lastRestart: new Date('1970-01-01T00:00:00.00Z'), + restarts: 0, + startedAt: new Date('1970-01-01T00:00:00.00Z'), + state: "state_example", + taskHandle: { + driverState: 'YQ==', + version: 1, + }, + }, + }, + }, + }, + }, + ], + }, + // string | Filters results based on the specified region. (optional) + region: "region_example", + // string | Filters results based on the specified namespace. (optional) + namespace: "namespace_example", + // string | A Nomad ACL token. (optional) + xNomadToken: "X-Nomad-Token_example", + // string | Can be used to ensure operations are only run once. (optional) + idempotencyToken: "idempotency_token_example", +}; + +apiInstance.postVolumeRegistration(body).then((data:any) => { + console.log('API called successfully. Returned data: ' + data); +}).catch((error:any) => console.error(error)); +``` + + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **cSIVolumeRegisterRequest** | **CSIVolumeRegisterRequest**| | + **volumeId** | [**string**] | Volume unique identifier. | defaults to undefined + **region** | [**string**] | Filters results based on the specified region. | (optional) defaults to undefined + **namespace** | [**string**] | Filters results based on the specified namespace. | (optional) defaults to undefined + **xNomadToken** | [**string**] | A Nomad ACL token. | (optional) defaults to undefined + **idempotencyToken** | [**string**] | Can be used to ensure operations are only run once. | (optional) defaults to undefined + + +### Return type + +**void** + +### Authorization + +[X-Nomad-Token](README.md#X-Nomad-Token) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: Not defined + + +### HTTP response details +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | | * X-Nomad-Index - A unique identifier representing the current state of the requested resource. On a new Nomad cluster the value of this index starts at 1.
| +**400** | Bad request | - | +**403** | Forbidden | - | +**405** | Method not allowed | - | +**500** | Internal server error | - | + +[[Back to top]](#) [[Back to API list]](README.md#documentation-for-api-endpoints) [[Back to Model list]](README.md#documentation-for-models) [[Back to README]](README.md) + + diff --git a/clients/typescript/v1/apis/ACLApi.ts b/clients/typescript/v1/apis/ACLApi.ts index f46e76fa..e3e6aa50 100644 --- a/clients/typescript/v1/apis/ACLApi.ts +++ b/clients/typescript/v1/apis/ACLApi.ts @@ -1,10 +1,12 @@ // TODO: better import syntax? -import { BaseAPIRequestFactory, RequiredError } from './baseapi'; +import {BaseAPIRequestFactory, RequiredError} from './baseapi'; import {Configuration} from '../configuration'; -import { RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; +import {RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; import {ObjectSerializer} from '../models/ObjectSerializer'; import {ApiException} from './exception'; -import {isCodeInRange} from '../util'; +import {canConsumeForm, isCodeInRange} from '../util'; +import {SecurityAuthentication} from '../auth/auth'; + import { ACLPolicy } from '../models/ACLPolicy'; import { ACLPolicyListStub } from '../models/ACLPolicyListStub'; @@ -30,7 +32,7 @@ export class ACLApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'policyName' is not null or undefined if (policyName === null || policyName === undefined) { - throw new RequiredError('Required parameter policyName was null or undefined when calling deleteACLPolicy.'); + throw new RequiredError("ACLApi", "deleteACLPolicy", "policyName"); } @@ -50,9 +52,13 @@ export class ACLApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -60,16 +66,17 @@ export class ACLApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - - // Body Params - - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -87,7 +94,7 @@ export class ACLApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'tokenAccessor' is not null or undefined if (tokenAccessor === null || tokenAccessor === undefined) { - throw new RequiredError('Required parameter tokenAccessor was null or undefined when calling deleteACLToken.'); + throw new RequiredError("ACLApi", "deleteACLToken", "tokenAccessor"); } @@ -107,9 +114,13 @@ export class ACLApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -117,16 +128,17 @@ export class ACLApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - - // Body Params - - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -166,39 +178,54 @@ export class ACLApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -221,7 +248,7 @@ export class ACLApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'policyName' is not null or undefined if (policyName === null || policyName === undefined) { - throw new RequiredError('Required parameter policyName was null or undefined when calling getACLPolicy.'); + throw new RequiredError("ACLApi", "getACLPolicy", "policyName"); } @@ -246,39 +273,54 @@ export class ACLApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -301,7 +343,7 @@ export class ACLApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'tokenAccessor' is not null or undefined if (tokenAccessor === null || tokenAccessor === undefined) { - throw new RequiredError('Required parameter tokenAccessor was null or undefined when calling getACLToken.'); + throw new RequiredError("ACLApi", "getACLToken", "tokenAccessor"); } @@ -326,39 +368,54 @@ export class ACLApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -398,39 +455,54 @@ export class ACLApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -470,39 +542,54 @@ export class ACLApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -532,9 +619,13 @@ export class ACLApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -542,16 +633,17 @@ export class ACLApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - - // Body Params - - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -570,13 +662,13 @@ export class ACLApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'policyName' is not null or undefined if (policyName === null || policyName === undefined) { - throw new RequiredError('Required parameter policyName was null or undefined when calling postACLPolicy.'); + throw new RequiredError("ACLApi", "postACLPolicy", "policyName"); } // verify required parameter 'aCLPolicy' is not null or undefined if (aCLPolicy === null || aCLPolicy === undefined) { - throw new RequiredError('Required parameter aCLPolicy was null or undefined when calling postACLPolicy.'); + throw new RequiredError("ACLApi", "postACLPolicy", "aCLPolicy"); } @@ -596,9 +688,13 @@ export class ACLApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -606,8 +702,6 @@ export class ACLApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - // Body Params const contentType = ObjectSerializer.getPreferredMediaType([ @@ -620,11 +714,16 @@ export class ACLApiRequestFactory extends BaseAPIRequestFactory { ); requestContext.setBody(serializedBody); - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -643,13 +742,13 @@ export class ACLApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'tokenAccessor' is not null or undefined if (tokenAccessor === null || tokenAccessor === undefined) { - throw new RequiredError('Required parameter tokenAccessor was null or undefined when calling postACLToken.'); + throw new RequiredError("ACLApi", "postACLToken", "tokenAccessor"); } // verify required parameter 'aCLToken' is not null or undefined if (aCLToken === null || aCLToken === undefined) { - throw new RequiredError('Required parameter aCLToken was null or undefined when calling postACLToken.'); + throw new RequiredError("ACLApi", "postACLToken", "aCLToken"); } @@ -669,9 +768,13 @@ export class ACLApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -679,8 +782,6 @@ export class ACLApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - // Body Params const contentType = ObjectSerializer.getPreferredMediaType([ @@ -693,11 +794,16 @@ export class ACLApiRequestFactory extends BaseAPIRequestFactory { ); requestContext.setBody(serializedBody); - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -727,9 +833,13 @@ export class ACLApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -737,16 +847,17 @@ export class ACLApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - - // Body Params - - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -764,7 +875,7 @@ export class ACLApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'oneTimeTokenExchangeRequest' is not null or undefined if (oneTimeTokenExchangeRequest === null || oneTimeTokenExchangeRequest === undefined) { - throw new RequiredError('Required parameter oneTimeTokenExchangeRequest was null or undefined when calling postACLTokenOnetimeExchange.'); + throw new RequiredError("ACLApi", "postACLTokenOnetimeExchange", "oneTimeTokenExchangeRequest"); } @@ -783,9 +894,13 @@ export class ACLApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -793,8 +908,6 @@ export class ACLApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - // Body Params const contentType = ObjectSerializer.getPreferredMediaType([ @@ -807,11 +920,16 @@ export class ACLApiRequestFactory extends BaseAPIRequestFactory { ); requestContext.setBody(serializedBody); - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -834,16 +952,16 @@ export class ACLApiResponseProcessor { return; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -855,8 +973,7 @@ export class ACLApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -872,16 +989,16 @@ export class ACLApiResponseProcessor { return; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -893,8 +1010,7 @@ export class ACLApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -914,16 +1030,16 @@ export class ACLApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -935,8 +1051,7 @@ export class ACLApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -956,16 +1071,16 @@ export class ACLApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -977,8 +1092,7 @@ export class ACLApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -998,16 +1112,16 @@ export class ACLApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -1019,8 +1133,7 @@ export class ACLApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -1040,16 +1153,16 @@ export class ACLApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -1061,8 +1174,7 @@ export class ACLApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -1082,16 +1194,16 @@ export class ACLApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -1103,8 +1215,7 @@ export class ACLApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -1124,16 +1235,16 @@ export class ACLApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -1145,8 +1256,7 @@ export class ACLApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -1162,16 +1272,16 @@ export class ACLApiResponseProcessor { return; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -1183,8 +1293,7 @@ export class ACLApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -1204,16 +1313,16 @@ export class ACLApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -1225,8 +1334,7 @@ export class ACLApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -1246,16 +1354,16 @@ export class ACLApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -1267,8 +1375,7 @@ export class ACLApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -1288,16 +1395,16 @@ export class ACLApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -1309,8 +1416,7 @@ export class ACLApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } } diff --git a/clients/typescript/v1/apis/AllocationsApi.ts b/clients/typescript/v1/apis/AllocationsApi.ts index c74e970d..c4842eaa 100644 --- a/clients/typescript/v1/apis/AllocationsApi.ts +++ b/clients/typescript/v1/apis/AllocationsApi.ts @@ -1,10 +1,12 @@ // TODO: better import syntax? -import { BaseAPIRequestFactory, RequiredError } from './baseapi'; +import {BaseAPIRequestFactory, RequiredError} from './baseapi'; import {Configuration} from '../configuration'; -import { RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; +import {RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; import {ObjectSerializer} from '../models/ObjectSerializer'; import {ApiException} from './exception'; -import {isCodeInRange} from '../util'; +import {canConsumeForm, isCodeInRange} from '../util'; +import {SecurityAuthentication} from '../auth/auth'; + import { AllocStopResponse } from '../models/AllocStopResponse'; import { Allocation } from '../models/Allocation'; @@ -33,7 +35,7 @@ export class AllocationsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'allocID' is not null or undefined if (allocID === null || allocID === undefined) { - throw new RequiredError('Required parameter allocID was null or undefined when calling getAllocation.'); + throw new RequiredError("AllocationsApi", "getAllocation", "allocID"); } @@ -58,39 +60,54 @@ export class AllocationsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -113,7 +130,7 @@ export class AllocationsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'allocID' is not null or undefined if (allocID === null || allocID === undefined) { - throw new RequiredError('Required parameter allocID was null or undefined when calling getAllocationServices.'); + throw new RequiredError("AllocationsApi", "getAllocationServices", "allocID"); } @@ -138,39 +155,54 @@ export class AllocationsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -214,45 +246,64 @@ export class AllocationsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } + + // Query Params if (resources !== undefined) { requestContext.setQueryParam("resources", ObjectSerializer.serialize(resources, "boolean", "")); } + + // Query Params if (taskStates !== undefined) { requestContext.setQueryParam("task_states", ObjectSerializer.serialize(taskStates, "boolean", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -276,7 +327,7 @@ export class AllocationsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'allocID' is not null or undefined if (allocID === null || allocID === undefined) { - throw new RequiredError('Required parameter allocID was null or undefined when calling postAllocationStop.'); + throw new RequiredError("AllocationsApi", "postAllocationStop", "allocID"); } @@ -302,42 +353,59 @@ export class AllocationsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } + + // Query Params if (noShutdownDelay !== undefined) { requestContext.setQueryParam("no_shutdown_delay", ObjectSerializer.serialize(noShutdownDelay, "boolean", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -364,16 +432,16 @@ export class AllocationsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -385,8 +453,7 @@ export class AllocationsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -406,16 +473,16 @@ export class AllocationsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -427,8 +494,7 @@ export class AllocationsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -448,16 +514,16 @@ export class AllocationsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -469,8 +535,7 @@ export class AllocationsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -490,16 +555,16 @@ export class AllocationsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -511,8 +576,7 @@ export class AllocationsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } } diff --git a/clients/typescript/v1/apis/DeploymentsApi.ts b/clients/typescript/v1/apis/DeploymentsApi.ts index ce1f935e..edfc983c 100644 --- a/clients/typescript/v1/apis/DeploymentsApi.ts +++ b/clients/typescript/v1/apis/DeploymentsApi.ts @@ -1,10 +1,12 @@ // TODO: better import syntax? -import { BaseAPIRequestFactory, RequiredError } from './baseapi'; +import {BaseAPIRequestFactory, RequiredError} from './baseapi'; import {Configuration} from '../configuration'; -import { RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; +import {RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; import {ObjectSerializer} from '../models/ObjectSerializer'; import {ApiException} from './exception'; -import {isCodeInRange} from '../util'; +import {canConsumeForm, isCodeInRange} from '../util'; +import {SecurityAuthentication} from '../auth/auth'; + import { AllocationListStub } from '../models/AllocationListStub'; import { Deployment } from '../models/Deployment'; @@ -36,7 +38,7 @@ export class DeploymentsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'deploymentID' is not null or undefined if (deploymentID === null || deploymentID === undefined) { - throw new RequiredError('Required parameter deploymentID was null or undefined when calling getDeployment.'); + throw new RequiredError("DeploymentsApi", "getDeployment", "deploymentID"); } @@ -61,39 +63,54 @@ export class DeploymentsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -116,7 +133,7 @@ export class DeploymentsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'deploymentID' is not null or undefined if (deploymentID === null || deploymentID === undefined) { - throw new RequiredError('Required parameter deploymentID was null or undefined when calling getDeploymentAllocations.'); + throw new RequiredError("DeploymentsApi", "getDeploymentAllocations", "deploymentID"); } @@ -141,39 +158,54 @@ export class DeploymentsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -213,39 +245,54 @@ export class DeploymentsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -264,13 +311,13 @@ export class DeploymentsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'deploymentID' is not null or undefined if (deploymentID === null || deploymentID === undefined) { - throw new RequiredError('Required parameter deploymentID was null or undefined when calling postDeploymentAllocationHealth.'); + throw new RequiredError("DeploymentsApi", "postDeploymentAllocationHealth", "deploymentID"); } // verify required parameter 'deploymentAllocHealthRequest' is not null or undefined if (deploymentAllocHealthRequest === null || deploymentAllocHealthRequest === undefined) { - throw new RequiredError('Required parameter deploymentAllocHealthRequest was null or undefined when calling postDeploymentAllocationHealth.'); + throw new RequiredError("DeploymentsApi", "postDeploymentAllocationHealth", "deploymentAllocHealthRequest"); } @@ -290,9 +337,13 @@ export class DeploymentsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -300,8 +351,6 @@ export class DeploymentsApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - // Body Params const contentType = ObjectSerializer.getPreferredMediaType([ @@ -314,11 +363,16 @@ export class DeploymentsApiRequestFactory extends BaseAPIRequestFactory { ); requestContext.setBody(serializedBody); - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -336,7 +390,7 @@ export class DeploymentsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'deploymentID' is not null or undefined if (deploymentID === null || deploymentID === undefined) { - throw new RequiredError('Required parameter deploymentID was null or undefined when calling postDeploymentFail.'); + throw new RequiredError("DeploymentsApi", "postDeploymentFail", "deploymentID"); } @@ -356,9 +410,13 @@ export class DeploymentsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -366,16 +424,17 @@ export class DeploymentsApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - - // Body Params - - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -394,13 +453,13 @@ export class DeploymentsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'deploymentID' is not null or undefined if (deploymentID === null || deploymentID === undefined) { - throw new RequiredError('Required parameter deploymentID was null or undefined when calling postDeploymentPause.'); + throw new RequiredError("DeploymentsApi", "postDeploymentPause", "deploymentID"); } // verify required parameter 'deploymentPauseRequest' is not null or undefined if (deploymentPauseRequest === null || deploymentPauseRequest === undefined) { - throw new RequiredError('Required parameter deploymentPauseRequest was null or undefined when calling postDeploymentPause.'); + throw new RequiredError("DeploymentsApi", "postDeploymentPause", "deploymentPauseRequest"); } @@ -420,9 +479,13 @@ export class DeploymentsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -430,8 +493,6 @@ export class DeploymentsApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - // Body Params const contentType = ObjectSerializer.getPreferredMediaType([ @@ -444,11 +505,16 @@ export class DeploymentsApiRequestFactory extends BaseAPIRequestFactory { ); requestContext.setBody(serializedBody); - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -467,13 +533,13 @@ export class DeploymentsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'deploymentID' is not null or undefined if (deploymentID === null || deploymentID === undefined) { - throw new RequiredError('Required parameter deploymentID was null or undefined when calling postDeploymentPromote.'); + throw new RequiredError("DeploymentsApi", "postDeploymentPromote", "deploymentID"); } // verify required parameter 'deploymentPromoteRequest' is not null or undefined if (deploymentPromoteRequest === null || deploymentPromoteRequest === undefined) { - throw new RequiredError('Required parameter deploymentPromoteRequest was null or undefined when calling postDeploymentPromote.'); + throw new RequiredError("DeploymentsApi", "postDeploymentPromote", "deploymentPromoteRequest"); } @@ -493,9 +559,13 @@ export class DeploymentsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -503,8 +573,6 @@ export class DeploymentsApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - // Body Params const contentType = ObjectSerializer.getPreferredMediaType([ @@ -517,11 +585,16 @@ export class DeploymentsApiRequestFactory extends BaseAPIRequestFactory { ); requestContext.setBody(serializedBody); - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -540,13 +613,13 @@ export class DeploymentsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'deploymentID' is not null or undefined if (deploymentID === null || deploymentID === undefined) { - throw new RequiredError('Required parameter deploymentID was null or undefined when calling postDeploymentUnblock.'); + throw new RequiredError("DeploymentsApi", "postDeploymentUnblock", "deploymentID"); } // verify required parameter 'deploymentUnblockRequest' is not null or undefined if (deploymentUnblockRequest === null || deploymentUnblockRequest === undefined) { - throw new RequiredError('Required parameter deploymentUnblockRequest was null or undefined when calling postDeploymentUnblock.'); + throw new RequiredError("DeploymentsApi", "postDeploymentUnblock", "deploymentUnblockRequest"); } @@ -566,9 +639,13 @@ export class DeploymentsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -576,8 +653,6 @@ export class DeploymentsApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - // Body Params const contentType = ObjectSerializer.getPreferredMediaType([ @@ -590,11 +665,16 @@ export class DeploymentsApiRequestFactory extends BaseAPIRequestFactory { ); requestContext.setBody(serializedBody); - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -621,16 +701,16 @@ export class DeploymentsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -642,8 +722,7 @@ export class DeploymentsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -663,16 +742,16 @@ export class DeploymentsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -684,8 +763,7 @@ export class DeploymentsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -705,16 +783,16 @@ export class DeploymentsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -726,8 +804,7 @@ export class DeploymentsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -747,16 +824,16 @@ export class DeploymentsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -768,8 +845,7 @@ export class DeploymentsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -789,16 +865,16 @@ export class DeploymentsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -810,8 +886,7 @@ export class DeploymentsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -831,16 +906,16 @@ export class DeploymentsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -852,8 +927,7 @@ export class DeploymentsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -873,16 +947,16 @@ export class DeploymentsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -894,8 +968,7 @@ export class DeploymentsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -915,16 +988,16 @@ export class DeploymentsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -936,8 +1009,7 @@ export class DeploymentsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } } diff --git a/clients/typescript/v1/apis/EnterpriseApi.ts b/clients/typescript/v1/apis/EnterpriseApi.ts index c08d67c3..2ef7c617 100644 --- a/clients/typescript/v1/apis/EnterpriseApi.ts +++ b/clients/typescript/v1/apis/EnterpriseApi.ts @@ -1,12 +1,13 @@ // TODO: better import syntax? -import { BaseAPIRequestFactory, RequiredError } from './baseapi'; +import {BaseAPIRequestFactory, RequiredError} from './baseapi'; import {Configuration} from '../configuration'; -import { RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; +import {RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; import {ObjectSerializer} from '../models/ObjectSerializer'; import {ApiException} from './exception'; -import {isCodeInRange} from '../util'; +import {canConsumeForm, isCodeInRange} from '../util'; +import {SecurityAuthentication} from '../auth/auth'; + -import { AnyType } from '../models/AnyType'; import { QuotaSpec } from '../models/QuotaSpec'; /** @@ -26,7 +27,7 @@ export class EnterpriseApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'quotaSpec' is not null or undefined if (quotaSpec === null || quotaSpec === undefined) { - throw new RequiredError('Required parameter quotaSpec was null or undefined when calling createQuotaSpec.'); + throw new RequiredError("EnterpriseApi", "createQuotaSpec", "quotaSpec"); } @@ -45,9 +46,13 @@ export class EnterpriseApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -55,8 +60,6 @@ export class EnterpriseApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - // Body Params const contentType = ObjectSerializer.getPreferredMediaType([ @@ -69,11 +72,16 @@ export class EnterpriseApiRequestFactory extends BaseAPIRequestFactory { ); requestContext.setBody(serializedBody); - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -91,7 +99,7 @@ export class EnterpriseApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'specName' is not null or undefined if (specName === null || specName === undefined) { - throw new RequiredError('Required parameter specName was null or undefined when calling deleteQuotaSpec.'); + throw new RequiredError("EnterpriseApi", "deleteQuotaSpec", "specName"); } @@ -111,9 +119,13 @@ export class EnterpriseApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -121,16 +133,17 @@ export class EnterpriseApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - - // Body Params - - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -153,7 +166,7 @@ export class EnterpriseApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'specName' is not null or undefined if (specName === null || specName === undefined) { - throw new RequiredError('Required parameter specName was null or undefined when calling getQuotaSpec.'); + throw new RequiredError("EnterpriseApi", "getQuotaSpec", "specName"); } @@ -178,39 +191,54 @@ export class EnterpriseApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -250,39 +278,54 @@ export class EnterpriseApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -301,13 +344,13 @@ export class EnterpriseApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'specName' is not null or undefined if (specName === null || specName === undefined) { - throw new RequiredError('Required parameter specName was null or undefined when calling postQuotaSpec.'); + throw new RequiredError("EnterpriseApi", "postQuotaSpec", "specName"); } // verify required parameter 'quotaSpec' is not null or undefined if (quotaSpec === null || quotaSpec === undefined) { - throw new RequiredError('Required parameter quotaSpec was null or undefined when calling postQuotaSpec.'); + throw new RequiredError("EnterpriseApi", "postQuotaSpec", "quotaSpec"); } @@ -327,9 +370,13 @@ export class EnterpriseApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -337,8 +384,6 @@ export class EnterpriseApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - // Body Params const contentType = ObjectSerializer.getPreferredMediaType([ @@ -351,11 +396,16 @@ export class EnterpriseApiRequestFactory extends BaseAPIRequestFactory { ); requestContext.setBody(serializedBody); - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -378,16 +428,16 @@ export class EnterpriseApiResponseProcessor { return; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -399,8 +449,7 @@ export class EnterpriseApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -416,16 +465,16 @@ export class EnterpriseApiResponseProcessor { return; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -437,8 +486,7 @@ export class EnterpriseApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -458,16 +506,16 @@ export class EnterpriseApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -479,8 +527,7 @@ export class EnterpriseApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -490,39 +537,38 @@ export class EnterpriseApiResponseProcessor { * @params response Response returned by the server for a request to getQuotas * @throws ApiException if the response code was not in [200, 299] */ - public async getQuotas(response: ResponseContext): Promise > { + public async getQuotas(response: ResponseContext): Promise > { const contentType = ObjectSerializer.normalizeMediaType(response.headers["content-type"]); if (isCodeInRange("200", response.httpStatusCode)) { - const body: Array = ObjectSerializer.deserialize( + const body: Array = ObjectSerializer.deserialize( ObjectSerializer.parse(await response.body.text(), contentType), - "Array", "" - ) as Array; + "Array", "" + ) as Array; return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) { - const body: Array = ObjectSerializer.deserialize( + const body: Array = ObjectSerializer.deserialize( ObjectSerializer.parse(await response.body.text(), contentType), - "Array", "" - ) as Array; + "Array", "" + ) as Array; return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -538,16 +584,16 @@ export class EnterpriseApiResponseProcessor { return; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -559,8 +605,7 @@ export class EnterpriseApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } } diff --git a/clients/typescript/v1/apis/EvaluationsApi.ts b/clients/typescript/v1/apis/EvaluationsApi.ts index 995824b1..fe9e0847 100644 --- a/clients/typescript/v1/apis/EvaluationsApi.ts +++ b/clients/typescript/v1/apis/EvaluationsApi.ts @@ -1,10 +1,12 @@ // TODO: better import syntax? -import { BaseAPIRequestFactory, RequiredError } from './baseapi'; +import {BaseAPIRequestFactory, RequiredError} from './baseapi'; import {Configuration} from '../configuration'; -import { RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; +import {RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; import {ObjectSerializer} from '../models/ObjectSerializer'; import {ApiException} from './exception'; -import {isCodeInRange} from '../util'; +import {canConsumeForm, isCodeInRange} from '../util'; +import {SecurityAuthentication} from '../auth/auth'; + import { AllocationListStub } from '../models/AllocationListStub'; import { Evaluation } from '../models/Evaluation'; @@ -31,7 +33,7 @@ export class EvaluationsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'evalID' is not null or undefined if (evalID === null || evalID === undefined) { - throw new RequiredError('Required parameter evalID was null or undefined when calling getEvaluation.'); + throw new RequiredError("EvaluationsApi", "getEvaluation", "evalID"); } @@ -56,39 +58,54 @@ export class EvaluationsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -111,7 +128,7 @@ export class EvaluationsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'evalID' is not null or undefined if (evalID === null || evalID === undefined) { - throw new RequiredError('Required parameter evalID was null or undefined when calling getEvaluationAllocations.'); + throw new RequiredError("EvaluationsApi", "getEvaluationAllocations", "evalID"); } @@ -136,39 +153,54 @@ export class EvaluationsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -208,39 +240,54 @@ export class EvaluationsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -267,16 +314,16 @@ export class EvaluationsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -288,8 +335,7 @@ export class EvaluationsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -309,16 +355,16 @@ export class EvaluationsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -330,8 +376,7 @@ export class EvaluationsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -351,16 +396,16 @@ export class EvaluationsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -372,8 +417,7 @@ export class EvaluationsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } } diff --git a/clients/typescript/v1/apis/JobsApi.ts b/clients/typescript/v1/apis/JobsApi.ts index d27360d1..4bc2fc92 100644 --- a/clients/typescript/v1/apis/JobsApi.ts +++ b/clients/typescript/v1/apis/JobsApi.ts @@ -1,10 +1,12 @@ // TODO: better import syntax? -import { BaseAPIRequestFactory, RequiredError } from './baseapi'; +import {BaseAPIRequestFactory, RequiredError} from './baseapi'; import {Configuration} from '../configuration'; -import { RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; +import {RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; import {ObjectSerializer} from '../models/ObjectSerializer'; import {ApiException} from './exception'; -import {isCodeInRange} from '../util'; +import {canConsumeForm, isCodeInRange} from '../util'; +import {SecurityAuthentication} from '../auth/auth'; + import { AllocationListStub } from '../models/AllocationListStub'; import { Deployment } from '../models/Deployment'; @@ -50,7 +52,7 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'jobName' is not null or undefined if (jobName === null || jobName === undefined) { - throw new RequiredError('Required parameter jobName was null or undefined when calling deleteJob.'); + throw new RequiredError("JobsApi", "deleteJob", "jobName"); } @@ -72,15 +74,23 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } + + // Query Params if (purge !== undefined) { requestContext.setQueryParam("purge", ObjectSerializer.serialize(purge, "boolean", "")); } + + // Query Params if (global !== undefined) { requestContext.setQueryParam("global", ObjectSerializer.serialize(global, "boolean", "")); } @@ -88,16 +98,17 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - - - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -120,7 +131,7 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'jobName' is not null or undefined if (jobName === null || jobName === undefined) { - throw new RequiredError('Required parameter jobName was null or undefined when calling getJob.'); + throw new RequiredError("JobsApi", "getJob", "jobName"); } @@ -145,39 +156,54 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -201,7 +227,7 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'jobName' is not null or undefined if (jobName === null || jobName === undefined) { - throw new RequiredError('Required parameter jobName was null or undefined when calling getJobAllocations.'); + throw new RequiredError("JobsApi", "getJobAllocations", "jobName"); } @@ -227,42 +253,59 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } + + // Query Params if (all !== undefined) { requestContext.setQueryParam("all", ObjectSerializer.serialize(all, "boolean", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -285,7 +328,7 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'jobName' is not null or undefined if (jobName === null || jobName === undefined) { - throw new RequiredError('Required parameter jobName was null or undefined when calling getJobDeployment.'); + throw new RequiredError("JobsApi", "getJobDeployment", "jobName"); } @@ -310,39 +353,54 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -366,7 +424,7 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'jobName' is not null or undefined if (jobName === null || jobName === undefined) { - throw new RequiredError('Required parameter jobName was null or undefined when calling getJobDeployments.'); + throw new RequiredError("JobsApi", "getJobDeployments", "jobName"); } @@ -392,42 +450,59 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } + + // Query Params if (all !== undefined) { requestContext.setQueryParam("all", ObjectSerializer.serialize(all, "number", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -450,7 +525,7 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'jobName' is not null or undefined if (jobName === null || jobName === undefined) { - throw new RequiredError('Required parameter jobName was null or undefined when calling getJobEvaluations.'); + throw new RequiredError("JobsApi", "getJobEvaluations", "jobName"); } @@ -475,39 +550,54 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -530,7 +620,7 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'jobName' is not null or undefined if (jobName === null || jobName === undefined) { - throw new RequiredError('Required parameter jobName was null or undefined when calling getJobScaleStatus.'); + throw new RequiredError("JobsApi", "getJobScaleStatus", "jobName"); } @@ -555,39 +645,54 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -610,7 +715,7 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'jobName' is not null or undefined if (jobName === null || jobName === undefined) { - throw new RequiredError('Required parameter jobName was null or undefined when calling getJobSummary.'); + throw new RequiredError("JobsApi", "getJobSummary", "jobName"); } @@ -635,39 +740,54 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -691,7 +811,7 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'jobName' is not null or undefined if (jobName === null || jobName === undefined) { - throw new RequiredError('Required parameter jobName was null or undefined when calling getJobVersions.'); + throw new RequiredError("JobsApi", "getJobVersions", "jobName"); } @@ -717,42 +837,59 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } + + // Query Params if (diffs !== undefined) { requestContext.setQueryParam("diffs", ObjectSerializer.serialize(diffs, "boolean", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -792,39 +929,54 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -843,13 +995,13 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'jobName' is not null or undefined if (jobName === null || jobName === undefined) { - throw new RequiredError('Required parameter jobName was null or undefined when calling postJob.'); + throw new RequiredError("JobsApi", "postJob", "jobName"); } // verify required parameter 'jobRegisterRequest' is not null or undefined if (jobRegisterRequest === null || jobRegisterRequest === undefined) { - throw new RequiredError('Required parameter jobRegisterRequest was null or undefined when calling postJob.'); + throw new RequiredError("JobsApi", "postJob", "jobRegisterRequest"); } @@ -869,9 +1021,13 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -879,8 +1035,6 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - // Body Params const contentType = ObjectSerializer.getPreferredMediaType([ @@ -893,11 +1047,16 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { ); requestContext.setBody(serializedBody); - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -916,13 +1075,13 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'jobName' is not null or undefined if (jobName === null || jobName === undefined) { - throw new RequiredError('Required parameter jobName was null or undefined when calling postJobDispatch.'); + throw new RequiredError("JobsApi", "postJobDispatch", "jobName"); } // verify required parameter 'jobDispatchRequest' is not null or undefined if (jobDispatchRequest === null || jobDispatchRequest === undefined) { - throw new RequiredError('Required parameter jobDispatchRequest was null or undefined when calling postJobDispatch.'); + throw new RequiredError("JobsApi", "postJobDispatch", "jobDispatchRequest"); } @@ -942,9 +1101,13 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -952,8 +1115,6 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - // Body Params const contentType = ObjectSerializer.getPreferredMediaType([ @@ -966,11 +1127,16 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { ); requestContext.setBody(serializedBody); - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -989,13 +1155,13 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'jobName' is not null or undefined if (jobName === null || jobName === undefined) { - throw new RequiredError('Required parameter jobName was null or undefined when calling postJobEvaluate.'); + throw new RequiredError("JobsApi", "postJobEvaluate", "jobName"); } // verify required parameter 'jobEvaluateRequest' is not null or undefined if (jobEvaluateRequest === null || jobEvaluateRequest === undefined) { - throw new RequiredError('Required parameter jobEvaluateRequest was null or undefined when calling postJobEvaluate.'); + throw new RequiredError("JobsApi", "postJobEvaluate", "jobEvaluateRequest"); } @@ -1015,9 +1181,13 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -1025,8 +1195,6 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - // Body Params const contentType = ObjectSerializer.getPreferredMediaType([ @@ -1039,11 +1207,16 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { ); requestContext.setBody(serializedBody); - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -1057,7 +1230,7 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'jobsParseRequest' is not null or undefined if (jobsParseRequest === null || jobsParseRequest === undefined) { - throw new RequiredError('Required parameter jobsParseRequest was null or undefined when calling postJobParse.'); + throw new RequiredError("JobsApi", "postJobParse", "jobsParseRequest"); } @@ -1068,12 +1241,6 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.POST); requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8") - // Query Params - - // Header Params - - // Form Params - // Body Params const contentType = ObjectSerializer.getPreferredMediaType([ @@ -1086,11 +1253,16 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { ); requestContext.setBody(serializedBody); - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -1108,7 +1280,7 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'jobName' is not null or undefined if (jobName === null || jobName === undefined) { - throw new RequiredError('Required parameter jobName was null or undefined when calling postJobPeriodicForce.'); + throw new RequiredError("JobsApi", "postJobPeriodicForce", "jobName"); } @@ -1128,9 +1300,13 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -1138,16 +1314,17 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - - // Body Params - - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -1166,13 +1343,13 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'jobName' is not null or undefined if (jobName === null || jobName === undefined) { - throw new RequiredError('Required parameter jobName was null or undefined when calling postJobPlan.'); + throw new RequiredError("JobsApi", "postJobPlan", "jobName"); } // verify required parameter 'jobPlanRequest' is not null or undefined if (jobPlanRequest === null || jobPlanRequest === undefined) { - throw new RequiredError('Required parameter jobPlanRequest was null or undefined when calling postJobPlan.'); + throw new RequiredError("JobsApi", "postJobPlan", "jobPlanRequest"); } @@ -1192,9 +1369,13 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -1202,8 +1383,6 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - // Body Params const contentType = ObjectSerializer.getPreferredMediaType([ @@ -1216,11 +1395,16 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { ); requestContext.setBody(serializedBody); - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -1239,13 +1423,13 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'jobName' is not null or undefined if (jobName === null || jobName === undefined) { - throw new RequiredError('Required parameter jobName was null or undefined when calling postJobRevert.'); + throw new RequiredError("JobsApi", "postJobRevert", "jobName"); } // verify required parameter 'jobRevertRequest' is not null or undefined if (jobRevertRequest === null || jobRevertRequest === undefined) { - throw new RequiredError('Required parameter jobRevertRequest was null or undefined when calling postJobRevert.'); + throw new RequiredError("JobsApi", "postJobRevert", "jobRevertRequest"); } @@ -1265,9 +1449,13 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -1275,8 +1463,6 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - // Body Params const contentType = ObjectSerializer.getPreferredMediaType([ @@ -1289,11 +1475,16 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { ); requestContext.setBody(serializedBody); - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -1312,13 +1503,13 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'jobName' is not null or undefined if (jobName === null || jobName === undefined) { - throw new RequiredError('Required parameter jobName was null or undefined when calling postJobScalingRequest.'); + throw new RequiredError("JobsApi", "postJobScalingRequest", "jobName"); } // verify required parameter 'scalingRequest' is not null or undefined if (scalingRequest === null || scalingRequest === undefined) { - throw new RequiredError('Required parameter scalingRequest was null or undefined when calling postJobScalingRequest.'); + throw new RequiredError("JobsApi", "postJobScalingRequest", "scalingRequest"); } @@ -1338,9 +1529,13 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -1348,8 +1543,6 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - // Body Params const contentType = ObjectSerializer.getPreferredMediaType([ @@ -1362,11 +1555,16 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { ); requestContext.setBody(serializedBody); - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -1385,13 +1583,13 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'jobName' is not null or undefined if (jobName === null || jobName === undefined) { - throw new RequiredError('Required parameter jobName was null or undefined when calling postJobStability.'); + throw new RequiredError("JobsApi", "postJobStability", "jobName"); } // verify required parameter 'jobStabilityRequest' is not null or undefined if (jobStabilityRequest === null || jobStabilityRequest === undefined) { - throw new RequiredError('Required parameter jobStabilityRequest was null or undefined when calling postJobStability.'); + throw new RequiredError("JobsApi", "postJobStability", "jobStabilityRequest"); } @@ -1411,9 +1609,13 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -1421,8 +1623,6 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - // Body Params const contentType = ObjectSerializer.getPreferredMediaType([ @@ -1435,11 +1635,16 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { ); requestContext.setBody(serializedBody); - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -1457,7 +1662,7 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'jobValidateRequest' is not null or undefined if (jobValidateRequest === null || jobValidateRequest === undefined) { - throw new RequiredError('Required parameter jobValidateRequest was null or undefined when calling postJobValidateRequest.'); + throw new RequiredError("JobsApi", "postJobValidateRequest", "jobValidateRequest"); } @@ -1476,9 +1681,13 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -1486,8 +1695,6 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - // Body Params const contentType = ObjectSerializer.getPreferredMediaType([ @@ -1500,11 +1707,16 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { ); requestContext.setBody(serializedBody); - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -1522,7 +1734,7 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'jobRegisterRequest' is not null or undefined if (jobRegisterRequest === null || jobRegisterRequest === undefined) { - throw new RequiredError('Required parameter jobRegisterRequest was null or undefined when calling registerJob.'); + throw new RequiredError("JobsApi", "registerJob", "jobRegisterRequest"); } @@ -1541,9 +1753,13 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -1551,8 +1767,6 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - // Body Params const contentType = ObjectSerializer.getPreferredMediaType([ @@ -1565,11 +1779,16 @@ export class JobsApiRequestFactory extends BaseAPIRequestFactory { ); requestContext.setBody(serializedBody); - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -1596,16 +1815,16 @@ export class JobsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -1617,8 +1836,7 @@ export class JobsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -1638,16 +1856,16 @@ export class JobsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -1659,8 +1877,7 @@ export class JobsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -1680,16 +1897,16 @@ export class JobsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -1701,8 +1918,7 @@ export class JobsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -1722,16 +1938,16 @@ export class JobsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -1743,8 +1959,7 @@ export class JobsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -1764,16 +1979,16 @@ export class JobsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -1785,8 +2000,7 @@ export class JobsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -1806,16 +2020,16 @@ export class JobsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -1827,8 +2041,7 @@ export class JobsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -1848,16 +2061,16 @@ export class JobsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -1869,8 +2082,7 @@ export class JobsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -1890,16 +2102,16 @@ export class JobsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -1911,8 +2123,7 @@ export class JobsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -1932,16 +2143,16 @@ export class JobsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -1953,8 +2164,7 @@ export class JobsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -1974,16 +2184,16 @@ export class JobsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -1995,8 +2205,7 @@ export class JobsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -2016,16 +2225,16 @@ export class JobsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -2037,8 +2246,7 @@ export class JobsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -2058,16 +2266,16 @@ export class JobsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -2079,8 +2287,7 @@ export class JobsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -2100,16 +2307,16 @@ export class JobsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -2121,8 +2328,7 @@ export class JobsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -2142,16 +2348,16 @@ export class JobsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -2163,8 +2369,7 @@ export class JobsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -2184,16 +2389,16 @@ export class JobsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -2205,8 +2410,7 @@ export class JobsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -2226,16 +2430,16 @@ export class JobsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -2247,8 +2451,7 @@ export class JobsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -2268,16 +2471,16 @@ export class JobsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -2289,8 +2492,7 @@ export class JobsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -2310,16 +2512,16 @@ export class JobsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -2331,8 +2533,7 @@ export class JobsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -2352,16 +2553,16 @@ export class JobsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -2373,8 +2574,7 @@ export class JobsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -2394,16 +2594,16 @@ export class JobsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -2415,8 +2615,7 @@ export class JobsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -2436,16 +2635,16 @@ export class JobsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -2457,8 +2656,7 @@ export class JobsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } } diff --git a/clients/typescript/v1/apis/MetricsApi.ts b/clients/typescript/v1/apis/MetricsApi.ts index d06a6825..f5dec447 100644 --- a/clients/typescript/v1/apis/MetricsApi.ts +++ b/clients/typescript/v1/apis/MetricsApi.ts @@ -1,10 +1,12 @@ // TODO: better import syntax? -import { BaseAPIRequestFactory, RequiredError } from './baseapi'; +import {BaseAPIRequestFactory, RequiredError} from './baseapi'; import {Configuration} from '../configuration'; -import { RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; +import {RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; import {ObjectSerializer} from '../models/ObjectSerializer'; import {ApiException} from './exception'; -import {isCodeInRange} from '../util'; +import {canConsumeForm, isCodeInRange} from '../util'; +import {SecurityAuthentication} from '../auth/auth'; + import { MetricsSummary } from '../models/MetricsSummary'; @@ -32,18 +34,17 @@ export class MetricsApiRequestFactory extends BaseAPIRequestFactory { requestContext.setQueryParam("format", ObjectSerializer.serialize(format, "string", "")); } - // Header Params - - // Form Params - - // Body Params - - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -70,16 +71,16 @@ export class MetricsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -91,8 +92,7 @@ export class MetricsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } } diff --git a/clients/typescript/v1/apis/NamespacesApi.ts b/clients/typescript/v1/apis/NamespacesApi.ts index 067d1094..8922a3ff 100644 --- a/clients/typescript/v1/apis/NamespacesApi.ts +++ b/clients/typescript/v1/apis/NamespacesApi.ts @@ -1,10 +1,12 @@ // TODO: better import syntax? -import { BaseAPIRequestFactory, RequiredError } from './baseapi'; +import {BaseAPIRequestFactory, RequiredError} from './baseapi'; import {Configuration} from '../configuration'; -import { RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; +import {RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; import {ObjectSerializer} from '../models/ObjectSerializer'; import {ApiException} from './exception'; -import {isCodeInRange} from '../util'; +import {canConsumeForm, isCodeInRange} from '../util'; +import {SecurityAuthentication} from '../auth/auth'; + import { Namespace } from '../models/Namespace'; @@ -37,9 +39,13 @@ export class NamespacesApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -47,16 +53,17 @@ export class NamespacesApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - - - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -74,7 +81,7 @@ export class NamespacesApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'namespaceName' is not null or undefined if (namespaceName === null || namespaceName === undefined) { - throw new RequiredError('Required parameter namespaceName was null or undefined when calling deleteNamespace.'); + throw new RequiredError("NamespacesApi", "deleteNamespace", "namespaceName"); } @@ -94,9 +101,13 @@ export class NamespacesApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -104,16 +115,17 @@ export class NamespacesApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - - - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -136,7 +148,7 @@ export class NamespacesApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'namespaceName' is not null or undefined if (namespaceName === null || namespaceName === undefined) { - throw new RequiredError('Required parameter namespaceName was null or undefined when calling getNamespace.'); + throw new RequiredError("NamespacesApi", "getNamespace", "namespaceName"); } @@ -161,39 +173,54 @@ export class NamespacesApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -233,39 +260,54 @@ export class NamespacesApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -284,13 +326,13 @@ export class NamespacesApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'namespaceName' is not null or undefined if (namespaceName === null || namespaceName === undefined) { - throw new RequiredError('Required parameter namespaceName was null or undefined when calling postNamespace.'); + throw new RequiredError("NamespacesApi", "postNamespace", "namespaceName"); } // verify required parameter 'namespace2' is not null or undefined if (namespace2 === null || namespace2 === undefined) { - throw new RequiredError('Required parameter namespace2 was null or undefined when calling postNamespace.'); + throw new RequiredError("NamespacesApi", "postNamespace", "namespace2"); } @@ -310,9 +352,13 @@ export class NamespacesApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -320,8 +366,6 @@ export class NamespacesApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - // Body Params const contentType = ObjectSerializer.getPreferredMediaType([ @@ -334,11 +378,16 @@ export class NamespacesApiRequestFactory extends BaseAPIRequestFactory { ); requestContext.setBody(serializedBody); - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -361,16 +410,16 @@ export class NamespacesApiResponseProcessor { return; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -382,8 +431,7 @@ export class NamespacesApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -399,16 +447,16 @@ export class NamespacesApiResponseProcessor { return; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -420,8 +468,7 @@ export class NamespacesApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -441,16 +488,16 @@ export class NamespacesApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -462,8 +509,7 @@ export class NamespacesApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -483,16 +529,16 @@ export class NamespacesApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -504,8 +550,7 @@ export class NamespacesApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -521,16 +566,16 @@ export class NamespacesApiResponseProcessor { return; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -542,8 +587,7 @@ export class NamespacesApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } } diff --git a/clients/typescript/v1/apis/NodesApi.ts b/clients/typescript/v1/apis/NodesApi.ts index b057b5e0..1fe9204d 100644 --- a/clients/typescript/v1/apis/NodesApi.ts +++ b/clients/typescript/v1/apis/NodesApi.ts @@ -1,10 +1,12 @@ // TODO: better import syntax? -import { BaseAPIRequestFactory, RequiredError } from './baseapi'; +import {BaseAPIRequestFactory, RequiredError} from './baseapi'; import {Configuration} from '../configuration'; -import { RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; +import {RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; import {ObjectSerializer} from '../models/ObjectSerializer'; import {ApiException} from './exception'; -import {isCodeInRange} from '../util'; +import {canConsumeForm, isCodeInRange} from '../util'; +import {SecurityAuthentication} from '../auth/auth'; + import { AllocationListStub } from '../models/AllocationListStub'; import { Node } from '../models/Node'; @@ -37,7 +39,7 @@ export class NodesApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'nodeId' is not null or undefined if (nodeId === null || nodeId === undefined) { - throw new RequiredError('Required parameter nodeId was null or undefined when calling getNode.'); + throw new RequiredError("NodesApi", "getNode", "nodeId"); } @@ -62,39 +64,54 @@ export class NodesApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -117,7 +134,7 @@ export class NodesApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'nodeId' is not null or undefined if (nodeId === null || nodeId === undefined) { - throw new RequiredError('Required parameter nodeId was null or undefined when calling getNodeAllocations.'); + throw new RequiredError("NodesApi", "getNodeAllocations", "nodeId"); } @@ -142,39 +159,54 @@ export class NodesApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -216,42 +248,59 @@ export class NodesApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } + + // Query Params if (resources !== undefined) { requestContext.setQueryParam("resources", ObjectSerializer.serialize(resources, "boolean", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -275,13 +324,13 @@ export class NodesApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'nodeId' is not null or undefined if (nodeId === null || nodeId === undefined) { - throw new RequiredError('Required parameter nodeId was null or undefined when calling updateNodeDrain.'); + throw new RequiredError("NodesApi", "updateNodeDrain", "nodeId"); } // verify required parameter 'nodeUpdateDrainRequest' is not null or undefined if (nodeUpdateDrainRequest === null || nodeUpdateDrainRequest === undefined) { - throw new RequiredError('Required parameter nodeUpdateDrainRequest was null or undefined when calling updateNodeDrain.'); + throw new RequiredError("NodesApi", "updateNodeDrain", "nodeUpdateDrainRequest"); } @@ -306,30 +355,42 @@ export class NodesApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); // Body Params @@ -343,11 +404,16 @@ export class NodesApiRequestFactory extends BaseAPIRequestFactory { ); requestContext.setBody(serializedBody); - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -371,13 +437,13 @@ export class NodesApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'nodeId' is not null or undefined if (nodeId === null || nodeId === undefined) { - throw new RequiredError('Required parameter nodeId was null or undefined when calling updateNodeEligibility.'); + throw new RequiredError("NodesApi", "updateNodeEligibility", "nodeId"); } // verify required parameter 'nodeUpdateEligibilityRequest' is not null or undefined if (nodeUpdateEligibilityRequest === null || nodeUpdateEligibilityRequest === undefined) { - throw new RequiredError('Required parameter nodeUpdateEligibilityRequest was null or undefined when calling updateNodeEligibility.'); + throw new RequiredError("NodesApi", "updateNodeEligibility", "nodeUpdateEligibilityRequest"); } @@ -402,30 +468,42 @@ export class NodesApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); // Body Params @@ -439,11 +517,16 @@ export class NodesApiRequestFactory extends BaseAPIRequestFactory { ); requestContext.setBody(serializedBody); - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -466,7 +549,7 @@ export class NodesApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'nodeId' is not null or undefined if (nodeId === null || nodeId === undefined) { - throw new RequiredError('Required parameter nodeId was null or undefined when calling updateNodePurge.'); + throw new RequiredError("NodesApi", "updateNodePurge", "nodeId"); } @@ -491,39 +574,54 @@ export class NodesApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -550,16 +648,16 @@ export class NodesApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -571,8 +669,7 @@ export class NodesApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -592,16 +689,16 @@ export class NodesApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -613,8 +710,7 @@ export class NodesApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -634,16 +730,16 @@ export class NodesApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -655,8 +751,7 @@ export class NodesApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -676,16 +771,16 @@ export class NodesApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -697,8 +792,7 @@ export class NodesApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -718,16 +812,16 @@ export class NodesApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -739,8 +833,7 @@ export class NodesApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -760,16 +853,16 @@ export class NodesApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -781,8 +874,7 @@ export class NodesApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } } diff --git a/clients/typescript/v1/apis/OperatorApi.ts b/clients/typescript/v1/apis/OperatorApi.ts index 8fbaeb37..bddc12a7 100644 --- a/clients/typescript/v1/apis/OperatorApi.ts +++ b/clients/typescript/v1/apis/OperatorApi.ts @@ -1,10 +1,12 @@ // TODO: better import syntax? -import { BaseAPIRequestFactory, RequiredError } from './baseapi'; +import {BaseAPIRequestFactory, RequiredError} from './baseapi'; import {Configuration} from '../configuration'; -import { RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; +import {RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; import {ObjectSerializer} from '../models/ObjectSerializer'; import {ApiException} from './exception'; -import {isCodeInRange} from '../util'; +import {canConsumeForm, isCodeInRange} from '../util'; +import {SecurityAuthentication} from '../auth/auth'; + import { AutopilotConfiguration } from '../models/AutopilotConfiguration'; import { OperatorHealthReply } from '../models/OperatorHealthReply'; @@ -42,9 +44,13 @@ export class OperatorApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -52,16 +58,17 @@ export class OperatorApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - - // Body Params - - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -101,39 +108,54 @@ export class OperatorApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -173,39 +195,54 @@ export class OperatorApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -245,39 +282,54 @@ export class OperatorApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -317,39 +369,54 @@ export class OperatorApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -367,7 +434,7 @@ export class OperatorApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'schedulerConfiguration' is not null or undefined if (schedulerConfiguration === null || schedulerConfiguration === undefined) { - throw new RequiredError('Required parameter schedulerConfiguration was null or undefined when calling postOperatorSchedulerConfiguration.'); + throw new RequiredError("OperatorApi", "postOperatorSchedulerConfiguration", "schedulerConfiguration"); } @@ -386,9 +453,13 @@ export class OperatorApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -396,8 +467,6 @@ export class OperatorApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - // Body Params const contentType = ObjectSerializer.getPreferredMediaType([ @@ -410,11 +479,16 @@ export class OperatorApiRequestFactory extends BaseAPIRequestFactory { ); requestContext.setBody(serializedBody); - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -432,7 +506,7 @@ export class OperatorApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'autopilotConfiguration' is not null or undefined if (autopilotConfiguration === null || autopilotConfiguration === undefined) { - throw new RequiredError('Required parameter autopilotConfiguration was null or undefined when calling putOperatorAutopilotConfiguration.'); + throw new RequiredError("OperatorApi", "putOperatorAutopilotConfiguration", "autopilotConfiguration"); } @@ -451,9 +525,13 @@ export class OperatorApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -461,8 +539,6 @@ export class OperatorApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - // Body Params const contentType = ObjectSerializer.getPreferredMediaType([ @@ -475,11 +551,16 @@ export class OperatorApiRequestFactory extends BaseAPIRequestFactory { ); requestContext.setBody(serializedBody); - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -502,16 +583,16 @@ export class OperatorApiResponseProcessor { return; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -523,8 +604,7 @@ export class OperatorApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -544,16 +624,16 @@ export class OperatorApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -565,8 +645,7 @@ export class OperatorApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -586,16 +665,16 @@ export class OperatorApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -607,8 +686,7 @@ export class OperatorApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -628,16 +706,16 @@ export class OperatorApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -649,8 +727,7 @@ export class OperatorApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -670,16 +747,16 @@ export class OperatorApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -691,8 +768,7 @@ export class OperatorApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -712,16 +788,16 @@ export class OperatorApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -733,8 +809,7 @@ export class OperatorApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -754,16 +829,16 @@ export class OperatorApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -775,8 +850,7 @@ export class OperatorApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } } diff --git a/clients/typescript/v1/apis/PluginsApi.ts b/clients/typescript/v1/apis/PluginsApi.ts index 05222c5e..c6055c58 100644 --- a/clients/typescript/v1/apis/PluginsApi.ts +++ b/clients/typescript/v1/apis/PluginsApi.ts @@ -1,10 +1,12 @@ // TODO: better import syntax? -import { BaseAPIRequestFactory, RequiredError } from './baseapi'; +import {BaseAPIRequestFactory, RequiredError} from './baseapi'; import {Configuration} from '../configuration'; -import { RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; +import {RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; import {ObjectSerializer} from '../models/ObjectSerializer'; import {ApiException} from './exception'; -import {isCodeInRange} from '../util'; +import {canConsumeForm, isCodeInRange} from '../util'; +import {SecurityAuthentication} from '../auth/auth'; + import { CSIPlugin } from '../models/CSIPlugin'; import { CSIPluginListStub } from '../models/CSIPluginListStub'; @@ -31,7 +33,7 @@ export class PluginsApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'pluginID' is not null or undefined if (pluginID === null || pluginID === undefined) { - throw new RequiredError('Required parameter pluginID was null or undefined when calling getPluginCSI.'); + throw new RequiredError("PluginsApi", "getPluginCSI", "pluginID"); } @@ -56,39 +58,54 @@ export class PluginsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -128,39 +145,54 @@ export class PluginsApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -187,16 +219,16 @@ export class PluginsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -208,8 +240,7 @@ export class PluginsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -229,16 +260,16 @@ export class PluginsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -250,8 +281,7 @@ export class PluginsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } } diff --git a/clients/typescript/v1/apis/RegionsApi.ts b/clients/typescript/v1/apis/RegionsApi.ts index 43ae3111..a3efc3ed 100644 --- a/clients/typescript/v1/apis/RegionsApi.ts +++ b/clients/typescript/v1/apis/RegionsApi.ts @@ -1,10 +1,12 @@ // TODO: better import syntax? -import { BaseAPIRequestFactory, RequiredError } from './baseapi'; +import {BaseAPIRequestFactory, RequiredError} from './baseapi'; import {Configuration} from '../configuration'; -import { RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; +import {RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; import {ObjectSerializer} from '../models/ObjectSerializer'; import {ApiException} from './exception'; -import {isCodeInRange} from '../util'; +import {canConsumeForm, isCodeInRange} from '../util'; +import {SecurityAuthentication} from '../auth/auth'; + /** @@ -24,20 +26,17 @@ export class RegionsApiRequestFactory extends BaseAPIRequestFactory { const requestContext = _config.baseServer.makeRequestContext(localVarPath, HttpMethod.GET); requestContext.setHeaderParam("Accept", "application/json, */*;q=0.8") - // Query Params - - // Header Params - - // Form Params - - // Body Params - - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -64,16 +63,16 @@ export class RegionsApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -85,8 +84,7 @@ export class RegionsApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } } diff --git a/clients/typescript/v1/apis/ScalingApi.ts b/clients/typescript/v1/apis/ScalingApi.ts index 68522613..82c0da90 100644 --- a/clients/typescript/v1/apis/ScalingApi.ts +++ b/clients/typescript/v1/apis/ScalingApi.ts @@ -1,10 +1,12 @@ // TODO: better import syntax? -import { BaseAPIRequestFactory, RequiredError } from './baseapi'; +import {BaseAPIRequestFactory, RequiredError} from './baseapi'; import {Configuration} from '../configuration'; -import { RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; +import {RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; import {ObjectSerializer} from '../models/ObjectSerializer'; import {ApiException} from './exception'; -import {isCodeInRange} from '../util'; +import {canConsumeForm, isCodeInRange} from '../util'; +import {SecurityAuthentication} from '../auth/auth'; + import { ScalingPolicy } from '../models/ScalingPolicy'; import { ScalingPolicyListStub } from '../models/ScalingPolicyListStub'; @@ -48,39 +50,54 @@ export class ScalingApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -103,7 +120,7 @@ export class ScalingApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'policyID' is not null or undefined if (policyID === null || policyID === undefined) { - throw new RequiredError('Required parameter policyID was null or undefined when calling getScalingPolicy.'); + throw new RequiredError("ScalingApi", "getScalingPolicy", "policyID"); } @@ -128,39 +145,54 @@ export class ScalingApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -187,16 +219,16 @@ export class ScalingApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -208,8 +240,7 @@ export class ScalingApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -229,16 +260,16 @@ export class ScalingApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -250,8 +281,7 @@ export class ScalingApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } } diff --git a/clients/typescript/v1/apis/SearchApi.ts b/clients/typescript/v1/apis/SearchApi.ts index 4df4dc6b..7338c415 100644 --- a/clients/typescript/v1/apis/SearchApi.ts +++ b/clients/typescript/v1/apis/SearchApi.ts @@ -1,10 +1,12 @@ // TODO: better import syntax? -import { BaseAPIRequestFactory, RequiredError } from './baseapi'; +import {BaseAPIRequestFactory, RequiredError} from './baseapi'; import {Configuration} from '../configuration'; -import { RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; +import {RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; import {ObjectSerializer} from '../models/ObjectSerializer'; import {ApiException} from './exception'; -import {isCodeInRange} from '../util'; +import {canConsumeForm, isCodeInRange} from '../util'; +import {SecurityAuthentication} from '../auth/auth'; + import { FuzzySearchRequest } from '../models/FuzzySearchRequest'; import { FuzzySearchResponse } from '../models/FuzzySearchResponse'; @@ -33,7 +35,7 @@ export class SearchApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'fuzzySearchRequest' is not null or undefined if (fuzzySearchRequest === null || fuzzySearchRequest === undefined) { - throw new RequiredError('Required parameter fuzzySearchRequest was null or undefined when calling getFuzzySearch.'); + throw new RequiredError("SearchApi", "getFuzzySearch", "fuzzySearchRequest"); } @@ -57,30 +59,42 @@ export class SearchApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); // Body Params @@ -94,11 +108,16 @@ export class SearchApiRequestFactory extends BaseAPIRequestFactory { ); requestContext.setBody(serializedBody); - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -121,7 +140,7 @@ export class SearchApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'searchRequest' is not null or undefined if (searchRequest === null || searchRequest === undefined) { - throw new RequiredError('Required parameter searchRequest was null or undefined when calling getSearch.'); + throw new RequiredError("SearchApi", "getSearch", "searchRequest"); } @@ -145,30 +164,42 @@ export class SearchApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); // Body Params @@ -182,11 +213,16 @@ export class SearchApiRequestFactory extends BaseAPIRequestFactory { ); requestContext.setBody(serializedBody); - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -213,16 +249,16 @@ export class SearchApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -234,8 +270,7 @@ export class SearchApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -255,16 +290,16 @@ export class SearchApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -276,8 +311,7 @@ export class SearchApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } } diff --git a/clients/typescript/v1/apis/StatusApi.ts b/clients/typescript/v1/apis/StatusApi.ts index 3dd3230a..6e5b5d9e 100644 --- a/clients/typescript/v1/apis/StatusApi.ts +++ b/clients/typescript/v1/apis/StatusApi.ts @@ -1,10 +1,12 @@ // TODO: better import syntax? -import { BaseAPIRequestFactory, RequiredError } from './baseapi'; +import {BaseAPIRequestFactory, RequiredError} from './baseapi'; import {Configuration} from '../configuration'; -import { RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; +import {RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; import {ObjectSerializer} from '../models/ObjectSerializer'; import {ApiException} from './exception'; -import {isCodeInRange} from '../util'; +import {canConsumeForm, isCodeInRange} from '../util'; +import {SecurityAuthentication} from '../auth/auth'; + /** @@ -46,39 +48,54 @@ export class StatusApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -118,39 +135,54 @@ export class StatusApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -177,16 +209,16 @@ export class StatusApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -198,8 +230,7 @@ export class StatusApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -219,16 +250,16 @@ export class StatusApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -240,8 +271,7 @@ export class StatusApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } } diff --git a/clients/typescript/v1/apis/SystemApi.ts b/clients/typescript/v1/apis/SystemApi.ts index 4df6c024..b9210757 100644 --- a/clients/typescript/v1/apis/SystemApi.ts +++ b/clients/typescript/v1/apis/SystemApi.ts @@ -1,10 +1,12 @@ // TODO: better import syntax? -import { BaseAPIRequestFactory, RequiredError } from './baseapi'; +import {BaseAPIRequestFactory, RequiredError} from './baseapi'; import {Configuration} from '../configuration'; -import { RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; +import {RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; import {ObjectSerializer} from '../models/ObjectSerializer'; import {ApiException} from './exception'; -import {isCodeInRange} from '../util'; +import {canConsumeForm, isCodeInRange} from '../util'; +import {SecurityAuthentication} from '../auth/auth'; + /** @@ -36,9 +38,13 @@ export class SystemApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -46,16 +52,17 @@ export class SystemApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - - // Body Params - - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -85,9 +92,13 @@ export class SystemApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -95,16 +106,17 @@ export class SystemApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - - // Body Params - - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -127,16 +139,16 @@ export class SystemApiResponseProcessor { return; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -148,8 +160,7 @@ export class SystemApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -165,16 +176,16 @@ export class SystemApiResponseProcessor { return; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -186,8 +197,7 @@ export class SystemApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } } diff --git a/clients/typescript/v1/apis/VolumesApi.ts b/clients/typescript/v1/apis/VolumesApi.ts index 67702d0e..d56c3483 100644 --- a/clients/typescript/v1/apis/VolumesApi.ts +++ b/clients/typescript/v1/apis/VolumesApi.ts @@ -1,10 +1,12 @@ // TODO: better import syntax? -import { BaseAPIRequestFactory, RequiredError } from './baseapi'; +import {BaseAPIRequestFactory, RequiredError} from './baseapi'; import {Configuration} from '../configuration'; -import { RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; +import {RequestContext, HttpMethod, ResponseContext, HttpFile} from '../http/http'; import {ObjectSerializer} from '../models/ObjectSerializer'; import {ApiException} from './exception'; -import {isCodeInRange} from '../util'; +import {canConsumeForm, isCodeInRange} from '../util'; +import {SecurityAuthentication} from '../auth/auth'; + import { CSISnapshotCreateRequest } from '../models/CSISnapshotCreateRequest'; import { CSISnapshotCreateResponse } from '../models/CSISnapshotCreateResponse'; @@ -34,19 +36,19 @@ export class VolumesApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'volumeId' is not null or undefined if (volumeId === null || volumeId === undefined) { - throw new RequiredError('Required parameter volumeId was null or undefined when calling createVolume.'); + throw new RequiredError("VolumesApi", "createVolume", "volumeId"); } // verify required parameter 'action' is not null or undefined if (action === null || action === undefined) { - throw new RequiredError('Required parameter action was null or undefined when calling createVolume.'); + throw new RequiredError("VolumesApi", "createVolume", "action"); } // verify required parameter 'cSIVolumeCreateRequest' is not null or undefined if (cSIVolumeCreateRequest === null || cSIVolumeCreateRequest === undefined) { - throw new RequiredError('Required parameter cSIVolumeCreateRequest was null or undefined when calling createVolume.'); + throw new RequiredError("VolumesApi", "createVolume", "cSIVolumeCreateRequest"); } @@ -67,9 +69,13 @@ export class VolumesApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -77,8 +83,6 @@ export class VolumesApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - // Body Params const contentType = ObjectSerializer.getPreferredMediaType([ @@ -91,11 +95,16 @@ export class VolumesApiRequestFactory extends BaseAPIRequestFactory { ); requestContext.setBody(serializedBody); - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -129,15 +138,23 @@ export class VolumesApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } + + // Query Params if (pluginId !== undefined) { requestContext.setQueryParam("plugin_id", ObjectSerializer.serialize(pluginId, "string", "")); } + + // Query Params if (snapshotId !== undefined) { requestContext.setQueryParam("snapshot_id", ObjectSerializer.serialize(snapshotId, "string", "")); } @@ -145,16 +162,17 @@ export class VolumesApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - - - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -173,7 +191,7 @@ export class VolumesApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'volumeId' is not null or undefined if (volumeId === null || volumeId === undefined) { - throw new RequiredError('Required parameter volumeId was null or undefined when calling deleteVolumeRegistration.'); + throw new RequiredError("VolumesApi", "deleteVolumeRegistration", "volumeId"); } @@ -194,12 +212,18 @@ export class VolumesApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } + + // Query Params if (force !== undefined) { requestContext.setQueryParam("force", ObjectSerializer.serialize(force, "string", "")); } @@ -207,16 +231,17 @@ export class VolumesApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - - // Body Params - - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -236,13 +261,13 @@ export class VolumesApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'volumeId' is not null or undefined if (volumeId === null || volumeId === undefined) { - throw new RequiredError('Required parameter volumeId was null or undefined when calling detachOrDeleteVolume.'); + throw new RequiredError("VolumesApi", "detachOrDeleteVolume", "volumeId"); } // verify required parameter 'action' is not null or undefined if (action === null || action === undefined) { - throw new RequiredError('Required parameter action was null or undefined when calling detachOrDeleteVolume.'); + throw new RequiredError("VolumesApi", "detachOrDeleteVolume", "action"); } @@ -264,12 +289,18 @@ export class VolumesApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } + + // Query Params if (node !== undefined) { requestContext.setQueryParam("node", ObjectSerializer.serialize(node, "string", "")); } @@ -277,16 +308,17 @@ export class VolumesApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - - // Body Params - - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -328,42 +360,59 @@ export class VolumesApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } + + // Query Params if (pluginId !== undefined) { requestContext.setQueryParam("plugin_id", ObjectSerializer.serialize(pluginId, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -405,42 +454,59 @@ export class VolumesApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } + + // Query Params if (pluginId !== undefined) { requestContext.setQueryParam("plugin_id", ObjectSerializer.serialize(pluginId, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -463,7 +529,7 @@ export class VolumesApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'volumeId' is not null or undefined if (volumeId === null || volumeId === undefined) { - throw new RequiredError('Required parameter volumeId was null or undefined when calling getVolume.'); + throw new RequiredError("VolumesApi", "getVolume", "volumeId"); } @@ -488,39 +554,54 @@ export class VolumesApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -566,48 +647,69 @@ export class VolumesApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (wait !== undefined) { requestContext.setQueryParam("wait", ObjectSerializer.serialize(wait, "string", "")); } + + // Query Params if (stale !== undefined) { requestContext.setQueryParam("stale", ObjectSerializer.serialize(stale, "string", "")); } + + // Query Params if (prefix !== undefined) { requestContext.setQueryParam("prefix", ObjectSerializer.serialize(prefix, "string", "")); } + + // Query Params if (perPage !== undefined) { requestContext.setQueryParam("per_page", ObjectSerializer.serialize(perPage, "number", "")); } + + // Query Params if (nextToken !== undefined) { requestContext.setQueryParam("next_token", ObjectSerializer.serialize(nextToken, "string", "")); } + + // Query Params if (nodeId !== undefined) { requestContext.setQueryParam("node_id", ObjectSerializer.serialize(nodeId, "string", "")); } + + // Query Params if (pluginId !== undefined) { requestContext.setQueryParam("plugin_id", ObjectSerializer.serialize(pluginId, "string", "")); } + + // Query Params if (type !== undefined) { requestContext.setQueryParam("type", ObjectSerializer.serialize(type, "string", "")); } // Header Params requestContext.setHeaderParam("index", ObjectSerializer.serialize(index, "number", "")); - requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - - // Form Params + // Header Params + requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Body Params - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -625,7 +727,7 @@ export class VolumesApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'cSISnapshotCreateRequest' is not null or undefined if (cSISnapshotCreateRequest === null || cSISnapshotCreateRequest === undefined) { - throw new RequiredError('Required parameter cSISnapshotCreateRequest was null or undefined when calling postSnapshot.'); + throw new RequiredError("VolumesApi", "postSnapshot", "cSISnapshotCreateRequest"); } @@ -644,9 +746,13 @@ export class VolumesApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -654,8 +760,6 @@ export class VolumesApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - // Body Params const contentType = ObjectSerializer.getPreferredMediaType([ @@ -668,11 +772,16 @@ export class VolumesApiRequestFactory extends BaseAPIRequestFactory { ); requestContext.setBody(serializedBody); - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -690,7 +799,7 @@ export class VolumesApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'cSIVolumeRegisterRequest' is not null or undefined if (cSIVolumeRegisterRequest === null || cSIVolumeRegisterRequest === undefined) { - throw new RequiredError('Required parameter cSIVolumeRegisterRequest was null or undefined when calling postVolume.'); + throw new RequiredError("VolumesApi", "postVolume", "cSIVolumeRegisterRequest"); } @@ -709,9 +818,13 @@ export class VolumesApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -719,8 +832,6 @@ export class VolumesApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - // Body Params const contentType = ObjectSerializer.getPreferredMediaType([ @@ -733,11 +844,16 @@ export class VolumesApiRequestFactory extends BaseAPIRequestFactory { ); requestContext.setBody(serializedBody); - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -756,13 +872,13 @@ export class VolumesApiRequestFactory extends BaseAPIRequestFactory { // verify required parameter 'volumeId' is not null or undefined if (volumeId === null || volumeId === undefined) { - throw new RequiredError('Required parameter volumeId was null or undefined when calling postVolumeRegistration.'); + throw new RequiredError("VolumesApi", "postVolumeRegistration", "volumeId"); } // verify required parameter 'cSIVolumeRegisterRequest' is not null or undefined if (cSIVolumeRegisterRequest === null || cSIVolumeRegisterRequest === undefined) { - throw new RequiredError('Required parameter cSIVolumeRegisterRequest was null or undefined when calling postVolumeRegistration.'); + throw new RequiredError("VolumesApi", "postVolumeRegistration", "cSIVolumeRegisterRequest"); } @@ -782,9 +898,13 @@ export class VolumesApiRequestFactory extends BaseAPIRequestFactory { if (region !== undefined) { requestContext.setQueryParam("region", ObjectSerializer.serialize(region, "string", "")); } + + // Query Params if (namespace !== undefined) { requestContext.setQueryParam("namespace", ObjectSerializer.serialize(namespace, "string", "")); } + + // Query Params if (idempotencyToken !== undefined) { requestContext.setQueryParam("idempotency_token", ObjectSerializer.serialize(idempotencyToken, "string", "")); } @@ -792,8 +912,6 @@ export class VolumesApiRequestFactory extends BaseAPIRequestFactory { // Header Params requestContext.setHeaderParam("X-Nomad-Token", ObjectSerializer.serialize(xNomadToken, "string", "")); - // Form Params - // Body Params const contentType = ObjectSerializer.getPreferredMediaType([ @@ -806,11 +924,16 @@ export class VolumesApiRequestFactory extends BaseAPIRequestFactory { ); requestContext.setBody(serializedBody); - let authMethod = null; + let authMethod: SecurityAuthentication | undefined; // Apply auth methods authMethod = _config.authMethods["X-Nomad-Token"] - if (authMethod) { - await authMethod.applySecurityAuthentication(requestContext); + if (authMethod?.applySecurityAuthentication) { + await authMethod?.applySecurityAuthentication(requestContext); + } + + const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default + if (defaultAuth?.applySecurityAuthentication) { + await defaultAuth?.applySecurityAuthentication(requestContext); } return requestContext; @@ -833,16 +956,16 @@ export class VolumesApiResponseProcessor { return; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -854,8 +977,7 @@ export class VolumesApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -871,16 +993,16 @@ export class VolumesApiResponseProcessor { return; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -892,8 +1014,7 @@ export class VolumesApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -909,16 +1030,16 @@ export class VolumesApiResponseProcessor { return; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -930,8 +1051,7 @@ export class VolumesApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -947,16 +1067,16 @@ export class VolumesApiResponseProcessor { return; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -968,8 +1088,7 @@ export class VolumesApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -989,16 +1108,16 @@ export class VolumesApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -1010,8 +1129,7 @@ export class VolumesApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -1031,16 +1149,16 @@ export class VolumesApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -1052,8 +1170,7 @@ export class VolumesApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -1073,16 +1190,16 @@ export class VolumesApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -1094,8 +1211,7 @@ export class VolumesApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -1115,16 +1231,16 @@ export class VolumesApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -1136,8 +1252,7 @@ export class VolumesApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -1157,16 +1272,16 @@ export class VolumesApiResponseProcessor { return body; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -1178,8 +1293,7 @@ export class VolumesApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -1195,16 +1309,16 @@ export class VolumesApiResponseProcessor { return; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -1216,8 +1330,7 @@ export class VolumesApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } /** @@ -1233,16 +1346,16 @@ export class VolumesApiResponseProcessor { return; } if (isCodeInRange("400", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Bad request"); + throw new ApiException(response.httpStatusCode, "Bad request", undefined, response.headers); } if (isCodeInRange("403", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Forbidden"); + throw new ApiException(response.httpStatusCode, "Forbidden", undefined, response.headers); } if (isCodeInRange("405", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Method not allowed"); + throw new ApiException(response.httpStatusCode, "Method not allowed", undefined, response.headers); } if (isCodeInRange("500", response.httpStatusCode)) { - throw new ApiException(response.httpStatusCode, "Internal server error"); + throw new ApiException(response.httpStatusCode, "Internal server error", undefined, response.headers); } // Work around for missing responses in specification, e.g. for petstore.yaml @@ -1254,8 +1367,7 @@ export class VolumesApiResponseProcessor { return body; } - let body = response.body || ""; - throw new ApiException(response.httpStatusCode, "Unknown API Status Code!\nBody: \"" + body + "\""); + throw new ApiException(response.httpStatusCode, "Unknown API Status Code!", await response.getBodyAsAny(), response.headers); } } diff --git a/clients/typescript/v1/apis/baseapi.ts b/clients/typescript/v1/apis/baseapi.ts index fe7ee3d1..ce1e2dbc 100644 --- a/clients/typescript/v1/apis/baseapi.ts +++ b/clients/typescript/v1/apis/baseapi.ts @@ -13,7 +13,7 @@ export const COLLECTION_FORMATS = { /** - * + * * @export * @class BaseAPI */ @@ -24,14 +24,14 @@ export class BaseAPIRequestFactory { }; /** - * + * * @export * @class RequiredError * @extends {Error} */ export class RequiredError extends Error { name: "RequiredError" = "RequiredError"; - constructor(public field: string, msg?: string) { - super(msg); + constructor(public api: string, public method: string, public field: string) { + super("Required parameter " + field + " was null or undefined when calling " + api + "." + method + "."); } } diff --git a/clients/typescript/v1/apis/exception.ts b/clients/typescript/v1/apis/exception.ts index fb8d314e..9365d33a 100644 --- a/clients/typescript/v1/apis/exception.ts +++ b/clients/typescript/v1/apis/exception.ts @@ -1,5 +1,5 @@ /** - * Represents an error caused by an api call i.e. it has attributes for a HTTP status code + * Represents an error caused by an api call i.e. it has attributes for a HTTP status code * and the returned body object. * * Example @@ -8,7 +8,8 @@ * */ export class ApiException extends Error { - public constructor(public code: number, public body: T) { - super("HTTP-Code: " + code + "\nMessage: " + JSON.stringify(body)) + public constructor(public code: number, message: string, public body: T, public headers: { [key: string]: string; }) { + super("HTTP-Code: " + code + "\nMessage: " + message + "\nBody: " + JSON.stringify(body) + "\nHeaders: " + + JSON.stringify(headers)) } } diff --git a/clients/typescript/v1/auth/auth.ts b/clients/typescript/v1/auth/auth.ts index 8b1c4128..630f48b8 100644 --- a/clients/typescript/v1/auth/auth.ts +++ b/clients/typescript/v1/auth/auth.ts @@ -44,6 +44,7 @@ export class XNomadTokenAuthentication implements SecurityAuthentication { export type AuthMethods = { + "default"?: SecurityAuthentication, "X-Nomad-Token"?: SecurityAuthentication } @@ -53,6 +54,7 @@ export type HttpBearerConfiguration = { tokenProvider: TokenProvider }; export type OAuth2Configuration = { accessToken: string }; export type AuthMethodsConfiguration = { + "default"?: SecurityAuthentication, "X-Nomad-Token"?: ApiKeyConfiguration } @@ -66,6 +68,7 @@ export function configureAuthMethods(config: AuthMethodsConfiguration | undefine if (!config) { return authMethods; } + authMethods["default"] = config["default"] if (config["X-Nomad-Token"]) { authMethods["X-Nomad-Token"] = new XNomadTokenAuthentication( diff --git a/clients/typescript/v1/http/http.ts b/clients/typescript/v1/http/http.ts index 8b8219e9..f19e206b 100644 --- a/clients/typescript/v1/http/http.ts +++ b/clients/typescript/v1/http/http.ts @@ -1,5 +1,5 @@ // typings of url-parse are incorrect... -// @ts-ignore +// @ts-ignore import * as URLParse from "url-parse"; import { Observable, from } from '../rxjsStub'; @@ -35,7 +35,7 @@ export class HttpException extends Error { /** * Represents the body of an outgoing HTTP request. */ -export type RequestBody = undefined | string | FormData; +export type RequestBody = undefined | string | FormData | URLSearchParams; /** * Represents an HTTP request context @@ -113,7 +113,7 @@ export class RequestContext { this.headers["Cookie"] += name + "=" + value + "; "; } - public setHeaderParam(key: string, value: string): void { + public setHeaderParam(key: string, value: string): void { this.headers[key] = value; } } @@ -201,6 +201,22 @@ export class ResponseContext { }); } } + + /** + * Use a heuristic to get a body of unknown data structure. + * Return as string if possible, otherwise as binary. + */ + public getBodyAsAny(): Promise { + try { + return this.body.text(); + } catch {} + + try { + return this.body.binary(); + } catch {} + + return Promise.resolve(undefined); + } } export interface HttpLibrary { diff --git a/clients/typescript/v1/middleware.ts b/clients/typescript/v1/middleware.ts index e9007138..524f93f0 100644 --- a/clients/typescript/v1/middleware.ts +++ b/clients/typescript/v1/middleware.ts @@ -34,7 +34,7 @@ export class PromiseMiddlewareWrapper implements Middleware { pre(context: RequestContext): Observable { return from(this.middleware.pre(context)); } - + post(context: ResponseContext): Observable { return from(this.middleware.post(context)); } diff --git a/clients/typescript/v1/models/ACLPolicy.ts b/clients/typescript/v1/models/ACLPolicy.ts index a90fcfa2..864535d3 100644 --- a/clients/typescript/v1/models/ACLPolicy.ts +++ b/clients/typescript/v1/models/ACLPolicy.ts @@ -56,7 +56,7 @@ export class ACLPolicy { static getAttributeTypeMap() { return ACLPolicy.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/ACLPolicyListStub.ts b/clients/typescript/v1/models/ACLPolicyListStub.ts index 33c0ef83..d7576f1f 100644 --- a/clients/typescript/v1/models/ACLPolicyListStub.ts +++ b/clients/typescript/v1/models/ACLPolicyListStub.ts @@ -49,7 +49,7 @@ export class ACLPolicyListStub { static getAttributeTypeMap() { return ACLPolicyListStub.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/ACLToken.ts b/clients/typescript/v1/models/ACLToken.ts index b993b23f..9dec23a2 100644 --- a/clients/typescript/v1/models/ACLToken.ts +++ b/clients/typescript/v1/models/ACLToken.ts @@ -84,7 +84,7 @@ export class ACLToken { static getAttributeTypeMap() { return ACLToken.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/ACLTokenListStub.ts b/clients/typescript/v1/models/ACLTokenListStub.ts index a10a678e..bd321a74 100644 --- a/clients/typescript/v1/models/ACLTokenListStub.ts +++ b/clients/typescript/v1/models/ACLTokenListStub.ts @@ -77,7 +77,7 @@ export class ACLTokenListStub { static getAttributeTypeMap() { return ACLTokenListStub.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/Affinity.ts b/clients/typescript/v1/models/Affinity.ts index 01343e43..6ff9e83d 100644 --- a/clients/typescript/v1/models/Affinity.ts +++ b/clients/typescript/v1/models/Affinity.ts @@ -49,7 +49,7 @@ export class Affinity { static getAttributeTypeMap() { return Affinity.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/AllocDeploymentStatus.ts b/clients/typescript/v1/models/AllocDeploymentStatus.ts index fab07002..76388f5d 100644 --- a/clients/typescript/v1/models/AllocDeploymentStatus.ts +++ b/clients/typescript/v1/models/AllocDeploymentStatus.ts @@ -49,7 +49,7 @@ export class AllocDeploymentStatus { static getAttributeTypeMap() { return AllocDeploymentStatus.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/AllocStopResponse.ts b/clients/typescript/v1/models/AllocStopResponse.ts index 63dd5c05..ab640645 100644 --- a/clients/typescript/v1/models/AllocStopResponse.ts +++ b/clients/typescript/v1/models/AllocStopResponse.ts @@ -35,7 +35,7 @@ export class AllocStopResponse { static getAttributeTypeMap() { return AllocStopResponse.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/AllocatedCpuResources.ts b/clients/typescript/v1/models/AllocatedCpuResources.ts index 5a138a02..bc376882 100644 --- a/clients/typescript/v1/models/AllocatedCpuResources.ts +++ b/clients/typescript/v1/models/AllocatedCpuResources.ts @@ -28,7 +28,7 @@ export class AllocatedCpuResources { static getAttributeTypeMap() { return AllocatedCpuResources.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/AllocatedDeviceResource.ts b/clients/typescript/v1/models/AllocatedDeviceResource.ts index c2ea8c7a..f6b2840c 100644 --- a/clients/typescript/v1/models/AllocatedDeviceResource.ts +++ b/clients/typescript/v1/models/AllocatedDeviceResource.ts @@ -49,7 +49,7 @@ export class AllocatedDeviceResource { static getAttributeTypeMap() { return AllocatedDeviceResource.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/AllocatedMemoryResources.ts b/clients/typescript/v1/models/AllocatedMemoryResources.ts index 99161a00..2cf3b443 100644 --- a/clients/typescript/v1/models/AllocatedMemoryResources.ts +++ b/clients/typescript/v1/models/AllocatedMemoryResources.ts @@ -35,7 +35,7 @@ export class AllocatedMemoryResources { static getAttributeTypeMap() { return AllocatedMemoryResources.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/AllocatedResources.ts b/clients/typescript/v1/models/AllocatedResources.ts index 44231813..3210f045 100644 --- a/clients/typescript/v1/models/AllocatedResources.ts +++ b/clients/typescript/v1/models/AllocatedResources.ts @@ -37,7 +37,7 @@ export class AllocatedResources { static getAttributeTypeMap() { return AllocatedResources.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/AllocatedSharedResources.ts b/clients/typescript/v1/models/AllocatedSharedResources.ts index 9f3a9b07..8e3f5267 100644 --- a/clients/typescript/v1/models/AllocatedSharedResources.ts +++ b/clients/typescript/v1/models/AllocatedSharedResources.ts @@ -44,7 +44,7 @@ export class AllocatedSharedResources { static getAttributeTypeMap() { return AllocatedSharedResources.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/AllocatedTaskResources.ts b/clients/typescript/v1/models/AllocatedTaskResources.ts index e4a26b16..1fec8c52 100644 --- a/clients/typescript/v1/models/AllocatedTaskResources.ts +++ b/clients/typescript/v1/models/AllocatedTaskResources.ts @@ -53,7 +53,7 @@ export class AllocatedTaskResources { static getAttributeTypeMap() { return AllocatedTaskResources.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/Allocation.ts b/clients/typescript/v1/models/Allocation.ts index e79eaba5..2ecb7946 100644 --- a/clients/typescript/v1/models/Allocation.ts +++ b/clients/typescript/v1/models/Allocation.ts @@ -260,7 +260,7 @@ export class Allocation { static getAttributeTypeMap() { return Allocation.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/AllocationListStub.ts b/clients/typescript/v1/models/AllocationListStub.ts index 43f6c1e7..f2942bdb 100644 --- a/clients/typescript/v1/models/AllocationListStub.ts +++ b/clients/typescript/v1/models/AllocationListStub.ts @@ -200,7 +200,7 @@ export class AllocationListStub { static getAttributeTypeMap() { return AllocationListStub.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/AllocationMetric.ts b/clients/typescript/v1/models/AllocationMetric.ts index 336c7749..804dc1cf 100644 --- a/clients/typescript/v1/models/AllocationMetric.ts +++ b/clients/typescript/v1/models/AllocationMetric.ts @@ -121,7 +121,7 @@ export class AllocationMetric { static getAttributeTypeMap() { return AllocationMetric.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/Attribute.ts b/clients/typescript/v1/models/Attribute.ts index 00d43f2f..29bd6fe4 100644 --- a/clients/typescript/v1/models/Attribute.ts +++ b/clients/typescript/v1/models/Attribute.ts @@ -56,7 +56,7 @@ export class Attribute { static getAttributeTypeMap() { return Attribute.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/AutopilotConfiguration.ts b/clients/typescript/v1/models/AutopilotConfiguration.ts index 596705c2..af087572 100644 --- a/clients/typescript/v1/models/AutopilotConfiguration.ts +++ b/clients/typescript/v1/models/AutopilotConfiguration.ts @@ -91,7 +91,7 @@ export class AutopilotConfiguration { static getAttributeTypeMap() { return AutopilotConfiguration.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/CSIControllerInfo.ts b/clients/typescript/v1/models/CSIControllerInfo.ts index 147121db..846fa5c2 100644 --- a/clients/typescript/v1/models/CSIControllerInfo.ts +++ b/clients/typescript/v1/models/CSIControllerInfo.ts @@ -105,7 +105,7 @@ export class CSIControllerInfo { static getAttributeTypeMap() { return CSIControllerInfo.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/CSIInfo.ts b/clients/typescript/v1/models/CSIInfo.ts index 93667299..f0f28221 100644 --- a/clients/typescript/v1/models/CSIInfo.ts +++ b/clients/typescript/v1/models/CSIInfo.ts @@ -86,7 +86,7 @@ export class CSIInfo { static getAttributeTypeMap() { return CSIInfo.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/CSIMountOptions.ts b/clients/typescript/v1/models/CSIMountOptions.ts index 315f9c43..632625cd 100644 --- a/clients/typescript/v1/models/CSIMountOptions.ts +++ b/clients/typescript/v1/models/CSIMountOptions.ts @@ -35,7 +35,7 @@ export class CSIMountOptions { static getAttributeTypeMap() { return CSIMountOptions.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/CSINodeInfo.ts b/clients/typescript/v1/models/CSINodeInfo.ts index 4f6bf124..8a9fa5ce 100644 --- a/clients/typescript/v1/models/CSINodeInfo.ts +++ b/clients/typescript/v1/models/CSINodeInfo.ts @@ -71,7 +71,7 @@ export class CSINodeInfo { static getAttributeTypeMap() { return CSINodeInfo.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/CSIPlugin.ts b/clients/typescript/v1/models/CSIPlugin.ts index 0b8b921d..4f9b729b 100644 --- a/clients/typescript/v1/models/CSIPlugin.ts +++ b/clients/typescript/v1/models/CSIPlugin.ts @@ -114,7 +114,7 @@ export class CSIPlugin { static getAttributeTypeMap() { return CSIPlugin.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/CSIPluginListStub.ts b/clients/typescript/v1/models/CSIPluginListStub.ts index 3ee3bdcb..170d17bf 100644 --- a/clients/typescript/v1/models/CSIPluginListStub.ts +++ b/clients/typescript/v1/models/CSIPluginListStub.ts @@ -84,7 +84,7 @@ export class CSIPluginListStub { static getAttributeTypeMap() { return CSIPluginListStub.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/CSISnapshot.ts b/clients/typescript/v1/models/CSISnapshot.ts index fef531ee..86978b11 100644 --- a/clients/typescript/v1/models/CSISnapshot.ts +++ b/clients/typescript/v1/models/CSISnapshot.ts @@ -91,7 +91,7 @@ export class CSISnapshot { static getAttributeTypeMap() { return CSISnapshot.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/CSISnapshotCreateRequest.ts b/clients/typescript/v1/models/CSISnapshotCreateRequest.ts index 80d96d34..10087c1a 100644 --- a/clients/typescript/v1/models/CSISnapshotCreateRequest.ts +++ b/clients/typescript/v1/models/CSISnapshotCreateRequest.ts @@ -50,7 +50,7 @@ export class CSISnapshotCreateRequest { static getAttributeTypeMap() { return CSISnapshotCreateRequest.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/CSISnapshotCreateResponse.ts b/clients/typescript/v1/models/CSISnapshotCreateResponse.ts index 83dd80e9..e918822f 100644 --- a/clients/typescript/v1/models/CSISnapshotCreateResponse.ts +++ b/clients/typescript/v1/models/CSISnapshotCreateResponse.ts @@ -64,7 +64,7 @@ export class CSISnapshotCreateResponse { static getAttributeTypeMap() { return CSISnapshotCreateResponse.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/CSISnapshotListResponse.ts b/clients/typescript/v1/models/CSISnapshotListResponse.ts index e8675109..ccd9ec9c 100644 --- a/clients/typescript/v1/models/CSISnapshotListResponse.ts +++ b/clients/typescript/v1/models/CSISnapshotListResponse.ts @@ -64,7 +64,7 @@ export class CSISnapshotListResponse { static getAttributeTypeMap() { return CSISnapshotListResponse.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/CSITopology.ts b/clients/typescript/v1/models/CSITopology.ts index 423a2724..ca45508d 100644 --- a/clients/typescript/v1/models/CSITopology.ts +++ b/clients/typescript/v1/models/CSITopology.ts @@ -28,7 +28,7 @@ export class CSITopology { static getAttributeTypeMap() { return CSITopology.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/CSITopologyRequest.ts b/clients/typescript/v1/models/CSITopologyRequest.ts index 17aea148..56b33454 100644 --- a/clients/typescript/v1/models/CSITopologyRequest.ts +++ b/clients/typescript/v1/models/CSITopologyRequest.ts @@ -36,7 +36,7 @@ export class CSITopologyRequest { static getAttributeTypeMap() { return CSITopologyRequest.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/CSIVolume.ts b/clients/typescript/v1/models/CSIVolume.ts index dfdc38eb..4e218797 100644 --- a/clients/typescript/v1/models/CSIVolume.ts +++ b/clients/typescript/v1/models/CSIVolume.ts @@ -258,7 +258,7 @@ export class CSIVolume { static getAttributeTypeMap() { return CSIVolume.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/CSIVolumeCapability.ts b/clients/typescript/v1/models/CSIVolumeCapability.ts index ad61fc34..77540f11 100644 --- a/clients/typescript/v1/models/CSIVolumeCapability.ts +++ b/clients/typescript/v1/models/CSIVolumeCapability.ts @@ -35,7 +35,7 @@ export class CSIVolumeCapability { static getAttributeTypeMap() { return CSIVolumeCapability.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/CSIVolumeCreateRequest.ts b/clients/typescript/v1/models/CSIVolumeCreateRequest.ts index 10916ca3..3e86480f 100644 --- a/clients/typescript/v1/models/CSIVolumeCreateRequest.ts +++ b/clients/typescript/v1/models/CSIVolumeCreateRequest.ts @@ -50,7 +50,7 @@ export class CSIVolumeCreateRequest { static getAttributeTypeMap() { return CSIVolumeCreateRequest.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/CSIVolumeExternalStub.ts b/clients/typescript/v1/models/CSIVolumeExternalStub.ts index 312838fd..a2c27e46 100644 --- a/clients/typescript/v1/models/CSIVolumeExternalStub.ts +++ b/clients/typescript/v1/models/CSIVolumeExternalStub.ts @@ -77,7 +77,7 @@ export class CSIVolumeExternalStub { static getAttributeTypeMap() { return CSIVolumeExternalStub.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/CSIVolumeListExternalResponse.ts b/clients/typescript/v1/models/CSIVolumeListExternalResponse.ts index 95205ec2..f7e5d0e9 100644 --- a/clients/typescript/v1/models/CSIVolumeListExternalResponse.ts +++ b/clients/typescript/v1/models/CSIVolumeListExternalResponse.ts @@ -36,7 +36,7 @@ export class CSIVolumeListExternalResponse { static getAttributeTypeMap() { return CSIVolumeListExternalResponse.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/CSIVolumeListStub.ts b/clients/typescript/v1/models/CSIVolumeListStub.ts index a8d76d43..32c12ecd 100644 --- a/clients/typescript/v1/models/CSIVolumeListStub.ts +++ b/clients/typescript/v1/models/CSIVolumeListStub.ts @@ -148,7 +148,7 @@ export class CSIVolumeListStub { static getAttributeTypeMap() { return CSIVolumeListStub.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/CSIVolumeRegisterRequest.ts b/clients/typescript/v1/models/CSIVolumeRegisterRequest.ts index 6f49bf34..8a38af71 100644 --- a/clients/typescript/v1/models/CSIVolumeRegisterRequest.ts +++ b/clients/typescript/v1/models/CSIVolumeRegisterRequest.ts @@ -50,7 +50,7 @@ export class CSIVolumeRegisterRequest { static getAttributeTypeMap() { return CSIVolumeRegisterRequest.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/CheckRestart.ts b/clients/typescript/v1/models/CheckRestart.ts index 767043dc..aa8f6e11 100644 --- a/clients/typescript/v1/models/CheckRestart.ts +++ b/clients/typescript/v1/models/CheckRestart.ts @@ -42,7 +42,7 @@ export class CheckRestart { static getAttributeTypeMap() { return CheckRestart.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/Constraint.ts b/clients/typescript/v1/models/Constraint.ts index fd35226e..704af1d8 100644 --- a/clients/typescript/v1/models/Constraint.ts +++ b/clients/typescript/v1/models/Constraint.ts @@ -42,7 +42,7 @@ export class Constraint { static getAttributeTypeMap() { return Constraint.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/Consul.ts b/clients/typescript/v1/models/Consul.ts index c816da13..b1872cc7 100644 --- a/clients/typescript/v1/models/Consul.ts +++ b/clients/typescript/v1/models/Consul.ts @@ -28,7 +28,7 @@ export class Consul { static getAttributeTypeMap() { return Consul.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/ConsulConnect.ts b/clients/typescript/v1/models/ConsulConnect.ts index 333aac8d..11dfde94 100644 --- a/clients/typescript/v1/models/ConsulConnect.ts +++ b/clients/typescript/v1/models/ConsulConnect.ts @@ -52,7 +52,7 @@ export class ConsulConnect { static getAttributeTypeMap() { return ConsulConnect.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/ConsulExposeConfig.ts b/clients/typescript/v1/models/ConsulExposeConfig.ts index 86dafc16..46175758 100644 --- a/clients/typescript/v1/models/ConsulExposeConfig.ts +++ b/clients/typescript/v1/models/ConsulExposeConfig.ts @@ -29,7 +29,7 @@ export class ConsulExposeConfig { static getAttributeTypeMap() { return ConsulExposeConfig.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/ConsulExposePath.ts b/clients/typescript/v1/models/ConsulExposePath.ts index dbad5c1d..dcbdb751 100644 --- a/clients/typescript/v1/models/ConsulExposePath.ts +++ b/clients/typescript/v1/models/ConsulExposePath.ts @@ -49,7 +49,7 @@ export class ConsulExposePath { static getAttributeTypeMap() { return ConsulExposePath.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/ConsulGateway.ts b/clients/typescript/v1/models/ConsulGateway.ts index 0c431013..2bb7b22d 100644 --- a/clients/typescript/v1/models/ConsulGateway.ts +++ b/clients/typescript/v1/models/ConsulGateway.ts @@ -10,7 +10,6 @@ * Do not edit the class manually. */ -import { AnyType } from './AnyType'; import { ConsulGatewayProxy } from './ConsulGatewayProxy'; import { ConsulIngressConfigEntry } from './ConsulIngressConfigEntry'; import { ConsulTerminatingConfigEntry } from './ConsulTerminatingConfigEntry'; @@ -18,7 +17,7 @@ import { HttpFile } from '../http/http'; export class ConsulGateway { 'ingress'?: ConsulIngressConfigEntry; - 'mesh'?: AnyType; + 'mesh'?: any; 'proxy'?: ConsulGatewayProxy; 'terminating'?: ConsulTerminatingConfigEntry; @@ -34,7 +33,7 @@ export class ConsulGateway { { "name": "mesh", "baseName": "Mesh", - "type": "AnyType", + "type": "any", "format": "" }, { @@ -53,7 +52,7 @@ export class ConsulGateway { static getAttributeTypeMap() { return ConsulGateway.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/ConsulGatewayBindAddress.ts b/clients/typescript/v1/models/ConsulGatewayBindAddress.ts index 01217ce7..444383e1 100644 --- a/clients/typescript/v1/models/ConsulGatewayBindAddress.ts +++ b/clients/typescript/v1/models/ConsulGatewayBindAddress.ts @@ -42,7 +42,7 @@ export class ConsulGatewayBindAddress { static getAttributeTypeMap() { return ConsulGatewayBindAddress.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/ConsulGatewayProxy.ts b/clients/typescript/v1/models/ConsulGatewayProxy.ts index 53e6cab7..db1b508a 100644 --- a/clients/typescript/v1/models/ConsulGatewayProxy.ts +++ b/clients/typescript/v1/models/ConsulGatewayProxy.ts @@ -10,12 +10,11 @@ * Do not edit the class manually. */ -import { AnyType } from './AnyType'; import { ConsulGatewayBindAddress } from './ConsulGatewayBindAddress'; import { HttpFile } from '../http/http'; export class ConsulGatewayProxy { - 'config'?: { [key: string]: AnyType; }; + 'config'?: { [key: string]: any; }; 'connectTimeout'?: number; 'envoyDNSDiscoveryType'?: string; 'envoyGatewayBindAddresses'?: { [key: string]: ConsulGatewayBindAddress; }; @@ -28,7 +27,7 @@ export class ConsulGatewayProxy { { "name": "config", "baseName": "Config", - "type": "{ [key: string]: AnyType; }", + "type": "{ [key: string]: any; }", "format": "" }, { @@ -65,7 +64,7 @@ export class ConsulGatewayProxy { static getAttributeTypeMap() { return ConsulGatewayProxy.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/ConsulGatewayTLSConfig.ts b/clients/typescript/v1/models/ConsulGatewayTLSConfig.ts index 94d02bee..193aae53 100644 --- a/clients/typescript/v1/models/ConsulGatewayTLSConfig.ts +++ b/clients/typescript/v1/models/ConsulGatewayTLSConfig.ts @@ -49,7 +49,7 @@ export class ConsulGatewayTLSConfig { static getAttributeTypeMap() { return ConsulGatewayTLSConfig.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/ConsulIngressConfigEntry.ts b/clients/typescript/v1/models/ConsulIngressConfigEntry.ts index 31b1c703..b327711b 100644 --- a/clients/typescript/v1/models/ConsulIngressConfigEntry.ts +++ b/clients/typescript/v1/models/ConsulIngressConfigEntry.ts @@ -37,7 +37,7 @@ export class ConsulIngressConfigEntry { static getAttributeTypeMap() { return ConsulIngressConfigEntry.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/ConsulIngressListener.ts b/clients/typescript/v1/models/ConsulIngressListener.ts index 7c64ddc6..db3c8de8 100644 --- a/clients/typescript/v1/models/ConsulIngressListener.ts +++ b/clients/typescript/v1/models/ConsulIngressListener.ts @@ -43,7 +43,7 @@ export class ConsulIngressListener { static getAttributeTypeMap() { return ConsulIngressListener.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/ConsulIngressService.ts b/clients/typescript/v1/models/ConsulIngressService.ts index a6ae7606..d352e423 100644 --- a/clients/typescript/v1/models/ConsulIngressService.ts +++ b/clients/typescript/v1/models/ConsulIngressService.ts @@ -35,7 +35,7 @@ export class ConsulIngressService { static getAttributeTypeMap() { return ConsulIngressService.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/ConsulLinkedService.ts b/clients/typescript/v1/models/ConsulLinkedService.ts index f088bdad..f889383b 100644 --- a/clients/typescript/v1/models/ConsulLinkedService.ts +++ b/clients/typescript/v1/models/ConsulLinkedService.ts @@ -56,7 +56,7 @@ export class ConsulLinkedService { static getAttributeTypeMap() { return ConsulLinkedService.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/ConsulMeshGateway.ts b/clients/typescript/v1/models/ConsulMeshGateway.ts index facdbf99..d14d492e 100644 --- a/clients/typescript/v1/models/ConsulMeshGateway.ts +++ b/clients/typescript/v1/models/ConsulMeshGateway.ts @@ -28,7 +28,7 @@ export class ConsulMeshGateway { static getAttributeTypeMap() { return ConsulMeshGateway.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/ConsulProxy.ts b/clients/typescript/v1/models/ConsulProxy.ts index 49e4310c..cf136ad9 100644 --- a/clients/typescript/v1/models/ConsulProxy.ts +++ b/clients/typescript/v1/models/ConsulProxy.ts @@ -10,13 +10,12 @@ * Do not edit the class manually. */ -import { AnyType } from './AnyType'; import { ConsulExposeConfig } from './ConsulExposeConfig'; import { ConsulUpstream } from './ConsulUpstream'; import { HttpFile } from '../http/http'; export class ConsulProxy { - 'config'?: { [key: string]: AnyType; }; + 'config'?: { [key: string]: any; }; 'exposeConfig'?: ConsulExposeConfig; 'localServiceAddress'?: string; 'localServicePort'?: number; @@ -28,7 +27,7 @@ export class ConsulProxy { { "name": "config", "baseName": "Config", - "type": "{ [key: string]: AnyType; }", + "type": "{ [key: string]: any; }", "format": "" }, { @@ -59,7 +58,7 @@ export class ConsulProxy { static getAttributeTypeMap() { return ConsulProxy.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/ConsulSidecarService.ts b/clients/typescript/v1/models/ConsulSidecarService.ts index e0a1802b..24fdcc16 100644 --- a/clients/typescript/v1/models/ConsulSidecarService.ts +++ b/clients/typescript/v1/models/ConsulSidecarService.ts @@ -50,7 +50,7 @@ export class ConsulSidecarService { static getAttributeTypeMap() { return ConsulSidecarService.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/ConsulTerminatingConfigEntry.ts b/clients/typescript/v1/models/ConsulTerminatingConfigEntry.ts index ec061810..3308441e 100644 --- a/clients/typescript/v1/models/ConsulTerminatingConfigEntry.ts +++ b/clients/typescript/v1/models/ConsulTerminatingConfigEntry.ts @@ -29,7 +29,7 @@ export class ConsulTerminatingConfigEntry { static getAttributeTypeMap() { return ConsulTerminatingConfigEntry.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/ConsulUpstream.ts b/clients/typescript/v1/models/ConsulUpstream.ts index 7e508f42..e49da5c1 100644 --- a/clients/typescript/v1/models/ConsulUpstream.ts +++ b/clients/typescript/v1/models/ConsulUpstream.ts @@ -64,7 +64,7 @@ export class ConsulUpstream { static getAttributeTypeMap() { return ConsulUpstream.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/DNSConfig.ts b/clients/typescript/v1/models/DNSConfig.ts index 1c0eaafb..f4071daf 100644 --- a/clients/typescript/v1/models/DNSConfig.ts +++ b/clients/typescript/v1/models/DNSConfig.ts @@ -42,7 +42,7 @@ export class DNSConfig { static getAttributeTypeMap() { return DNSConfig.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/Deployment.ts b/clients/typescript/v1/models/Deployment.ts index 0fe0c33f..45835cc8 100644 --- a/clients/typescript/v1/models/Deployment.ts +++ b/clients/typescript/v1/models/Deployment.ts @@ -113,7 +113,7 @@ export class Deployment { static getAttributeTypeMap() { return Deployment.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/DeploymentAllocHealthRequest.ts b/clients/typescript/v1/models/DeploymentAllocHealthRequest.ts index 6dc31630..4c3fbd3d 100644 --- a/clients/typescript/v1/models/DeploymentAllocHealthRequest.ts +++ b/clients/typescript/v1/models/DeploymentAllocHealthRequest.ts @@ -63,7 +63,7 @@ export class DeploymentAllocHealthRequest { static getAttributeTypeMap() { return DeploymentAllocHealthRequest.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/DeploymentPauseRequest.ts b/clients/typescript/v1/models/DeploymentPauseRequest.ts index 6ca0209b..0a5339bd 100644 --- a/clients/typescript/v1/models/DeploymentPauseRequest.ts +++ b/clients/typescript/v1/models/DeploymentPauseRequest.ts @@ -56,7 +56,7 @@ export class DeploymentPauseRequest { static getAttributeTypeMap() { return DeploymentPauseRequest.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/DeploymentPromoteRequest.ts b/clients/typescript/v1/models/DeploymentPromoteRequest.ts index cde5304d..3c96d971 100644 --- a/clients/typescript/v1/models/DeploymentPromoteRequest.ts +++ b/clients/typescript/v1/models/DeploymentPromoteRequest.ts @@ -63,7 +63,7 @@ export class DeploymentPromoteRequest { static getAttributeTypeMap() { return DeploymentPromoteRequest.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/DeploymentState.ts b/clients/typescript/v1/models/DeploymentState.ts index 2aef1984..9df89f99 100644 --- a/clients/typescript/v1/models/DeploymentState.ts +++ b/clients/typescript/v1/models/DeploymentState.ts @@ -91,7 +91,7 @@ export class DeploymentState { static getAttributeTypeMap() { return DeploymentState.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/DeploymentUnblockRequest.ts b/clients/typescript/v1/models/DeploymentUnblockRequest.ts index f99f02e1..3c57b804 100644 --- a/clients/typescript/v1/models/DeploymentUnblockRequest.ts +++ b/clients/typescript/v1/models/DeploymentUnblockRequest.ts @@ -49,7 +49,7 @@ export class DeploymentUnblockRequest { static getAttributeTypeMap() { return DeploymentUnblockRequest.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/DeploymentUpdateResponse.ts b/clients/typescript/v1/models/DeploymentUpdateResponse.ts index 4f7ee6d4..63361f83 100644 --- a/clients/typescript/v1/models/DeploymentUpdateResponse.ts +++ b/clients/typescript/v1/models/DeploymentUpdateResponse.ts @@ -63,7 +63,7 @@ export class DeploymentUpdateResponse { static getAttributeTypeMap() { return DeploymentUpdateResponse.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/DesiredTransition.ts b/clients/typescript/v1/models/DesiredTransition.ts index 690e9349..b1fae254 100644 --- a/clients/typescript/v1/models/DesiredTransition.ts +++ b/clients/typescript/v1/models/DesiredTransition.ts @@ -35,7 +35,7 @@ export class DesiredTransition { static getAttributeTypeMap() { return DesiredTransition.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/DesiredUpdates.ts b/clients/typescript/v1/models/DesiredUpdates.ts index dc45328e..e9f25a81 100644 --- a/clients/typescript/v1/models/DesiredUpdates.ts +++ b/clients/typescript/v1/models/DesiredUpdates.ts @@ -77,7 +77,7 @@ export class DesiredUpdates { static getAttributeTypeMap() { return DesiredUpdates.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/DispatchPayloadConfig.ts b/clients/typescript/v1/models/DispatchPayloadConfig.ts index f723515f..0051ae2b 100644 --- a/clients/typescript/v1/models/DispatchPayloadConfig.ts +++ b/clients/typescript/v1/models/DispatchPayloadConfig.ts @@ -28,7 +28,7 @@ export class DispatchPayloadConfig { static getAttributeTypeMap() { return DispatchPayloadConfig.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/DrainMetadata.ts b/clients/typescript/v1/models/DrainMetadata.ts index 7a4f44ed..20dc6aa5 100644 --- a/clients/typescript/v1/models/DrainMetadata.ts +++ b/clients/typescript/v1/models/DrainMetadata.ts @@ -56,7 +56,7 @@ export class DrainMetadata { static getAttributeTypeMap() { return DrainMetadata.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/DrainSpec.ts b/clients/typescript/v1/models/DrainSpec.ts index 1c6ffb07..80836881 100644 --- a/clients/typescript/v1/models/DrainSpec.ts +++ b/clients/typescript/v1/models/DrainSpec.ts @@ -35,7 +35,7 @@ export class DrainSpec { static getAttributeTypeMap() { return DrainSpec.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/DrainStrategy.ts b/clients/typescript/v1/models/DrainStrategy.ts index 3bd0b96f..38c92504 100644 --- a/clients/typescript/v1/models/DrainStrategy.ts +++ b/clients/typescript/v1/models/DrainStrategy.ts @@ -49,7 +49,7 @@ export class DrainStrategy { static getAttributeTypeMap() { return DrainStrategy.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/DriverInfo.ts b/clients/typescript/v1/models/DriverInfo.ts index 729e328b..3475209b 100644 --- a/clients/typescript/v1/models/DriverInfo.ts +++ b/clients/typescript/v1/models/DriverInfo.ts @@ -56,7 +56,7 @@ export class DriverInfo { static getAttributeTypeMap() { return DriverInfo.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/EphemeralDisk.ts b/clients/typescript/v1/models/EphemeralDisk.ts index 47dd8dc5..93000ed3 100644 --- a/clients/typescript/v1/models/EphemeralDisk.ts +++ b/clients/typescript/v1/models/EphemeralDisk.ts @@ -42,7 +42,7 @@ export class EphemeralDisk { static getAttributeTypeMap() { return EphemeralDisk.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/EvalOptions.ts b/clients/typescript/v1/models/EvalOptions.ts index 570b13b3..824a4be9 100644 --- a/clients/typescript/v1/models/EvalOptions.ts +++ b/clients/typescript/v1/models/EvalOptions.ts @@ -28,7 +28,7 @@ export class EvalOptions { static getAttributeTypeMap() { return EvalOptions.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/Evaluation.ts b/clients/typescript/v1/models/Evaluation.ts index 3dd42f12..143f5495 100644 --- a/clients/typescript/v1/models/Evaluation.ts +++ b/clients/typescript/v1/models/Evaluation.ts @@ -226,7 +226,7 @@ export class Evaluation { static getAttributeTypeMap() { return Evaluation.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/EvaluationStub.ts b/clients/typescript/v1/models/EvaluationStub.ts index 405c24a8..29840537 100644 --- a/clients/typescript/v1/models/EvaluationStub.ts +++ b/clients/typescript/v1/models/EvaluationStub.ts @@ -147,7 +147,7 @@ export class EvaluationStub { static getAttributeTypeMap() { return EvaluationStub.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/FieldDiff.ts b/clients/typescript/v1/models/FieldDiff.ts index 5e40c9b0..d5f51e73 100644 --- a/clients/typescript/v1/models/FieldDiff.ts +++ b/clients/typescript/v1/models/FieldDiff.ts @@ -56,7 +56,7 @@ export class FieldDiff { static getAttributeTypeMap() { return FieldDiff.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/FuzzyMatch.ts b/clients/typescript/v1/models/FuzzyMatch.ts index 83a16004..cc876b0c 100644 --- a/clients/typescript/v1/models/FuzzyMatch.ts +++ b/clients/typescript/v1/models/FuzzyMatch.ts @@ -35,7 +35,7 @@ export class FuzzyMatch { static getAttributeTypeMap() { return FuzzyMatch.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/FuzzySearchRequest.ts b/clients/typescript/v1/models/FuzzySearchRequest.ts index 3c1bdba8..960774b9 100644 --- a/clients/typescript/v1/models/FuzzySearchRequest.ts +++ b/clients/typescript/v1/models/FuzzySearchRequest.ts @@ -126,7 +126,7 @@ export class FuzzySearchRequest { static getAttributeTypeMap() { return FuzzySearchRequest.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/FuzzySearchResponse.ts b/clients/typescript/v1/models/FuzzySearchResponse.ts index 73753399..c4febecf 100644 --- a/clients/typescript/v1/models/FuzzySearchResponse.ts +++ b/clients/typescript/v1/models/FuzzySearchResponse.ts @@ -71,7 +71,7 @@ export class FuzzySearchResponse { static getAttributeTypeMap() { return FuzzySearchResponse.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/GaugeValue.ts b/clients/typescript/v1/models/GaugeValue.ts index 957a2b26..be32ff05 100644 --- a/clients/typescript/v1/models/GaugeValue.ts +++ b/clients/typescript/v1/models/GaugeValue.ts @@ -42,7 +42,7 @@ export class GaugeValue { static getAttributeTypeMap() { return GaugeValue.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/HostNetworkInfo.ts b/clients/typescript/v1/models/HostNetworkInfo.ts index 6ffbb4c6..f11afe92 100644 --- a/clients/typescript/v1/models/HostNetworkInfo.ts +++ b/clients/typescript/v1/models/HostNetworkInfo.ts @@ -49,7 +49,7 @@ export class HostNetworkInfo { static getAttributeTypeMap() { return HostNetworkInfo.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/HostVolumeInfo.ts b/clients/typescript/v1/models/HostVolumeInfo.ts index bd012bcb..12757988 100644 --- a/clients/typescript/v1/models/HostVolumeInfo.ts +++ b/clients/typescript/v1/models/HostVolumeInfo.ts @@ -35,7 +35,7 @@ export class HostVolumeInfo { static getAttributeTypeMap() { return HostVolumeInfo.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/Job.ts b/clients/typescript/v1/models/Job.ts index 09b1a6b7..27250ff0 100644 --- a/clients/typescript/v1/models/Job.ts +++ b/clients/typescript/v1/models/Job.ts @@ -290,7 +290,7 @@ export class Job { static getAttributeTypeMap() { return Job.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/JobChildrenSummary.ts b/clients/typescript/v1/models/JobChildrenSummary.ts index c7f80cf5..9dc8415d 100644 --- a/clients/typescript/v1/models/JobChildrenSummary.ts +++ b/clients/typescript/v1/models/JobChildrenSummary.ts @@ -42,7 +42,7 @@ export class JobChildrenSummary { static getAttributeTypeMap() { return JobChildrenSummary.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/JobDeregisterResponse.ts b/clients/typescript/v1/models/JobDeregisterResponse.ts index d8dc2b2c..92b42cc5 100644 --- a/clients/typescript/v1/models/JobDeregisterResponse.ts +++ b/clients/typescript/v1/models/JobDeregisterResponse.ts @@ -77,7 +77,7 @@ export class JobDeregisterResponse { static getAttributeTypeMap() { return JobDeregisterResponse.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/JobDiff.ts b/clients/typescript/v1/models/JobDiff.ts index bcdea379..cbb3c157 100644 --- a/clients/typescript/v1/models/JobDiff.ts +++ b/clients/typescript/v1/models/JobDiff.ts @@ -59,7 +59,7 @@ export class JobDiff { static getAttributeTypeMap() { return JobDiff.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/JobDispatchRequest.ts b/clients/typescript/v1/models/JobDispatchRequest.ts index f05f8001..1a957ed0 100644 --- a/clients/typescript/v1/models/JobDispatchRequest.ts +++ b/clients/typescript/v1/models/JobDispatchRequest.ts @@ -42,7 +42,7 @@ export class JobDispatchRequest { static getAttributeTypeMap() { return JobDispatchRequest.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/JobDispatchResponse.ts b/clients/typescript/v1/models/JobDispatchResponse.ts index 4b47f271..9e4851de 100644 --- a/clients/typescript/v1/models/JobDispatchResponse.ts +++ b/clients/typescript/v1/models/JobDispatchResponse.ts @@ -63,7 +63,7 @@ export class JobDispatchResponse { static getAttributeTypeMap() { return JobDispatchResponse.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/JobEvaluateRequest.ts b/clients/typescript/v1/models/JobEvaluateRequest.ts index 300efc56..eb00ffe1 100644 --- a/clients/typescript/v1/models/JobEvaluateRequest.ts +++ b/clients/typescript/v1/models/JobEvaluateRequest.ts @@ -57,7 +57,7 @@ export class JobEvaluateRequest { static getAttributeTypeMap() { return JobEvaluateRequest.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/JobListStub.ts b/clients/typescript/v1/models/JobListStub.ts index e3c398db..6c229479 100644 --- a/clients/typescript/v1/models/JobListStub.ts +++ b/clients/typescript/v1/models/JobListStub.ts @@ -141,7 +141,7 @@ export class JobListStub { static getAttributeTypeMap() { return JobListStub.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/JobPlanRequest.ts b/clients/typescript/v1/models/JobPlanRequest.ts index cbe25753..7902dab1 100644 --- a/clients/typescript/v1/models/JobPlanRequest.ts +++ b/clients/typescript/v1/models/JobPlanRequest.ts @@ -64,7 +64,7 @@ export class JobPlanRequest { static getAttributeTypeMap() { return JobPlanRequest.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/JobPlanResponse.ts b/clients/typescript/v1/models/JobPlanResponse.ts index a9ac0192..f8c431b0 100644 --- a/clients/typescript/v1/models/JobPlanResponse.ts +++ b/clients/typescript/v1/models/JobPlanResponse.ts @@ -74,7 +74,7 @@ export class JobPlanResponse { static getAttributeTypeMap() { return JobPlanResponse.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/JobRegisterRequest.ts b/clients/typescript/v1/models/JobRegisterRequest.ts index e3faa5fa..75a612fa 100644 --- a/clients/typescript/v1/models/JobRegisterRequest.ts +++ b/clients/typescript/v1/models/JobRegisterRequest.ts @@ -85,7 +85,7 @@ export class JobRegisterRequest { static getAttributeTypeMap() { return JobRegisterRequest.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/JobRegisterResponse.ts b/clients/typescript/v1/models/JobRegisterResponse.ts index f09f9740..2d1b1cc8 100644 --- a/clients/typescript/v1/models/JobRegisterResponse.ts +++ b/clients/typescript/v1/models/JobRegisterResponse.ts @@ -84,7 +84,7 @@ export class JobRegisterResponse { static getAttributeTypeMap() { return JobRegisterResponse.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/JobRevertRequest.ts b/clients/typescript/v1/models/JobRevertRequest.ts index a103c776..71c2b40d 100644 --- a/clients/typescript/v1/models/JobRevertRequest.ts +++ b/clients/typescript/v1/models/JobRevertRequest.ts @@ -77,7 +77,7 @@ export class JobRevertRequest { static getAttributeTypeMap() { return JobRevertRequest.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/JobScaleStatusResponse.ts b/clients/typescript/v1/models/JobScaleStatusResponse.ts index 123a70a4..6a97866c 100644 --- a/clients/typescript/v1/models/JobScaleStatusResponse.ts +++ b/clients/typescript/v1/models/JobScaleStatusResponse.ts @@ -64,7 +64,7 @@ export class JobScaleStatusResponse { static getAttributeTypeMap() { return JobScaleStatusResponse.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/JobStabilityRequest.ts b/clients/typescript/v1/models/JobStabilityRequest.ts index c1445362..93dc7033 100644 --- a/clients/typescript/v1/models/JobStabilityRequest.ts +++ b/clients/typescript/v1/models/JobStabilityRequest.ts @@ -63,7 +63,7 @@ export class JobStabilityRequest { static getAttributeTypeMap() { return JobStabilityRequest.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/JobStabilityResponse.ts b/clients/typescript/v1/models/JobStabilityResponse.ts index efc2473c..1112efef 100644 --- a/clients/typescript/v1/models/JobStabilityResponse.ts +++ b/clients/typescript/v1/models/JobStabilityResponse.ts @@ -28,7 +28,7 @@ export class JobStabilityResponse { static getAttributeTypeMap() { return JobStabilityResponse.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/JobSummary.ts b/clients/typescript/v1/models/JobSummary.ts index 88a7a2e0..a5d63df6 100644 --- a/clients/typescript/v1/models/JobSummary.ts +++ b/clients/typescript/v1/models/JobSummary.ts @@ -65,7 +65,7 @@ export class JobSummary { static getAttributeTypeMap() { return JobSummary.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/JobValidateRequest.ts b/clients/typescript/v1/models/JobValidateRequest.ts index ee98ecb3..542238b0 100644 --- a/clients/typescript/v1/models/JobValidateRequest.ts +++ b/clients/typescript/v1/models/JobValidateRequest.ts @@ -50,7 +50,7 @@ export class JobValidateRequest { static getAttributeTypeMap() { return JobValidateRequest.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/JobValidateResponse.ts b/clients/typescript/v1/models/JobValidateResponse.ts index 0e20dfc2..a84e0f91 100644 --- a/clients/typescript/v1/models/JobValidateResponse.ts +++ b/clients/typescript/v1/models/JobValidateResponse.ts @@ -49,7 +49,7 @@ export class JobValidateResponse { static getAttributeTypeMap() { return JobValidateResponse.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/JobVersionsResponse.ts b/clients/typescript/v1/models/JobVersionsResponse.ts index c016b94c..21462662 100644 --- a/clients/typescript/v1/models/JobVersionsResponse.ts +++ b/clients/typescript/v1/models/JobVersionsResponse.ts @@ -72,7 +72,7 @@ export class JobVersionsResponse { static getAttributeTypeMap() { return JobVersionsResponse.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/JobsParseRequest.ts b/clients/typescript/v1/models/JobsParseRequest.ts index c805340d..b02238cf 100644 --- a/clients/typescript/v1/models/JobsParseRequest.ts +++ b/clients/typescript/v1/models/JobsParseRequest.ts @@ -42,7 +42,7 @@ export class JobsParseRequest { static getAttributeTypeMap() { return JobsParseRequest.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/LogConfig.ts b/clients/typescript/v1/models/LogConfig.ts index e81e7857..a63cea94 100644 --- a/clients/typescript/v1/models/LogConfig.ts +++ b/clients/typescript/v1/models/LogConfig.ts @@ -35,7 +35,7 @@ export class LogConfig { static getAttributeTypeMap() { return LogConfig.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/MetricsSummary.ts b/clients/typescript/v1/models/MetricsSummary.ts index 169bf2d6..729ab9ea 100644 --- a/clients/typescript/v1/models/MetricsSummary.ts +++ b/clients/typescript/v1/models/MetricsSummary.ts @@ -59,7 +59,7 @@ export class MetricsSummary { static getAttributeTypeMap() { return MetricsSummary.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/MigrateStrategy.ts b/clients/typescript/v1/models/MigrateStrategy.ts index 950e2aa5..b1b18dc9 100644 --- a/clients/typescript/v1/models/MigrateStrategy.ts +++ b/clients/typescript/v1/models/MigrateStrategy.ts @@ -49,7 +49,7 @@ export class MigrateStrategy { static getAttributeTypeMap() { return MigrateStrategy.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/Multiregion.ts b/clients/typescript/v1/models/Multiregion.ts index 57471674..df6b8f2e 100644 --- a/clients/typescript/v1/models/Multiregion.ts +++ b/clients/typescript/v1/models/Multiregion.ts @@ -37,7 +37,7 @@ export class Multiregion { static getAttributeTypeMap() { return Multiregion.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/MultiregionRegion.ts b/clients/typescript/v1/models/MultiregionRegion.ts index c94fa715..7d715d93 100644 --- a/clients/typescript/v1/models/MultiregionRegion.ts +++ b/clients/typescript/v1/models/MultiregionRegion.ts @@ -49,7 +49,7 @@ export class MultiregionRegion { static getAttributeTypeMap() { return MultiregionRegion.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/MultiregionStrategy.ts b/clients/typescript/v1/models/MultiregionStrategy.ts index 6bba5f66..b28b53e3 100644 --- a/clients/typescript/v1/models/MultiregionStrategy.ts +++ b/clients/typescript/v1/models/MultiregionStrategy.ts @@ -35,7 +35,7 @@ export class MultiregionStrategy { static getAttributeTypeMap() { return MultiregionStrategy.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/Namespace.ts b/clients/typescript/v1/models/Namespace.ts index dbd1ea7d..5bd40388 100644 --- a/clients/typescript/v1/models/Namespace.ts +++ b/clients/typescript/v1/models/Namespace.ts @@ -71,7 +71,7 @@ export class Namespace { static getAttributeTypeMap() { return Namespace.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/NamespaceCapabilities.ts b/clients/typescript/v1/models/NamespaceCapabilities.ts index d26063cb..0c949c03 100644 --- a/clients/typescript/v1/models/NamespaceCapabilities.ts +++ b/clients/typescript/v1/models/NamespaceCapabilities.ts @@ -35,7 +35,7 @@ export class NamespaceCapabilities { static getAttributeTypeMap() { return NamespaceCapabilities.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/NetworkResource.ts b/clients/typescript/v1/models/NetworkResource.ts index 3c3636eb..37a425e2 100644 --- a/clients/typescript/v1/models/NetworkResource.ts +++ b/clients/typescript/v1/models/NetworkResource.ts @@ -86,7 +86,7 @@ export class NetworkResource { static getAttributeTypeMap() { return NetworkResource.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/Node.ts b/clients/typescript/v1/models/Node.ts index 7160a096..43872c21 100644 --- a/clients/typescript/v1/models/Node.ts +++ b/clients/typescript/v1/models/Node.ts @@ -234,7 +234,7 @@ export class Node { static getAttributeTypeMap() { return Node.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/NodeCpuResources.ts b/clients/typescript/v1/models/NodeCpuResources.ts index 28426632..7c6a5c7d 100644 --- a/clients/typescript/v1/models/NodeCpuResources.ts +++ b/clients/typescript/v1/models/NodeCpuResources.ts @@ -42,7 +42,7 @@ export class NodeCpuResources { static getAttributeTypeMap() { return NodeCpuResources.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/NodeDevice.ts b/clients/typescript/v1/models/NodeDevice.ts index cef864d5..71e425b6 100644 --- a/clients/typescript/v1/models/NodeDevice.ts +++ b/clients/typescript/v1/models/NodeDevice.ts @@ -50,7 +50,7 @@ export class NodeDevice { static getAttributeTypeMap() { return NodeDevice.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/NodeDeviceLocality.ts b/clients/typescript/v1/models/NodeDeviceLocality.ts index 49e41c85..01131749 100644 --- a/clients/typescript/v1/models/NodeDeviceLocality.ts +++ b/clients/typescript/v1/models/NodeDeviceLocality.ts @@ -28,7 +28,7 @@ export class NodeDeviceLocality { static getAttributeTypeMap() { return NodeDeviceLocality.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/NodeDeviceResource.ts b/clients/typescript/v1/models/NodeDeviceResource.ts index b800b7f9..1cc56b45 100644 --- a/clients/typescript/v1/models/NodeDeviceResource.ts +++ b/clients/typescript/v1/models/NodeDeviceResource.ts @@ -58,7 +58,7 @@ export class NodeDeviceResource { static getAttributeTypeMap() { return NodeDeviceResource.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/NodeDiskResources.ts b/clients/typescript/v1/models/NodeDiskResources.ts index 24c20ae5..848601c4 100644 --- a/clients/typescript/v1/models/NodeDiskResources.ts +++ b/clients/typescript/v1/models/NodeDiskResources.ts @@ -28,7 +28,7 @@ export class NodeDiskResources { static getAttributeTypeMap() { return NodeDiskResources.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/NodeDrainUpdateResponse.ts b/clients/typescript/v1/models/NodeDrainUpdateResponse.ts index b274e231..8aca66c2 100644 --- a/clients/typescript/v1/models/NodeDrainUpdateResponse.ts +++ b/clients/typescript/v1/models/NodeDrainUpdateResponse.ts @@ -56,7 +56,7 @@ export class NodeDrainUpdateResponse { static getAttributeTypeMap() { return NodeDrainUpdateResponse.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/NodeEligibilityUpdateResponse.ts b/clients/typescript/v1/models/NodeEligibilityUpdateResponse.ts index 55cefad3..8e5f9bdf 100644 --- a/clients/typescript/v1/models/NodeEligibilityUpdateResponse.ts +++ b/clients/typescript/v1/models/NodeEligibilityUpdateResponse.ts @@ -56,7 +56,7 @@ export class NodeEligibilityUpdateResponse { static getAttributeTypeMap() { return NodeEligibilityUpdateResponse.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/NodeEvent.ts b/clients/typescript/v1/models/NodeEvent.ts index 405de083..220f5611 100644 --- a/clients/typescript/v1/models/NodeEvent.ts +++ b/clients/typescript/v1/models/NodeEvent.ts @@ -56,7 +56,7 @@ export class NodeEvent { static getAttributeTypeMap() { return NodeEvent.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/NodeListStub.ts b/clients/typescript/v1/models/NodeListStub.ts index 03678c60..8d2f9b91 100644 --- a/clients/typescript/v1/models/NodeListStub.ts +++ b/clients/typescript/v1/models/NodeListStub.ts @@ -144,7 +144,7 @@ export class NodeListStub { static getAttributeTypeMap() { return NodeListStub.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/NodeMemoryResources.ts b/clients/typescript/v1/models/NodeMemoryResources.ts index fb17ea21..280d7585 100644 --- a/clients/typescript/v1/models/NodeMemoryResources.ts +++ b/clients/typescript/v1/models/NodeMemoryResources.ts @@ -28,7 +28,7 @@ export class NodeMemoryResources { static getAttributeTypeMap() { return NodeMemoryResources.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/NodePurgeResponse.ts b/clients/typescript/v1/models/NodePurgeResponse.ts index 8beb0652..0a796590 100644 --- a/clients/typescript/v1/models/NodePurgeResponse.ts +++ b/clients/typescript/v1/models/NodePurgeResponse.ts @@ -42,7 +42,7 @@ export class NodePurgeResponse { static getAttributeTypeMap() { return NodePurgeResponse.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/NodeReservedCpuResources.ts b/clients/typescript/v1/models/NodeReservedCpuResources.ts index a8b0c348..9a62a786 100644 --- a/clients/typescript/v1/models/NodeReservedCpuResources.ts +++ b/clients/typescript/v1/models/NodeReservedCpuResources.ts @@ -28,7 +28,7 @@ export class NodeReservedCpuResources { static getAttributeTypeMap() { return NodeReservedCpuResources.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/NodeReservedDiskResources.ts b/clients/typescript/v1/models/NodeReservedDiskResources.ts index 3b5bb895..b1d2289d 100644 --- a/clients/typescript/v1/models/NodeReservedDiskResources.ts +++ b/clients/typescript/v1/models/NodeReservedDiskResources.ts @@ -28,7 +28,7 @@ export class NodeReservedDiskResources { static getAttributeTypeMap() { return NodeReservedDiskResources.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/NodeReservedMemoryResources.ts b/clients/typescript/v1/models/NodeReservedMemoryResources.ts index 5880757a..0661c969 100644 --- a/clients/typescript/v1/models/NodeReservedMemoryResources.ts +++ b/clients/typescript/v1/models/NodeReservedMemoryResources.ts @@ -28,7 +28,7 @@ export class NodeReservedMemoryResources { static getAttributeTypeMap() { return NodeReservedMemoryResources.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/NodeReservedNetworkResources.ts b/clients/typescript/v1/models/NodeReservedNetworkResources.ts index f4ede554..2a858747 100644 --- a/clients/typescript/v1/models/NodeReservedNetworkResources.ts +++ b/clients/typescript/v1/models/NodeReservedNetworkResources.ts @@ -28,7 +28,7 @@ export class NodeReservedNetworkResources { static getAttributeTypeMap() { return NodeReservedNetworkResources.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/NodeReservedResources.ts b/clients/typescript/v1/models/NodeReservedResources.ts index 784638c7..429742c3 100644 --- a/clients/typescript/v1/models/NodeReservedResources.ts +++ b/clients/typescript/v1/models/NodeReservedResources.ts @@ -53,7 +53,7 @@ export class NodeReservedResources { static getAttributeTypeMap() { return NodeReservedResources.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/NodeResources.ts b/clients/typescript/v1/models/NodeResources.ts index 36d09598..bd4ac90c 100644 --- a/clients/typescript/v1/models/NodeResources.ts +++ b/clients/typescript/v1/models/NodeResources.ts @@ -75,7 +75,7 @@ export class NodeResources { static getAttributeTypeMap() { return NodeResources.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/NodeScoreMeta.ts b/clients/typescript/v1/models/NodeScoreMeta.ts index 489a4907..da1aac81 100644 --- a/clients/typescript/v1/models/NodeScoreMeta.ts +++ b/clients/typescript/v1/models/NodeScoreMeta.ts @@ -42,7 +42,7 @@ export class NodeScoreMeta { static getAttributeTypeMap() { return NodeScoreMeta.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/NodeUpdateDrainRequest.ts b/clients/typescript/v1/models/NodeUpdateDrainRequest.ts index da271ba7..62a200fa 100644 --- a/clients/typescript/v1/models/NodeUpdateDrainRequest.ts +++ b/clients/typescript/v1/models/NodeUpdateDrainRequest.ts @@ -50,7 +50,7 @@ export class NodeUpdateDrainRequest { static getAttributeTypeMap() { return NodeUpdateDrainRequest.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/NodeUpdateEligibilityRequest.ts b/clients/typescript/v1/models/NodeUpdateEligibilityRequest.ts index 6dce0d8c..456874f1 100644 --- a/clients/typescript/v1/models/NodeUpdateEligibilityRequest.ts +++ b/clients/typescript/v1/models/NodeUpdateEligibilityRequest.ts @@ -35,7 +35,7 @@ export class NodeUpdateEligibilityRequest { static getAttributeTypeMap() { return NodeUpdateEligibilityRequest.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/ObjectDiff.ts b/clients/typescript/v1/models/ObjectDiff.ts index 91f01b14..084597dc 100644 --- a/clients/typescript/v1/models/ObjectDiff.ts +++ b/clients/typescript/v1/models/ObjectDiff.ts @@ -50,7 +50,7 @@ export class ObjectDiff { static getAttributeTypeMap() { return ObjectDiff.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/ObjectSerializer.ts b/clients/typescript/v1/models/ObjectSerializer.ts index 2730b418..4565eabe 100644 --- a/clients/typescript/v1/models/ObjectSerializer.ts +++ b/clients/typescript/v1/models/ObjectSerializer.ts @@ -394,10 +394,11 @@ let primitives = [ const supportedMediaTypes: { [mediaType: string]: number } = { "application/json": Infinity, - "application/octet-stream": 0 + "application/octet-stream": 0, + "application/x-www-form-urlencoded": 0 } - + let enumsMap: Set = new Set([ ]); @@ -662,7 +663,7 @@ export class ObjectSerializer { if (!typeMap[type]) { // in case we dont know the type return data; } - + // Get the actual type of this object type = this.findCorrectType(data, type); diff --git a/clients/typescript/v1/models/OneTimeToken.ts b/clients/typescript/v1/models/OneTimeToken.ts index 72945f98..a06954b6 100644 --- a/clients/typescript/v1/models/OneTimeToken.ts +++ b/clients/typescript/v1/models/OneTimeToken.ts @@ -56,7 +56,7 @@ export class OneTimeToken { static getAttributeTypeMap() { return OneTimeToken.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/OneTimeTokenExchangeRequest.ts b/clients/typescript/v1/models/OneTimeTokenExchangeRequest.ts index 1f34b8d7..db50b13f 100644 --- a/clients/typescript/v1/models/OneTimeTokenExchangeRequest.ts +++ b/clients/typescript/v1/models/OneTimeTokenExchangeRequest.ts @@ -28,7 +28,7 @@ export class OneTimeTokenExchangeRequest { static getAttributeTypeMap() { return OneTimeTokenExchangeRequest.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/OperatorHealthReply.ts b/clients/typescript/v1/models/OperatorHealthReply.ts index 30b179a5..7293e086 100644 --- a/clients/typescript/v1/models/OperatorHealthReply.ts +++ b/clients/typescript/v1/models/OperatorHealthReply.ts @@ -43,7 +43,7 @@ export class OperatorHealthReply { static getAttributeTypeMap() { return OperatorHealthReply.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/ParameterizedJobConfig.ts b/clients/typescript/v1/models/ParameterizedJobConfig.ts index 7d6c59ac..b6c41e54 100644 --- a/clients/typescript/v1/models/ParameterizedJobConfig.ts +++ b/clients/typescript/v1/models/ParameterizedJobConfig.ts @@ -42,7 +42,7 @@ export class ParameterizedJobConfig { static getAttributeTypeMap() { return ParameterizedJobConfig.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/PeriodicConfig.ts b/clients/typescript/v1/models/PeriodicConfig.ts index 60adc0ca..df345346 100644 --- a/clients/typescript/v1/models/PeriodicConfig.ts +++ b/clients/typescript/v1/models/PeriodicConfig.ts @@ -56,7 +56,7 @@ export class PeriodicConfig { static getAttributeTypeMap() { return PeriodicConfig.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/PeriodicForceResponse.ts b/clients/typescript/v1/models/PeriodicForceResponse.ts index 09573b1a..e8bb9d00 100644 --- a/clients/typescript/v1/models/PeriodicForceResponse.ts +++ b/clients/typescript/v1/models/PeriodicForceResponse.ts @@ -42,7 +42,7 @@ export class PeriodicForceResponse { static getAttributeTypeMap() { return PeriodicForceResponse.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/PlanAnnotations.ts b/clients/typescript/v1/models/PlanAnnotations.ts index 2b92d761..056d8a17 100644 --- a/clients/typescript/v1/models/PlanAnnotations.ts +++ b/clients/typescript/v1/models/PlanAnnotations.ts @@ -37,7 +37,7 @@ export class PlanAnnotations { static getAttributeTypeMap() { return PlanAnnotations.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/PointValue.ts b/clients/typescript/v1/models/PointValue.ts index d756e2f3..bf824d8f 100644 --- a/clients/typescript/v1/models/PointValue.ts +++ b/clients/typescript/v1/models/PointValue.ts @@ -35,7 +35,7 @@ export class PointValue { static getAttributeTypeMap() { return PointValue.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/Port.ts b/clients/typescript/v1/models/Port.ts index 400d5164..96819f89 100644 --- a/clients/typescript/v1/models/Port.ts +++ b/clients/typescript/v1/models/Port.ts @@ -49,7 +49,7 @@ export class Port { static getAttributeTypeMap() { return Port.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/PortMapping.ts b/clients/typescript/v1/models/PortMapping.ts index 9eeb5422..8098ccaf 100644 --- a/clients/typescript/v1/models/PortMapping.ts +++ b/clients/typescript/v1/models/PortMapping.ts @@ -49,7 +49,7 @@ export class PortMapping { static getAttributeTypeMap() { return PortMapping.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/PreemptionConfig.ts b/clients/typescript/v1/models/PreemptionConfig.ts index a6e4fb7d..ecd16910 100644 --- a/clients/typescript/v1/models/PreemptionConfig.ts +++ b/clients/typescript/v1/models/PreemptionConfig.ts @@ -49,7 +49,7 @@ export class PreemptionConfig { static getAttributeTypeMap() { return PreemptionConfig.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/QuotaLimit.ts b/clients/typescript/v1/models/QuotaLimit.ts index de72d66c..1cdeaac9 100644 --- a/clients/typescript/v1/models/QuotaLimit.ts +++ b/clients/typescript/v1/models/QuotaLimit.ts @@ -43,7 +43,7 @@ export class QuotaLimit { static getAttributeTypeMap() { return QuotaLimit.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/QuotaSpec.ts b/clients/typescript/v1/models/QuotaSpec.ts index cdb14056..4efe2d81 100644 --- a/clients/typescript/v1/models/QuotaSpec.ts +++ b/clients/typescript/v1/models/QuotaSpec.ts @@ -57,7 +57,7 @@ export class QuotaSpec { static getAttributeTypeMap() { return QuotaSpec.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/RaftConfiguration.ts b/clients/typescript/v1/models/RaftConfiguration.ts index 85f29907..e1e3c9ab 100644 --- a/clients/typescript/v1/models/RaftConfiguration.ts +++ b/clients/typescript/v1/models/RaftConfiguration.ts @@ -36,7 +36,7 @@ export class RaftConfiguration { static getAttributeTypeMap() { return RaftConfiguration.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/RaftServer.ts b/clients/typescript/v1/models/RaftServer.ts index 29fdf1e1..4672ab86 100644 --- a/clients/typescript/v1/models/RaftServer.ts +++ b/clients/typescript/v1/models/RaftServer.ts @@ -63,7 +63,7 @@ export class RaftServer { static getAttributeTypeMap() { return RaftServer.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/RequestedDevice.ts b/clients/typescript/v1/models/RequestedDevice.ts index 371056d0..73cfb390 100644 --- a/clients/typescript/v1/models/RequestedDevice.ts +++ b/clients/typescript/v1/models/RequestedDevice.ts @@ -51,7 +51,7 @@ export class RequestedDevice { static getAttributeTypeMap() { return RequestedDevice.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/RescheduleEvent.ts b/clients/typescript/v1/models/RescheduleEvent.ts index f6003f82..f0e063ae 100644 --- a/clients/typescript/v1/models/RescheduleEvent.ts +++ b/clients/typescript/v1/models/RescheduleEvent.ts @@ -42,7 +42,7 @@ export class RescheduleEvent { static getAttributeTypeMap() { return RescheduleEvent.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/ReschedulePolicy.ts b/clients/typescript/v1/models/ReschedulePolicy.ts index 3a569376..ce16158a 100644 --- a/clients/typescript/v1/models/ReschedulePolicy.ts +++ b/clients/typescript/v1/models/ReschedulePolicy.ts @@ -63,7 +63,7 @@ export class ReschedulePolicy { static getAttributeTypeMap() { return ReschedulePolicy.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/RescheduleTracker.ts b/clients/typescript/v1/models/RescheduleTracker.ts index 86c07318..1da9fc4b 100644 --- a/clients/typescript/v1/models/RescheduleTracker.ts +++ b/clients/typescript/v1/models/RescheduleTracker.ts @@ -29,7 +29,7 @@ export class RescheduleTracker { static getAttributeTypeMap() { return RescheduleTracker.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/Resources.ts b/clients/typescript/v1/models/Resources.ts index d331a4f5..44354c4c 100644 --- a/clients/typescript/v1/models/Resources.ts +++ b/clients/typescript/v1/models/Resources.ts @@ -79,7 +79,7 @@ export class Resources { static getAttributeTypeMap() { return Resources.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/RestartPolicy.ts b/clients/typescript/v1/models/RestartPolicy.ts index dc9421e4..55f7e6e0 100644 --- a/clients/typescript/v1/models/RestartPolicy.ts +++ b/clients/typescript/v1/models/RestartPolicy.ts @@ -49,7 +49,7 @@ export class RestartPolicy { static getAttributeTypeMap() { return RestartPolicy.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/SampledValue.ts b/clients/typescript/v1/models/SampledValue.ts index 52bfc9fb..edb56596 100644 --- a/clients/typescript/v1/models/SampledValue.ts +++ b/clients/typescript/v1/models/SampledValue.ts @@ -84,7 +84,7 @@ export class SampledValue { static getAttributeTypeMap() { return SampledValue.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/ScalingEvent.ts b/clients/typescript/v1/models/ScalingEvent.ts index 1a257f96..e3ef4cc8 100644 --- a/clients/typescript/v1/models/ScalingEvent.ts +++ b/clients/typescript/v1/models/ScalingEvent.ts @@ -10,7 +10,6 @@ * Do not edit the class manually. */ -import { AnyType } from './AnyType'; import { HttpFile } from '../http/http'; export class ScalingEvent { @@ -19,7 +18,7 @@ export class ScalingEvent { 'error'?: boolean; 'evalID'?: string; 'message'?: string; - 'meta'?: { [key: string]: AnyType; }; + 'meta'?: { [key: string]: any; }; 'previousCount'?: number; 'time'?: number; @@ -59,7 +58,7 @@ export class ScalingEvent { { "name": "meta", "baseName": "Meta", - "type": "{ [key: string]: AnyType; }", + "type": "{ [key: string]: any; }", "format": "" }, { @@ -78,7 +77,7 @@ export class ScalingEvent { static getAttributeTypeMap() { return ScalingEvent.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/ScalingPolicy.ts b/clients/typescript/v1/models/ScalingPolicy.ts index 79884c49..33c6ea61 100644 --- a/clients/typescript/v1/models/ScalingPolicy.ts +++ b/clients/typescript/v1/models/ScalingPolicy.ts @@ -10,7 +10,6 @@ * Do not edit the class manually. */ -import { AnyType } from './AnyType'; import { HttpFile } from '../http/http'; export class ScalingPolicy { @@ -21,7 +20,7 @@ export class ScalingPolicy { 'min'?: number; 'modifyIndex'?: number; 'namespace'?: string; - 'policy'?: { [key: string]: AnyType; }; + 'policy'?: { [key: string]: any; }; 'target'?: { [key: string]: string; }; 'type'?: string; @@ -73,7 +72,7 @@ export class ScalingPolicy { { "name": "policy", "baseName": "Policy", - "type": "{ [key: string]: AnyType; }", + "type": "{ [key: string]: any; }", "format": "" }, { @@ -92,7 +91,7 @@ export class ScalingPolicy { static getAttributeTypeMap() { return ScalingPolicy.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/ScalingPolicyListStub.ts b/clients/typescript/v1/models/ScalingPolicyListStub.ts index 8410be01..cb1a6b94 100644 --- a/clients/typescript/v1/models/ScalingPolicyListStub.ts +++ b/clients/typescript/v1/models/ScalingPolicyListStub.ts @@ -63,7 +63,7 @@ export class ScalingPolicyListStub { static getAttributeTypeMap() { return ScalingPolicyListStub.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/ScalingRequest.ts b/clients/typescript/v1/models/ScalingRequest.ts index 18bb4867..b687f0fb 100644 --- a/clients/typescript/v1/models/ScalingRequest.ts +++ b/clients/typescript/v1/models/ScalingRequest.ts @@ -10,14 +10,13 @@ * Do not edit the class manually. */ -import { AnyType } from './AnyType'; import { HttpFile } from '../http/http'; export class ScalingRequest { 'count'?: number; 'error'?: boolean; 'message'?: string; - 'meta'?: { [key: string]: AnyType; }; + 'meta'?: { [key: string]: any; }; 'namespace'?: string; 'policyOverride'?: boolean; 'region'?: string; @@ -48,7 +47,7 @@ export class ScalingRequest { { "name": "meta", "baseName": "Meta", - "type": "{ [key: string]: AnyType; }", + "type": "{ [key: string]: any; }", "format": "" }, { @@ -85,7 +84,7 @@ export class ScalingRequest { static getAttributeTypeMap() { return ScalingRequest.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/SchedulerConfiguration.ts b/clients/typescript/v1/models/SchedulerConfiguration.ts index 9c8d5e1a..8e20c0a4 100644 --- a/clients/typescript/v1/models/SchedulerConfiguration.ts +++ b/clients/typescript/v1/models/SchedulerConfiguration.ts @@ -71,7 +71,7 @@ export class SchedulerConfiguration { static getAttributeTypeMap() { return SchedulerConfiguration.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/SchedulerConfigurationResponse.ts b/clients/typescript/v1/models/SchedulerConfigurationResponse.ts index 747c9c4b..852bc217 100644 --- a/clients/typescript/v1/models/SchedulerConfigurationResponse.ts +++ b/clients/typescript/v1/models/SchedulerConfigurationResponse.ts @@ -64,7 +64,7 @@ export class SchedulerConfigurationResponse { static getAttributeTypeMap() { return SchedulerConfigurationResponse.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/SchedulerSetConfigurationResponse.ts b/clients/typescript/v1/models/SchedulerSetConfigurationResponse.ts index e05030b7..96993d77 100644 --- a/clients/typescript/v1/models/SchedulerSetConfigurationResponse.ts +++ b/clients/typescript/v1/models/SchedulerSetConfigurationResponse.ts @@ -42,7 +42,7 @@ export class SchedulerSetConfigurationResponse { static getAttributeTypeMap() { return SchedulerSetConfigurationResponse.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/SearchRequest.ts b/clients/typescript/v1/models/SearchRequest.ts index 7292ce2c..6ac997af 100644 --- a/clients/typescript/v1/models/SearchRequest.ts +++ b/clients/typescript/v1/models/SearchRequest.ts @@ -119,7 +119,7 @@ export class SearchRequest { static getAttributeTypeMap() { return SearchRequest.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/SearchResponse.ts b/clients/typescript/v1/models/SearchResponse.ts index d2cc75c0..6b86c26d 100644 --- a/clients/typescript/v1/models/SearchResponse.ts +++ b/clients/typescript/v1/models/SearchResponse.ts @@ -70,7 +70,7 @@ export class SearchResponse { static getAttributeTypeMap() { return SearchResponse.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/ServerHealth.ts b/clients/typescript/v1/models/ServerHealth.ts index 30d5fdf1..7d00e237 100644 --- a/clients/typescript/v1/models/ServerHealth.ts +++ b/clients/typescript/v1/models/ServerHealth.ts @@ -105,7 +105,7 @@ export class ServerHealth { static getAttributeTypeMap() { return ServerHealth.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/Service.ts b/clients/typescript/v1/models/Service.ts index 26046df9..82f637d8 100644 --- a/clients/typescript/v1/models/Service.ts +++ b/clients/typescript/v1/models/Service.ts @@ -136,7 +136,7 @@ export class Service { static getAttributeTypeMap() { return Service.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/ServiceCheck.ts b/clients/typescript/v1/models/ServiceCheck.ts index 7057add9..9bd44e68 100644 --- a/clients/typescript/v1/models/ServiceCheck.ts +++ b/clients/typescript/v1/models/ServiceCheck.ts @@ -190,7 +190,7 @@ export class ServiceCheck { static getAttributeTypeMap() { return ServiceCheck.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/ServiceRegistration.ts b/clients/typescript/v1/models/ServiceRegistration.ts index 291fcee5..e8c3dc51 100644 --- a/clients/typescript/v1/models/ServiceRegistration.ts +++ b/clients/typescript/v1/models/ServiceRegistration.ts @@ -105,7 +105,7 @@ export class ServiceRegistration { static getAttributeTypeMap() { return ServiceRegistration.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/SidecarTask.ts b/clients/typescript/v1/models/SidecarTask.ts index d806dbbb..55d9354b 100644 --- a/clients/typescript/v1/models/SidecarTask.ts +++ b/clients/typescript/v1/models/SidecarTask.ts @@ -10,13 +10,12 @@ * Do not edit the class manually. */ -import { AnyType } from './AnyType'; import { LogConfig } from './LogConfig'; import { Resources } from './Resources'; import { HttpFile } from '../http/http'; export class SidecarTask { - 'config'?: { [key: string]: AnyType; }; + 'config'?: { [key: string]: any; }; 'driver'?: string; 'env'?: { [key: string]: string; }; 'killSignal'?: string; @@ -34,7 +33,7 @@ export class SidecarTask { { "name": "config", "baseName": "Config", - "type": "{ [key: string]: AnyType; }", + "type": "{ [key: string]: any; }", "format": "" }, { @@ -101,7 +100,7 @@ export class SidecarTask { static getAttributeTypeMap() { return SidecarTask.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/Spread.ts b/clients/typescript/v1/models/Spread.ts index 021ff335..9910044a 100644 --- a/clients/typescript/v1/models/Spread.ts +++ b/clients/typescript/v1/models/Spread.ts @@ -43,7 +43,7 @@ export class Spread { static getAttributeTypeMap() { return Spread.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/SpreadTarget.ts b/clients/typescript/v1/models/SpreadTarget.ts index f50bcef2..5e085140 100644 --- a/clients/typescript/v1/models/SpreadTarget.ts +++ b/clients/typescript/v1/models/SpreadTarget.ts @@ -35,7 +35,7 @@ export class SpreadTarget { static getAttributeTypeMap() { return SpreadTarget.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/Task.ts b/clients/typescript/v1/models/Task.ts index 38fe947e..9689e2d0 100644 --- a/clients/typescript/v1/models/Task.ts +++ b/clients/typescript/v1/models/Task.ts @@ -11,7 +11,6 @@ */ import { Affinity } from './Affinity'; -import { AnyType } from './AnyType'; import { Constraint } from './Constraint'; import { DispatchPayloadConfig } from './DispatchPayloadConfig'; import { LogConfig } from './LogConfig'; @@ -31,7 +30,7 @@ export class Task { 'affinities'?: Array; 'artifacts'?: Array; 'cSIPluginConfig'?: TaskCSIPluginConfig; - 'config'?: { [key: string]: AnyType; }; + 'config'?: { [key: string]: any; }; 'constraints'?: Array; 'dispatchPayload'?: DispatchPayloadConfig; 'driver'?: string; @@ -78,7 +77,7 @@ export class Task { { "name": "config", "baseName": "Config", - "type": "{ [key: string]: AnyType; }", + "type": "{ [key: string]: any; }", "format": "" }, { @@ -211,7 +210,7 @@ export class Task { static getAttributeTypeMap() { return Task.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/TaskArtifact.ts b/clients/typescript/v1/models/TaskArtifact.ts index e76b072c..af64e83a 100644 --- a/clients/typescript/v1/models/TaskArtifact.ts +++ b/clients/typescript/v1/models/TaskArtifact.ts @@ -56,7 +56,7 @@ export class TaskArtifact { static getAttributeTypeMap() { return TaskArtifact.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/TaskCSIPluginConfig.ts b/clients/typescript/v1/models/TaskCSIPluginConfig.ts index d54ee37d..74528e98 100644 --- a/clients/typescript/v1/models/TaskCSIPluginConfig.ts +++ b/clients/typescript/v1/models/TaskCSIPluginConfig.ts @@ -49,7 +49,7 @@ export class TaskCSIPluginConfig { static getAttributeTypeMap() { return TaskCSIPluginConfig.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/TaskDiff.ts b/clients/typescript/v1/models/TaskDiff.ts index fc1a175b..2d9d05cd 100644 --- a/clients/typescript/v1/models/TaskDiff.ts +++ b/clients/typescript/v1/models/TaskDiff.ts @@ -58,7 +58,7 @@ export class TaskDiff { static getAttributeTypeMap() { return TaskDiff.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/TaskEvent.ts b/clients/typescript/v1/models/TaskEvent.ts index e845d581..52183113 100644 --- a/clients/typescript/v1/models/TaskEvent.ts +++ b/clients/typescript/v1/models/TaskEvent.ts @@ -196,7 +196,7 @@ export class TaskEvent { static getAttributeTypeMap() { return TaskEvent.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/TaskGroup.ts b/clients/typescript/v1/models/TaskGroup.ts index b5da27e4..cda64b35 100644 --- a/clients/typescript/v1/models/TaskGroup.ts +++ b/clients/typescript/v1/models/TaskGroup.ts @@ -175,7 +175,7 @@ export class TaskGroup { static getAttributeTypeMap() { return TaskGroup.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/TaskGroupDiff.ts b/clients/typescript/v1/models/TaskGroupDiff.ts index 70135d74..aa0437b1 100644 --- a/clients/typescript/v1/models/TaskGroupDiff.ts +++ b/clients/typescript/v1/models/TaskGroupDiff.ts @@ -66,7 +66,7 @@ export class TaskGroupDiff { static getAttributeTypeMap() { return TaskGroupDiff.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/TaskGroupScaleStatus.ts b/clients/typescript/v1/models/TaskGroupScaleStatus.ts index 3c139e93..e6179939 100644 --- a/clients/typescript/v1/models/TaskGroupScaleStatus.ts +++ b/clients/typescript/v1/models/TaskGroupScaleStatus.ts @@ -64,7 +64,7 @@ export class TaskGroupScaleStatus { static getAttributeTypeMap() { return TaskGroupScaleStatus.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/TaskGroupSummary.ts b/clients/typescript/v1/models/TaskGroupSummary.ts index 255f37b7..61b1154b 100644 --- a/clients/typescript/v1/models/TaskGroupSummary.ts +++ b/clients/typescript/v1/models/TaskGroupSummary.ts @@ -70,7 +70,7 @@ export class TaskGroupSummary { static getAttributeTypeMap() { return TaskGroupSummary.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/TaskHandle.ts b/clients/typescript/v1/models/TaskHandle.ts index ce64b794..a66f7f2e 100644 --- a/clients/typescript/v1/models/TaskHandle.ts +++ b/clients/typescript/v1/models/TaskHandle.ts @@ -35,7 +35,7 @@ export class TaskHandle { static getAttributeTypeMap() { return TaskHandle.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/TaskLifecycle.ts b/clients/typescript/v1/models/TaskLifecycle.ts index e6c1b564..5a71677d 100644 --- a/clients/typescript/v1/models/TaskLifecycle.ts +++ b/clients/typescript/v1/models/TaskLifecycle.ts @@ -35,7 +35,7 @@ export class TaskLifecycle { static getAttributeTypeMap() { return TaskLifecycle.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/TaskState.ts b/clients/typescript/v1/models/TaskState.ts index ab3cb6a0..f0a4f82d 100644 --- a/clients/typescript/v1/models/TaskState.ts +++ b/clients/typescript/v1/models/TaskState.ts @@ -79,7 +79,7 @@ export class TaskState { static getAttributeTypeMap() { return TaskState.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/Template.ts b/clients/typescript/v1/models/Template.ts index 643bd199..c3219ecb 100644 --- a/clients/typescript/v1/models/Template.ts +++ b/clients/typescript/v1/models/Template.ts @@ -106,7 +106,7 @@ export class Template { static getAttributeTypeMap() { return Template.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/UpdateStrategy.ts b/clients/typescript/v1/models/UpdateStrategy.ts index 419e1b55..5f8405bc 100644 --- a/clients/typescript/v1/models/UpdateStrategy.ts +++ b/clients/typescript/v1/models/UpdateStrategy.ts @@ -84,7 +84,7 @@ export class UpdateStrategy { static getAttributeTypeMap() { return UpdateStrategy.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/Vault.ts b/clients/typescript/v1/models/Vault.ts index c25801e3..df9ba69d 100644 --- a/clients/typescript/v1/models/Vault.ts +++ b/clients/typescript/v1/models/Vault.ts @@ -56,7 +56,7 @@ export class Vault { static getAttributeTypeMap() { return Vault.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/VolumeMount.ts b/clients/typescript/v1/models/VolumeMount.ts index e214d8b5..569cf8b3 100644 --- a/clients/typescript/v1/models/VolumeMount.ts +++ b/clients/typescript/v1/models/VolumeMount.ts @@ -49,7 +49,7 @@ export class VolumeMount { static getAttributeTypeMap() { return VolumeMount.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/VolumeRequest.ts b/clients/typescript/v1/models/VolumeRequest.ts index 73a1b21c..1d8a9d73 100644 --- a/clients/typescript/v1/models/VolumeRequest.ts +++ b/clients/typescript/v1/models/VolumeRequest.ts @@ -78,7 +78,7 @@ export class VolumeRequest { static getAttributeTypeMap() { return VolumeRequest.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/models/WaitConfig.ts b/clients/typescript/v1/models/WaitConfig.ts index 26be9f73..ec68f168 100644 --- a/clients/typescript/v1/models/WaitConfig.ts +++ b/clients/typescript/v1/models/WaitConfig.ts @@ -35,7 +35,7 @@ export class WaitConfig { static getAttributeTypeMap() { return WaitConfig.attributeTypeMap; } - + public constructor() { } } diff --git a/clients/typescript/v1/tsconfig.json b/clients/typescript/v1/tsconfig.json index ce51978e..6576215e 100644 --- a/clients/typescript/v1/tsconfig.json +++ b/clients/typescript/v1/tsconfig.json @@ -6,7 +6,7 @@ "module": "commonjs", "moduleResolution": "node", "declaration": true, - + /* Additional Checks */ "noUnusedLocals": false, /* Report errors on unused locals. */ // TODO: reenable (unused imports!) "noUnusedParameters": false, /* Report errors on unused parameters. */ // TODO: set to true again diff --git a/clients/typescript/v1/types/ObjectParamAPI.ts b/clients/typescript/v1/types/ObjectParamAPI.ts index 6d2df618..45844415 100644 --- a/clients/typescript/v1/types/ObjectParamAPI.ts +++ b/clients/typescript/v1/types/ObjectParamAPI.ts @@ -748,7 +748,7 @@ export class ObjectACLApi { /** * @param param the request object */ - public getACLPolicies(param: ACLApiGetACLPoliciesRequest, options?: Configuration): Promise> { + public getACLPolicies(param: ACLApiGetACLPoliciesRequest = {}, options?: Configuration): Promise> { return this.api.getACLPolicies(param.region, param.namespace, param.index, param.wait, param.stale, param.prefix, param.xNomadToken, param.perPage, param.nextToken, options).toPromise(); } @@ -769,21 +769,21 @@ export class ObjectACLApi { /** * @param param the request object */ - public getACLTokenSelf(param: ACLApiGetACLTokenSelfRequest, options?: Configuration): Promise { + public getACLTokenSelf(param: ACLApiGetACLTokenSelfRequest = {}, options?: Configuration): Promise { return this.api.getACLTokenSelf(param.region, param.namespace, param.index, param.wait, param.stale, param.prefix, param.xNomadToken, param.perPage, param.nextToken, options).toPromise(); } /** * @param param the request object */ - public getACLTokens(param: ACLApiGetACLTokensRequest, options?: Configuration): Promise> { + public getACLTokens(param: ACLApiGetACLTokensRequest = {}, options?: Configuration): Promise> { return this.api.getACLTokens(param.region, param.namespace, param.index, param.wait, param.stale, param.prefix, param.xNomadToken, param.perPage, param.nextToken, options).toPromise(); } /** * @param param the request object */ - public postACLBootstrap(param: ACLApiPostACLBootstrapRequest, options?: Configuration): Promise { + public postACLBootstrap(param: ACLApiPostACLBootstrapRequest = {}, options?: Configuration): Promise { return this.api.postACLBootstrap(param.region, param.namespace, param.xNomadToken, param.idempotencyToken, options).toPromise(); } @@ -804,7 +804,7 @@ export class ObjectACLApi { /** * @param param the request object */ - public postACLTokenOnetime(param: ACLApiPostACLTokenOnetimeRequest, options?: Configuration): Promise { + public postACLTokenOnetime(param: ACLApiPostACLTokenOnetimeRequest = {}, options?: Configuration): Promise { return this.api.postACLTokenOnetime(param.region, param.namespace, param.xNomadToken, param.idempotencyToken, options).toPromise(); } @@ -1108,7 +1108,7 @@ export class ObjectAllocationsApi { /** * @param param the request object */ - public getAllocations(param: AllocationsApiGetAllocationsRequest, options?: Configuration): Promise> { + public getAllocations(param: AllocationsApiGetAllocationsRequest = {}, options?: Configuration): Promise> { return this.api.getAllocations(param.region, param.namespace, param.index, param.wait, param.stale, param.prefix, param.xNomadToken, param.perPage, param.nextToken, param.resources, param.taskStates, options).toPromise(); } @@ -1520,7 +1520,7 @@ export class ObjectDeploymentsApi { /** * @param param the request object */ - public getDeployments(param: DeploymentsApiGetDeploymentsRequest, options?: Configuration): Promise> { + public getDeployments(param: DeploymentsApiGetDeploymentsRequest = {}, options?: Configuration): Promise> { return this.api.getDeployments(param.region, param.namespace, param.index, param.wait, param.stale, param.prefix, param.xNomadToken, param.perPage, param.nextToken, options).toPromise(); } @@ -1820,7 +1820,7 @@ export class ObjectEnterpriseApi { /** * @param param the request object */ - public getQuotas(param: EnterpriseApiGetQuotasRequest, options?: Configuration): Promise> { + public getQuotas(param: EnterpriseApiGetQuotasRequest = {}, options?: Configuration): Promise> { return this.api.getQuotas(param.region, param.namespace, param.index, param.wait, param.stale, param.prefix, param.xNomadToken, param.perPage, param.nextToken, options).toPromise(); } @@ -2043,7 +2043,7 @@ export class ObjectEvaluationsApi { /** * @param param the request object */ - public getEvaluations(param: EvaluationsApiGetEvaluationsRequest, options?: Configuration): Promise> { + public getEvaluations(param: EvaluationsApiGetEvaluationsRequest = {}, options?: Configuration): Promise> { return this.api.getEvaluations(param.region, param.namespace, param.index, param.wait, param.stale, param.prefix, param.xNomadToken, param.perPage, param.nextToken, options).toPromise(); } @@ -3130,7 +3130,7 @@ export class ObjectJobsApi { /** * @param param the request object */ - public getJobs(param: JobsApiGetJobsRequest, options?: Configuration): Promise> { + public getJobs(param: JobsApiGetJobsRequest = {}, options?: Configuration): Promise> { return this.api.getJobs(param.region, param.namespace, param.index, param.wait, param.stale, param.prefix, param.xNomadToken, param.perPage, param.nextToken, options).toPromise(); } @@ -3235,7 +3235,7 @@ export class ObjectMetricsApi { /** * @param param the request object */ - public getMetricsSummary(param: MetricsApiGetMetricsSummaryRequest, options?: Configuration): Promise { + public getMetricsSummary(param: MetricsApiGetMetricsSummaryRequest = {}, options?: Configuration): Promise { return this.api.getMetricsSummary(param.format, options).toPromise(); } @@ -3473,7 +3473,7 @@ export class ObjectNamespacesApi { /** * @param param the request object */ - public createNamespace(param: NamespacesApiCreateNamespaceRequest, options?: Configuration): Promise { + public createNamespace(param: NamespacesApiCreateNamespaceRequest = {}, options?: Configuration): Promise { return this.api.createNamespace(param.region, param.namespace, param.xNomadToken, param.idempotencyToken, options).toPromise(); } @@ -3494,7 +3494,7 @@ export class ObjectNamespacesApi { /** * @param param the request object */ - public getNamespaces(param: NamespacesApiGetNamespacesRequest, options?: Configuration): Promise> { + public getNamespaces(param: NamespacesApiGetNamespacesRequest = {}, options?: Configuration): Promise> { return this.api.getNamespaces(param.region, param.namespace, param.index, param.wait, param.stale, param.prefix, param.xNomadToken, param.perPage, param.nextToken, options).toPromise(); } @@ -3924,7 +3924,7 @@ export class ObjectNodesApi { /** * @param param the request object */ - public getNodes(param: NodesApiGetNodesRequest, options?: Configuration): Promise> { + public getNodes(param: NodesApiGetNodesRequest = {}, options?: Configuration): Promise> { return this.api.getNodes(param.region, param.namespace, param.index, param.wait, param.stale, param.prefix, param.xNomadToken, param.perPage, param.nextToken, param.resources, options).toPromise(); } @@ -4285,35 +4285,35 @@ export class ObjectOperatorApi { /** * @param param the request object */ - public deleteOperatorRaftPeer(param: OperatorApiDeleteOperatorRaftPeerRequest, options?: Configuration): Promise { + public deleteOperatorRaftPeer(param: OperatorApiDeleteOperatorRaftPeerRequest = {}, options?: Configuration): Promise { return this.api.deleteOperatorRaftPeer(param.region, param.namespace, param.xNomadToken, param.idempotencyToken, options).toPromise(); } /** * @param param the request object */ - public getOperatorAutopilotConfiguration(param: OperatorApiGetOperatorAutopilotConfigurationRequest, options?: Configuration): Promise { + public getOperatorAutopilotConfiguration(param: OperatorApiGetOperatorAutopilotConfigurationRequest = {}, options?: Configuration): Promise { return this.api.getOperatorAutopilotConfiguration(param.region, param.namespace, param.index, param.wait, param.stale, param.prefix, param.xNomadToken, param.perPage, param.nextToken, options).toPromise(); } /** * @param param the request object */ - public getOperatorAutopilotHealth(param: OperatorApiGetOperatorAutopilotHealthRequest, options?: Configuration): Promise { + public getOperatorAutopilotHealth(param: OperatorApiGetOperatorAutopilotHealthRequest = {}, options?: Configuration): Promise { return this.api.getOperatorAutopilotHealth(param.region, param.namespace, param.index, param.wait, param.stale, param.prefix, param.xNomadToken, param.perPage, param.nextToken, options).toPromise(); } /** * @param param the request object */ - public getOperatorRaftConfiguration(param: OperatorApiGetOperatorRaftConfigurationRequest, options?: Configuration): Promise { + public getOperatorRaftConfiguration(param: OperatorApiGetOperatorRaftConfigurationRequest = {}, options?: Configuration): Promise { return this.api.getOperatorRaftConfiguration(param.region, param.namespace, param.index, param.wait, param.stale, param.prefix, param.xNomadToken, param.perPage, param.nextToken, options).toPromise(); } /** * @param param the request object */ - public getOperatorSchedulerConfiguration(param: OperatorApiGetOperatorSchedulerConfigurationRequest, options?: Configuration): Promise { + public getOperatorSchedulerConfiguration(param: OperatorApiGetOperatorSchedulerConfigurationRequest = {}, options?: Configuration): Promise { return this.api.getOperatorSchedulerConfiguration(param.region, param.namespace, param.index, param.wait, param.stale, param.prefix, param.xNomadToken, param.perPage, param.nextToken, options).toPromise(); } @@ -4473,7 +4473,7 @@ export class ObjectPluginsApi { /** * @param param the request object */ - public getPlugins(param: PluginsApiGetPluginsRequest, options?: Configuration): Promise> { + public getPlugins(param: PluginsApiGetPluginsRequest = {}, options?: Configuration): Promise> { return this.api.getPlugins(param.region, param.namespace, param.index, param.wait, param.stale, param.prefix, param.xNomadToken, param.perPage, param.nextToken, options).toPromise(); } @@ -4495,7 +4495,7 @@ export class ObjectRegionsApi { /** * @param param the request object */ - public getRegions(param: RegionsApiGetRegionsRequest, options?: Configuration): Promise> { + public getRegions(param: RegionsApiGetRegionsRequest = {}, options?: Configuration): Promise> { return this.api.getRegions( options).toPromise(); } @@ -4634,7 +4634,7 @@ export class ObjectScalingApi { /** * @param param the request object */ - public getScalingPolicies(param: ScalingApiGetScalingPoliciesRequest, options?: Configuration): Promise> { + public getScalingPolicies(param: ScalingApiGetScalingPoliciesRequest = {}, options?: Configuration): Promise> { return this.api.getScalingPolicies(param.region, param.namespace, param.index, param.wait, param.stale, param.prefix, param.xNomadToken, param.perPage, param.nextToken, options).toPromise(); } @@ -4926,14 +4926,14 @@ export class ObjectStatusApi { /** * @param param the request object */ - public getStatusLeader(param: StatusApiGetStatusLeaderRequest, options?: Configuration): Promise { + public getStatusLeader(param: StatusApiGetStatusLeaderRequest = {}, options?: Configuration): Promise { return this.api.getStatusLeader(param.region, param.namespace, param.index, param.wait, param.stale, param.prefix, param.xNomadToken, param.perPage, param.nextToken, options).toPromise(); } /** * @param param the request object */ - public getStatusPeers(param: StatusApiGetStatusPeersRequest, options?: Configuration): Promise> { + public getStatusPeers(param: StatusApiGetStatusPeersRequest = {}, options?: Configuration): Promise> { return this.api.getStatusPeers(param.region, param.namespace, param.index, param.wait, param.stale, param.prefix, param.xNomadToken, param.perPage, param.nextToken, options).toPromise(); } @@ -5006,14 +5006,14 @@ export class ObjectSystemApi { /** * @param param the request object */ - public putSystemGC(param: SystemApiPutSystemGCRequest, options?: Configuration): Promise { + public putSystemGC(param: SystemApiPutSystemGCRequest = {}, options?: Configuration): Promise { return this.api.putSystemGC(param.region, param.namespace, param.xNomadToken, param.idempotencyToken, options).toPromise(); } /** * @param param the request object */ - public putSystemReconcileSummaries(param: SystemApiPutSystemReconcileSummariesRequest, options?: Configuration): Promise { + public putSystemReconcileSummaries(param: SystemApiPutSystemReconcileSummariesRequest = {}, options?: Configuration): Promise { return this.api.putSystemReconcileSummaries(param.region, param.namespace, param.xNomadToken, param.idempotencyToken, options).toPromise(); } @@ -5576,7 +5576,7 @@ export class ObjectVolumesApi { /** * @param param the request object */ - public deleteSnapshot(param: VolumesApiDeleteSnapshotRequest, options?: Configuration): Promise { + public deleteSnapshot(param: VolumesApiDeleteSnapshotRequest = {}, options?: Configuration): Promise { return this.api.deleteSnapshot(param.region, param.namespace, param.xNomadToken, param.idempotencyToken, param.pluginId, param.snapshotId, options).toPromise(); } @@ -5597,14 +5597,14 @@ export class ObjectVolumesApi { /** * @param param the request object */ - public getExternalVolumes(param: VolumesApiGetExternalVolumesRequest, options?: Configuration): Promise { + public getExternalVolumes(param: VolumesApiGetExternalVolumesRequest = {}, options?: Configuration): Promise { return this.api.getExternalVolumes(param.region, param.namespace, param.index, param.wait, param.stale, param.prefix, param.xNomadToken, param.perPage, param.nextToken, param.pluginId, options).toPromise(); } /** * @param param the request object */ - public getSnapshots(param: VolumesApiGetSnapshotsRequest, options?: Configuration): Promise { + public getSnapshots(param: VolumesApiGetSnapshotsRequest = {}, options?: Configuration): Promise { return this.api.getSnapshots(param.region, param.namespace, param.index, param.wait, param.stale, param.prefix, param.xNomadToken, param.perPage, param.nextToken, param.pluginId, options).toPromise(); } @@ -5618,7 +5618,7 @@ export class ObjectVolumesApi { /** * @param param the request object */ - public getVolumes(param: VolumesApiGetVolumesRequest, options?: Configuration): Promise> { + public getVolumes(param: VolumesApiGetVolumesRequest = {}, options?: Configuration): Promise> { return this.api.getVolumes(param.region, param.namespace, param.index, param.wait, param.stale, param.prefix, param.xNomadToken, param.perPage, param.nextToken, param.nodeId, param.pluginId, param.type, options).toPromise(); } diff --git a/clients/typescript/v1/types/ObservableAPI.ts b/clients/typescript/v1/types/ObservableAPI.ts index a8152030..f291df51 100644 --- a/clients/typescript/v1/types/ObservableAPI.ts +++ b/clients/typescript/v1/types/ObservableAPI.ts @@ -235,7 +235,7 @@ export class ObservableACLApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.deleteACLPolicy(rsp))); })); } - + /** * @param tokenAccessor The token accessor ID. * @param region Filters results based on the specified region. @@ -261,7 +261,7 @@ export class ObservableACLApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.deleteACLToken(rsp))); })); } - + /** * @param region Filters results based on the specified region. * @param namespace Filters results based on the specified namespace. @@ -291,7 +291,7 @@ export class ObservableACLApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getACLPolicies(rsp))); })); } - + /** * @param policyName The ACL policy name. * @param region Filters results based on the specified region. @@ -322,7 +322,7 @@ export class ObservableACLApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getACLPolicy(rsp))); })); } - + /** * @param tokenAccessor The token accessor ID. * @param region Filters results based on the specified region. @@ -353,7 +353,7 @@ export class ObservableACLApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getACLToken(rsp))); })); } - + /** * @param region Filters results based on the specified region. * @param namespace Filters results based on the specified namespace. @@ -383,7 +383,7 @@ export class ObservableACLApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getACLTokenSelf(rsp))); })); } - + /** * @param region Filters results based on the specified region. * @param namespace Filters results based on the specified namespace. @@ -413,7 +413,7 @@ export class ObservableACLApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getACLTokens(rsp))); })); } - + /** * @param region Filters results based on the specified region. * @param namespace Filters results based on the specified namespace. @@ -438,7 +438,7 @@ export class ObservableACLApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.postACLBootstrap(rsp))); })); } - + /** * @param policyName The ACL policy name. * @param aCLPolicy @@ -465,7 +465,7 @@ export class ObservableACLApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.postACLPolicy(rsp))); })); } - + /** * @param tokenAccessor The token accessor ID. * @param aCLToken @@ -492,7 +492,7 @@ export class ObservableACLApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.postACLToken(rsp))); })); } - + /** * @param region Filters results based on the specified region. * @param namespace Filters results based on the specified namespace. @@ -517,7 +517,7 @@ export class ObservableACLApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.postACLTokenOnetime(rsp))); })); } - + /** * @param oneTimeTokenExchangeRequest * @param region Filters results based on the specified region. @@ -543,7 +543,7 @@ export class ObservableACLApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.postACLTokenOnetimeExchange(rsp))); })); } - + } import { AllocationsApiRequestFactory, AllocationsApiResponseProcessor} from "../apis/AllocationsApi"; @@ -592,7 +592,7 @@ export class ObservableAllocationsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getAllocation(rsp))); })); } - + /** * @param allocID Allocation ID. * @param region Filters results based on the specified region. @@ -623,7 +623,7 @@ export class ObservableAllocationsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getAllocationServices(rsp))); })); } - + /** * @param region Filters results based on the specified region. * @param namespace Filters results based on the specified namespace. @@ -655,7 +655,7 @@ export class ObservableAllocationsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getAllocations(rsp))); })); } - + /** * @param allocID Allocation ID. * @param region Filters results based on the specified region. @@ -687,7 +687,7 @@ export class ObservableAllocationsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.postAllocationStop(rsp))); })); } - + } import { DeploymentsApiRequestFactory, DeploymentsApiResponseProcessor} from "../apis/DeploymentsApi"; @@ -736,7 +736,7 @@ export class ObservableDeploymentsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getDeployment(rsp))); })); } - + /** * @param deploymentID Deployment ID. * @param region Filters results based on the specified region. @@ -767,7 +767,7 @@ export class ObservableDeploymentsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getDeploymentAllocations(rsp))); })); } - + /** * @param region Filters results based on the specified region. * @param namespace Filters results based on the specified namespace. @@ -797,7 +797,7 @@ export class ObservableDeploymentsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getDeployments(rsp))); })); } - + /** * @param deploymentID Deployment ID. * @param deploymentAllocHealthRequest @@ -824,7 +824,7 @@ export class ObservableDeploymentsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.postDeploymentAllocationHealth(rsp))); })); } - + /** * @param deploymentID Deployment ID. * @param region Filters results based on the specified region. @@ -850,7 +850,7 @@ export class ObservableDeploymentsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.postDeploymentFail(rsp))); })); } - + /** * @param deploymentID Deployment ID. * @param deploymentPauseRequest @@ -877,7 +877,7 @@ export class ObservableDeploymentsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.postDeploymentPause(rsp))); })); } - + /** * @param deploymentID Deployment ID. * @param deploymentPromoteRequest @@ -904,7 +904,7 @@ export class ObservableDeploymentsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.postDeploymentPromote(rsp))); })); } - + /** * @param deploymentID Deployment ID. * @param deploymentUnblockRequest @@ -931,7 +931,7 @@ export class ObservableDeploymentsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.postDeploymentUnblock(rsp))); })); } - + } import { EnterpriseApiRequestFactory, EnterpriseApiResponseProcessor} from "../apis/EnterpriseApi"; @@ -975,7 +975,7 @@ export class ObservableEnterpriseApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.createQuotaSpec(rsp))); })); } - + /** * @param specName The quota spec identifier. * @param region Filters results based on the specified region. @@ -1001,7 +1001,7 @@ export class ObservableEnterpriseApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.deleteQuotaSpec(rsp))); })); } - + /** * @param specName The quota spec identifier. * @param region Filters results based on the specified region. @@ -1032,7 +1032,7 @@ export class ObservableEnterpriseApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getQuotaSpec(rsp))); })); } - + /** * @param region Filters results based on the specified region. * @param namespace Filters results based on the specified namespace. @@ -1044,7 +1044,7 @@ export class ObservableEnterpriseApi { * @param perPage Maximum number of results to return. * @param nextToken Indicates where to start paging for queries that support pagination. */ - public getQuotas(region?: string, namespace?: string, index?: number, wait?: string, stale?: string, prefix?: string, xNomadToken?: string, perPage?: number, nextToken?: string, _options?: Configuration): Observable> { + public getQuotas(region?: string, namespace?: string, index?: number, wait?: string, stale?: string, prefix?: string, xNomadToken?: string, perPage?: number, nextToken?: string, _options?: Configuration): Observable> { const requestContextPromise = this.requestFactory.getQuotas(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken, _options); // build promise chain @@ -1062,7 +1062,7 @@ export class ObservableEnterpriseApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getQuotas(rsp))); })); } - + /** * @param specName The quota spec identifier. * @param quotaSpec @@ -1089,7 +1089,7 @@ export class ObservableEnterpriseApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.postQuotaSpec(rsp))); })); } - + } import { EvaluationsApiRequestFactory, EvaluationsApiResponseProcessor} from "../apis/EvaluationsApi"; @@ -1138,7 +1138,7 @@ export class ObservableEvaluationsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getEvaluation(rsp))); })); } - + /** * @param evalID Evaluation ID. * @param region Filters results based on the specified region. @@ -1169,7 +1169,7 @@ export class ObservableEvaluationsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getEvaluationAllocations(rsp))); })); } - + /** * @param region Filters results based on the specified region. * @param namespace Filters results based on the specified namespace. @@ -1199,7 +1199,7 @@ export class ObservableEvaluationsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getEvaluations(rsp))); })); } - + } import { JobsApiRequestFactory, JobsApiResponseProcessor} from "../apis/JobsApi"; @@ -1245,7 +1245,7 @@ export class ObservableJobsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.deleteJob(rsp))); })); } - + /** * @param jobName The job identifier. * @param region Filters results based on the specified region. @@ -1276,7 +1276,7 @@ export class ObservableJobsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getJob(rsp))); })); } - + /** * @param jobName The job identifier. * @param region Filters results based on the specified region. @@ -1308,7 +1308,7 @@ export class ObservableJobsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getJobAllocations(rsp))); })); } - + /** * @param jobName The job identifier. * @param region Filters results based on the specified region. @@ -1339,7 +1339,7 @@ export class ObservableJobsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getJobDeployment(rsp))); })); } - + /** * @param jobName The job identifier. * @param region Filters results based on the specified region. @@ -1371,7 +1371,7 @@ export class ObservableJobsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getJobDeployments(rsp))); })); } - + /** * @param jobName The job identifier. * @param region Filters results based on the specified region. @@ -1402,7 +1402,7 @@ export class ObservableJobsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getJobEvaluations(rsp))); })); } - + /** * @param jobName The job identifier. * @param region Filters results based on the specified region. @@ -1433,7 +1433,7 @@ export class ObservableJobsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getJobScaleStatus(rsp))); })); } - + /** * @param jobName The job identifier. * @param region Filters results based on the specified region. @@ -1464,7 +1464,7 @@ export class ObservableJobsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getJobSummary(rsp))); })); } - + /** * @param jobName The job identifier. * @param region Filters results based on the specified region. @@ -1496,7 +1496,7 @@ export class ObservableJobsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getJobVersions(rsp))); })); } - + /** * @param region Filters results based on the specified region. * @param namespace Filters results based on the specified namespace. @@ -1526,7 +1526,7 @@ export class ObservableJobsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getJobs(rsp))); })); } - + /** * @param jobName The job identifier. * @param jobRegisterRequest @@ -1553,7 +1553,7 @@ export class ObservableJobsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.postJob(rsp))); })); } - + /** * @param jobName The job identifier. * @param jobDispatchRequest @@ -1580,7 +1580,7 @@ export class ObservableJobsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.postJobDispatch(rsp))); })); } - + /** * @param jobName The job identifier. * @param jobEvaluateRequest @@ -1607,7 +1607,7 @@ export class ObservableJobsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.postJobEvaluate(rsp))); })); } - + /** * @param jobsParseRequest */ @@ -1629,7 +1629,7 @@ export class ObservableJobsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.postJobParse(rsp))); })); } - + /** * @param jobName The job identifier. * @param region Filters results based on the specified region. @@ -1655,7 +1655,7 @@ export class ObservableJobsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.postJobPeriodicForce(rsp))); })); } - + /** * @param jobName The job identifier. * @param jobPlanRequest @@ -1682,7 +1682,7 @@ export class ObservableJobsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.postJobPlan(rsp))); })); } - + /** * @param jobName The job identifier. * @param jobRevertRequest @@ -1709,7 +1709,7 @@ export class ObservableJobsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.postJobRevert(rsp))); })); } - + /** * @param jobName The job identifier. * @param scalingRequest @@ -1736,7 +1736,7 @@ export class ObservableJobsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.postJobScalingRequest(rsp))); })); } - + /** * @param jobName The job identifier. * @param jobStabilityRequest @@ -1763,7 +1763,7 @@ export class ObservableJobsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.postJobStability(rsp))); })); } - + /** * @param jobValidateRequest * @param region Filters results based on the specified region. @@ -1789,7 +1789,7 @@ export class ObservableJobsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.postJobValidateRequest(rsp))); })); } - + /** * @param jobRegisterRequest * @param region Filters results based on the specified region. @@ -1815,7 +1815,7 @@ export class ObservableJobsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.registerJob(rsp))); })); } - + } import { MetricsApiRequestFactory, MetricsApiResponseProcessor} from "../apis/MetricsApi"; @@ -1855,7 +1855,7 @@ export class ObservableMetricsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getMetricsSummary(rsp))); })); } - + } import { NamespacesApiRequestFactory, NamespacesApiResponseProcessor} from "../apis/NamespacesApi"; @@ -1898,7 +1898,7 @@ export class ObservableNamespacesApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.createNamespace(rsp))); })); } - + /** * @param namespaceName The namespace identifier. * @param region Filters results based on the specified region. @@ -1924,7 +1924,7 @@ export class ObservableNamespacesApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.deleteNamespace(rsp))); })); } - + /** * @param namespaceName The namespace identifier. * @param region Filters results based on the specified region. @@ -1955,7 +1955,7 @@ export class ObservableNamespacesApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getNamespace(rsp))); })); } - + /** * @param region Filters results based on the specified region. * @param namespace Filters results based on the specified namespace. @@ -1985,7 +1985,7 @@ export class ObservableNamespacesApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getNamespaces(rsp))); })); } - + /** * @param namespaceName The namespace identifier. * @param namespace2 @@ -2012,7 +2012,7 @@ export class ObservableNamespacesApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.postNamespace(rsp))); })); } - + } import { NodesApiRequestFactory, NodesApiResponseProcessor} from "../apis/NodesApi"; @@ -2061,7 +2061,7 @@ export class ObservableNodesApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getNode(rsp))); })); } - + /** * @param nodeId The ID of the node. * @param region Filters results based on the specified region. @@ -2092,7 +2092,7 @@ export class ObservableNodesApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getNodeAllocations(rsp))); })); } - + /** * @param region Filters results based on the specified region. * @param namespace Filters results based on the specified namespace. @@ -2123,7 +2123,7 @@ export class ObservableNodesApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getNodes(rsp))); })); } - + /** * @param nodeId The ID of the node. * @param nodeUpdateDrainRequest @@ -2155,7 +2155,7 @@ export class ObservableNodesApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.updateNodeDrain(rsp))); })); } - + /** * @param nodeId The ID of the node. * @param nodeUpdateEligibilityRequest @@ -2187,7 +2187,7 @@ export class ObservableNodesApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.updateNodeEligibility(rsp))); })); } - + /** * @param nodeId The ID of the node. * @param region Filters results based on the specified region. @@ -2218,7 +2218,7 @@ export class ObservableNodesApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.updateNodePurge(rsp))); })); } - + } import { OperatorApiRequestFactory, OperatorApiResponseProcessor} from "../apis/OperatorApi"; @@ -2261,7 +2261,7 @@ export class ObservableOperatorApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.deleteOperatorRaftPeer(rsp))); })); } - + /** * @param region Filters results based on the specified region. * @param namespace Filters results based on the specified namespace. @@ -2291,7 +2291,7 @@ export class ObservableOperatorApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getOperatorAutopilotConfiguration(rsp))); })); } - + /** * @param region Filters results based on the specified region. * @param namespace Filters results based on the specified namespace. @@ -2321,7 +2321,7 @@ export class ObservableOperatorApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getOperatorAutopilotHealth(rsp))); })); } - + /** * @param region Filters results based on the specified region. * @param namespace Filters results based on the specified namespace. @@ -2351,7 +2351,7 @@ export class ObservableOperatorApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getOperatorRaftConfiguration(rsp))); })); } - + /** * @param region Filters results based on the specified region. * @param namespace Filters results based on the specified namespace. @@ -2381,7 +2381,7 @@ export class ObservableOperatorApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getOperatorSchedulerConfiguration(rsp))); })); } - + /** * @param schedulerConfiguration * @param region Filters results based on the specified region. @@ -2407,7 +2407,7 @@ export class ObservableOperatorApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.postOperatorSchedulerConfiguration(rsp))); })); } - + /** * @param autopilotConfiguration * @param region Filters results based on the specified region. @@ -2433,7 +2433,7 @@ export class ObservableOperatorApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.putOperatorAutopilotConfiguration(rsp))); })); } - + } import { PluginsApiRequestFactory, PluginsApiResponseProcessor} from "../apis/PluginsApi"; @@ -2482,7 +2482,7 @@ export class ObservablePluginsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getPluginCSI(rsp))); })); } - + /** * @param region Filters results based on the specified region. * @param namespace Filters results based on the specified namespace. @@ -2512,7 +2512,7 @@ export class ObservablePluginsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getPlugins(rsp))); })); } - + } import { RegionsApiRequestFactory, RegionsApiResponseProcessor} from "../apis/RegionsApi"; @@ -2551,7 +2551,7 @@ export class ObservableRegionsApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getRegions(rsp))); })); } - + } import { ScalingApiRequestFactory, ScalingApiResponseProcessor} from "../apis/ScalingApi"; @@ -2599,7 +2599,7 @@ export class ObservableScalingApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getScalingPolicies(rsp))); })); } - + /** * @param policyID The scaling policy identifier. * @param region Filters results based on the specified region. @@ -2630,7 +2630,7 @@ export class ObservableScalingApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getScalingPolicy(rsp))); })); } - + } import { SearchApiRequestFactory, SearchApiResponseProcessor} from "../apis/SearchApi"; @@ -2679,7 +2679,7 @@ export class ObservableSearchApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getFuzzySearch(rsp))); })); } - + /** * @param searchRequest * @param region Filters results based on the specified region. @@ -2710,7 +2710,7 @@ export class ObservableSearchApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getSearch(rsp))); })); } - + } import { StatusApiRequestFactory, StatusApiResponseProcessor} from "../apis/StatusApi"; @@ -2758,7 +2758,7 @@ export class ObservableStatusApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getStatusLeader(rsp))); })); } - + /** * @param region Filters results based on the specified region. * @param namespace Filters results based on the specified namespace. @@ -2788,7 +2788,7 @@ export class ObservableStatusApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getStatusPeers(rsp))); })); } - + } import { SystemApiRequestFactory, SystemApiResponseProcessor} from "../apis/SystemApi"; @@ -2831,7 +2831,7 @@ export class ObservableSystemApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.putSystemGC(rsp))); })); } - + /** * @param region Filters results based on the specified region. * @param namespace Filters results based on the specified namespace. @@ -2856,7 +2856,7 @@ export class ObservableSystemApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.putSystemReconcileSummaries(rsp))); })); } - + } import { VolumesApiRequestFactory, VolumesApiResponseProcessor} from "../apis/VolumesApi"; @@ -2902,7 +2902,7 @@ export class ObservableVolumesApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.createVolume(rsp))); })); } - + /** * @param region Filters results based on the specified region. * @param namespace Filters results based on the specified namespace. @@ -2929,7 +2929,7 @@ export class ObservableVolumesApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.deleteSnapshot(rsp))); })); } - + /** * @param volumeId Volume unique identifier. * @param region Filters results based on the specified region. @@ -2956,7 +2956,7 @@ export class ObservableVolumesApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.deleteVolumeRegistration(rsp))); })); } - + /** * @param volumeId Volume unique identifier. * @param action The action to perform on the Volume (create, detach, delete). @@ -2984,7 +2984,7 @@ export class ObservableVolumesApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.detachOrDeleteVolume(rsp))); })); } - + /** * @param region Filters results based on the specified region. * @param namespace Filters results based on the specified namespace. @@ -3015,7 +3015,7 @@ export class ObservableVolumesApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getExternalVolumes(rsp))); })); } - + /** * @param region Filters results based on the specified region. * @param namespace Filters results based on the specified namespace. @@ -3046,7 +3046,7 @@ export class ObservableVolumesApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getSnapshots(rsp))); })); } - + /** * @param volumeId Volume unique identifier. * @param region Filters results based on the specified region. @@ -3077,7 +3077,7 @@ export class ObservableVolumesApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getVolume(rsp))); })); } - + /** * @param region Filters results based on the specified region. * @param namespace Filters results based on the specified namespace. @@ -3110,7 +3110,7 @@ export class ObservableVolumesApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.getVolumes(rsp))); })); } - + /** * @param cSISnapshotCreateRequest * @param region Filters results based on the specified region. @@ -3136,7 +3136,7 @@ export class ObservableVolumesApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.postSnapshot(rsp))); })); } - + /** * @param cSIVolumeRegisterRequest * @param region Filters results based on the specified region. @@ -3162,7 +3162,7 @@ export class ObservableVolumesApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.postVolume(rsp))); })); } - + /** * @param volumeId Volume unique identifier. * @param cSIVolumeRegisterRequest @@ -3189,5 +3189,5 @@ export class ObservableVolumesApi { return middlewarePostObservable.pipe(map((rsp: ResponseContext) => this.responseProcessor.postVolumeRegistration(rsp))); })); } - + } diff --git a/clients/typescript/v1/types/PromiseAPI.ts b/clients/typescript/v1/types/PromiseAPI.ts index ffd7622b..ce342fcb 100644 --- a/clients/typescript/v1/types/PromiseAPI.ts +++ b/clients/typescript/v1/types/PromiseAPI.ts @@ -665,7 +665,7 @@ export class PromiseEnterpriseApi { * @param perPage Maximum number of results to return. * @param nextToken Indicates where to start paging for queries that support pagination. */ - public getQuotas(region?: string, namespace?: string, index?: number, wait?: string, stale?: string, prefix?: string, xNomadToken?: string, perPage?: number, nextToken?: string, _options?: Configuration): Promise> { + public getQuotas(region?: string, namespace?: string, index?: number, wait?: string, stale?: string, prefix?: string, xNomadToken?: string, perPage?: number, nextToken?: string, _options?: Configuration): Promise> { const result = this.api.getQuotas(region, namespace, index, wait, stale, prefix, xNomadToken, perPage, nextToken, _options); return result.toPromise(); } diff --git a/clients/typescript/v1/util.ts b/clients/typescript/v1/util.ts index 07317f58..96ea3dfd 100644 --- a/clients/typescript/v1/util.ts +++ b/clients/typescript/v1/util.ts @@ -1,6 +1,6 @@ /** * Returns if a specific http code is in a given code range - * where the code range is defined as a combination of digits + * where the code range is defined as a combination of digits * and "X" (the letter X) with a length of 3 * * @param codeRange string with length 3 consisting of digits and "X" (the letter X) @@ -26,3 +26,12 @@ export function isCodeInRange(codeRange: string, code: number): boolean { return true; } } + +/** +* Returns if it can consume form +* +* @param consumes array +*/ +export function canConsumeForm(contentTypes: string[]): boolean { + return contentTypes.indexOf('multipart/form-data') !== -1 +} diff --git a/generator/go.mod b/generator/go.mod index f55fae35..84eb2772 100644 --- a/generator/go.mod +++ b/generator/go.mod @@ -2,8 +2,10 @@ module github.com/hashicorp/nomad-openapi/generator go 1.17 +replace github.com/getkin/kin-openapi => ../../kin-openapi + require ( - github.com/getkin/kin-openapi v0.74.0 + github.com/getkin/kin-openapi v0.96.0 github.com/ghodss/yaml v1.0.0 github.com/hashicorp/go-hclog v1.2.0 github.com/hashicorp/nomad v1.3.2 @@ -156,6 +158,7 @@ require ( github.com/hpcloud/tail v1.0.1-0.20170814160653-37f427138745 // indirect github.com/huandu/xstrings v1.3.2 // indirect github.com/imdario/mergo v0.3.12 // indirect + github.com/invopop/yaml v0.1.0 // indirect github.com/ishidawataru/sctp v0.0.0-20191218070446-00ab2ac2db07 // indirect github.com/jefferai/isbadcipher v0.0.0-20190226160619-51d2077c035f // indirect github.com/jmespath/go-jmespath v0.4.0 // indirect diff --git a/generator/go.sum b/generator/go.sum index ae9e53c6..b49dc22d 100644 --- a/generator/go.sum +++ b/generator/go.sum @@ -483,8 +483,6 @@ github.com/fsouza/go-dockerclient v1.6.5 h1:vuFDnPcds3LvTWGYb9h0Rty14FLgkjHZdwLD github.com/fsouza/go-dockerclient v1.6.5/go.mod h1:GOdftxWLWIbIWKbIMDroKFJzPdg6Iw7r+jX1DDZdVsA= github.com/fullsailor/pkcs7 v0.0.0-20190404230743-d7302db945fa/go.mod h1:KnogPXtdwXqoenmZCw6S+25EAm2MkxbG0deNDu4cbSA= github.com/garyburd/redigo v0.0.0-20150301180006-535138d7bcd7/go.mod h1:NR3MbYisc3/PwhQ00EMzDiPmrwpPxAn5GI05/YaO1SY= -github.com/getkin/kin-openapi v0.74.0 h1:cTTAb0jRm6vr+XptL3U2PDQiINGzNPyqrwkjvtoLaxg= -github.com/getkin/kin-openapi v0.74.0/go.mod h1:7Yn5whZr5kJi6t+kShccXS8ae1APpYTW6yheSwk8Yi4= github.com/ghodss/yaml v0.0.0-20150909031657-73d445a93680/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= github.com/ghodss/yaml v1.0.0 h1:wQHKEahhL6wmXdzwWG11gIVCkOv05bNOh+Rxn0yngAk= github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= @@ -869,6 +867,8 @@ github.com/imdario/mergo v0.3.11/go.mod h1:jmQim1M+e3UYxmgPu/WyfjB3N3VflVyUjjjwH github.com/imdario/mergo v0.3.12 h1:b6R2BslTbIEToALKP7LxUvijTsNI9TAe80pLWN2g/HU= github.com/imdario/mergo v0.3.12/go.mod h1:jmQim1M+e3UYxmgPu/WyfjB3N3VflVyUjjjwH0dnCYA= github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= +github.com/invopop/yaml v0.1.0 h1:YW3WGUoJEXYfzWBjn00zIlrw7brGVD0fUKRYDPAPhrc= +github.com/invopop/yaml v0.1.0/go.mod h1:2XuRLgs/ouIrW3XNzuNj7J3Nvu/Dig5MXvbCEdiBN3Q= github.com/ishidawataru/sctp v0.0.0-20191218070446-00ab2ac2db07 h1:rw3IAne6CDuVFlZbPOkA7bhxlqawFh7RJJ+CejfMaxE= github.com/ishidawataru/sctp v0.0.0-20191218070446-00ab2ac2db07/go.mod h1:co9pwDoBCm1kGxawmb4sPq0cSIOOWNPT4KnHotMP1Zg= github.com/j-keck/arping v0.0.0-20160618110441-2cf9dc699c56/go.mod h1:ymszkNOg6tORTn+6F6j+Jc8TOr5osrynvN6ivFWZ2GA= @@ -1927,6 +1927,7 @@ gopkg.in/yaml.v2 v2.3.0/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= +gopkg.in/yaml.v3 v3.0.0/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gotest.tools v2.2.0+incompatible h1:VsBPFP1AI068pPrMxtb/S8Zkgf9xEmTLJjfM+P5UIEo= diff --git a/generator/specbuilder.go b/generator/specbuilder.go index c795077d..81d4aaa6 100644 --- a/generator/specbuilder.go +++ b/generator/specbuilder.go @@ -52,7 +52,26 @@ type specBuilder struct { func (b *specBuilder) buildSpec() (*spec, error) { b.logger = hclog.Default() - b.kingen = openapi3gen.NewGenerator(openapi3gen.UseAllExportedFields()) + + requiredCustomizerFn := func(name string, ft reflect.Type, tag reflect.StructTag, schema *openapi3.Schema) error { + if ft.Kind() == reflect.Ptr { + schema.Nullable = true + return nil + } + + if ft.Kind() != reflect.Struct { + return nil + } + + for i := 0; i < ft.NumField(); i++ { + if ft.Field(i).Type.Kind() != reflect.Ptr { + schema.Nullable = true + } + } + return nil + } + + b.kingen = openapi3gen.NewGenerator(openapi3gen.UseAllExportedFields(), openapi3gen.SchemaCustomizer(requiredCustomizerFn)) // TODO: Eventually may need to support multiple OpenAPI versions, but pushing // that off for now. b.spec = &spec{ @@ -414,35 +433,78 @@ func (b *specBuilder) getOrCreateSchemaRef(model reflect.Type) (*openapi3.Schema } func (b *specBuilder) resolveRefPaths() { - for _, schemaRef := range b.spec.Model.Components.Schemas { + firedHandlers := map[string]int{} + // DEBUG NOTE: These are maps with schema and property names + for schemaName, schemaRef := range b.spec.Model.Components.Schemas { // Next make sure the refs point to other schemas, if not already done. - for _, propertyRef := range schemaRef.Value.Properties { + for propertyName, propertyRef := range schemaRef.Value.Properties { if strings.Contains(propertyRef.Ref, schemaPath) { continue } + if schemaName == "SearchResponse" && propertyName == "Matches" { + fmt.Println("got here") + } + if isBasic(propertyRef.Value.Type) { propertyRef.Ref = "" + firedHandlers["basic handler"] += firedHandlers["basic handler"] } else if propertyRef.Value.Type == "array" { propertyRef.Value.Items.Ref = formatSchemaRefPath(propertyRef.Value.Items, propertyRef.Value.Items.Ref) + firedHandlers["array handler"] += firedHandlers["array handler"] } else if propertyRef.Value.AdditionalProperties != nil { // This handles maps - if len(propertyRef.Value.AdditionalProperties.Ref) != 0 { - propertyRef.Value.AdditionalProperties.Ref = formatSchemaRefPath(propertyRef.Value.AdditionalProperties, propertyRef.Value.AdditionalProperties.Ref) - } else if propertyRef.Value.AdditionalProperties.Value.Type == "array" { - propertyRef.Value.AdditionalProperties.Value.Items.Ref = formatSchemaRefPath(propertyRef.Value.AdditionalProperties, propertyRef.Value.AdditionalProperties.Value.Items.Ref) - } else if len(propertyRef.Ref) != 0 { + // If the property has a ref, then format it. + if len(propertyRef.Ref) != 0 { propertyRef.Ref = formatSchemaRefPath(propertyRef, propertyRef.Ref) + firedHandlers["map set set property ref handler"] += firedHandlers["map set set property ref handler"] + } + + // TODO: Keeping this previous version until we prove this empty string check removal from isBasic is valid. + // isBasic(propertyRef.Value.AdditionalProperties.Ref) && propertyRef.Value.AdditionalProperties.Ref != "" { + // if the map element is for a basic type, clear it so that built in types are handled. + if isBasic(propertyRef.Value.AdditionalProperties.Ref) { + propertyRef.Value.AdditionalProperties.Ref = "" + firedHandlers["map basic handler"] += firedHandlers["map basic handler"] + } else if propertyRef.Value.AdditionalProperties.Value.Type == "object" { + // Handle mapping of map of maps. + if isBasic(propertyRef.Value.AdditionalProperties.Ref) { + propertyRef.Value.AdditionalProperties.Value.Type = propertyRef.Value.AdditionalProperties.Ref + propertyRef.Value.AdditionalProperties.Ref = "" + firedHandlers["map clear embedded map basic handler"] += firedHandlers["map clear embedded map basic handler"] + } else { + propertyRef.Value.AdditionalProperties.Ref = formatSchemaRefPath(propertyRef.Value.AdditionalProperties, propertyRef.Value.AdditionalProperties.Ref) + firedHandlers["map set embedded map complex handler"] += firedHandlers["map set embedded map complex handler"] + } + } else if propertyRef.Value.AdditionalProperties.Value.Type == "array" { + if isBasic(propertyRef.Value.AdditionalProperties.Value.Items.Ref) { + propertyRef.Value.AdditionalProperties.Value.Items.Value.Type = propertyRef.Value.AdditionalProperties.Value.Items.Ref + propertyRef.Value.AdditionalProperties.Value.Items.Ref = "" + firedHandlers["map clear embedded array basic handler"] += firedHandlers["map clear embedded array basic handler"] + } else { + propertyRef.Value.AdditionalProperties.Value.Items.Ref = formatSchemaRefPath(propertyRef.Value.AdditionalProperties, propertyRef.Value.AdditionalProperties.Value.Items.Ref) + firedHandlers["map set embedded array complex handler"] += firedHandlers["map set embedded array complex handler"] + } + } else if len(propertyRef.Value.AdditionalProperties.Ref) != 0 { + propertyRef.Value.AdditionalProperties.Ref = fmt.Sprintf("#/components/schemas/%s", propertyRef.Value.AdditionalProperties.Ref) + firedHandlers["map set embedded map ref handler"] += firedHandlers["map set embedded map ref handler"] } } else { propertyRef.Ref = formatSchemaRefPath(propertyRef, propertyRef.Ref) + firedHandlers["set property ref handler"] += firedHandlers["set property ref handler"] } } } + + for handler, count := range firedHandlers { + fmt.Println(handler + ": " + fmt.Sprint(count)) + } } func isBasic(typ string) bool { - return typ == "" || typ == "integer" || typ == "number" || typ == "string" || typ == "boolean" || typ == "bool" + return typ == "integer" || typ == "number" || typ == "string" || typ == "boolean" || typ == "bool" + // TODO: Keeping this previous version until we prove that removing the empty string check is valid. + // return typ == "" || typ == "integer" || typ == "number" || typ == "string" || typ == "boolean" || typ == "bool" } func formatSchemaRefPath(ref *openapi3.SchemaRef, modelName string) string { diff --git a/generator/specbuilder_test.go b/generator/specbuilder_test.go index c1198c80..b94cda13 100644 --- a/generator/specbuilder_test.go +++ b/generator/specbuilder_test.go @@ -68,6 +68,7 @@ func TestSchemaRefs(t *testing.T) { var jobResponseSchema = ` JobRegisterResponse: + nullable: true properties: EvalCreateIndex: maximum: 1.8446744073709552e+19 @@ -88,6 +89,8 @@ var jobResponseSchema = ` maximum: 1.8446744073709552e+19 minimum: 0 type: integer + NextToken: + type: string RequestTime: format: int64 type: integer diff --git a/snippets/query-endpoint.txt b/snippets/query-endpoint.txt index 11eadf77..3024082c 100644 --- a/snippets/query-endpoint.txt +++ b/snippets/query-endpoint.txt @@ -6,5 +6,5 @@ func (todo *TODO) GetTODO(ctx context.Context) (*client.TODO, *QueryMeta, error) } final := result.(client.TODO) - return &final, meta, nil -} \ No newline at end of file + return &final , meta, nil +} diff --git a/snippets/write-endpoint.txt b/snippets/write-endpoint.txt index 8a33dbe4..430bb647 100644 --- a/snippets/write-endpoint.txt +++ b/snippets/write-endpoint.txt @@ -6,5 +6,5 @@ func (todo *TODO) PostTODO(ctx context.Context) (*client.TODO, *WriteMeta, error } final := result.(client.TODO) - return &final, meta, nil -} \ No newline at end of file + return &final , meta, nil +} diff --git a/v1/acl.go b/v1/acl.go index ca50c312..1fc63dad 100644 --- a/v1/acl.go +++ b/v1/acl.go @@ -43,8 +43,8 @@ func (a *ACL) GetPolicy(ctx context.Context, policyName string) (*client.ACLPoli return nil, nil, err } - final := result.(client.ACLPolicy) - return &final, meta, nil + final := result.(*client.ACLPolicy) + return final, meta, nil } // returns nilSchema @@ -88,8 +88,8 @@ func (a *ACL) OnetimeToken(ctx context.Context) (*client.OneTimeToken, *WriteMet return nil, nil, err } - final := result.(client.OneTimeToken) - return &final, meta, nil + final := result.(*client.OneTimeToken) + return final, meta, nil } func (a *ACL) Exchange(ctx context.Context) (*client.ACLToken, *WriteMeta, OpenAPIError) { @@ -99,8 +99,8 @@ func (a *ACL) Exchange(ctx context.Context) (*client.ACLToken, *WriteMeta, OpenA return nil, nil, err } - final := result.(client.ACLToken) - return &final, meta, nil + final := result.(*client.ACLToken) + return final, meta, nil } func (a *ACL) Bootstrap(ctx context.Context) (*client.ACLToken, *WriteMeta, OpenAPIError) { @@ -110,8 +110,8 @@ func (a *ACL) Bootstrap(ctx context.Context) (*client.ACLToken, *WriteMeta, Open return nil, nil, err } - final := result.(client.ACLToken) - return &final, meta, nil + final := result.(*client.ACLToken) + return final, meta, nil } func (a *ACL) Tokens(ctx context.Context) (*[]client.ACLTokenListStub, *QueryMeta, OpenAPIError) { @@ -132,8 +132,8 @@ func (a *ACL) Self(ctx context.Context) (*client.ACLToken, *QueryMeta, OpenAPIEr return nil, nil, err } - final := result.(client.ACLToken) - return &final, meta, nil + final := result.(*client.ACLToken) + return final, meta, nil } func (a *ACL) GetToken(ctx context.Context, tokenAccessor string) (*client.ACLToken, *QueryMeta, OpenAPIError) { @@ -147,8 +147,8 @@ func (a *ACL) GetToken(ctx context.Context, tokenAccessor string) (*client.ACLTo return nil, nil, err } - final := result.(client.ACLToken) - return &final, meta, nil + final := result.(*client.ACLToken) + return final, meta, nil } func (a *ACL) SaveToken(ctx context.Context, token *client.ACLToken) (*client.ACLToken, *WriteMeta, OpenAPIError) { @@ -162,8 +162,8 @@ func (a *ACL) SaveToken(ctx context.Context, token *client.ACLToken) (*client.AC return nil, nil, err } - final := result.(client.ACLToken) - return &final, meta, nil + final := result.(*client.ACLToken) + return final, meta, nil } func (a *ACL) DeleteToken(ctx context.Context, tokenAccessor string) (*WriteMeta, OpenAPIError) { diff --git a/v1/allocations.go b/v1/allocations.go index a57eff7b..c02dad0b 100644 --- a/v1/allocations.go +++ b/v1/allocations.go @@ -39,8 +39,8 @@ func (a *Allocations) GetAllocation(ctx context.Context, allocID string) (*clien return nil, nil, err } - final := result.(client.Allocation) - return &final, meta, nil + final := result.(*client.Allocation) + return final, meta, nil } func (a *Allocations) StopAllocation(ctx context.Context, allocID string, noShutdownDelay bool) (*client.AllocStopResponse, *WriteMeta, OpenAPIError) { @@ -52,11 +52,10 @@ func (a *Allocations) StopAllocation(ctx context.Context, allocID string, noShut return nil, nil, err } - final := result.(client.AllocStopResponse) - return &final, meta, nil + final := result.(*client.AllocStopResponse) + return final, meta, nil } - func (a *Allocations) GetAllocationServices(ctx context.Context, allocID string) (*[]client.ServiceRegistration, *QueryMeta, OpenAPIError) { request := a.AllocationsApi().GetAllocationServices(a.client.Ctx, allocID) diff --git a/v1/allocations_test.go b/v1/allocations_test.go index 74d809a6..c48a8abd 100644 --- a/v1/allocations_test.go +++ b/v1/allocations_test.go @@ -57,7 +57,7 @@ func testGetAllocations(t *testing.T, s *agent.TestAgent) { require.NotNil(t, allocList) taskStates := *allocList[0].TaskStates require.NotNil(t, taskStates) - events := *taskStates["test"].Events + events := taskStates["test"].Events require.NotNil(t, events) displayMsg1 := *events[0].DisplayMessage require.Equal(t, expectedMsg, displayMsg1, "DisplayMessage should be set") diff --git a/v1/deployments.go b/v1/deployments.go index 88e4533d..9e8c90df 100644 --- a/v1/deployments.go +++ b/v1/deployments.go @@ -40,8 +40,8 @@ func (d *Deployments) GetDeployment(ctx context.Context, deploymentID string) (* return nil, nil, err } - final := result.(client.Deployment) - return &final, meta, nil + final := result.(*client.Deployment) + return final, meta, nil } func (d *Deployments) Allocations(ctx context.Context, deploymentID string) (*[]client.AllocationListStub, *QueryMeta, OpenAPIError) { @@ -70,8 +70,8 @@ func (d *Deployments) Fail(ctx context.Context, deploymentID string) (*client.De return nil, &APIError{error: err.Error()} } - final := result.(client.DeploymentUpdateResponse) - return &final, nil + final := result.(*client.DeploymentUpdateResponse) + return final, nil } func (d *Deployments) Pause(ctx context.Context, deploymentID string, pause bool) (*client.DeploymentUpdateResponse, OpenAPIError) { @@ -92,8 +92,8 @@ func (d *Deployments) Pause(ctx context.Context, deploymentID string, pause bool return nil, &APIError{error: err.Error()} } - final := result.(client.DeploymentUpdateResponse) - return &final, nil + final := result.(*client.DeploymentUpdateResponse) + return final, nil } func (d *Deployments) Promote(ctx context.Context, deploymentID string, all bool, groups []string) (*client.DeploymentUpdateResponse, OpenAPIError) { @@ -115,8 +115,8 @@ func (d *Deployments) Promote(ctx context.Context, deploymentID string, all bool return nil, &APIError{error: err.Error()} } - final := result.(client.DeploymentUpdateResponse) - return &final, nil + final := result.(*client.DeploymentUpdateResponse) + return final, nil } func (d *Deployments) AllocationHealth(ctx context.Context, deploymentID string, healthyallocs []string, unhealthyallocs []string) (*client.DeploymentUpdateResponse, OpenAPIError) { @@ -138,8 +138,8 @@ func (d *Deployments) AllocationHealth(ctx context.Context, deploymentID string, return nil, &APIError{error: err.Error()} } - final := result.(client.DeploymentUpdateResponse) - return &final, nil + final := result.(*client.DeploymentUpdateResponse) + return final, nil } func (d *Deployments) Unblock(ctx context.Context, deploymentID string) (*client.DeploymentUpdateResponse, OpenAPIError) { @@ -159,6 +159,6 @@ func (d *Deployments) Unblock(ctx context.Context, deploymentID string) (*client return nil, &APIError{error: err.Error()} } - final := result.(client.DeploymentUpdateResponse) - return &final, nil + final := result.(*client.DeploymentUpdateResponse) + return final, nil } diff --git a/v1/evaluations.go b/v1/evaluations.go index c55a8e7a..3a967e7d 100644 --- a/v1/evaluations.go +++ b/v1/evaluations.go @@ -40,8 +40,8 @@ func (e *Evaluations) GetEvaluation(ctx context.Context, evalID string) (*client return nil, nil, err } - final := result.(client.Evaluation) - return &final, meta, nil + final := result.(*client.Evaluation) + return final, meta, nil } func (e *Evaluations) Allocations(ctx context.Context, evalID string) (*[]client.AllocationListStub, *QueryMeta, OpenAPIError) { diff --git a/v1/jobs.go b/v1/jobs.go index cbe2d36e..e331c6a1 100644 --- a/v1/jobs.go +++ b/v1/jobs.go @@ -52,8 +52,8 @@ func (j *Jobs) Delete(ctx context.Context, jobName string, purge, global bool) ( return nil, nil, err } - final := result.(client.JobDeregisterResponse) - return &final, meta, nil + final := result.(*client.JobDeregisterResponse) + return final, meta, nil } func (j *Jobs) Deployment(ctx context.Context, jobName string) (*client.Deployment, *QueryMeta, OpenAPIError) { @@ -68,8 +68,8 @@ func (j *Jobs) Deployment(ctx context.Context, jobName string) (*client.Deployme return nil, nil, err } - final := result.(client.Deployment) - return &final, meta, nil + final := result.(*client.Deployment) + return final, meta, nil } func (j *Jobs) Deployments(ctx context.Context, jobName string) (*[]client.Deployment, *QueryMeta, OpenAPIError) { @@ -106,8 +106,8 @@ func (j *Jobs) Dispatch(ctx context.Context, jobName string, payload string, met return nil, nil, err } - final := result.(client.JobDispatchResponse) - return &final, writeMeta, nil + final := result.(*client.JobDispatchResponse) + return final, writeMeta, nil } func (j *Jobs) EnforceRegister(ctx context.Context, job *client.Job, modifyIndex uint64) (*client.JobRegisterResponse, *WriteMeta, OpenAPIError) { @@ -137,8 +137,8 @@ func (j *Jobs) Evaluate(ctx context.Context, jobName string, forceReschedule boo return nil, nil, err } - final := result.(client.JobRegisterResponse) - return &final, meta, nil + final := result.(*client.JobRegisterResponse) + return final, meta, nil } func (j *Jobs) GetJob(ctx context.Context, jobName string) (*client.Job, *QueryMeta, OpenAPIError) { @@ -153,8 +153,8 @@ func (j *Jobs) GetJob(ctx context.Context, jobName string) (*client.Job, *QueryM return nil, nil, err } - final := result.(client.Job) - return &final, meta, nil + final := result.(*client.Job) + return final, meta, nil } func (j *Jobs) GetJobs(ctx context.Context) (*[]client.JobListStub, *QueryMeta, OpenAPIError) { @@ -188,8 +188,8 @@ func (j *Jobs) Parse(ctx context.Context, hcl string, canonicalize, hclV1 bool) return nil, err } - final := result.(client.Job) - return &final, nil + final := result.(*client.Job) + return final, nil } type PlanOpts struct { @@ -209,8 +209,8 @@ func (j *Jobs) PeriodicForce(ctx context.Context, jobName string) (*client.Perio return nil, nil, err } - final := result.(client.PeriodicForceResponse) - return &final, meta, nil + final := result.(*client.PeriodicForceResponse) + return final, meta, nil } func (j *Jobs) Plan(ctx context.Context, job *client.Job, diff bool) (*client.JobPlanResponse, *WriteMeta, OpenAPIError) { @@ -233,8 +233,8 @@ func (j *Jobs) PlanOpts(ctx context.Context, job *client.Job, opts *PlanOpts) (* return nil, nil, err } - final := result.(client.JobPlanResponse) - return &final, meta, nil + final := result.(*client.JobPlanResponse) + return final, meta, nil } func (j *Jobs) Post(ctx context.Context, job *client.Job) (*client.JobRegisterResponse, *WriteMeta, OpenAPIError) { @@ -274,8 +274,8 @@ func (j *Jobs) Register(ctx context.Context, job *client.Job, registerOpts *Regi return nil, nil, err } - final := result.(client.JobRegisterResponse) - return &final, meta, nil + final := result.(*client.JobRegisterResponse) + return final, meta, nil } func (j *Jobs) Revert(ctx context.Context, jobName string, versionNumber, enforcePriorVersion int32, consulToken, vaultToken string) (*client.JobRegisterResponse, *WriteMeta, OpenAPIError) { @@ -308,8 +308,8 @@ func (j *Jobs) Revert(ctx context.Context, jobName string, versionNumber, enforc return nil, nil, err } - final := result.(client.JobRegisterResponse) - return &final, meta, nil + final := result.(*client.JobRegisterResponse) + return final, meta, nil } func (j *Jobs) Scale(ctx context.Context, jobName string, count int64, msg string, target map[string]string) (*client.JobRegisterResponse, *WriteMeta, OpenAPIError) { @@ -331,8 +331,8 @@ func (j *Jobs) Scale(ctx context.Context, jobName string, count int64, msg strin return nil, nil, err } - final := result.(client.JobRegisterResponse) - return &final, meta, nil + final := result.(*client.JobRegisterResponse) + return final, meta, nil } func (j *Jobs) ScaleStatus(ctx context.Context, jobName string) (*client.JobScaleStatusResponse, *QueryMeta, OpenAPIError) { @@ -347,8 +347,8 @@ func (j *Jobs) ScaleStatus(ctx context.Context, jobName string) (*client.JobScal return nil, nil, err } - final := result.(client.JobScaleStatusResponse) - return &final, meta, nil + final := result.(*client.JobScaleStatusResponse) + return final, meta, nil } func (j *Jobs) Stability(ctx context.Context, jobName string, versionNumber int32, stable bool) (*client.JobStabilityResponse, *WriteMeta, OpenAPIError) { @@ -370,8 +370,8 @@ func (j *Jobs) Stability(ctx context.Context, jobName string, versionNumber int3 return nil, nil, err } - final := result.(client.JobStabilityResponse) - return &final, meta, nil + final := result.(*client.JobStabilityResponse) + return final, meta, nil } func (j *Jobs) Summary(ctx context.Context, jobName string) (*client.JobSummary, *QueryMeta, OpenAPIError) { @@ -386,8 +386,8 @@ func (j *Jobs) Summary(ctx context.Context, jobName string) (*client.JobSummary, return nil, nil, err } - final := result.(client.JobSummary) - return &final, meta, nil + final := result.(*client.JobSummary) + return final, meta, nil } func (j *Jobs) Versions(ctx context.Context, jobName string, withDiffs bool) (*client.JobVersionsResponse, *QueryMeta, OpenAPIError) { @@ -402,8 +402,8 @@ func (j *Jobs) Versions(ctx context.Context, jobName string, withDiffs bool) (*c return nil, nil, err } - final := result.(client.JobVersionsResponse) - return &final, meta, nil + final := result.(*client.JobVersionsResponse) + return final, meta, nil } func (j *Jobs) GetLocation(job *client.Job) (*time.Location, error) { @@ -416,7 +416,7 @@ func (j *Jobs) GetLocation(job *client.Job) (*time.Location, error) { } func (j *Jobs) IsMultiRegion(job *client.Job) bool { - return job.Multiregion != nil && *job.Multiregion.Regions != nil && len(*job.Multiregion.Regions) > 0 + return job.Multiregion.IsSet() && job.Multiregion.Get().Regions != nil && len(job.Multiregion.Get().Regions) > 0 } func (j *Jobs) IsParameterized(job *client.Job) bool { @@ -424,7 +424,7 @@ func (j *Jobs) IsParameterized(job *client.Job) bool { if job.Dispatched != nil { dispatched = *job.Dispatched } - return job.ParameterizedJob != nil && !dispatched + return job.ParameterizedJob.IsSet() && !dispatched } func (j *Jobs) IsPeriodic(job *client.Job) bool { diff --git a/v1/jobs_test.go b/v1/jobs_test.go index 2f0f68fb..3d6bd6f4 100644 --- a/v1/jobs_test.go +++ b/v1/jobs_test.go @@ -141,8 +141,8 @@ func testJobParse(t *testing.T, s *agent.TestAgent) { require.Equal(t, *result.Name, *expected.Name) if result.Datacenters == nil { - expectedDatacenters := *expected.Datacenters - jobDatacenters := *result.Datacenters + expectedDatacenters := expected.Datacenters + jobDatacenters := result.Datacenters require.NotEqual(t, jobDatacenters[0], expectedDatacenters[0]) } } @@ -232,7 +232,7 @@ func testJobVersions(t *testing.T, s *agent.TestAgent) { require.NoError(t, err) require.NotNil(t, meta) - versions := *result.Versions + versions := result.Versions require.Len(t, versions, 2) v1 := versions[0] @@ -240,7 +240,7 @@ func testJobVersions(t *testing.T, s *agent.TestAgent) { require.Equal(t, int32(1), *v1.Version) require.Equal(t, int32(100), *v1.Priority) require.Equal(t, int32(0), *v0.Version) - require.Len(t, *result.Diffs, 1) + require.Len(t, result.Diffs, 1) } func testJobRevert(t *testing.T, s *agent.TestAgent) { @@ -253,9 +253,9 @@ func testJobRevert(t *testing.T, s *agent.TestAgent) { job, _, err := testClient.Jobs().GetJob(queryOpts.Ctx(), rpcJob.ID) require.NoError(t, err) - dcs := *job.Datacenters + dcs := job.Datacenters dcs = append(dcs, "foo") - job.Datacenters = &dcs + job.Datacenters = dcs _, _, err = testClient.Jobs().Post(writeOpts.Ctx(), job) require.NoError(t, err) @@ -492,6 +492,8 @@ func mockPeriodicJob() *client.Job { job := mockJob() batch := structs.JobTypeBatch job.Type = &batch + job.Update = nil + job.Migrate = nil enabled := true specType := structs.PeriodicSpecCron @@ -505,7 +507,7 @@ func mockPeriodicJob() *client.Job { } job.Status = &running - tg := *job.TaskGroups + tg := job.TaskGroups tg[0].Migrate = nil return job @@ -514,10 +516,10 @@ func mockPeriodicJob() *client.Job { func mockJobWithDiff() *client.Job { job := mockJob() - tgs := *job.TaskGroups - tgs[0].Tasks = &[]client.Task{ + tgs := job.TaskGroups + tgs[0].Tasks = []client.Task{ { - Config: &map[string]interface{}{ + Config: map[string]interface{}{ "image": "redis:3.4", "ports": []string{dbLabel}, }, @@ -532,107 +534,43 @@ func mockJobWithDiff() *client.Job { func mockJob() *client.Job { jobID := fmt.Sprintf("%s-%s", id, uuid.Generate()) return &client.Job{ - Region: &globalRegion, - ID: &jobID, - Name: &jobName, - Namespace: &defaultNamespace, - Type: &jobTypeService, - Priority: &priority, - AllAtOnce: &allAtOnce, - Datacenters: &[]string{"dc1"}, - Constraints: &[]client.Constraint{ - { - LTarget: &lTarget, - RTarget: &rTarget, - Operand: &operand, - }, - }, - TaskGroups: &[]client.TaskGroup{ - { - Name: &web, - Count: &count, - EphemeralDisk: &client.EphemeralDisk{ - SizeMB: &sizeMB, - }, - RestartPolicy: &client.RestartPolicy{ - Attempts: &restartPolicyAttempts, - Interval: &restartPolicyInterval, - Delay: &restartPolicyDelay, - Mode: &restartPolicyMode, - }, - ReschedulePolicy: &client.ReschedulePolicy{ - Attempts: &reschedulePolicyAttempts, - Interval: &reschedulePolicyInterval, - Delay: &reschedulePolicyDelay, - DelayFunction: &reschedulePolicyDelayFunction, - Unlimited: ¬Unlimited, - }, - Migrate: defaultMigrateStrategy, - Networks: &[]client.NetworkResource{ - { - Mode: &hostMode, - DynamicPorts: &[]client.Port{ - {Label: &httpLabel}, - {Label: &adminLabel}, - }, - }, - }, - Tasks: &[]client.Task{ - { - Name: &web, - Driver: &execDriver, - Config: &map[string]interface{}{ - "command": "/bin/date", - }, - Env: &map[string]string{ - "FOO": "bar", - }, - Services: &[]client.Service{ - { - Name: &frontEndTaskName, - PortLabel: &httpLabel, - Tags: &[]string{"pci:${meta.pci-dss}", "datacenter:${node.datacenter}"}, - Checks: &[]client.ServiceCheck{ - { - Name: &serviceCheckName, - Type: &serviceCheckType, - Command: &serviceCheckCommand, - Args: &[]string{"${meta.version}"}, - Interval: &serviceCheckInterval, - Timeout: &serviceCheckTimeout, - }, - }, - }, - { - Name: &adminTaskName, - PortLabel: &adminLabel, - }, - }, - LogConfig: defaultLogConfig, - Resources: &client.Resources{ - CPU: &resourcesCPU, - MemoryMB: &resourcesMemoryMB, - }, - Meta: &map[string]string{ - "foo": "bar", - }, - }, - }, - Meta: &map[string]string{ - "elb_check_type": "http", - "elb_check_interval": "30s", - "elb_check_min": "3", - }, - }, - }, - Meta: &map[string]string{ - "owner": "armon", - }, - Status: &pendingStatus, - Version: &version, - CreateIndex: &createIndex, - ModifyIndex: &modifyIndex, - JobModifyIndex: &jobModifyIndex, + Affinities: []client.Affinity{}, + AllAtOnce: &allAtOnce, + Constraints: []client.Constraint{{LTarget: &lTarget, RTarget: &rTarget, Operand: &operand}}, + ConsulNamespace: new(string), + ConsulToken: new(string), + CreateIndex: &createIndex, + Datacenters: []string{"dc1"}, + DispatchIdempotencyToken: new(string), + Dispatched: new(bool), + ID: &jobID, + JobModifyIndex: &jobModifyIndex, + Meta: &map[string]string{}, + Migrate: defaultMigrateStrategy, + ModifyIndex: &modifyIndex, + Multiregion: client.NullableMultiregion{}, + Name: &jobName, + Namespace: &defaultNamespace, + NomadTokenID: new(string), + ParameterizedJob: client.NullableParameterizedJobConfig{}, + ParentID: new(string), + Payload: new(string), + Periodic: nil, + Priority: &priority, + Region: &globalRegion, + Reschedule: &client.ReschedulePolicy{}, + Spreads: []client.Spread{}, + Stable: new(bool), + Status: &pendingStatus, + StatusDescription: new(string), + Stop: new(bool), + SubmitTime: new(int64), + TaskGroups: []client.TaskGroup{{Name: &web, Count: &count, EphemeralDisk: &client.EphemeralDisk{SizeMB: &sizeMB}, RestartPolicy: &client.RestartPolicy{Attempts: &restartPolicyAttempts, Interval: &restartPolicyInterval, Delay: &restartPolicyDelay, Mode: &restartPolicyMode}, ReschedulePolicy: &client.ReschedulePolicy{Attempts: &reschedulePolicyAttempts, Interval: &reschedulePolicyInterval, Delay: &reschedulePolicyDelay, DelayFunction: &reschedulePolicyDelayFunction, Unlimited: ¬Unlimited}, Migrate: defaultMigrateStrategy, Networks: []client.NetworkResource{{Mode: &hostMode, DynamicPorts: []client.Port{{Label: &httpLabel}, {Label: &adminLabel}}}}, Tasks: []client.Task{{Name: &web, Driver: &execDriver, Config: map[string]interface{}{"command": "/bin/date"}, Env: &map[string]string{"FOO": "bar"}, Services: []client.Service{{Name: &frontEndTaskName, PortLabel: &httpLabel, Tags: []string{"pci:${meta.pci-dss}", "datacenter:${node.datacenter}"}, Checks: []client.ServiceCheck{{Name: &serviceCheckName, Type: &serviceCheckType, Command: &serviceCheckCommand, Args: []string{"${meta.version}"}, Interval: &serviceCheckInterval, Timeout: &serviceCheckTimeout}}}, {Name: &adminTaskName, PortLabel: &adminLabel}}, LogConfig: defaultLogConfig, Resources: *client.NewNullableResources(&client.Resources{CPU: &resourcesCPU, MemoryMB: &resourcesMemoryMB}), Meta: &map[string]string{"foo": "bar"}}}, Meta: &map[string]string{"elb_check_type": "http", "elb_check_interval": "30s", "elb_check_min": "3"}}}, + Type: &jobTypeService, + Update: &client.UpdateStrategy{}, + VaultNamespace: new(string), + VaultToken: new(string), + Version: &version, } } diff --git a/v1/metrics.go b/v1/metrics.go index c7388b39..5d665cd8 100644 --- a/v1/metrics.go +++ b/v1/metrics.go @@ -26,6 +26,6 @@ func (m *Metrics) GetMetricsSummary(ctx context.Context) (*client.MetricsSummary return nil, err } - final := result.(client.MetricsSummary) - return &final, nil + final := result.(*client.MetricsSummary) + return final, nil } diff --git a/v1/metrics_test.go b/v1/metrics_test.go index 4bc0657d..d5466c48 100644 --- a/v1/metrics_test.go +++ b/v1/metrics_test.go @@ -31,5 +31,5 @@ func testMetrics(t *testing.T, s *agent.TestAgent) { result, err := testClient.Metrics().GetMetricsSummary(queryOpts.Ctx()) require.NoError(t, err) - require.NotEqual(t, 0, *result.Gauges) + require.NotEqual(t, 0, result.Gauges) } diff --git a/v1/namespaces.go b/v1/namespaces.go index 9bc343d7..928e4fa7 100644 --- a/v1/namespaces.go +++ b/v1/namespaces.go @@ -43,8 +43,8 @@ func (n *Namespaces) GetNamespace(ctx context.Context, name string) (*client.Nam return nil, nil, err } - final := result.(client.Namespace) - return &final, meta, nil + final := result.(*client.Namespace) + return final, meta, nil } func (n *Namespaces) GetNamespaces(ctx context.Context) (*[]client.Namespace, *QueryMeta, OpenAPIError) { diff --git a/v1/openapi.yaml b/v1/openapi.yaml index 6c88a168..fb4dffa2 100644 --- a/v1/openapi.yaml +++ b/v1/openapi.yaml @@ -1271,7 +1271,8 @@ components: content: application/json: schema: - items: {} + items: + $ref: '#/components/schemas/Quotas' type: array description: "" headers: @@ -1802,6 +1803,7 @@ components: description: "" schemas: ACLPolicy: + nullable: true properties: CreateIndex: maximum: 1.8446744073709552e+19 @@ -1819,6 +1821,7 @@ components: type: string type: object ACLPolicyListStub: + nullable: true properties: CreateIndex: maximum: 1.8446744073709552e+19 @@ -1834,6 +1837,7 @@ components: type: string type: object ACLToken: + nullable: true properties: AccessorID: type: string @@ -1843,6 +1847,7 @@ components: type: integer CreateTime: format: date-time + nullable: true type: string Global: type: boolean @@ -1862,6 +1867,7 @@ components: type: string type: object ACLTokenListStub: + nullable: true properties: AccessorID: type: string @@ -1871,6 +1877,7 @@ components: type: integer CreateTime: format: date-time + nullable: true type: string Global: type: boolean @@ -1888,6 +1895,7 @@ components: type: string type: object Affinity: + nullable: true properties: LTarget: type: string @@ -1901,6 +1909,7 @@ components: type: integer type: object AllocDeploymentStatus: + nullable: true properties: Canary: type: boolean @@ -1912,9 +1921,11 @@ components: type: integer Timestamp: format: date-time + nullable: true type: string type: object AllocStopResponse: + nullable: true properties: EvalID: type: string @@ -1924,12 +1935,14 @@ components: type: integer type: object AllocatedCpuResources: + nullable: true properties: CpuShares: format: int64 type: integer type: object AllocatedDeviceResource: + nullable: true properties: DeviceIDs: items: @@ -1943,6 +1956,7 @@ components: type: string type: object AllocatedMemoryResources: + nullable: true properties: MemoryMB: format: int64 @@ -1952,6 +1966,7 @@ components: type: integer type: object AllocatedResources: + nullable: true properties: Shared: $ref: '#/components/schemas/AllocatedSharedResources' @@ -1961,6 +1976,7 @@ components: type: object type: object AllocatedSharedResources: + nullable: true properties: DiskMB: format: int64 @@ -1975,6 +1991,7 @@ components: type: array type: object AllocatedTaskResources: + nullable: true properties: Cpu: $ref: '#/components/schemas/AllocatedCpuResources' @@ -1990,6 +2007,7 @@ components: type: array type: object Allocation: + nullable: true properties: AllocModifyIndex: maximum: 1.8446744073709552e+19 @@ -2075,6 +2093,7 @@ components: type: object type: object AllocationListStub: + nullable: true properties: AllocatedResources: $ref: '#/components/schemas/AllocatedResources' @@ -2140,31 +2159,32 @@ components: type: object type: object AllocationMetric: + nullable: true properties: AllocationTime: format: int64 type: integer ClassExhausted: additionalProperties: - type: integer + $ref: '#/components/schemas/int' type: object ClassFiltered: additionalProperties: - type: integer + $ref: '#/components/schemas/int' type: object CoalescedFailures: type: integer ConstraintFiltered: additionalProperties: - type: integer + $ref: '#/components/schemas/int' type: object DimensionExhausted: additionalProperties: - type: integer + $ref: '#/components/schemas/int' type: object NodesAvailable: additionalProperties: - type: integer + $ref: '#/components/schemas/int' type: object NodesEvaluated: type: integer @@ -2186,11 +2206,11 @@ components: type: array Scores: additionalProperties: - format: double - type: number + $ref: '#/components/schemas/float64' type: object type: object Attribute: + nullable: true properties: Bool: type: boolean @@ -2206,6 +2226,7 @@ components: type: string type: object AutopilotConfiguration: + nullable: true properties: CleanupDeadServers: type: boolean @@ -2236,6 +2257,7 @@ components: type: string type: object CSIControllerInfo: + nullable: true properties: SupportsAttachDetach: type: boolean @@ -2263,6 +2285,7 @@ components: type: boolean type: object CSIInfo: + nullable: true properties: AllocID: type: string @@ -2282,9 +2305,11 @@ components: type: boolean UpdateTime: format: date-time + nullable: true type: string type: object CSIMountOptions: + nullable: true properties: FSType: type: string @@ -2294,6 +2319,7 @@ components: type: array type: object CSINodeInfo: + nullable: true properties: AccessibleTopology: $ref: '#/components/schemas/CSITopology' @@ -2312,6 +2338,7 @@ components: type: boolean type: object CSIPlugin: + nullable: true properties: Allocations: items: @@ -2351,6 +2378,7 @@ components: type: string type: object CSIPluginListStub: + nullable: true properties: ControllerRequired: type: boolean @@ -2382,6 +2410,7 @@ components: type: string type: object CSISnapshot: + nullable: true properties: CreateTime: format: int64 @@ -2409,6 +2438,7 @@ components: type: string type: object CSISnapshotCreateRequest: + nullable: true properties: Namespace: type: string @@ -2422,6 +2452,7 @@ components: type: array type: object CSISnapshotCreateResponse: + nullable: true properties: KnownLeader: type: boolean @@ -2443,6 +2474,7 @@ components: type: array type: object CSISnapshotListResponse: + nullable: true properties: KnownLeader: type: boolean @@ -2464,6 +2496,7 @@ components: type: array type: object CSITopology: + nullable: true properties: Segments: additionalProperties: @@ -2471,6 +2504,7 @@ components: type: object type: object CSITopologyRequest: + nullable: true properties: Preferred: items: @@ -2482,6 +2516,7 @@ components: type: array type: object CSIVolume: + nullable: true properties: AccessMode: type: string @@ -2556,6 +2591,7 @@ components: $ref: '#/components/schemas/CSITopologyRequest' ResourceExhausted: format: date-time + nullable: true type: string Schedulable: type: boolean @@ -2577,6 +2613,7 @@ components: CSIVolumeAttachmentMode: type: string CSIVolumeCapability: + nullable: true properties: AccessMode: type: string @@ -2584,6 +2621,7 @@ components: type: string type: object CSIVolumeCreateRequest: + nullable: true properties: Namespace: type: string @@ -2597,6 +2635,7 @@ components: type: array type: object CSIVolumeExternalStub: + nullable: true properties: CapacityBytes: format: int64 @@ -2621,6 +2660,7 @@ components: type: object type: object CSIVolumeListExternalResponse: + nullable: true properties: NextToken: type: string @@ -2630,6 +2670,7 @@ components: type: array type: object CSIVolumeListStub: + nullable: true properties: AccessMode: type: string @@ -2667,6 +2708,7 @@ components: type: string ResourceExhausted: format: date-time + nullable: true type: string Schedulable: type: boolean @@ -2676,6 +2718,7 @@ components: type: array type: object CSIVolumeRegisterRequest: + nullable: true properties: Namespace: type: string @@ -2689,6 +2732,7 @@ components: type: array type: object CheckRestart: + nullable: true properties: Grace: format: int64 @@ -2699,6 +2743,7 @@ components: type: integer type: object Constraint: + nullable: true properties: LTarget: type: string @@ -2708,11 +2753,13 @@ components: type: string type: object Consul: + nullable: true properties: Namespace: type: string type: object ConsulConnect: + nullable: true properties: Gateway: $ref: '#/components/schemas/ConsulGateway' @@ -2724,6 +2771,7 @@ components: $ref: '#/components/schemas/SidecarTask' type: object ConsulExposeConfig: + nullable: true properties: Path: items: @@ -2731,6 +2779,7 @@ components: type: array type: object ConsulExposePath: + nullable: true properties: ListenerPort: type: string @@ -2745,13 +2794,15 @@ components: properties: Ingress: $ref: '#/components/schemas/ConsulIngressConfigEntry' - Mesh: {} + Mesh: + $ref: '#/components/schemas/ConsulMeshConfigEntry' Proxy: $ref: '#/components/schemas/ConsulGatewayProxy' Terminating: $ref: '#/components/schemas/ConsulTerminatingConfigEntry' type: object ConsulGatewayBindAddress: + nullable: true properties: Address: type: string @@ -2761,6 +2812,7 @@ components: type: integer type: object ConsulGatewayProxy: + nullable: true properties: Config: additionalProperties: {} @@ -2780,6 +2832,7 @@ components: type: boolean type: object ConsulGatewayTLSConfig: + nullable: true properties: CipherSuites: items: @@ -2793,6 +2846,7 @@ components: type: string type: object ConsulIngressConfigEntry: + nullable: true properties: Listeners: items: @@ -2802,6 +2856,7 @@ components: $ref: '#/components/schemas/ConsulGatewayTLSConfig' type: object ConsulIngressListener: + nullable: true properties: Port: type: integer @@ -2813,6 +2868,7 @@ components: type: array type: object ConsulIngressService: + nullable: true properties: Hosts: items: @@ -2822,6 +2878,7 @@ components: type: string type: object ConsulLinkedService: + nullable: true properties: CAFile: type: string @@ -2836,11 +2893,13 @@ components: type: object ConsulMeshConfigEntry: {} ConsulMeshGateway: + nullable: true properties: Mode: type: string type: object ConsulProxy: + nullable: true properties: Config: additionalProperties: {} @@ -2857,6 +2916,7 @@ components: type: array type: object ConsulSidecarService: + nullable: true properties: DisableDefaultTCPCheck: type: boolean @@ -2870,6 +2930,7 @@ components: type: array type: object ConsulTerminatingConfigEntry: + nullable: true properties: Services: items: @@ -2877,6 +2938,7 @@ components: type: array type: object ConsulUpstream: + nullable: true properties: Datacenter: type: string @@ -2894,6 +2956,7 @@ components: Context: type: string DNSConfig: + nullable: true properties: Options: items: @@ -2909,6 +2972,7 @@ components: type: array type: object Deployment: + nullable: true properties: CreateIndex: maximum: 1.8446744073709552e+19 @@ -2952,6 +3016,7 @@ components: type: object type: object DeploymentAllocHealthRequest: + nullable: true properties: DeploymentID: type: string @@ -2971,6 +3036,7 @@ components: type: array type: object DeploymentPauseRequest: + nullable: true properties: DeploymentID: type: string @@ -2984,6 +3050,7 @@ components: type: string type: object DeploymentPromoteRequest: + nullable: true properties: All: type: boolean @@ -3001,6 +3068,7 @@ components: type: string type: object DeploymentState: + nullable: true properties: AutoRevert: type: boolean @@ -3023,11 +3091,13 @@ components: type: boolean RequireProgressBy: format: date-time + nullable: true type: string UnhealthyAllocs: type: integer type: object DeploymentUnblockRequest: + nullable: true properties: DeploymentID: type: string @@ -3039,6 +3109,7 @@ components: type: string type: object DeploymentUpdateResponse: + nullable: true properties: DeploymentModifyIndex: maximum: 1.8446744073709552e+19 @@ -3070,6 +3141,7 @@ components: type: boolean type: object DesiredUpdates: + nullable: true properties: Canary: maximum: 1.8446744073709552e+19 @@ -3105,11 +3177,13 @@ components: type: integer type: object DispatchPayloadConfig: + nullable: true properties: File: type: string type: object DrainMetadata: + nullable: true properties: AccessorID: type: string @@ -3119,14 +3193,17 @@ components: type: object StartedAt: format: date-time + nullable: true type: string Status: type: string UpdatedAt: format: date-time + nullable: true type: string type: object DrainSpec: + nullable: true properties: Deadline: format: int64 @@ -3137,20 +3214,24 @@ components: DrainStatus: type: string DrainStrategy: + nullable: true properties: Deadline: format: int64 type: integer ForceDeadline: format: date-time + nullable: true type: string IgnoreSystemJobs: type: boolean StartedAt: format: date-time + nullable: true type: string type: object DriverInfo: + nullable: true properties: Attributes: additionalProperties: @@ -3164,6 +3245,7 @@ components: type: boolean UpdateTime: format: date-time + nullable: true type: string type: object Duration: @@ -3179,11 +3261,13 @@ components: type: boolean type: object EvalOptions: + nullable: true properties: ForceReschedule: type: boolean type: object Evaluation: + nullable: true properties: AnnotatePlan: type: boolean @@ -3239,7 +3323,7 @@ components: type: integer QueuedAllocations: additionalProperties: - type: integer + $ref: '#/components/schemas/int' type: object QuotaLimitReached: type: string @@ -3264,9 +3348,11 @@ components: type: integer WaitUntil: format: date-time + nullable: true type: string type: object EvaluationStub: + nullable: true properties: BlockedEval: type: string @@ -3310,9 +3396,11 @@ components: type: string WaitUntil: format: date-time + nullable: true type: string type: object FieldDiff: + nullable: true properties: Annotations: items: @@ -3328,6 +3416,7 @@ components: type: string type: object FuzzyMatch: + nullable: true properties: ID: type: string @@ -3337,6 +3426,7 @@ components: type: array type: object FuzzySearchRequest: + nullable: true properties: AllowStale: type: boolean @@ -3378,6 +3468,7 @@ components: type: integer type: object FuzzySearchResponse: + nullable: true properties: KnownLeader: type: boolean @@ -3405,6 +3496,7 @@ components: type: object type: object GaugeValue: + nullable: true properties: Labels: additionalProperties: @@ -3417,6 +3509,7 @@ components: type: number type: object HostNetworkInfo: + nullable: true properties: CIDR: type: string @@ -3428,6 +3521,7 @@ components: type: string type: object HostVolumeInfo: + nullable: true properties: Path: type: string @@ -3435,6 +3529,7 @@ components: type: boolean type: object Job: + nullable: true properties: Affinities: items: @@ -3534,6 +3629,7 @@ components: type: integer type: object JobChildrenSummary: + nullable: true properties: Dead: format: int64 @@ -3546,6 +3642,7 @@ components: type: integer type: object JobDeregisterResponse: + nullable: true properties: EvalCreateIndex: maximum: 1.8446744073709552e+19 @@ -3573,6 +3670,7 @@ components: type: integer type: object JobDiff: + nullable: true properties: Fields: items: @@ -3592,6 +3690,7 @@ components: type: string type: object JobDispatchRequest: + nullable: true properties: JobID: type: string @@ -3604,6 +3703,7 @@ components: type: string type: object JobDispatchResponse: + nullable: true properties: DispatchedJobID: type: string @@ -3626,6 +3726,7 @@ components: type: integer type: object JobEvaluateRequest: + nullable: true properties: EvalOptions: $ref: '#/components/schemas/EvalOptions' @@ -3639,6 +3740,7 @@ components: type: string type: object JobListStub: + nullable: true properties: CreateIndex: maximum: 1.8446744073709552e+19 @@ -3685,6 +3787,7 @@ components: type: string type: object JobPlanRequest: + nullable: true properties: Diff: type: boolean @@ -3700,6 +3803,7 @@ components: type: string type: object JobPlanResponse: + nullable: true properties: Annotations: $ref: '#/components/schemas/PlanAnnotations' @@ -3719,11 +3823,13 @@ components: type: integer NextPeriodicLaunch: format: date-time + nullable: true type: string Warnings: type: string type: object JobRegisterRequest: + nullable: true properties: EnforceIndex: type: boolean @@ -3747,6 +3853,7 @@ components: type: string type: object JobRegisterResponse: + nullable: true properties: EvalCreateIndex: maximum: 1.8446744073709552e+19 @@ -3776,6 +3883,7 @@ components: type: string type: object JobRevertRequest: + nullable: true properties: ConsulToken: type: string @@ -3799,6 +3907,7 @@ components: type: string type: object JobScaleStatusResponse: + nullable: true properties: JobCreateIndex: maximum: 1.8446744073709552e+19 @@ -3820,6 +3929,7 @@ components: type: object type: object JobStabilityRequest: + nullable: true properties: JobID: type: string @@ -3837,6 +3947,7 @@ components: type: boolean type: object JobStabilityResponse: + nullable: true properties: Index: maximum: 1.8446744073709552e+19 @@ -3844,6 +3955,7 @@ components: type: integer type: object JobSummary: + nullable: true properties: Children: $ref: '#/components/schemas/JobChildrenSummary' @@ -3865,6 +3977,7 @@ components: type: object type: object JobValidateRequest: + nullable: true properties: Job: $ref: '#/components/schemas/Job' @@ -3876,6 +3989,7 @@ components: type: string type: object JobValidateResponse: + nullable: true properties: DriverConfigValidated: type: boolean @@ -3889,6 +4003,7 @@ components: type: string type: object JobVersionsResponse: + nullable: true properties: Diffs: items: @@ -3914,6 +4029,7 @@ components: type: array type: object JobsParseRequest: + nullable: true properties: Canonicalize: type: boolean @@ -3930,6 +4046,7 @@ components: type: integer type: object MetricsSummary: + nullable: true properties: Counters: items: @@ -3964,6 +4081,7 @@ components: type: integer type: object Multiregion: + nullable: true properties: Regions: items: @@ -3973,6 +4091,7 @@ components: $ref: '#/components/schemas/MultiregionStrategy' type: object MultiregionRegion: + nullable: true properties: Count: type: integer @@ -3995,6 +4114,7 @@ components: type: string type: object Namespace: + nullable: true properties: Capabilities: $ref: '#/components/schemas/NamespaceCapabilities' @@ -4018,6 +4138,7 @@ components: type: string type: object NamespaceCapabilities: + nullable: true properties: DisabledTaskDrivers: items: @@ -4029,6 +4150,7 @@ components: type: array type: object NetworkResource: + nullable: true properties: CIDR: type: string @@ -4054,6 +4176,7 @@ components: type: array type: object Node: + nullable: true properties: Attributes: additionalProperties: @@ -4138,6 +4261,7 @@ components: type: boolean type: object NodeCpuResources: + nullable: true properties: CpuShares: format: int64 @@ -4154,6 +4278,7 @@ components: type: integer type: object NodeDevice: + nullable: true properties: HealthDescription: type: string @@ -4165,11 +4290,13 @@ components: $ref: '#/components/schemas/NodeDeviceLocality' type: object NodeDeviceLocality: + nullable: true properties: PciBusID: type: string type: object NodeDeviceResource: + nullable: true properties: Attributes: additionalProperties: @@ -4187,12 +4314,14 @@ components: type: string type: object NodeDiskResources: + nullable: true properties: DiskMB: format: int64 type: integer type: object NodeDrainUpdateResponse: + nullable: true properties: EvalCreateIndex: maximum: 1.8446744073709552e+19 @@ -4215,6 +4344,7 @@ components: type: integer type: object NodeEligibilityUpdateResponse: + nullable: true properties: EvalCreateIndex: maximum: 1.8446744073709552e+19 @@ -4237,6 +4367,7 @@ components: type: integer type: object NodeEvent: + nullable: true properties: CreateIndex: maximum: 1.8446744073709552e+19 @@ -4252,9 +4383,11 @@ components: type: string Timestamp: format: date-time + nullable: true type: string type: object NodeListStub: + nullable: true properties: Address: type: string @@ -4300,12 +4433,14 @@ components: type: string type: object NodeMemoryResources: + nullable: true properties: MemoryMB: format: int64 type: integer type: object NodePurgeResponse: + nullable: true properties: EvalCreateIndex: maximum: 1.8446744073709552e+19 @@ -4321,6 +4456,7 @@ components: type: integer type: object NodeReservedCpuResources: + nullable: true properties: CpuShares: maximum: 1.8446744073709552e+19 @@ -4328,6 +4464,7 @@ components: type: integer type: object NodeReservedDiskResources: + nullable: true properties: DiskMB: maximum: 1.8446744073709552e+19 @@ -4335,6 +4472,7 @@ components: type: integer type: object NodeReservedMemoryResources: + nullable: true properties: MemoryMB: maximum: 1.8446744073709552e+19 @@ -4342,11 +4480,13 @@ components: type: integer type: object NodeReservedNetworkResources: + nullable: true properties: ReservedHostPorts: type: string type: object NodeReservedResources: + nullable: true properties: Cpu: $ref: '#/components/schemas/NodeReservedCpuResources' @@ -4358,6 +4498,7 @@ components: $ref: '#/components/schemas/NodeReservedNetworkResources' type: object NodeResources: + nullable: true properties: Cpu: $ref: '#/components/schemas/NodeCpuResources' @@ -4379,6 +4520,7 @@ components: type: array type: object NodeScoreMeta: + nullable: true properties: NodeID: type: string @@ -4387,11 +4529,11 @@ components: type: number Scores: additionalProperties: - format: double - type: number + $ref: '#/components/schemas/float64' type: object type: object NodeUpdateDrainRequest: + nullable: true properties: DrainSpec: $ref: '#/components/schemas/DrainSpec' @@ -4405,6 +4547,7 @@ components: type: string type: object NodeUpdateEligibilityRequest: + nullable: true properties: Eligibility: type: string @@ -4412,6 +4555,7 @@ components: type: string type: object ObjectDiff: + nullable: true properties: Fields: items: @@ -4427,6 +4571,7 @@ components: type: string type: object OneTimeToken: + nullable: true properties: AccessorID: type: string @@ -4436,6 +4581,7 @@ components: type: integer ExpiresAt: format: date-time + nullable: true type: string ModifyIndex: maximum: 1.8446744073709552e+19 @@ -4445,11 +4591,13 @@ components: type: string type: object OneTimeTokenExchangeRequest: + nullable: true properties: OneTimeSecretID: type: string type: object OperatorHealthReply: + nullable: true properties: FailureTolerance: type: integer @@ -4461,6 +4609,7 @@ components: type: array type: object ParameterizedJobConfig: + nullable: true properties: MetaOptional: items: @@ -4487,6 +4636,7 @@ components: type: string type: object PeriodicForceResponse: + nullable: true properties: EvalCreateIndex: maximum: 1.8446744073709552e+19 @@ -4500,6 +4650,7 @@ components: type: integer type: object PlanAnnotations: + nullable: true properties: DesiredTGUpdates: additionalProperties: @@ -4511,6 +4662,7 @@ components: type: array type: object PointValue: + nullable: true properties: Name: type: string @@ -4521,6 +4673,7 @@ components: type: array type: object Port: + nullable: true properties: HostNetwork: type: string @@ -4532,6 +4685,7 @@ components: type: integer type: object PortMapping: + nullable: true properties: HostIP: type: string @@ -4543,6 +4697,7 @@ components: type: integer type: object PreemptionConfig: + nullable: true properties: BatchSchedulerEnabled: type: boolean @@ -4554,6 +4709,7 @@ components: type: boolean type: object QuotaLimit: + nullable: true properties: Hash: format: byte @@ -4564,6 +4720,7 @@ components: $ref: '#/components/schemas/Resources' type: object QuotaSpec: + nullable: true properties: CreateIndex: maximum: 1.8446744073709552e+19 @@ -4584,6 +4741,7 @@ components: type: object Quotas: {} RaftConfiguration: + nullable: true properties: Index: maximum: 1.8446744073709552e+19 @@ -4595,6 +4753,7 @@ components: type: array type: object RaftServer: + nullable: true properties: Address: type: string @@ -4610,6 +4769,7 @@ components: type: boolean type: object RequestedDevice: + nullable: true properties: Affinities: items: @@ -4627,6 +4787,7 @@ components: type: string type: object RescheduleEvent: + nullable: true properties: PrevAllocID: type: string @@ -4655,6 +4816,7 @@ components: type: boolean type: object RescheduleTracker: + nullable: true properties: Events: items: @@ -4662,6 +4824,7 @@ components: type: array type: object Resources: + nullable: true properties: CPU: type: integer @@ -4698,6 +4861,7 @@ components: type: string type: object SampledValue: + nullable: true properties: Count: type: integer @@ -4727,6 +4891,7 @@ components: type: number type: object ScalingEvent: + nullable: true properties: Count: format: int64 @@ -4753,6 +4918,7 @@ components: type: integer type: object ScalingPolicy: + nullable: true properties: CreateIndex: maximum: 1.8446744073709552e+19 @@ -4785,6 +4951,7 @@ components: type: string type: object ScalingPolicyListStub: + nullable: true properties: CreateIndex: maximum: 1.8446744073709552e+19 @@ -4806,6 +4973,7 @@ components: type: string type: object ScalingRequest: + nullable: true properties: Count: format: int64 @@ -4833,6 +5001,7 @@ components: SchedulerAlgorithm: type: string SchedulerConfiguration: + nullable: true properties: CreateIndex: maximum: 1.8446744073709552e+19 @@ -4854,6 +5023,7 @@ components: type: string type: object SchedulerConfigurationResponse: + nullable: true properties: KnownLeader: type: boolean @@ -4873,6 +5043,7 @@ components: $ref: '#/components/schemas/SchedulerConfiguration' type: object SchedulerSetConfigurationResponse: + nullable: true properties: LastIndex: maximum: 1.8446744073709552e+19 @@ -4885,6 +5056,7 @@ components: type: boolean type: object SearchRequest: + nullable: true properties: AllowStale: type: boolean @@ -4924,6 +5096,7 @@ components: type: integer type: object SearchResponse: + nullable: true properties: KnownLeader: type: boolean @@ -4951,6 +5124,7 @@ components: type: object type: object ServerHealth: + nullable: true properties: Address: type: string @@ -4977,6 +5151,7 @@ components: type: string StableSince: format: date-time + nullable: true type: string Version: type: string @@ -4984,6 +5159,7 @@ components: type: boolean type: object Service: + nullable: true properties: Address: type: string @@ -5031,6 +5207,7 @@ components: type: string type: object ServiceCheck: + nullable: true properties: AddressMode: type: string @@ -5090,6 +5267,7 @@ components: type: string type: object ServiceRegistration: + nullable: true properties: Address: type: string @@ -5123,6 +5301,7 @@ components: type: array type: object SidecarTask: + nullable: true properties: Config: additionalProperties: {} @@ -5155,6 +5334,7 @@ components: type: string type: object Spread: + nullable: true properties: Attribute: type: string @@ -5168,6 +5348,7 @@ components: type: integer type: object SpreadTarget: + nullable: true properties: Percent: maximum: 255 @@ -5177,6 +5358,7 @@ components: type: string type: object Task: + nullable: true properties: Affinities: items: @@ -5251,6 +5433,7 @@ components: type: array type: object TaskArtifact: + nullable: true properties: GetterHeaders: additionalProperties: @@ -5268,6 +5451,7 @@ components: type: string type: object TaskCSIPluginConfig: + nullable: true properties: HealthTimeout: format: int64 @@ -5280,6 +5464,7 @@ components: type: string type: object TaskDiff: + nullable: true properties: Annotations: items: @@ -5299,6 +5484,7 @@ components: type: string type: object TaskEvent: + nullable: true properties: Details: additionalProperties: @@ -5359,6 +5545,7 @@ components: type: string type: object TaskGroup: + nullable: true properties: Affinities: items: @@ -5421,6 +5608,7 @@ components: type: object type: object TaskGroupDiff: + nullable: true properties: Fields: items: @@ -5440,12 +5628,11 @@ components: type: string Updates: additionalProperties: - maximum: 1.8446744073709552e+19 - minimum: 0 - type: integer + $ref: '#/components/schemas/uint64' type: object type: object TaskGroupScaleStatus: + nullable: true properties: Desired: type: integer @@ -5463,6 +5650,7 @@ components: type: integer type: object TaskGroupSummary: + nullable: true properties: Complete: type: integer @@ -5480,6 +5668,7 @@ components: type: integer type: object TaskHandle: + nullable: true properties: DriverState: format: byte @@ -5488,6 +5677,7 @@ components: type: integer type: object TaskLifecycle: + nullable: true properties: Hook: type: string @@ -5495,6 +5685,7 @@ components: type: boolean type: object TaskState: + nullable: true properties: Events: items: @@ -5504,9 +5695,11 @@ components: type: boolean FinishedAt: format: date-time + nullable: true type: string LastRestart: format: date-time + nullable: true type: string Restarts: maximum: 1.8446744073709552e+19 @@ -5514,6 +5707,7 @@ components: type: integer StartedAt: format: date-time + nullable: true type: string State: type: string @@ -5551,6 +5745,7 @@ components: type: object Time: format: date-time + nullable: true type: string UpdateStrategy: properties: @@ -5578,6 +5773,7 @@ components: type: integer type: object Vault: + nullable: true properties: ChangeMode: type: string @@ -5604,6 +5800,7 @@ components: type: string type: object VolumeRequest: + nullable: true properties: AccessMode: type: string diff --git a/v1/operator.go b/v1/operator.go index 2e944e61..4c8a35c5 100644 --- a/v1/operator.go +++ b/v1/operator.go @@ -26,8 +26,8 @@ func (o *Operator) Raft(ctx context.Context) (*client.RaftConfiguration, error) return nil, err } - final := result.(client.RaftConfiguration) - return &final, nil + final := result.(*client.RaftConfiguration) + return final, nil } func (o *Operator) Peer(ctx context.Context) error { @@ -49,8 +49,8 @@ func (o *Operator) Autopilot(ctx context.Context) (*client.AutopilotConfiguratio return nil, err } - final := result.(client.AutopilotConfiguration) - return &final, nil + final := result.(*client.AutopilotConfiguration) + return final, nil } func (o *Operator) UpdateAutopilot(ctx context.Context, config *client.AutopilotConfiguration) (*bool, error) { @@ -84,8 +84,8 @@ func (o *Operator) AutopilotHealth(ctx context.Context) (*client.OperatorHealthR return nil, err } - final := result.(client.OperatorHealthReply) - return &final, nil + final := result.(*client.OperatorHealthReply) + return final, nil } func (o *Operator) Scheduler(ctx context.Context) (*client.SchedulerConfigurationResponse, *QueryMeta, error) { @@ -96,8 +96,8 @@ func (o *Operator) Scheduler(ctx context.Context) (*client.SchedulerConfiguratio return nil, nil, err } - final := result.(client.SchedulerConfigurationResponse) - return &final, meta, nil + final := result.(*client.SchedulerConfigurationResponse) + return final, meta, nil } // TODO: update Nomad version to pick up new fields (i.e. RejectJobRegistration) @@ -107,7 +107,7 @@ func (o *Operator) UpdateScheduler(ctx context.Context, config *client.Scheduler updateRequest := client.NewSchedulerConfiguration() updateRequest.SetSchedulerAlgorithm(*config.SchedulerAlgorithm) updateRequest.SetMemoryOversubscriptionEnabled(*config.MemoryOversubscriptionEnabled) - updateRequest.SetPreemptionConfig(*config.PreemptionConfig) + updateRequest.SetPreemptionConfig(*config.PreemptionConfig.Get()) request = request.SchedulerConfiguration(*updateRequest) @@ -116,6 +116,6 @@ func (o *Operator) UpdateScheduler(ctx context.Context, config *client.Scheduler return nil, nil, err } - final := result.(client.SchedulerSetConfigurationResponse) - return &final, meta, nil + final := result.(*client.SchedulerSetConfigurationResponse) + return final, meta, nil } diff --git a/v1/operator_test.go b/v1/operator_test.go index f69cc4bc..9499e448 100644 --- a/v1/operator_test.go +++ b/v1/operator_test.go @@ -97,12 +97,12 @@ func testPostSchedulerConfiguration(t *testing.T, s *agent.TestAgent) { schedulerOpts := &client.SchedulerConfiguration{ SchedulerAlgorithm: helper.StringToPtr("spread"), MemoryOversubscriptionEnabled: helper.BoolToPtr(false), - PreemptionConfig: &client.PreemptionConfig{ + PreemptionConfig: *client.NewNullablePreemptionConfig(&client.PreemptionConfig{ BatchSchedulerEnabled: helper.BoolToPtr(true), ServiceSchedulerEnabled: helper.BoolToPtr(true), SysBatchSchedulerEnabled: helper.BoolToPtr(true), SystemSchedulerEnabled: helper.BoolToPtr(true), - }, + }), } result, meta, err := testClient.Operator().UpdateScheduler(writeOpts.Ctx(), schedulerOpts) diff --git a/v1/scaling.go b/v1/scaling.go index e5329518..728af5fb 100644 --- a/v1/scaling.go +++ b/v1/scaling.go @@ -40,6 +40,6 @@ func (s *Scaling) GetPolicy(ctx context.Context, policyID string) (*client.Scali return nil, nil, err } - final := result.(client.ScalingPolicy) - return &final, meta, nil + final := result.(*client.ScalingPolicy) + return final, meta, nil }