v.25.7Bug Fix (user-visible misbehavior in an official stable release)

Fix possible abort

Fix possible abort (due to joining threads from the task) and hopefully hungs (in unit tests) during BackgroundSchedulePool shutdown. #83769 (Azat Khuzhin).