marschall / memoryfilesystem

An in memory implementation of a JSR-203 file system
284 stars 36 forks source link

Set the size of the built file system #126

Open maximebochon opened 3 years ago

maximebochon commented 3 years ago

I didn't find how to set the memory space size of the built file system.

I looked at the MemoryFileSystemBuilder JavaDoc and at the README, but this feature seems to be missing.

My use case is to test a "no space left on device" situation by setting a low size on the test file system.

marschall commented 3 years ago

There isn’t currently a way to do this. MemoryFileStore doesn't currently track the whole used space so there is currently not a way to check if we exceed this.