Commit Graph

92 Commits

Author SHA1 Message Date
Andrew Hay
93d4d47bff
feat(metrics): consecutiveSoftErrors (#5502)
* feat(controller): add consecutive soft error metric and improve retry test

* docs: clean up metrics.md Go runtime metrics table, remove duplicates, ensure CI compliance

* style: gofmt

* style: gofmt
2025-06-06 09:52:39 -07:00
Michel Loiseleur
a48b75b266 remove ultradns provider 2025-05-25 10:09:11 +02:00
Michel Loiseleur
640e593fcb remove tencentcloud provider 2025-05-25 10:04:19 +02:00
Michel Loiseleur
756a7288da chore!: remove unmaintained providers 2025-05-25 09:43:01 +02:00
tom
14ea50300e
feat(cloudflare): Suppport DNS record comments (#5411)
* feat(cloudflare): Suppport DNS record comments

* Provide comment flag example
2025-05-19 00:43:15 -07:00
Shruti Panapana
7b9d8d9355
fix(azure): enhance retry logic using azure SDK (#5361)
* fix(azure): Enhance retry logic using azure SDK

* Added the changes for flag based maxretries configuration

* Fixed types.go, flags.md and delected unneccesary comments

* Added the correct image for the Azure Private DNS tutorial

* Following the go naming convention for maxRetriesCount

* Added the correct flag information to the --azure-maxretries-count

* Made the required changes to accept the --azure-maxretries-count flag value from cli/env
2025-05-17 02:09:14 -07:00
Michel Loiseleur
3c93bcb076
chore(code): improve some tests + re-order sources flags CLI (#5288)
* fix(plan): always use managed records

* robust random port in test

* use defaultconfig for managed-record-types

* be explicit about static variable

* fix wait

* re-order flags related to sources + dynamic managedrecordtype help

* fix flag doc
2025-04-27 14:11:24 -07:00
tJouve
1efdf4161c
feat(pihole): add optional support for v6 (#5226)
* Pi hole V6 impl

* Code Review Part One

* Fix Go Lint

* Regenerate Flags file

* Increase code coverage 1/2

* Increase code coverage 2/2

* Fix merge conflict => Provider init move from main.go to execute.go
2025-04-02 09:10:43 -07:00
Ivan Ka
65d534e4a1
chore(code-cleanup): move logic away from main.go add tests (#5222)
* feat(code cleanup): remove from main.go

Signed-off-by: ivan katliarchuk <ivan.katliarchuk@gmail.com>

* chore(code-cleanup): move logic from main.go add tests

Signed-off-by: ivan katliarchuk <ivan.katliarchuk@gmail.com>

* chore(code-cleanup): move logic from main.go add tests

Signed-off-by: ivan katliarchuk <ivan.katliarchuk@gmail.com>

* chore(code-cleanup): move logic from main.go add tests

Signed-off-by: ivan katliarchuk <ivan.katliarchuk@gmail.com>

* chore(code-cleanup): move logic from main.go add tests

Signed-off-by: ivan katliarchuk <ivan.katliarchuk@gmail.com>

* chore(code-cleanup): move logic away from main.go add tests

Signed-off-by: ivan katliarchuk <ivan.katliarchuk@gmail.com>

* chore(code-cleanup): move logic away from main.go add tests

Signed-off-by: ivan katliarchuk <ivan.katliarchuk@gmail.com>

* chore(code-cleanup): move logic away from main.go add tests

Co-authored-by: Michel Loiseleur <97035654+mloiseleur@users.noreply.github.com>

* chore(code-cleanup): move logic away from main.go add tests

Signed-off-by: ivan katliarchuk <ivan.katliarchuk@gmail.com>

* chore(code-cleanup): move logic away from main.go add tests

Signed-off-by: ivan katliarchuk <ivan.katliarchuk@gmail.com>

---------

Signed-off-by: ivan katliarchuk <ivan.katliarchuk@gmail.com>
Co-authored-by: Michel Loiseleur <97035654+mloiseleur@users.noreply.github.com>
2025-03-31 15:58:43 -07:00
Ivan Ka
1e8e5e06c5
chore(docs): generate docs/monitoring/metrics.md file (#5117)
* chore(docs): generate docs/monitoring/metrics.md file

Signed-off-by: ivan katliarchuk <ivan.katliarchuk@gmail.com>

* chore(docs): generate docs/monitoring/metrics.md file

Signed-off-by: ivan katliarchuk <ivan.katliarchuk@gmail.com>

* chore(docs): generate docs/monitoring/metrics.md file

Signed-off-by: ivan katliarchuk <ivan.katliarchuk@gmail.com>

* chore(docs): generate docs/monitoring/metrics.md file

Signed-off-by: ivan katliarchuk <ivan.katliarchuk@gmail.com>

* chore(docs): generate docs/monitoring/metrics.md file

Signed-off-by: ivan katliarchuk <ivan.katliarchuk@gmail.com>

* chore(docs): generate docs/monitoring/metrics.md file

Signed-off-by: ivan katliarchuk <ivan.katliarchuk@gmail.com>

* chore(docs): generate docs/monitoring/metrics.md file

Signed-off-by: ivan katliarchuk <ivan.katliarchuk@gmail.com>

* chore(docs): generate docs/monitoring/metrics.md file

Signed-off-by: ivan katliarchuk <ivan.katliarchuk@gmail.com>

* chore(docs): generate docs/monitoring/metrics.md file

Signed-off-by: ivan katliarchuk <ivan.katliarchuk@gmail.com>

* chore(docs): generate docs/monitoring/metrics.md file

Signed-off-by: ivan katliarchuk <ivan.katliarchuk@gmail.com>

* chore(docs): generate docs/monitoring/metrics.md file

Signed-off-by: ivan katliarchuk <ivan.katliarchuk@gmail.com>

* chore(docs): generate docs/monitoring/metrics.md file

Signed-off-by: ivan katliarchuk <ivan.katliarchuk@gmail.com>

* chore(docs): generate docs/monitoring/metrics.md file

Signed-off-by: ivan katliarchuk <ivan.katliarchuk@gmail.com>

* chore(docs): generate docs/monitoring/metrics.md file

Signed-off-by: ivan katliarchuk <ivan.katliarchuk@gmail.com>

* chore(docs): generate docs/monitoring/metrics.md file

Signed-off-by: ivan katliarchuk <ivan.katliarchuk@gmail.com>

* chore(docs): generate docs/monitoring/metrics.md file

Signed-off-by: ivan katliarchuk <ivan.katliarchuk@gmail.com>

* chore(docs): generate docs/monitoring/metrics.md file

Signed-off-by: ivan katliarchuk <ivan.katliarchuk@gmail.com>

* chore(docs): generate docs/monitoring/metrics.md file

Signed-off-by: ivan katliarchuk <ivan.katliarchuk@gmail.com>

* chore(docs): generate docs/monitoring/metrics.md file

Co-authored-by: Michel Loiseleur <97035654+mloiseleur@users.noreply.github.com>

---------

Signed-off-by: ivan katliarchuk <ivan.katliarchuk@gmail.com>
Co-authored-by: Michel Loiseleur <97035654+mloiseleur@users.noreply.github.com>
2025-03-04 05:05:44 -08:00
Thibault Jamet
b2ff1619f5
Add Domain filter interface 2024-08-14 10:20:59 +02:00
Thibault Jamet
2007a49f1f
Improve MinEventInterval compliance with docs
**Description**

In the command line arguments, we see `min-event-sync-interval` as
"The minimum interval between two consecutive synchronizations triggered from kubernetes events"

In the code, it actually acts a different way.

It imposes a certain dealy between syncs.
While this is compliant with the "minimum delay between 2 consecutive
synchronizations", it has side-effects in case of large delays.

In particular, when trying to fine-tune external-dns to match the
provider rate-limits.

In this case, it may be interesting to restrict the rate of reconciling
actions happening by having a high `min-event-sync-interval`, while
keeping a low latency for initial events.

This would allow to maximise the bulk effect of high change rate while
keeping fast enough reaction for isolated changes.

**Checklist**

- [X] Unit tests updated
- [X] End user documentation updated
> End user documentation matches the updated behaviour with more
> accuracy
Change-Id: Ibcea707974a095a2d5861a3974b4c79e5a15b00e
2024-08-06 08:52:27 +02:00
Kubernetes Prow Robot
fa17f9d06c
Merge pull request #3639 from kubernetes-sigs/test/controller-run
test: controller run() and successfully shutdown
2024-05-03 12:53:43 -07:00
Sandor Szücs
1ee6c0a77d
fix: provide possibility to have a soft error mode to only log error and not fatal
Signed-off-by: Sandor Szücs <sandor.szuecs@zalando.de>
2024-01-09 22:13:24 +01:00
Sandor Szücs
2b50b14726
refactor: as suggested
fix: race as suggested

Signed-off-by: Sandor Szücs <sandor.szuecs@zalando.de>
2024-01-05 20:11:19 +01:00
Kubernetes Prow Robot
bc22050579
Merge pull request #3340 from gozer/issue/3339/last_reconcile_timestamp_seconds
Add external_dns_controller_last_reconcile_timestamp_seconds metric
2023-10-07 11:45:10 +02:00
John Gardiner Myers
94713c20c6 Add --exclude-record-types flag 2023-09-15 18:45:09 -07:00
Kubernetes Prow Robot
bb705a146d
Merge pull request #3911 from johngmyers/adjust-err
chore(providers): allow AdjustEndpoints to return error
2023-09-14 22:50:12 -07:00
Kubernetes Prow Robot
030342f445
Merge pull request #3747 from cronik/bugfix/dual-stack-records
Fix planning for multi-cluster dual stack record types
2023-09-14 22:24:12 -07:00
John Gardiner Myers
c596611f9e Allow AdjustEndpoints to return error 2023-09-03 11:23:03 -07:00
Kyle Cronin
20bff0aae5 Remove EndpointFilterInterface 2023-08-16 23:48:30 -04:00
John Gardiner Myers
e9be5887bd Remove DomainFilterInterface 2023-08-11 13:01:22 -07:00
John Gardiner Myers
5affab0561 Remove PropertyValuesEqual method from Provider interface 2023-08-04 04:56:43 -07:00
John Gardiner Myers
43eea7fa9b Refactor Provider to require DomainFilter 2023-06-19 20:25:59 -07:00
Matias Charriere
e938f5a67f
remove tests from missing endpoint tests from controller
the entire logic of missing endpoints was removed from the controller
taking leverage on the planner

Signed-off-by: Matias Charriere <matias@giantswarm.io>
2023-06-15 11:50:04 +02:00
Matias Charriere
1bd3834743
handle missing TXT records with a forcedUpdate strategy
This change tries to remove part of the logic added in 50f196c0db.
The forceUpdate strategy relies on existing code of the planner to migrate TXT records to the new format,
being the main goal to avoid conflicts during apply.

Signed-off-by: Matias Charriere <matias@giantswarm.io>
2023-06-15 11:50:04 +02:00
Sandor Szuecs
5af4ae0edc
test: controller run() should do somthing and successfully shutdown
Signed-off-by: Sandor Szuecs <sandor.szuecs@zalando.de>
2023-05-26 23:18:29 +02:00
Kubernetes Prow Robot
128bcf8d7f
Merge pull request #3009 from olemarkus/continue-on-bad-source
If an error propagates all the way out, bail execution
2023-05-08 04:43:17 -07:00
Philippe M. Chiasson
6e15aa0406
Merge branch 'master' into issue/3339/last_reconcile_timestamp_seconds 2023-04-14 02:08:34 -04:00
John Gardiner Myers
2eed9cb6ba Add AAAA records metrics 2023-03-30 17:49:31 -07:00
Philippe M. Chiasson
8389939f18
Add external_dns_controller_last_reconcile_timestamp_seconds metric 2023-01-25 21:33:18 -05:00
Ole Markus With
07dc39abc7 If controller error propagates all the way out, bail execution 2022-11-20 15:40:00 +01:00
Kubernetes Prow Robot
03e3d22298
Merge pull request #2609 from claudiumocanu/fix-reconcile-blocker
Do not reschedule, if already scheduled in the next MinInterval
2022-07-29 12:43:12 -07:00
Andrey Lebedev
0feb32de3c Handle the migration to the new TXT format: missing records to be created separately 2022-07-27 12:57:18 +02:00
Claudiu Mocanu
6e75baa356
Fixed type as suggested
Co-authored-by: Raffaele Di Fazio <raffo@github.com>
2022-07-23 17:47:38 +03:00
Andrey Lebedev
50f196c0db Handle the migration to the new TXT format: create missing records 2022-07-13 21:49:27 +02:00
claudiumocanu
58ae18439c ScheduleRunOnce if not already scheduled 2022-02-17 18:28:07 +02:00
Aditya Kolhar
19d9bc8ef9 Changes to add A records of source and registry as metrics
Changes to add A records of source and registry as metrics. The existing metrics -
external_dns_registry_endpoints_total & external_dns_source_endpoints_total gives a cumulative count of records all records (A, SRV, CNAME, TXT).

We have a metric - external_dns_controller_verified_records which gives the intersection of A records between source & regsitry. However, in order to determined how many records are yet to be synced to registry, we need count of total A records in registry & source.
2021-11-08 15:22:36 +05:30
Aditya Kolhar
39d5b39e18 Changes to add metric to external-dns.
1. external_dns_controller_verified_records - No of DNS A-records that exists both in source and registry - Gauge Metric
2021-10-27 13:51:31 +05:30
Dinar Valeev
c792d49c41
Fix controller tests
8d6f29b8a0 commit breaks
TestWhenNoFilterControllerConsidersAllComain and
TestWhenMultipleControllerConsidersAllFilteredComain tests,
lets fix them

Signed-off-by: Dinar Valeev <dinar.valeev@absa.africa>
2021-08-04 19:53:31 +02:00
Kubernetes Prow Robot
41ea66b7c6
Merge pull request #2078 from k0da/ns
Fix managed-record-types option
2021-08-04 08:35:24 -07:00
Dinar Valeev
8d6f29b8a0
Fix managed-record-types
Use config option instead of passing just A and CNAME

Signed-off-by: Dinar Valeev <dinar.valeev@absa.africa>
2021-05-13 17:03:13 +02:00
Thibault Jamet
0eebf53c95
Update controller/controller.go
Co-authored-by: Nick Jüttner <nick@juni.io>
2021-05-05 16:32:09 +02:00
Thibault Jamet
17fb8813d0
Reduce AWS Route53 API calls
Currently, planning instructs to create all records even
those which does not match any zone.
Later, those records will be checked towards the existing
records and filtered whether they match or not a hosted zone.

This causes a problem, at least in the specific case of the Route53
implementation as it always calls the ApplyChanges method, which in its
turn always retrieves all records in all zones.

This causes high pressure on Route53 APIs, for non-necessary actions.

By being able to filter all unmanaged records from the plan, we can
prevent from calling ApplyChanges when nothing has to be done and hence
prevent an unnecessary listing of records.

By doing so, the rate of API calls to AWS Route53 is expected to be
reduced by 2
2021-04-25 18:10:36 +02:00
Thibault Jamet
43f9f564b3
Rename MinInterval to MinEventSyncInterval
Co-authored-by: Raffaele Di Fazio <raffo@github.com>
2021-03-24 11:27:18 +01:00
Thibault Jamet
72b4b4f411
Add the ability to configure k8s event rate limit
Currently, the minimum delay between 2 kubernetes events handling is
hard-coded to 5s.

This may cause higher synchronization rates and higher DNS provider API
calls when handling an important number of kubernetes events at once.

Give the opportunity to configure this delay so service owners can
define the acceptable thresholds on their side
2021-03-16 11:59:00 +01:00
Raffaele Di Fazio
daeee26684
Add flag to opt in for NS records management (#1915)
* adds flag to opt in for NS records management

Signed-off-by: Raffaele Di Fazio <difazio.raffaele@gmail.com>

* go fmt

Signed-off-by: Raffaele Di Fazio <difazio.raffaele@gmail.com>

* goimports

Signed-off-by: Raffaele Di Fazio <difazio.raffaele@gmail.com>

* fix more tests

Signed-off-by: Raffaele Di Fazio <difazio.raffaele@gmail.com>

* go fmt again

Signed-off-by: Raffaele Di Fazio <difazio.raffaele@gmail.com>

* fix test

Signed-off-by: Raffaele Di Fazio <difazio.raffaele@gmail.com>

* more tests

Signed-off-by: Raffaele Di Fazio <difazio.raffaele@gmail.com>

* make ordering of managed records consistent

Signed-off-by: Raffaele Di Fazio <difazio.raffaele@gmail.com>

* fix flag

Signed-off-by: Raffaele Di Fazio <difazio.raffaele@gmail.com>
2021-01-12 06:32:26 -08:00
Guangwen Feng
b714e9f7a3 Fix typo in comment
Signed-off-by: Guangwen Feng <fenggw-fnst@cn.fujitsu.com>
2021-01-07 11:01:04 +08:00
Raffaele Di Fazio
f5aa1c4c37
Add new method to provider interface to implement provider specific changes (#1868)
* adds tests for shouldUpdateProviderSpecific

Signed-off-by: Raffaele Di Fazio <difazio.raffaele@gmail.com>

* move AWS health to where it belongs

Signed-off-by: Raffaele Di Fazio <difazio.raffaele@gmail.com>

* add test that breaks things

Signed-off-by: Raffaele Di Fazio <difazio.raffaele@gmail.com>

* adds adjustendpoints method

Signed-off-by: Raffaele Di Fazio <raffo@github.com>

* fix controller

Signed-off-by: Raffaele Di Fazio <raffo@github.com>

* actually pass the provider where needed

Signed-off-by: Raffaele Di Fazio <raffo@github.com>

* OMG goland do your go fmt thing

Signed-off-by: Raffaele Di Fazio <raffo@github.com>

* use registry as proxy

Signed-off-by: Raffaele Di Fazio <raffo@github.com>

* make linter happy

Signed-off-by: Raffaele Di Fazio <raffo@github.com>

* change AdjustEndpoints signature

Signed-off-by: Raffaele Di Fazio <raffo@github.com>

* fix typo

Signed-off-by: Raffaele Di Fazio <raffo@github.com>

* actually use adjusted endpoints

Signed-off-by: Raffaele Di Fazio <raffo@github.com>

* revert cloudflare change

Signed-off-by: Raffaele Di Fazio <raffo@github.com>

* Update provider/cloudflare/cloudflare.go

Co-authored-by: Nick Jüttner <nick@juni.io>

Co-authored-by: Nick Jüttner <nick@juni.io>
2020-12-09 23:40:54 -08:00
windayski
262822e2f6 fix typos 2020-10-30 03:28:57 +00:00