Function ngx_cycle_log

Source
pub fn ngx_cycle_log() -> NonNull<ngx_log_t>
Expand description

Obtains a pointer to the global (cycle) log object.

The returned pointer is tied to the current cycle lifetime, and will be invalidated by a configuration reload in the master process or in a single-process mode. If you plan to store it, make sure that your storage is also tied to the cycle lifetime (e.g. module configuration or connection/request data).

The function may panic if you call it before the main() in nginx creates an initial cycle.