Comments (4)
@szuecs OK, I created a PR. Please have a look, I hope it will fix the issues! 🙏
from external-dns.
I had a look and I'm not exactly sure why the test is failing in CI.
There are two problems that I've identified so far:
- The validateServices method isn't really working, it doesn't check the expected services as one would think. If I change the code in coredns_test.go to the following, the test still passes for me
expectedServices4 := map[string]*Service{ "/skydns/local/domain2": {Host: "site.local"}, "/skydns/local/xx1": {Host: "5.5.5.5"}, // <-- no reference to domain1 anymore "/skydns/local/xx2": {Host: "6.6.6.6"}, // <-- no reference to domain1 anymore "/skydns/local/domain1": {Host: "7.7.7.7"}, }
- The expected behaviour, at least in the test setup, is not actually happening. The failing part of the test was part of 3602c47 which says "Multiple A records support for the same FQDN" but I added some logging to validateServices and saw that all A records point to the same IP, instead of 3 different ones:
(That's why the test is passing locally, it always takes
coredns_test.go:325: srv: /skydns/local/domain1/3a4dab26 7.7.7.7 coredns_test.go:325: srv: /skydns/local/domain2/18d03fa3 site.local coredns_test.go:325: srv: /skydns/local/domain1/1d5f2afc 7.7.7.7 coredns_test.go:325: srv: /skydns/local/domain1/30517d1e 7.7.7.7
/skydns/local/domain1
from the expectedServices map, which gives 7.7.7.7, which is what all records have)
from external-dns.
Interesting this sounds like a common Go iteration issue if you hold only the reference to the last one of a list....
Did the Go version changed in the test suite?
from external-dns.
I had another look and it could be this code in coredns_test.go, where we directly store the pointers to the given service in the map.
func (c fakeETCDClient) SaveService(service *Service) error {
c.services[service.Key] = service
return nil
}
I have no idea about Go, so I don't know which guarantees there are around pointers, but during debugging I saw that in this loop, after the 3rd run, the fakeETCDClient contains 3 pointers which all point to the same memory, so they all have Host=7.7.7.7, even though the "Add/set key..." logging output shows the 3 different IPs
for _, service := range services {
log.Infof("Add/set key %s to Host=%s, Text=%s, TTL=%d", service.Key, service.Host, service.Text, service.TTL)
if !p.dryRun {
err := p.client.SaveService(&service)
I'm trying to create a PR, but, as I said, no idea about Go
from external-dns.
Related Issues (20)
- MX record for cloudflare gives error 1004
- Allow Configuration of Azure Active Directory Endpoints
- Add doc about how to run external DNS with Azure internal load balancer HOT 1
- [AWS] External-dns intermittent "records retrieval failed: failed to list hosted zones."
- Export metrics to Prometheus
- Incorrect suffix for TXT record
- Godaddy record replace failure HOT 2
- [bitnami/external-dns] Cloudflare A records not updated HOT 2
- Node source ignores multiple FQDN templates
- Add support for `labelFilter` to `node` source
- New format txt registry records fail for Apex record HOT 1
- MX Records created via CRD not being deleted
- Are cross Azure resource group DNS zones supported in External DNS?
- Manager sees all the 'alpha' status and wonders if external-dns can be trusted. How is the status of each provider decided? HOT 1
- v.0.14.0 [AWS] External-DNS cannot remove records from 2 Route 53 hosted zones (InvalidChangeBatch: [The request contains an invalid set of changes]) HOT 20
- GANDI: support for personal access token
- Allow to add metadata to the azure records
- Documentation for supported flags and environment variables HOT 1
- Cloudflare CF_API_TOKEN doesn't work HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from external-dns.