Commit Graph

394 Commits (dac0296f0b55a4042d9f747db4477efc278efa17)

Author SHA1 Message Date
Wojciech Tyczynski c789704e8e Switch kube-proxy to informers 2017-02-27 16:16:26 +01:00
Tim Hockin 1ce3395e7f Simplify stale-connection detection in kube-proxy 2017-02-15 12:39:49 -08:00
Tim Hockin 7046c7efcb Prep to move guts of OnEnpointsUpdate to sync
This makes it more obvious that they run together and makes the upcoming
rate-limited syncs easier.

Also make test use ints for ports, so it's easier to see when a port is
a literal value vs a name.
2017-02-15 10:37:05 -08:00
Tim Hockin cddda17d42 Make healthcheck an interface 2017-02-15 10:37:05 -08:00
Tim Hockin 6069d49d49 Add tests for updateEndpoints 2017-02-15 10:37:05 -08:00
Tim Hockin 8d24fc3984 Simplify maps which had almost the exact same info 2017-02-15 10:37:05 -08:00
Tim Hockin 48ea304711 Sanitize newEndpoints semantics, remove a dup arg 2017-02-15 10:37:05 -08:00
Tim Hockin 9507af3c79 Refactor OnEndpointsUpdate for testing
This is a weird function, but I didn't want to change any semantics
until the tests are in place.  Testing exposed one bug where stale
connections of renamed ports were not marked stale.

There are other things that seem wrong here, more will follow.
2017-02-15 10:37:05 -08:00
Tim Hockin d578105a44 Simple cleanup before refactoring 2017-02-15 10:37:05 -08:00
Tim Hockin 1c180e0865 Simplify "is local" detection
Move the feature test to where we are activating the feature, rather
than where we detect locality.  This is in service of better tests,
which is in service of less-frequent resyncing, which is going to
require refactoring.
2017-02-15 10:37:05 -08:00
Minhan Xia 572e3bebcc fix healthcheck update problem introduced by #41223 2017-02-13 12:18:42 -08:00
Minhan Xia 87fe4dca5e skip iptables sync if no endpoint changes 2017-02-10 10:03:23 -08:00
Klaus Ma f6aa8bbb8f Updated NodeRef to clientv1.ObjectReference. 2017-02-07 06:27:06 +08:00
deads2k 8a12000402 move client/record 2017-01-31 19:14:13 -05:00
deads2k c9a008dff3 move util/intstr to apimachinery 2017-01-30 12:46:59 -05:00
Dr. Stefan Schimanski 44ea6b3f30 Update generated files 2017-01-29 21:41:45 +01:00
Dr. Stefan Schimanski 79adb99a13 pkg/api: move Semantic equality to k8s.io/apimachinery/pkg/api/equality 2017-01-29 21:41:45 +01:00
deads2k b0b156b381 make tools/cache authoritative 2017-01-25 08:29:45 -05:00
Dr. Stefan Schimanski 2b8e938128 Update generated files 2017-01-24 20:56:03 +01:00
Dr. Stefan Schimanski a6b2ebb50c pkg/flag: make feature gate extensible and split between generic and kube 2017-01-24 20:56:03 +01:00
Dr. Stefan Schimanski 56d60cfae6 pkg/util: move flags from pkg/util/config to pkg/util/flags 2017-01-24 20:56:03 +01:00
deads2k 5a8f075197 move authoritative client-go utils out of pkg 2017-01-24 08:59:18 -05:00
Clayton Coleman 9009c1ac14
generated: informer,client 2017-01-23 17:52:47 -05:00
Clayton Coleman 469df12038
refactor: move ListOptions references to metav1 2017-01-23 17:52:46 -05:00
deads2k 11e8068d3f move pkg/fields to apimachinery 2017-01-19 09:50:16 -05:00
deads2k c47717134b move utils used in restclient to client-go 2017-01-19 07:55:14 -05:00
Clayton Coleman 9a2a50cda7
refactor: use metav1.ObjectMeta in other types 2017-01-17 16:17:19 -05:00
Dan Williams 5907639140 proxy/iptables: clean up service map creation
Instead of copying the map, like OnServicesUpdate() used to do and which
was copied into buildServiceMap() to preserve semantics while creating
testcases, start with a new empty map and do deletion checking later.
2017-01-11 15:17:55 -06:00
Dan Williams 6aa784e6f2 proxy/iptables: don't sync proxy rules if services map didn't change 2017-01-11 14:46:12 -06:00
Dan Williams 433f6830f8 proxy/iptables: don't proxy ExternalName services
The API docs say:

	// ServiceTypeExternalName means a service consists of only a reference to
	// an external name that kubedns or equivalent will return as a CNAME
	// record, with no exposing or proxying of any pods involved.

