pandeiro / boot-http

A simple HTTP serve task for the Boot build tool
62 stars 34 forks source link

Resources handler doesn't pick up modifications #29

Open pandeiro opened 8 years ago

pandeiro commented 8 years ago

Currently the resources handler (the default handler for the serve task) serves resources from the classpath.

If these resources exist in the filesystem in a directory that is in Boot's :resource-paths, e.g. something like html/index.html and have changed in the fileset as a result of some operation, the changed version should be served, but is not.

arichiardi commented 8 years ago

I was looking at this issue and discovered that not even source modifications are reloaded live for me. By checking a bit the code I see that the reloadable folders are read like :env-dirs ~(vec (:directories pod/env)) which in my case (from get-env is):

#{"~/.boot/cache/tmp/.../git/acu/7nu/99bt35"
   "~/.boot/cache/tmp/.../git/acu/7nu/mm3x96"
   "~/.boot/cache/tmp/.../git/acu/7nu/f0sqpx"
   "~/.boot/cache/tmp/.../git/acu/7nu/mh5540"
   "~/.boot/cache/tmp/.../git/acu/7nu/-rcsl8f"}

No :source/:resource in there, can it be related to that?

MartyGentillon commented 7 years ago

I find that I get random behavior with this. Sometimes it serves the modified files, sometimes it doesn't. It seems that whatever is on its classpath at the time that the request arrives gets served (perhaps because the underlying server is completely unaware of the fileset?).