Introduce $ABI [strict|lenient]
for VMOD descriptors
#2330
Closed
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
When versioning appeared in the VRT API, the goal was to allow loose
ABI compliance on loaded VMODs based on the major/minor revision against
which it was built. Strict checking was performed if Varnish was built
from the master branch in the VCC code, but omitted by the child.
This however has two flaws:
Release management might go wrong like it happened in 5.1.2 that got
released from the master branch.
This doesn't solve the original problem that some VMODs might rely
on supported symbols encompassed by the VRT major/minor while others
may choose to integrate deeper with Varnish and lose guarantees.
This patch retires the
VCS_Branch
macro that is no longer needed andprovides a new
$ABI
stanza that defaults to strict when omitted. Tohelp discovery, in-tree modules advertise a strict match.
To indicate that a VMOD needs the exact Varnish build to be loaded,
the VMOD's metadata contains 0.0 for the VRT major/minor revision.
In addition, both the VCC and child now perform the full ABI compliance
check, picking the strict or lenient option depending on the VMOD's
metadata.