I believe since you do not know the file name/process id, you could specify user name option as below.

lsof -r 2 -u username
  • The „-r 2“ option puts lsof in repeat mode, with updates every 2 seconds. (Ctrl -c quits)
  • The „-u‘ option can be used to keep an eye on a users activity.

If you know the directory name under which the application is being run and do not want to specify the user name,you could use the command like,

lsof +D /some/dir -r 2 

alternatively: Java application