#96 No file log if parent directory does not exist

All
open-accepted
nobody
None
5
2014-02-09
2014-02-06
Rune Glerup
No

We are using version YAJSW 11.05 and have observed that we get no file logging if the log output directory is not created before starting the service.

Stepping through the debugger, I discovered that an exception is thrown in the openFiles() method in MyFileHandler:

    if (unique > MAX_LOCKS) {
    throw new IOException("Couldn't get lock for " + pattern);
    }

Maybe the fix would be to run mkdirs() on the parent folder before trying to create the lock file.

Discussion

  • rzo
    rzo
    2014-02-09

    • status: open --> open-accepted