which implies that ExternalName services should be ignored for proxy
purposes.
2017-01-11 14:46:12 -06:00
Dan Williams eae2b8e9ba proxy/iptables: split out service map creation and add testcases 2017-01-11 14:46:12 -06:00
deads2k 6a4d5cd7cc start the apimachinery repo 2017-01-11 09:09:48 -05:00
Jeff Grafton 20d221f75c Enable auto-generating sources rules 2017-01-05 14:14:13 -08:00
Mike Danese 161c391f44 autogenerated 2016-12-29 13:04:10 -08:00
Kubernetes Submit Queue ff8e8c6778 Merge pull request #38920 from k82cn/k8s_37979
Automatic merge from submit-queue

Add event when failed to open local port.

fixes #37979 .
2016-12-22 21:32:27 -08:00
Klaus Ma b0dfa4ad47 Add event when failed to open local port. 2016-12-23 04:51:12 +08:00
Brendan Burns 47b79de76e Refactor port allocation logic a little, deflake tests. 2016-12-18 21:18:34 -08:00
Dan Winship d95181fa1e Port iptables code to pkg/util/version, don't use semvers 2016-12-13 08:53:04 -05:00
Mike Danese c87de85347 autoupdate BUILD files 2016-12-12 13:30:07 -08:00
Kubernetes Submit Queue 4fb21c8409 Merge pull request #37429 from andrewsykim/fix-kube-proxy-node-ip-warning
Automatic merge from submit-queue (batch tested with PRs 35884, 37305, 37369, 37429, 35679)

fix mixleading warning message regarding kube-proxy nodeIP initializa…

The current warning message implies that the operator should restart kube-proxy with some flag related to node IP which can be very misleading.
2016-12-08 03:55:17 -08:00
Kubernetes Submit Queue 08c0f7dded Merge pull request #27711 from xiangpengzhao/port-allocator-test
Automatic merge from submit-queue

Cover port_allocator_test with more conditions

The test cases of port_allocator_test should cover more conditions, such as `rangeAllocator.used.Bit`.
2016-12-07 12:14:36 -08:00
Eric Paris 78798f6191 Remove girishkalele from most places
This also updates the maintainers list and reassigns his tests
2016-12-05 19:29:34 -05:00
Kubernetes Submit Queue 6abb472357 Merge pull request #37720 from freehan/lb-src-update
Automatic merge from submit-queue

Fix Service Update on LoadBalancerSourceRanges Field

Fixes: https://github.com/kubernetes/kubernetes/issues/33033
Also expands: https://github.com/kubernetes/kubernetes/pull/32748
2016-12-01 18:21:39 -08:00
Kubernetes Submit Queue 9defe2ce99 Merge pull request #32561 from zreigz/fix-incoming-udp
Automatic merge from submit-queue

Bug fix. Incoming UDP packets not reach newly deployed services

**What this PR does / why we need it**:

Incoming UDP packets not reach newly deployed services when old connection's state in conntrack is not cleared. When a packet arrives, it will not go through NAT table again, because it is not "the first" packet. The PR fix the issue

**Which issue this PR fixes** 
Fixes #31983
xref https://github.com/docker/docker/issues/8795
2016-12-01 16:02:03 -08:00
Kubernetes Submit Queue 5c2117764b Merge pull request #36055 from m1093782566/m109-fix-proxy-hasjump
Automatic merge from submit-queue

