Skip to content

Commit

Permalink
Move CAT API requests into the .Specification.CatApi namespace (#200)
Browse files Browse the repository at this point in the history
* Move CAT API requests into the `.Specification.CatApi` namespace

Signed-off-by: Thomas Farr <[email protected]>

* Add changelog

Signed-off-by: Thomas Farr <[email protected]>

* Flag as breaking changes in changelog

Signed-off-by: Thomas Farr <[email protected]>

---------

Signed-off-by: Thomas Farr <[email protected]>
  • Loading branch information
Xtansia authored May 4, 2023
1 parent 9664628 commit b5b454a
Show file tree
Hide file tree
Showing 93 changed files with 96 additions and 50 deletions.
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
2 changes: 1 addition & 1 deletion src/OpenSearch.Client/Cat/CatAliases/CatAliasesRequest.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.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
2 changes: 1 addition & 1 deletion src/OpenSearch.Client/Cat/CatIndices/CatIndicesRequest.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.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
2 changes: 1 addition & 1 deletion src/OpenSearch.Client/Cat/CatPlugins/CatPluginsRequest.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.plugins.json")]
public partial interface ICatPluginsRequest { }
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch.Client/Cat/CatRecovery/CatRecoveryRecord.cs
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
2 changes: 1 addition & 1 deletion src/OpenSearch.Client/Cat/CatSegments/CatSegmentsRecord.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 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

0 comments on commit b5b454a

Please sign in to comment.