]> Cypherpunks.ru repositories - nncp.git/blobdiff - doc/call.texi
Replace YAML with Hjson
[nncp.git] / doc / call.texi
index a0fe0332e55900718188ecff1f193634869a7c40..447b764615af969e24ec8917fbbc50b8f5f00c28 100644 (file)
@@ -6,30 +6,37 @@ Call is a rule when and how node can be called.
 Example list of call structures:
 
 @verbatim
-calls:
-  -
-    cron: "*/1 * * * 0-4"
-    onlinedeadline: 3600
-    nice: 64
-  -
-    cron: "30 * * * 5-6"
-    onlinedeadline: 10
-    nice: 64
-  -
-    cron: "0 * * * 5-6"
-    xx: rx
-    addr: lan
+calls: [
+    {
+        cron: "*/1 * * * MON-FRI"
+        onlinedeadline: 3600
+        nice: PRIORITY+10
+    },
+    {
+        cron: "30 * * * SAT,SUN"
+        onlinedeadline: 1800
+        maxonlinetime: 1750
+        nice: NORMAL
+        rxrate: 10
+        txrate: 20
+    },
+    {
+        cron: "0 * * * SAT,SUN"
+        xx: rx
+        addr: lan
+    },
+]
 @end verbatim
 
 tells that on work days of the week call that node every minute,
 disconnect after an hour of inactivity and process only relatively high
 priority packets (presumably mail ones). So we connect and hold
 connection for very long time to pass only emails. On weekends call that
-node only each half-hour for processing high-priority packets and
-quickly disconnect. Also only on weekends try to connect to that node
-every hour only using LAN address and only receiving any (any priority)
-packets (assume that low priority huge file transmission are done
-additionally via offline connections).
+node only each half-hour for processing high-priority packets. Also only
+on weekends try to connect to that node every hour only using LAN
+address and only receiving any (any priority) packets (assume that low
+priority huge file transmission are done additionally via offline
+connections).
 
 It contains the following fields (only @emph{cron} is required):
 
@@ -150,7 +157,7 @@ and a wildcard year field is appended, that is, @verb{|* * * * Mon|}
 internally become @verb{|0 * * * * Mon *|}.
 @item
 Domain for day-of-week field is [0-7] instead of [0-6], 7 being Sunday
-(like 0). This to comply with @url{http://linux.die.net/man/5/crontab}.
+(like 0). This to comply with @url{https://linux.die.net/man/5/crontab}.
 @end itemize
 
 @item nice
@@ -166,8 +173,16 @@ Optional. Call only that address, instead of trying all from
 @ref{CfgAddrs, @emph{addrs}} configuration option. It can be either key
 from @emph{addrs} dictionary, or an ordinary @option{addr:port}.
 
+@item rxrate/txrate
+Optional. Override @ref{CfgXxRate, @emph{rxrate/txrate}} configuration
+option when calling.
+
 @item onlinedeadline
 Optional. Override @ref{CfgOnlineDeadline, @emph{onlinedeadline}}
 configuration option when calling.
 
+@item maxonlinetime
+Optional. Override @ref{CfgMaxOnlineTime, @emph{maxonlinetime}}
+configuration option when calling.
+
 @end table