diff --git a/src/Nest/XPack/MachineLearning/MachineLearningInfo/MachineLearningInfoResponse.cs b/src/Nest/XPack/MachineLearning/MachineLearningInfo/MachineLearningInfoResponse.cs index 22a8800fe00..18eb3680eb6 100644 --- a/src/Nest/XPack/MachineLearning/MachineLearningInfo/MachineLearningInfoResponse.cs +++ b/src/Nest/XPack/MachineLearning/MachineLearningInfo/MachineLearningInfoResponse.cs @@ -62,5 +62,11 @@ public class Limits { [DataMember(Name = "max_model_memory_limit")] public string MaxModelMemoryLimit { get; internal set; } + + /// + /// Available in Elasticsearch 7.8.0+ + /// + [DataMember(Name = "effective_max_model_memory_limit")] + public string EffectiveMaxModelMemoryLimit { get; internal set; } } } diff --git a/tests/Tests/XPack/MachineLearning/MachineLearningInfo/MachineLearningInfoApiTests.cs b/tests/Tests/XPack/MachineLearning/MachineLearningInfo/MachineLearningInfoApiTests.cs index e468f7cd30c..39dff6117b2 100644 --- a/tests/Tests/XPack/MachineLearning/MachineLearningInfo/MachineLearningInfoApiTests.cs +++ b/tests/Tests/XPack/MachineLearning/MachineLearningInfo/MachineLearningInfoApiTests.cs @@ -56,6 +56,9 @@ protected override void ExpectResponse(MachineLearningInfoResponse response) analyzer.Tokenizer.Should().Be("ml_classic"); analyzer.Filter.Should().NotBeNullOrEmpty(); } + + if (TestClient.Configuration.InRange(">=7.8.0")) + response.Limits.EffectiveMaxModelMemoryLimit.Should().NotBeNullOrEmpty(); } } }