Report the backend host as the pdbmux_source value #31
Reference in New Issue
Block a user
Delete Branch "benvin/pdbmux-source-fact-fqdn"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
The source fact carries the backend's configured name (
new/old), which means nothing outside pdbmux's own config. The upstream PuppetDB host identifies where a node's data came from directly.pdbmux_sourceon /facts and /nodes to the lowercased backend URL hostname/facts/pdbmux_source/<value>and AST value filters against that hostnamesource_fact_enabled: false, breaking previously valid configs (e.g. old/new PuppetDB on one host, different ports) for a collision that cannot occur → only enforce it whenc.SourceFactEnabled, and add a Validate case for that.url.Hostname()keeps case, soPuppetDB.exampleandpuppetdb.examplepass the duplicate check and the fact value depends on config spelling →strings.ToLowerthe host.s.hostscovers every backend) and would silently reintroduce name values → drop it and returnsi.hosts[backend].http://127.0.0.1:<port>(e2e_backend_test.go:157) and the source fact is on by default, so the new shared-host check failscfg.Validate()and the wholemake e2esuite fatals before any test runs → reach the backends under distinct hosts (e.g.pdb-a.localhost/pdb-b.localhost, as the unit tests do)pdbmux_source== backend name (pdb-a/pdb-b) → expect the backend host97ddc37"Narrow the source-fact /facts fetch…"); PR is unmergeable → merge the base branch in and resolveNo findings.