Only 48 hours left in the trailboss' kickstarter!

New rewards and stretch goals. CLICK HERE!

  • Post Reply Bookmark Topic Watch Topic
  • New Topic

How to determine if 2 files exists  RSS feed

Mathias Nilsson
Ranch Hand
Posts: 367
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have build a server that sends job to other servers ( not built by me )
The 3 party servers has a hotfolder attached and check for 2 files that my server has copied to them. When the hotfolder is empty the 3 party server is done.

My problem is that File.exists returns true even if the file doens not exist. Maybe because the server removes the files at the same time I call File.exists over network.

how can I be sure that the folder is empty? I Use a loop now but it doesn't work.
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!