authorize {
preprocess
files
}
Normal Processing
In normal operation, the interpreter processes lists of statements, such as the example given below:
In the above configuration, when the authorize
section is
executed, the preprocess
module is also called, followed by the
files
module. The processing is top to bottom and follows the
algorithm given earlier in this chapter.
The configurable failover function allows for more flexibility when
the interpreter processes a section. As stated previously, configurable
failover provides the ability to control exactly how the processing
flows through a section and to override or rewrite the return value of
any module. This capability allows administrators to create policies
such as "try sql1
, if it’s down, try sql2
, otherwise pretend
everything succeeded":
accounting {
detail # always log to detail, stopping if it fails
redundant {
sql1 # try module sql1
sql2 # if that's down, try module sql2
ok # otherwise treat it as success
}
}
In comparison to configurable failover, the Unlang interpreter is even more flexible.