Skip to content

Commit

Permalink
Revert generated code
Browse files Browse the repository at this point in the history
Signed-off-by: Kim Pepper <[email protected]>
  • Loading branch information
kimpepper committed Nov 4, 2024
1 parent 7d2da2c commit 8c3b0f4
Show file tree
Hide file tree
Showing 215 changed files with 266 additions and 409 deletions.
1 change: 0 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
### Fixed
- Fixed PHP 8.4 deprecations
### Updated APIs
- Updated opensearch-php APIs to reflect [opensearch-api-specification@07e329e](https://github.com/opensearch-project/opensearch-api-specification/commit/07e329e8d01fd0576de6a0a3c35412fd5a9163db)
- Updated opensearch-php APIs to reflect [opensearch-api-specification@1db1840](https://github.com/opensearch-project/opensearch-api-specification/commit/1db184063a463c5180a2cc824b1efc1aeebfd5eb)
- Updated opensearch-php APIs to reflect [opensearch-api-specification@cb320b5](https://github.com/opensearch-project/opensearch-api-specification/commit/cb320b5482551c4f28afa26ff0d1653332699722)
### Security
Expand Down
14 changes: 0 additions & 14 deletions src/OpenSearch/Client.php
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,6 @@
use OpenSearch\Namespaces\SslNamespace;
use OpenSearch\Namespaces\TasksNamespace;
use OpenSearch\Namespaces\TransformsNamespace;
use OpenSearch\Namespaces\WlmNamespace;

/**
* Class Client
Expand Down Expand Up @@ -231,11 +230,6 @@ class Client
*/
protected $transforms;

/**
* @var WlmNamespace
*/
protected $wlm;


/**
* Client constructor
Expand Down Expand Up @@ -277,7 +271,6 @@ public function __construct(Transport $transport, callable $endpoint, array $reg
$this->ssl = new SslNamespace($transport, $endpoint);
$this->tasks = new TasksNamespace($transport, $endpoint);
$this->transforms = new TransformsNamespace($transport, $endpoint);
$this->wlm = new WlmNamespace($transport, $endpoint);

$this->registeredNamespaces = $registeredNamespaces;
}
Expand Down Expand Up @@ -1949,13 +1942,6 @@ public function transforms(): TransformsNamespace
{
return $this->transforms;
}
/**
* Returns the wlm namespace
*/
public function wlm(): WlmNamespace
{
return $this->wlm;
}

/**
* Catchall for registered namespaces
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch/Endpoints/AsynchronousSearch/Search.php
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ public function getMethod(): string
return 'POST';
}

public function setBody($body): static
public function setBody($body): Search
{
if (isset($body) !== true) {
return $this;
Expand Down
3 changes: 1 addition & 2 deletions src/OpenSearch/Endpoints/Bulk.php
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ public function getMethod(): string
return 'POST';
}

public function setBody($body): static
public function setBody($body): Bulk
{
if (isset($body) !== true) {
return $this;
Expand All @@ -89,5 +89,4 @@ public function setBody($body): static
}
return $this;
}

}
3 changes: 1 addition & 2 deletions src/OpenSearch/Endpoints/BulkStream.php
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ public function getMethod(): string
return 'PUT';
}

public function setBody($body): static
public function setBody($body): BulkStream
{
if (isset($body) !== true) {
return $this;
Expand All @@ -85,5 +85,4 @@ public function setBody($body): static
}
return $this;
}

}
2 changes: 1 addition & 1 deletion src/OpenSearch/Endpoints/Cat/Aliases.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ public function getMethod(): string
return 'GET';
}

public function setName($name): static
public function setName($name): Aliases
{
if (isset($name) !== true) {
return $this;
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch/Endpoints/Cat/Allocation.php
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ public function getMethod(): string
return 'GET';
}

public function setNodeId($node_id): static
public function setNodeId($node_id): Allocation
{
if (isset($node_id) !== true) {
return $this;
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch/Endpoints/Cat/Fielddata.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ public function getMethod(): string
return 'GET';
}

public function setFields($fields): static
public function setFields($fields): Fielddata
{
if (isset($fields) !== true) {
return $this;
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch/Endpoints/Cat/PitSegments.php
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ public function getMethod(): string
return 'GET';
}

public function setBody($body): static
public function setBody($body): PitSegments
{
if (isset($body) !== true) {
return $this;
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch/Endpoints/Cat/Snapshots.php
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ public function getMethod(): string
return 'GET';
}

public function setRepository($repository): static
public function setRepository($repository): Snapshots
{
if (isset($repository) !== true) {
return $this;
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch/Endpoints/Cat/Templates.php
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ public function getMethod(): string
return 'GET';
}

public function setName($name): static
public function setName($name): Templates
{
if (isset($name) !== true) {
return $this;
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch/Endpoints/Cat/ThreadPool.php
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ public function getMethod(): string
return 'GET';
}

public function setThreadPoolPatterns($thread_pool_patterns): static
public function setThreadPoolPatterns($thread_pool_patterns): ThreadPool
{
if (isset($thread_pool_patterns) !== true) {
return $this;
Expand Down
4 changes: 2 additions & 2 deletions src/OpenSearch/Endpoints/ClearScroll.php
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ public function getMethod(): string
return 'DELETE';
}

public function setBody($body): static
public function setBody($body): ClearScroll
{
if (isset($body) !== true) {
return $this;
Expand All @@ -69,7 +69,7 @@ public function setBody($body): static
return $this;
}

public function setScrollId($scroll_id): static
public function setScrollId($scroll_id): ClearScroll
{
if (isset($scroll_id) !== true) {
return $this;
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch/Endpoints/Cluster/AllocationExplain.php
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ public function getMethod(): string
return isset($this->body) ? 'POST' : 'GET';
}

public function setBody($body): static
public function setBody($body): AllocationExplain
{
if (isset($body) !== true) {
return $this;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ public function getMethod(): string
return 'DELETE';
}

public function setName($name): static
public function setName($name): DeleteComponentTemplate
{
if (isset($name) !== true) {
return $this;
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch/Endpoints/Cluster/DeleteWeightedRouting.php
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ public function getMethod(): string
return 'DELETE';
}

public function setBody($body): static
public function setBody($body): DeleteWeightedRouting
{
if (isset($body) !== true) {
return $this;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ public function getMethod(): string
return 'HEAD';
}

public function setName($name): static
public function setName($name): ExistsComponentTemplate
{
if (isset($name) !== true) {
return $this;
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch/Endpoints/Cluster/GetComponentTemplate.php
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ public function getMethod(): string
return 'GET';
}

public function setName($name): static
public function setName($name): GetComponentTemplate
{
if (isset($name) !== true) {
return $this;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ public function getMethod(): string
return 'GET';
}

public function setAwarenessAttributeName($awareness_attribute_name): static
public function setAwarenessAttributeName($awareness_attribute_name): GetDecommissionAwareness
{
if (isset($awareness_attribute_name) !== true) {
return $this;
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch/Endpoints/Cluster/GetWeightedRouting.php
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ public function getMethod(): string
return 'GET';
}

public function setAttribute($attribute): static
public function setAttribute($attribute): GetWeightedRouting
{
if (isset($attribute) !== true) {
return $this;
Expand Down
4 changes: 2 additions & 2 deletions src/OpenSearch/Endpoints/Cluster/PutComponentTemplate.php
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ public function getMethod(): string
return 'PUT';
}

public function setBody($body): static
public function setBody($body): PutComponentTemplate
{
if (isset($body) !== true) {
return $this;
Expand All @@ -70,7 +70,7 @@ public function setBody($body): static
return $this;
}

public function setName($name): static
public function setName($name): PutComponentTemplate
{
if (isset($name) !== true) {
return $this;
Expand Down
4 changes: 2 additions & 2 deletions src/OpenSearch/Endpoints/Cluster/PutDecommissionAwareness.php
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ public function getMethod(): string
return 'PUT';
}

public function setAwarenessAttributeName($awareness_attribute_name): static
public function setAwarenessAttributeName($awareness_attribute_name): PutDecommissionAwareness
{
if (isset($awareness_attribute_name) !== true) {
return $this;
Expand All @@ -62,7 +62,7 @@ public function setAwarenessAttributeName($awareness_attribute_name): static
return $this;
}

public function setAwarenessAttributeValue($awareness_attribute_value): static
public function setAwarenessAttributeValue($awareness_attribute_value): PutDecommissionAwareness
{
if (isset($awareness_attribute_value) !== true) {
return $this;
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch/Endpoints/Cluster/PutSettings.php
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ public function getMethod(): string
return 'PUT';
}

public function setBody($body): static
public function setBody($body): PutSettings
{
if (isset($body) !== true) {
return $this;
Expand Down
4 changes: 2 additions & 2 deletions src/OpenSearch/Endpoints/Cluster/PutWeightedRouting.php
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ public function getMethod(): string
return 'PUT';
}

public function setBody($body): static
public function setBody($body): PutWeightedRouting
{
if (isset($body) !== true) {
return $this;
Expand All @@ -60,7 +60,7 @@ public function setBody($body): static
return $this;
}

public function setAttribute($attribute): static
public function setAttribute($attribute): PutWeightedRouting
{
if (isset($attribute) !== true) {
return $this;
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch/Endpoints/Cluster/Reroute.php
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ public function getMethod(): string
return 'POST';
}

public function setBody($body): static
public function setBody($body): Reroute
{
if (isset($body) !== true) {
return $this;
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch/Endpoints/Cluster/State.php
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ public function getMethod(): string
return 'GET';
}

public function setMetric($metric): static
public function setMetric($metric): State
{
if (isset($metric) !== true) {
return $this;
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch/Endpoints/Cluster/Stats.php
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ public function getMethod(): string
return 'GET';
}

public function setNodeId($node_id): static
public function setNodeId($node_id): Stats
{
if (isset($node_id) !== true) {
return $this;
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch/Endpoints/Count.php
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ public function getMethod(): string
return isset($this->body) ? 'POST' : 'GET';
}

public function setBody($body): static
public function setBody($body): Count
{
if (isset($body) !== true) {
return $this;
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch/Endpoints/Create.php
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ public function getMethod(): string
return 'PUT';
}

public function setBody($body): static
public function setBody($body): Create
{
if (isset($body) !== true) {
return $this;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ public function getMethod(): string
return 'DELETE';
}

public function setIndexUuid($index_uuid): static
public function setIndexUuid($index_uuid): DeleteDanglingIndex
{
if (isset($index_uuid) !== true) {
return $this;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ public function getMethod(): string
return 'POST';
}

public function setIndexUuid($index_uuid): static
public function setIndexUuid($index_uuid): ImportDanglingIndex
{
if (isset($index_uuid) !== true) {
return $this;
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch/Endpoints/DeleteByQuery.php
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ public function getMethod(): string
return 'POST';
}

public function setBody($body): static
public function setBody($body): DeleteByQuery
{
if (isset($body) !== true) {
return $this;
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch/Endpoints/DeleteByQueryRethrottle.php
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ public function getMethod(): string
return 'POST';
}

public function setTaskId($task_id): static
public function setTaskId($task_id): DeleteByQueryRethrottle
{
if (isset($task_id) !== true) {
return $this;
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch/Endpoints/DeletePit.php
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ public function getMethod(): string
return 'DELETE';
}

public function setBody($body): static
public function setBody($body): DeletePit
{
if (isset($body) !== true) {
return $this;
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch/Endpoints/Explain.php
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ public function getMethod(): string
return isset($this->body) ? 'POST' : 'GET';
}

public function setBody($body): static
public function setBody($body): Explain
{
if (isset($body) !== true) {
return $this;
Expand Down
Loading

0 comments on commit 8c3b0f4

Please sign in to comment.