Project

General

Profile

Actions

User story #9092

closed

Don't break agent that do not support dry-run

Added by Benoît PECCATTE about 8 years ago. Updated about 8 years ago.

Status:
Rejected
Priority:
N/A
Category:
Web - Compliance & node report
Target version:
UX impact:
Suggestion strength:
User visibility:
Effort required:
Name check:
Fix check:
Regression:

Description

We must never run dry-run promises on an agent that do not support it.
We prefer breaking the agent than breaking the OS.

To do this we need:
- on the server to know the agent version
- on the server generate the dry-run code when the agent version is OK (>=4.0)
- on the server, generate an alternate call when the agent version is not OK: call no_dry_run_support() bundle
- in ncf (from the server) add a no_dry_run_support() bundle that warns the user and set an abort_class
- in ncf (from the server) add a condition to not load the dry_run lib if it is not supported (based on @agent_version and @rudder_version tag)

Then:
- if the dry-run is supported and detected as supported on the server > it will work with compliance OK
if the dry-run is supported and not detected as supported on the server > it will abort properly with compliance KO
if the dry-run is not supported and detected as supported on the server > it will break the agent with a "missing set_dry_run method" message with compliance KO
if the dry-run is not supported and not detected as supported on the server -> it will abort properly with compliance KO


Related issues 3 (0 open3 closed)

Related to Rudder - User story #9225: Add support for negative checks and agent version checks in agent_requirementsRejectedBenoît PECCATTEActions
Related to Rudder - User story #9226: Define a standard abort class in ncfReleasedBenoît PECCATTEActions
Related to Rudder - User story #9230: Define a dry-run lib when default bodies are not supportedReleasedJonathan CLARKEActions
Actions

Also available in: Atom PDF