583 Commits

Author SHA1 Message Date
Marek Siarkowicz
3b252db4f6 version: bump up to 3.5.11 2023-12-07 11:29:12 +01:00
James Blair
f952197890
Backport embed: Add tracing integration test.
Signed-off-by: James Blair <mail@jamesblair.net>
2023-11-26 10:30:49 +13:00
sharath sivakumar
f26074ae56 CVE-2023-47108: Backport go.opentelemetry.io/otel@v1.20.0 and go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc@v0.46.0
Signed-off-by: sharath sivakumar <sharath.sivakumar@mollie.com>
2023-11-15 14:09:07 +01:00
Marek Siarkowicz
0223ca52b8 version: bump up to 3.5.10 2023-10-27 12:33:25 +02:00
Benjamin Wang
88beb6ca47 bump bbolt to 1.3.8 for etcd 3.5
Signed-off-by: Benjamin Wang <wachao@vmware.com>
2023-10-26 16:32:07 +01:00
Benjamin Wang
3521aaad9a
Merge pull request #16790 from chaochn47/3.5-grpc-update
[3.5] Upgrade gRPC-go to 1.58.3
2023-10-19 10:21:36 +01:00
Marek Siarkowicz
31b7c58fd5
Merge pull request #16637 from serathius/check-cluster-id-release-3.5
[release-3.5] etcdserver: add cluster id check for hashKVHandler
2023-10-17 20:58:21 +02:00
Chao Chen
1aa4aa8a96 3.5: upgrade gRPC-go to 1.58.3
The last step with gRPC update behavior changes auditing to resolve CVE #16740 in 3.5

This PR backports #14922, #16338, #16587, #16630, #16636 and #16739 to release-3.5.

Signed-off-by: Chao Chen <chaochn@amazon.com>
2023-10-17 11:07:08 -07:00
Marek Siarkowicz
5b8150a6cf Backport corrupt check test fix "etcd server shouldn't wait for the ready notification infinitely on startup"
Signed-off-by: Marek Siarkowicz <siarkowicz@google.com>
2023-10-17 14:37:14 +02:00
caojiamingalan
04cfb4c660 etcdserver: add cluster id check for hashKVHandler
Signed-off-by: caojiamingalan <alan.c.19971111@gmail.com>
Signed-off-by: Marek Siarkowicz <siarkowicz@google.com>
2023-10-17 13:27:47 +02:00
Chao Chen
6f4fa5a27a [release-3.5]: upgrade gRPC-go to v1.52.0
backport https://github.com/etcd-io/etcd/pull/14834 and https://github.com/etcd-io/etcd/pull/16324

Signed-off-by: Chao Chen <chaochn@amazon.com>
2023-10-16 21:43:00 -07:00
Chao Chen
db16069588 backport #14125 to release-3.5: Update to grpc-1.47 (and fix the connection-string format)
Signed-off-by: Chao Chen <chaochn@amazon.com>
2023-10-12 09:46:49 -07:00
Marek Siarkowicz
404eeaa74e Return to default write scheduler since golang.org/x/net@v0.11.0 started using round robin
Introduction of round robin 120fc906b3
Added in v0.10.0 https://github.com/golang/net/compare/v0.10.0...v0.11.0

Signed-off-by: Marek Siarkowicz <siarkowicz@google.com>
2023-10-12 15:19:17 +02:00
Allen Ray
24ee8e491f bump golang.org/x/net to 0.17.0
Part of https://github.com/etcd-io/etcd/issues/16740

Signed-off-by: Allen Ray <alray@redhat.com>
2023-10-11 10:43:51 -04:00
James Blair
bfb3494c06
Remove obsolete http 1.0 version.
From TestConnectionMultiplexing to ensure the test will run successfully in Debian 12.

Signed-off-by: James Blair <mail@jamesblair.net>
2023-09-10 21:02:38 +12:00
James Blair
baa580a0b6
Backport redirect metrics data into file to reduce output.
Signed-off-by: James Blair <mail@jamesblair.net>
2023-09-07 20:42:03 +12:00
Wei Fu
68e09defdf test: add v3 curl test to cover maintenance hash/hashkv REST API
Signed-off-by: Benjamin Wang <wachao@vmware.com>
Signed-off-by: Wei Fu <fuweid89@gmail.com>
2023-08-28 21:00:46 +08:00
James Blair
b9e5d9666a
tests: Backport deflake for TestWatchDelay
Signed-off-by: James Blair <mail@jamesblair.net>
2023-08-19 21:41:56 +12:00
James Blair
9c7c8c6b3f
Backport update to golang 1.20 minor release.
Signed-off-by: James Blair <mail@jamesblair.net>
2023-08-11 21:16:01 +12:00
caojiamingalan
6ac9d94d67 etcdserver: backport check scheduledCompactKeyName and finishedCompactKeyName before writing hash to release-3.5.
Fix #15919.
Check ScheduledCompactKeyName and FinishedCompactKeyName
before writing hash to hashstore.
If they do not match, then it means this compaction has once been interrupted and its hash value is invalid. In such cases, we won't write the hash values to the hashstore, and avoids the incorrect corruption alarm.

