11 Commits

Author SHA1 Message Date
Aaron U'Ren
d2178da5f2
fix(ecmp_vip): check for nil nodename (#903)
While rare that NodeName is missing it is not guaranteed to exist by the
Kubernetes API (see link below). This retains checking via NodeName
first if it exists, but if it's nil rather than segfaulting it evaluates
the via IP address.

Fixes #781

https://github.com/cloudnativelabs/kube-router/blob/master/vendor/k8s.io/api/core/v1/types.go#L3487
2020-05-24 20:30:18 +05:30
Murali Reddy
0f21f87fd5
withdraw external IP from advertisement only if the deleted service is the last service using external IP (#850)
* withdraw external IP from advertisement only if the deleted service
is the last service using external IP

Fixes #828

* addressing review comment
2020-04-23 08:18:56 +05:30
Murali Reddy
4c764f5486
handle DeletedFinalStateUnknown objects in DeleteFunc handlers (#856)
* in DeleteFunc handlers across the controllers  handle the case where received object can be of
type DeletedFinalStateUnknown

fixes one of the symptoms (panic on receiving DeletedFinalStateUnknown objects) reported in #712

* address review comments
2020-04-13 15:57:14 +05:30
Tom Pointon
d6f9f31a7b Fix: Send BGP Withdrawals for Service VIPs Upon Service Deletion (#756)
* Refactor: seperate fetching service VIPs from advertise/withdrawal decision

* Refactor: simplify advertise/withdrawal logic

* Pass svcDeleted param to getVIPsForService

* Don't advertise VIPs from deleted services

* Test for withdrawing VIPs from deleted service

* Refactor: use explicit handleServiceDelete functions
2019-09-19 17:55:15 +05:30
Aaron U'Ren
8fe9f70dd5 Add Import Policy for Service VIPs (#721)
* rename export policies to make it direction independent

* split creating neighborsets and prefixsets from applying export policy

* add bgp import policy to deny service VIPs

* add tests for addition of import policy
2019-05-26 23:29:10 +05:30
Matus Kral
961d8ab84c fix #639 (#670)
* - refactor / clean up / extract code dupes into methods and reuse

* - fix 639
- get external IPs to withdraw as diff against previous generation
  of service
2019-03-10 15:00:16 +05:30
Steven Armstrong
1a30f9e2e1 implement per-service annotations to control IP advertisment (#575)
* add unit tests for implementing #75

Signed-off-by: Steven Armstrong <steven.armstrong@id.ethz.ch>

* integration tests for #75

Signed-off-by: Steven Armstrong <steven.armstrong@id.ethz.ch>

* update docs for #75

Signed-off-by: Steven Armstrong <steven.armstrong@id.ethz.ch>

* define new kube-router.io/service.advertise.* annotations

Signed-off-by: Steven Armstrong <steven.armstrong@id.ethz.ch>

* Implement per service annotations for advertising IPs.

Signed-off-by: Steven Armstrong <steven.armstrong@id.ethz.ch>

* more consistent annotation names

Signed-off-by: Steven Armstrong <steven.armstrong@id.ethz.ch>

* remove redundant tests

Signed-off-by: Steven Armstrong <steven.armstrong@id.ethz.ch>
2018-12-09 10:38:12 +05:30
Andrew Sy Kim
94e163b5d7 update BGP export policies on endpoints add event (#508) 2018-08-10 19:40:37 +05:30
Murali Reddy
6d86656f5e
fix wrong use of advertiseVIPs where withdrawVIPs is required (#436) 2018-05-13 09:14:09 +05:30
Murali Reddy
b0733cb581
update clusteripprefixset so that BGP export policies allow advertising the service VIP (#435) 2018-05-13 08:32:36 +05:30
Murali Reddy
23d43622ec
split routing controllers to smaller modules by function (#406)
* split routing controllers to smaller modules by function

* review comments
2018-04-23 05:42:28 +00:00