diff --git a/src/Nest/XPack/MachineLearning/UpdateDataFeed/UpdateDatafeedRequest.cs b/src/Nest/XPack/MachineLearning/UpdateDataFeed/UpdateDatafeedRequest.cs index 51b03fb7b1d..a0d4e91665b 100644 --- a/src/Nest/XPack/MachineLearning/UpdateDataFeed/UpdateDatafeedRequest.cs +++ b/src/Nest/XPack/MachineLearning/UpdateDataFeed/UpdateDatafeedRequest.cs @@ -38,6 +38,7 @@ public partial interface IUpdateDatafeedRequest /// /// A numerical character string that uniquely identifies the job. /// + [Obsolete("As of 7.4.0 the ability to associate a feed with a different job is being deprecated as it adds unnecessary complexity")] [DataMember(Name ="job_id")] Id JobId { get; set; } @@ -85,6 +86,7 @@ public partial class UpdateDatafeedRequest public Indices Indices { get; set; } /// + [Obsolete("As of 7.4.0 the ability to associate a feed with a different job is being deprecated as it adds unnecessary complexity")] public Id JobId { get; set; } /// @@ -133,6 +135,7 @@ public UpdateDatafeedDescriptor ChunkingConfig(Func AllIndices() => Indices(Nest.Indices.All); /// + [Obsolete("As of 7.4.0 the ability to associate a feed with a different job is being deprecated as it adds unnecessary complexity")] public UpdateDatafeedDescriptor JobId(Id jobId) => Assign(jobId, (a, v) => a.JobId = v); /// diff --git a/src/Tests/Tests/XPack/MachineLearning/UpdateDatafeed/UpdateDatafeedApiTests.cs b/src/Tests/Tests/XPack/MachineLearning/UpdateDatafeed/UpdateDatafeedApiTests.cs index 3dd001c7a8b..c8078cb1d21 100644 --- a/src/Tests/Tests/XPack/MachineLearning/UpdateDatafeed/UpdateDatafeedApiTests.cs +++ b/src/Tests/Tests/XPack/MachineLearning/UpdateDatafeed/UpdateDatafeedApiTests.cs @@ -19,7 +19,6 @@ public UpdateDatafeedApiTests(MachineLearningCluster cluster, EndpointUsage usag protected override object ExpectJson => new { indices = new[] { "server-metrics" }, - job_id = CallIsolatedValue, query = new { match_all = new @@ -33,7 +32,6 @@ public UpdateDatafeedApiTests(MachineLearningCluster cluster, EndpointUsage usag protected override Func, IUpdateDatafeedRequest> Fluent => f => f .Indices("server-metrics") //goes on body not in the url - .JobId(CallIsolatedValue) .Query(q => q .MatchAll(m => m.Boost(2)) ); @@ -43,7 +41,6 @@ public UpdateDatafeedApiTests(MachineLearningCluster cluster, EndpointUsage usag protected override UpdateDatafeedRequest Initializer => new UpdateDatafeedRequest(CallIsolatedValue + "-datafeed") { - JobId = CallIsolatedValue, Indices = "server-metrics", Query = new MatchAllQuery {