OpenSearch/x-pack/plugin/ml
Dimitris Athanasiou c23a2187da
[7.x][ML] Only report complete writing_results progress after completion (#49551) (#49577)
We depend on the number of data frame rows in order to report progress
for the writing of results, the last phase of a job run. However, results
include other objects than just the data frame rows (e.g, progress, inference model, etc.).

The problem this commit fixes is that if we receive the last data frame row results
we'll report that progress is complete even though we still have more results to process
potentially. If the job gets stopped for any reason at this point, we will not be able
to restart the job properly as we'll think that the job was completed.

This commit addresses this by limiting the max progress we can report for the
writing_results phase before the results processor completes to 98.
At the end, when the process is done we set the progress to 100.

The commit also improves failure capturing and reporting in the results processor.

Backport of #49551
2019-11-26 12:20:37 +02:00
..
licenses [ML] Rename log structure to file structure (#33421) 2018-09-06 09:13:08 +01:00
qa [7.x][ML] Apply source query on data frame analytics memory estimation (#49517) (#49532) 2019-11-25 12:51:57 +02:00
src [7.x][ML] Only report complete writing_results progress after completion (#49551) (#49577) 2019-11-26 12:20:37 +02:00
build.gradle Apply 2-space indent to all gradle scripts (#49071) 2019-11-14 11:01:23 +00:00