Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Avoid circular reference in exception
Don't set the suppressed Exception in Translog.closeOnTragicEvent(Exception ex) if it is an AlreadyClosedException. ACE is thrown by the TranslogWriter and as cause might contain the Exception that we add the suppressed ACE to. We then end up with a circular reference where Exception A has a suppressed Exception B that has as cause A. This would cause a stackoverflow when we try to serialize it. For a more detailed description see elastic#15941 closes elastic#15941
- Loading branch information