summaryrefslogtreecommitdiff
path: root/obnam.md
diff options
context:
space:
mode:
authorAlexander Batischev <eual.jp@gmail.com>2021-07-27 21:47:37 +0300
committerAlexander Batischev <eual.jp@gmail.com>2021-07-31 17:27:06 +0300
commit9f8e448153b9b35a36063c5a2a659c139ff0e31d (patch)
tree2a9ff556764494a80c3c4ff02031bca23e522a1a /obnam.md
parent4c6206a2cb1f8c1efba9fd08a4d6b4fa7d09a6dc (diff)
downloadobnam2-9f8e448153b9b35a36063c5a2a659c139ff0e31d.tar.gz
feat: configure log verbosity with OBNAM_SERVER_LOG envvar
Fixes #117.
Diffstat (limited to 'obnam.md')
-rw-r--r--obnam.md25
1 files changed, 25 insertions, 0 deletions
diff --git a/obnam.md b/obnam.md
index decb28c..aba2110 100644
--- a/obnam.md
+++ b/obnam.md
@@ -1124,6 +1124,31 @@ and chunk-meta is {"sha256":"abc","generation":null,"ended":null}
and the body matches file data.dat
~~~
+
+## Obeys `OBNAM_SERVER_LOG` environment variable
+
+The chunk server logs its actions to stderr. Verbosity of the log depends on the
+`OBNAM_SERVER_LOG` envvar. This scenario verifies that the variable can make the
+server more chatty.
+
+~~~scenario
+given an installed obnam
+and a running chunk server
+and a file data1.dat containing some random data
+when I POST data1.dat to /chunks, with chunk-meta: {"sha256":"qwerty"}
+then the JSON body has a field chunk_id, henceforth ID
+and chunk server's stderr doesn't contain "Obnam server starting up"
+and chunk server's stderr doesn't contain "created chunk <ID>"
+
+given a running chunk server with environment {"OBNAM_SERVER_LOG": "info"}
+and a file data2.dat containing some random data
+when I POST data2.dat to /chunks, with chunk-meta: {"sha256":"xyz"}
+then the JSON body has a field chunk_id, henceforth ID
+and chunk server's stderr contains "Obnam server starting up"
+and chunk server's stderr contains "created chunk <ID>"
+~~~
+
+
# Acceptance criteria for the Obnam client
The scenarios in chapter verify that the Obnam client works as it