Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move CAT API requests into the .Specification.CatApi namespace #200

Merged
merged 3 commits into from
May 4, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)

## [Unreleased]
### ⚠️ Breaking Changes ⚠️
- Moved `OpenSearch.Client` request classes into their respective namespaces to match those in `OpenSearch.Net` ([#200](https://github.com/opensearch-project/opensearch-net/pull/200))

### Dependencies
- Bumps `System.Reflection.Emit` from 4.3.0 to 4.7.0
- Bumps `Argu` from 5.5.0 to 6.1.1
Expand Down Expand Up @@ -53,4 +56,4 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
- Bumps `Microsoft.NETFramework.ReferenceAssemblies` from 1.0.0-preview.2 to 1.0.3

[Unreleased]: https://github.com/opensearch-project/opensearch-net/compare/1.3.0...HEAD
[1.3.0]: https://github.com/opensearch-project/opensearch-net/compare/1.2.0...1.3.0
[1.3.0]: https://github.com/opensearch-project/opensearch-net/compare/1.2.0...1.3.0
2 changes: 1 addition & 1 deletion src/OpenSearch.Client/Cat/CatAliases/CatAliasesRecord.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@

using System.Runtime.Serialization;

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[DataContract]
public class CatAliasesRecord : ICatRecord
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
* under the License.
*/

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[MapsApi("cat.aliases.json")]
public partial interface ICatAliasesRequest { }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
using System;
using System.Runtime.Serialization;

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[DataContract]
public class CatAllocationRecord : ICatRecord
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
* under the License.
*/

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[MapsApi("cat.allocation.json")]
public partial interface ICatAllocationRequest { }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@

using System.Runtime.Serialization;

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
/// <summary>
/// See docs <see href="https://opensearch.org/docs/2.0/opensearch/rest-api/cat/cat-cluster_manager/">here</see>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
* under the License.
*/

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[MapsApi("cat.cluster_manager.json")]
///<remarks>Introduced in OpenSearch 2.0 instead of <see cref="ICatMasterRequest"/></remarks>
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch.Client/Cat/CatCount/CatCountRecord.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@

using System.Runtime.Serialization;

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[DataContract]
public class CatCountRecord : ICatRecord
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch.Client/Cat/CatCount/CatCountRequest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
* under the License.
*/

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[MapsApi("cat.count.json")]
public partial interface ICatCountRequest { }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
using System.Runtime.Serialization;
using OpenSearch.Net.Utf8Json;

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[DataContract]
[JsonFormatter(typeof(CatFielddataRecordFormatter))]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
using OpenSearch.Net.Utf8Json.Internal;


namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
internal class CatFielddataRecordFormatter : IJsonFormatter<CatFielddataRecord>
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
* under the License.
*/

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[MapsApi("cat.fielddata.json")]
public partial interface ICatFielddataRequest { }
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch.Client/Cat/CatHealth/CatHealthRecord.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@

using System.Runtime.Serialization;

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[DataContract]
public class CatHealthRecord : ICatRecord
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch.Client/Cat/CatHealth/CatHealthRequest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
* under the License.
*/

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[MapsApi("cat.health.json")]
public partial interface ICatHealthRequest { }
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch.Client/Cat/CatHelp/CatHelpRecord.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@

using System.Runtime.Serialization;

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[DataContract]
public class CatHelpRecord : ICatRecord
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch.Client/Cat/CatHelp/CatHelpRequest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
* under the License.
*/

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[MapsApi("cat.help.json")]
public partial interface ICatHelpRequest { }
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch.Client/Cat/CatHelpResponseBuilder.cs
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
using System.Threading.Tasks;
using OpenSearch.Net;

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
internal class CatHelpResponseBuilder : CustomResponseBuilderBase
{
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch.Client/Cat/CatIndices/CatIndicesRecord.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@

using System.Runtime.Serialization;

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[DataContract]
public class CatIndicesRecord : ICatRecord
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
* under the License.
*/

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[MapsApi("cat.indices.json")]
public partial interface ICatIndicesRequest { }
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch.Client/Cat/CatMaster/CatMasterRecord.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@

using System.Runtime.Serialization;

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
/// <summary>
/// See docs <see href="https://opensearch.org/docs/1.2/opensearch/rest-api/cat/cat-master/">here</see>
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch.Client/Cat/CatMaster/CatMasterRequest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
* under the License.
*/

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[MapsApi("cat.master.json")]
/// <remarks>Deprecated as of OpenSearch 2.0, use <see cref="ICatClusterManagerRequest"/> instead</remarks>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@

using System.Runtime.Serialization;

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[DataContract]
public class CatNodeAttributesRecord : ICatRecord
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@

#pragma warning disable 612, 618

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[MapsApi("cat.nodeattrs.json")]
public partial interface ICatNodeAttributesRequest { }
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch.Client/Cat/CatNodes/CatNodesRecord.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@

using System.Runtime.Serialization;

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[DataContract]
public class CatNodesRecord : ICatRecord
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch.Client/Cat/CatNodes/CatNodesRequest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
* under the License.
*/

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[MapsApi("cat.nodes.json")]
public partial interface ICatNodesRequest { }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
using System.Runtime.Serialization;
using OpenSearch.Net.Utf8Json;

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[DataContract]
public class CatPendingTasksRecord : ICatRecord
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
* under the License.
*/

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[MapsApi("cat.pending_tasks.json")]
public partial interface ICatPendingTasksRequest { }
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch.Client/Cat/CatPlugins/CatPluginsRecord.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@

using System.Runtime.Serialization;

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[DataContract]
public class CatPluginsRecord : ICatRecord
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
* under the License.
*/

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[MapsApi("cat.plugins.json")]
public partial interface ICatPluginsRequest { }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
using System.Runtime.Serialization;
using OpenSearch.Net.Utf8Json;

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[DataContract]
public class CatRecoveryRecord : ICatRecord
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
* under the License.
*/

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[MapsApi("cat.recovery.json")]
public partial interface ICatRecoveryRequest { }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@

using System.Runtime.Serialization;

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[DataContract]
public class CatRepositoriesRecord : ICatRecord
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
* under the License.
*/

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[MapsApi("cat.repositories.json")]
public partial interface ICatRepositoriesRequest { }
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch.Client/Cat/CatResponse.cs
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
using System.Runtime.Serialization;
using OpenSearch.Net;

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[DataContract]
public class CatResponse<TCatRecord> : ResponseBase
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch.Client/Cat/CatResponseBuilder.cs
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
using System.Threading.Tasks;
using OpenSearch.Net;

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
internal class CatResponseBuilder<TCatRecord> : CustomResponseBuilderBase where TCatRecord : ICatRecord
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@

using System.Runtime.Serialization;

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[DataContract]
public class CatSegmentsRecord : ICatRecord
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
* under the License.
*/

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[MapsApi("cat.segments.json")]
public partial interface ICatSegmentsRequest { }
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch.Client/Cat/CatShards/CatShardsRecord.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@

using System.Runtime.Serialization;

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[DataContract]
public class CatShardsRecord : ICatRecord
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch.Client/Cat/CatShards/CatShardsRequest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
* under the License.
*/

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[MapsApi("cat.shards.json")]
public partial interface ICatShardsRequest { }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
using System.Runtime.Serialization;
using OpenSearch.Net.Utf8Json;

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[DataContract]
public class CatSnapshotsRecord : ICatRecord
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
* under the License.
*/

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[MapsApi("cat.snapshots.json")]
public partial interface ICatSnapshotsRequest { }
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch.Client/Cat/CatTasks/CatTasksRecord.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@

using System.Runtime.Serialization;

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
public class CatTasksRecord : ICatRecord
{
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch.Client/Cat/CatTasks/CatTasksRequest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
* under the License.
*/

namespace OpenSearch.Client
namespace OpenSearch.Client.Specification.CatApi
{
[MapsApi("cat.tasks.json")]
public partial interface ICatTasksRequest { }
Expand Down
Loading
Loading