Fixes AMQ-5404: LevelDB files not being released after deletion

(cherry picked from commit 9de3fff1f5)
This commit is contained in:
Hiram Chirino 2015-12-21 11:18:08 -05:00 committed by Timothy Bish
parent 028a33ea7d
commit da45634e44
1 changed files with 6 additions and 0 deletions

View File

@ -155,6 +155,12 @@ case class RecordLog(directory: File, logSuffix:String) {
onDelete(info.file)
onDelete(id)
log_infos.remove(id)
reader_cache.synchronized {
val reader = reader_cache.remove(info.file);
if( reader!=null ) {
reader.release();
}
}
}
}
}