Liking cljdoc? Tell your friends :D
Clojure only.

puppetlabs.trapperkeeper.services.status.check

Shared status check functions.

Shared status check functions.
raw docstring

disk-writable?clj

(disk-writable? directory)

Given a directory, check whether the FS that the directory is in seems healthy by writing 4k random letters to a file in that directory, and then read them back in. If what was read matches what was written, then return true; if there's a mismatch or anything goes wrong in the process, return false.

Since this check involves writing to disk, it may not be appropriate to put at a high status check level like :critical or :info.

Given a directory, check whether the FS that the directory is in seems
healthy by writing 4k random letters to a file in that directory, and then
read them back in. If what was read matches what was written, then return
true; if there's a mismatch or anything goes wrong in the process, return
false.

Since this check involves writing to disk, it may not be appropriate to put at
a high status check level like :critical or :info.
sourceraw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close