Details
-
Sub-task
-
Status: Closed
-
Major
-
Resolution: Fixed
-
1.10.0
Description
Managed memory fractions should be rounded to floor at a certain precision when divided by the number of operators, otherwise the fractions can be summed up to be more than 1.0 due to the double precision issue, and the last operator may fail to allocate managed memory it is supposed to be able to acquire.
To achieve that, I think we should change StreamingJobGraphGenerator#setManagedMemoryFractionForOperator to use BigDecimal#divide(otherValue, scale, RoundMode.ROUND_DOWN) to calculate the fractions. In this way, the sum of the fractions will not exceed 1.0.
The scale can be a bit larger (maybe 16) so that we only lose little managed memory.
cc chesnay
Attachments
Issue Links
- links to