Signed-off-by: caojiamingalan <alan.c.19971111@gmail.com>
2023-07-14 19:22:38 -05:00
Lan Liang
960cd26bef Backport #13577
Disable auth gracefully without impacting existing watchers.

Signed-off-by: Lan Liang <gcslyp@gmail.com>
2023-07-14 12:50:21 +08:00
zhangwenkang
6be3ad36be clientv3: remove v3.WithFirstKey() in Barrier.Wait()
fix the unexpected blocking when using Barrier.Wait(), e.g.
NewBarrier(client, "a").Wait() will block if key "a" is not existed but "a0" is existed, but it should return immediately.

Signed-off-by: zhangwenkang <zwenkang@vmware.com>
2023-07-06 16:18:52 +08:00
Thomas Jungblut
4425ef572e Adding optional revision bump and mark compacted to snapshot restore
Signed-off-by: Allen Ray <alray@redhat.com>
Signed-off-by: Thomas Jungblut <tjungblu@redhat.com>
2023-07-03 12:57:12 +02:00
kkkkun
dca13c6d47 replace gobin with go install
Signed-off-by: kkkkun <scuzk373x@gmail.com>
2023-06-09 14:17:37 +08:00
Hubert Zhang
98117389d2 Fix test of clientv3/naming
Signed-off-by: Hubert Zhang <hubert.zyk@gmail.com>
2023-05-24 06:58:39 +00:00
Ramil Mirhasanov
2158f21ad5 clientv3/naming/endpoints: fix endpoints prefix bug
fixes bug with multiple endpoints with same prefix

Signed-off-by: Ramil Mirhasanov <ramil600@yahoo.com>
2023-05-23 12:00:21 +00:00
yellowzf
ecfed91e50 grpcproxy: fix memberlist results not update when proxy node down
If start grpc proxy with --resolver-prefix, memberlist will return all alive proxy nodes, when one grpc proxy node is down, it is expected to not return the down node, but it is still return

Signed-off-by: yellowzf <zzhf3311@163.com>
2023-05-16 11:35:31 +08:00
Marek Siarkowicz
bdbbde998b version: bump up to 3.5.9 2023-05-11 13:39:43 +02:00
Hitoshi Mitake
e38eb678bb tests: e2e and integration test for timetolive
Signed-off-by: Hitoshi Mitake <h.mitake@gmail.com>
Co-authored-by: Benjamin Wang <wachao@vmware.com>
2023-05-08 22:47:58 +09:00
Marek Siarkowicz
217d183e5a version: bump up to 3.5.8 2023-04-13 12:08:47 +02:00
Benjamin Wang
cd019255ba etcdserver: Guarantee order of requested progress notifications
Progress notifications requested using ProgressRequest were sent
directly using the ctrlStream, which means that they could race
against watch responses in the watchStream.

This would especially happen when the stream was not synced - e.g. if
you requested a progress notification on a freshly created unsynced
watcher, the notification would typically arrive indicating a revision
for which not all watch responses had been sent.

This changes the behaviour so that v3rpc always goes through the watch
stream, using a new RequestProgressAll function that closely matches
the behaviour of the v3rpc code - i.e.

1. Generate a message with WatchId -1, indicating the revision for
   *all* watchers in the stream

2. Guarantee that a response is (eventually) sent

The latter might require us to defer the response until all watchers
are synced, which is likely as it should be. Note that we do *not*
guarantee that the number of progress notifications matches the number
of requests, only that eventually at least one gets sent.

