- status: open --> open-accepted
Using yajsw 11.11 (running on mac os, java 1.7.0_51)!
Configuring a wrapped java app, running in eg console mode, invoking
/whatever/path/to/myapp/lib/yajsw $> java -jar wrapper.jar -c "/whatever/path/to/myapp/conf/yajsw.conf"
Among other things, yajsw.conf contains:
wrapper.working.dir=../..
wrapper.tmp.path=tmp/yajsw
Starting the app as described above, tmp-files are created in two directories.
/whatever/path/to/myapp/tmp/yajsw $> ls -la
total 800
drwxr-xr-x 5 me users 170 5 Maj 01:19 .
drwxr-xr-x 3 me users 102 30 Apr 14:23 ..
-rwxrwxrwx 1 me users 204800 5 Maj 01:19 err_3945868435574500360$1399245572384
-rwxrwxrwx 1 me users 0 5 Maj 01:19 in_3945868435574500360$1399245572384
-rwxrwxrwx 1 me users 204800 5 Maj 01:19 out_3945868435574500360$1399245572384
Note that temporary in_-file is of size 0.
/whatever/path/to/myapp/lib/yajsw/tmp/yajsw $> ls -la
total 400
drwxr-xr-x 3 me users 102 5 Maj 01:19 .
drwxr-xr-x 4 me users 136 30 Apr 14:23 ..
-rw-r--r-- 1 me users 204800 5 Maj 01:19 in_3945868435574500360$1399245572384
This tmp-file has the same name as above, but has actually allocated some space. Also, file permissions are different...
Is there a mismatch somewhere in code creating the temporary files? I would have expected the in-file to be created once, and only in the same directory as the two other temp-files.
It seems as resources using temporary files are assuming different working directories when creating the file handles, and I assume that this issue is only relevant when defining a value for the property wrapper.working.dir.
Note. I have not (yet) detected any issues resulting from this behavior. It is merely an observation which I suspect might result in downstream issues. However, if this is not by design, it should be fairly simplistic to find and correct.
(btw, specifying wrapper.tmp.dir as described in http://yajsw.sourceforge.net/index.html has no effect. However, http://yajsw.sourceforge.net/YAJSW%20Configuration%20Parameters.html mentions wrapper.tmp.path, which seems like the correct property to use in order to control tmp-file locations. Maybe http://yajsw.sourceforge.net/index.html should be updated?)