+ try (PrintWriter writer = new PrintWriter(new FileOutputStream(tmpMetaDataPath))) {
+ String metaData = req.getHeader("X-ATT-DR-META");
+ writer.print(metaData);
+ }
+ Files.move(Paths.get(tmpMetaDataPath), Paths.get(fullMetaDataPath), StandardCopyOption.REPLACE_EXISTING);