Signed-off-by: Benjamin Wang <wachao@vmware.com>
2023-04-11 09:51:48 +08:00
Marek Siarkowicz
4501fd88c7
Merge pull request #15619 from mitake/3.5-backport-15294
[3.5] backport 15294
2023-04-07 17:47:23 +02:00
Benjamin Wang
291cb7172a test: add an e2e test to reproduce https://nvd.nist.gov/vuln/detail/CVE-2021-28235
Signed-off-by: Benjamin Wang <wachao@vmware.com>
2023-04-06 20:11:20 +09:00
Hitoshi Mitake
e6eeca6885 server/auth: disallow creating empty permission ranges
Signed-off-by: Hitoshi Mitake <h.mitake@gmail.com>
Co-authored-by: Benjamin Wang <wachao@vmware.com>
2023-04-03 22:55:55 +09:00
Wei Fu
55bce22e97 chore: enable strict mode for test CI
Signed-off-by: Wei Fu <fuweid89@gmail.com>
2023-04-02 08:57:56 +08:00
Marek Siarkowicz
6637aee804 tests: Test separate http port connection multiplexing
Signed-off-by: Marek Siarkowicz <siarkowicz@google.com>
2023-03-30 16:01:28 +02:00
Marek Siarkowicz
c0421c7330 server: Add --listen-client-http-urls flag to allow running grpc server separate from http server
Difference in load configuration for watch delay tests show how huge the
impact is. Even with random write scheduler grpc under http
server can only handle 500 KB with 2 seconds delay. On the other hand,
separate grpc server easily hits 10, 100 or even 1000 MB within 100 miliseconds.

Priority write scheduler that was used in most previous releases
is far worse than random one.

Tests configured to only 5 MB to avoid flakes and taking too long to fill
etcd.

Signed-off-by: Marek Siarkowicz <siarkowicz@google.com>
2023-03-30 15:53:11 +02:00
Marek Siarkowicz
63576a25f5 refactor: Use proper variable names for urls
Signed-off-by: Marek Siarkowicz <siarkowicz@google.com>
2023-03-30 15:11:58 +02:00
Wei Fu
9e974792f9 server/embed: fix data race when start insecure grpc
There are two goroutines accessing the `gs` grpc server var. Before
insecure `gs` server start, the `gs` can be changed to secure server and
then the client will fail to connect to etcd with insecure request. It
is data-race. We should use argument for reference in the new goroutine.

fix: #15495

Signed-off-by: Wei Fu <fuweid89@gmail.com>
(cherry picked from commit a9988e2625eede1af81d189b5f2ecf7d4af3edf1)
Signed-off-by: Wei Fu <fuweid89@gmail.com>
2023-03-20 20:41:49 +08:00
Marek Siarkowicz
86101d333b tests: Add v2 API to connection multiplexing test
Signed-off-by: Marek Siarkowicz <siarkowicz@google.com>
2023-03-17 10:51:36 +01:00
Marek Siarkowicz
eb614c35f7 tests: Add connection muiltiplexer testing
Signed-off-by: Marek Siarkowicz <siarkowicz@google.com>
2023-03-17 10:51:35 +01:00
Marek Siarkowicz
2eeb26083f tests: Backport RunUtilCompletion
Signed-off-by: Marek Siarkowicz <siarkowicz@google.com>
2023-03-17 10:50:21 +01:00
Marek Siarkowicz
00e1e5db21 tests: Backport tls for etcdctl
Signed-off-by: Marek Siarkowicz <siarkowicz@google.com>
2023-03-17 10:50:19 +01:00
Marek Siarkowicz
46d6c1d7b2 tests: Extract e2e test utils
Consider creating generic testutils for both e2e and integration tests.

Signed-off-by: Marek Siarkowicz <siarkowicz@google.com>
2023-03-16 17:24:42 +01:00
Marek Siarkowicz
2f4d75feb1 tests: Allow specifying http version in curl
Signed-off-by: Marek Siarkowicz <siarkowicz@google.com>
2023-03-16 17:24:42 +01:00
Marek Siarkowicz
4e9911ec26 tests: Refactor newClient args
Signed-off-by: Marek Siarkowicz <siarkowicz@google.com>
2023-03-16 17:24:42 +01:00
Marek Siarkowicz
64bc55ef4e tests: Refactor CURLPrefixArgs
Signed-off-by: Marek Siarkowicz <siarkowicz@google.com>
2023-03-16 17:24:42 +01:00
Benjamin Wang
11ca1d356a
Merge pull request #15483 from jmhbnz/release-3.5-backport
[3.5] Backport tls 1.3 support
2023-03-16 06:06:45 +08:00
James Blair
358bcf3fb6
Backport tls 1.3 support.
Signed-off-by: James Blair <mail@jamesblair.net>
2023-03-15 14:10:14 +13:00
Marek Siarkowicz
3f96014d2d test: Test etcd watch stream starvation under high read response load when sharing the same connection
Signed-off-by: Marek Siarkowicz <siarkowicz@google.com>
2023-03-14 09:16:46 +01:00