[kube-proxy] Fix Jump() bug in pkg/proxy/iptables/proxier_test.go

<!--  Thanks for sending a pull request!  Here are some tips for you:
1. If this is your first time, read our contributor guidelines https://github.com/kubernetes/kubernetes/blob/master/CONTRIBUTING.md and developer guide https://github.com/kubernetes/kubernetes/blob/master/docs/devel/development.md
2. If you want *faster* PR reviews, read how: https://github.com/kubernetes/kubernetes/blob/master/docs/devel/faster_reviews.md
3. Follow the instructions for writing a release note: https://github.com/kubernetes/kubernetes/blob/master/docs/devel/pull-requests.md#release-notes
-->

**Which issue this PR fixes**

Fixes #36043
2016-12-01 06:31:27 -08:00
Lukasz Zajaczkowski dc54a8d46e Bug fix. Incoming UDP packets not reach newly deployed services 2016-12-01 08:52:30 +01:00
Minhan Xia 1c2c0c1f63 support service loadBalancerSourceRange update 2016-11-30 15:27:34 -08:00
Kubernetes Submit Queue 8a99f17f24 Merge pull request #37454 from xiaolou86/close-channel
Automatic merge from submit-queue

fix bug of closing the same channel multiple times

<!--  Thanks for sending a pull request!  Here are some tips for you:
1. If this is your first time, read our contributor guidelines https://github.com/kubernetes/kubernetes/blob/master/CONTRIBUTING.md and developer guide https://github.com/kubernetes/kubernetes/blob/master/docs/devel/development.md
2. If you want *faster* PR reviews, read how: https://github.com/kubernetes/kubernetes/blob/master/docs/devel/faster_reviews.md
3. Follow the instructions for writing a release note: https://github.com/kubernetes/kubernetes/blob/master/docs/devel/pull-requests.md#release-notes
-->


**Which issue this PR fixes**: fixes #37444 

**Release note**:None
2016-11-30 08:43:51 -08:00
Kubernetes Submit Queue 919dfc4211 Merge pull request #36523 from apelisse/owners-pkg-proxy
Automatic merge from submit-queue

Curating Owners: pkg/proxy

cc @thockin

In an effort to expand the existing pool of reviewers and establish a
two-tiered review process (first someone lgtms and then someone
experienced in the project approves), we are adding new reviewers to
existing owners files.


If You Care About the Process:
------------------------------

We did this by algorithmically figuring out who’s contributed code to
the project and in what directories.  Unfortunately, that doesn’t work
well: people that have made mechanical code changes (e.g change the
copyright header across all directories) end up as reviewers in lots of
places.

Instead of using pure commit data, we generated an excessively large
list of reviewers and pruned based on all time commit data, recent
commit data and review data (number of PRs commented on).

At this point we have a decent list of reviewers, but it needs one last
pass for fine tuning.

Also, see https://github.com/kubernetes/contrib/issues/1389.

TLDR:
-----

As an owner of a sig/directory and a leader of the project, here’s what
we need from you:

1. Use PR https://github.com/kubernetes/kubernetes/pull/35715 as an example.

2. The pull-request is made editable, please edit the `OWNERS` file to
remove the names of people that shouldn't be reviewing code in the
future in the **reviewers** section. You probably do NOT need to modify
the **approvers** section. Names asre sorted by relevance, using some
secret statistics.

3. Notify me if you want some OWNERS file to be removed.  Being an
approver or reviewer of a parent directory makes you a reviewer/approver
of the subdirectories too, so not all OWNERS files may be necessary.

4. Please use ALIAS if you want to use the same list of people over and
over again (don't hesitate to ask me for help, or use the pull-request
above as an example)
2016-11-28 11:42:49 -08:00
LouZhengwei 9fe0b88f92 fix bug of closing the same channel multiple times 2016-11-24 23:41:48 +08:00