appsody / controller

Appsody controller running in the development container. This repo will be archived soon.
https://appsody.dev
Apache License 2.0
2 stars 12 forks source link

Document that the watcher package does not follow symlinks when watching. #37

Closed kewegner closed 4 years ago

kewegner commented 5 years ago

We need to review and discuss this. Question.

kewegner commented 4 years ago

As of yet we have not encountered a problem with symlinks and the watcher. I believe there is an instance in the tooling where they used a symlink, but no problems were reported. At this time, it is unclear if there is a simple solution, should this ever become and issue in the future.

There are two kinds of situations that might encounter an issue.

  1. If a file or directory in the watch directory is a symlink.
  2. If one of the watch or ignore directories is a symlink.

I wonder if we should just document the fact that symlinks are not supported by the watcher as a known limitation for the moment?

kewegner commented 4 years ago

I am working on README comments for this and will have done by Friday.

helenmasters commented 4 years ago

@rykal-nate are you intending to test this out, or are we just looking to add wording, as if so I'd suggest adding something like:

"The use of symlinks within the directories that the controller monitors for file changes might result in undefined behavior."

to the README?

rykal-nate commented 4 years ago

@helenmasters - Yes, I did a bit of testing yesterday, the behavior is a bit nuanced and not worth documenting every individual scenario IMO. In large, edit actions on sym links are not recognized by the controller such as document edits, renames etc ... however if you deleted a symbolic link on a watched directory there would be a directory event. I think the text you have is sufficient.

I question if this should be documented with the stack env variables possibly or point to this controller notice from that location. @neeraj-laad maybe state its not a best practice to use symbolic links as it relates to changing stack artifacts in addition?

Thanks!