mirror of https://github.com/apache/activemq.git
force the datafile before it is removed so that all async writes are completed before the file handle is closed.
git-svn-id: https://svn.apache.org/repos/asf/incubator/activemq/trunk@476225 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
57a4071d94
commit
f65acf552b
|
@ -259,6 +259,7 @@ public final class DataManager{
|
|||
|
||||
private void removeDataFile(DataFile dataFile) throws IOException{
|
||||
fileMap.remove(dataFile.getNumber());
|
||||
writer.force(dataFile);
|
||||
boolean result=dataFile.delete();
|
||||
log.debug("discarding data file "+dataFile+(result?"successful ":"failed"));
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue