Make file writes more scalable