Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@MartinKDT
Copy link

@MartinKDT MartinKDT commented Oct 1, 2025

Added optional "optional" argument to load_module directive. If the argument is provided then failing to load the module will only emit a warning and not hinder nginx from starting. The existing behavior remains unchanged if "optional" is not provided.

Proposed changes

This change adds the ability to mark modules as optional in the configuration file. Failing to load an optional module does not hinder nginx from starting.
The motivation behind this change is for issues with non essential modules to not prevent nginx from working. For example modules that only collect data.

A warning message is logged if an optional module could not be loaded. Also added an error message if a core module's "create_conf" call fails for modules specified via load_module.

Usage

load_module module [optional];

@github-actions
Copy link

github-actions bot commented Oct 1, 2025

✅ All required contributors have signed the F5 CLA for this PR. Thank you!
Posted by the CLA Assistant Lite bot.

@MartinKDT
Copy link
Author

I have hereby read the F5 CLA and agree to its terms

Added optional "optional" argument to load_module directive. If the argument is provided then failing to load the module will only emit a warning and not hinder nginx from starting. The existing behaviour remains unchanged if "optional" is not provided.
@MartinKDT MartinKDT force-pushed the add-optional-modules branch from 991178b to fbae83a Compare October 9, 2025 08:34
@MartinKDT MartinKDT marked this pull request as ready for review October 9, 2025 10:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant