in.close();
// now save the runtime deployment descriptor...
OutputStream os = out.putNextEntry(getRuntimeDeploymentDescriptorPath());
writeRuntimeDeploymentDescriptors(os);
out.closeEntry();
out.close();
// if we overwrote the old archive, need to rename the tmp now
if (output == null) {
ReadableArchive finalArchive = archiveFactory.openArchive(new File(path));