1560 Commits

Author SHA1 Message Date
ahrtr
900fc8dd7e replace gobin with go install
The repository github.com/myitcv/gobin has already been archived,
and the `go install` command accepts arguments with version suffixs
starting from 1.16 (for example, go install example.com/cmd@v1.0.0).
So there is no reason to continue to use gobin.
2022-02-08 05:41:21 +08:00
Marek Siarkowicz
a1f3c2c7cc server: Make --v2-deprecation=write-only the default and remove not-yet option 2022-02-02 13:55:52 +01:00
Marek Siarkowicz
396efd9608 Cleanup scripts in root directory 2022-02-02 13:50:44 +01:00
Marek Siarkowicz
986a2b51f4
Merge pull request #13636 from serathius/remove-v2-client
Remove v2 server
2022-02-02 11:41:56 +01:00
Marek Siarkowicz
902dc05014 tests: Update assertAuthority to explain filtering put method requests 2022-02-01 16:47:23 +01:00
Marek Siarkowicz
43c1631f26 tests: Use cmp.Equal to avoid mutating arguments 2022-02-01 16:47:18 +01:00
Piotr Tabor
a99c919a9f
Merge pull request #13651 from serathius/coverage
Re-enable code coverage upload
2022-01-28 13:54:33 +01:00
ahrtr
a879ccf152 updated servePeers to remvoe the grpc server 2022-01-27 16:22:01 +08:00
ahrtr
1713dc67b5 etcd server shouldn't wait for the ready notification infinitely on startup 2022-01-27 16:19:20 +08:00
Marek Siarkowicz
50b09d4f88 Re-enable code coverage upload 2022-01-26 20:18:43 +01:00
Marek Siarkowicz
692b3c4cd7 server: Remove most of V2 API 2022-01-25 15:24:13 +01:00
Marek Siarkowicz
37879eb5f9 test: Migrate WaitMembersMatch to V3 API 2022-01-25 13:56:17 +01:00
Marek Siarkowicz
c59694d41e test: Migrate WaitMembersForLeader to V3 API 2022-01-24 17:26:51 +01:00
Marek Siarkowicz
81490c25d1 test: Migrate WaitStarted to V3 API 2022-01-24 17:26:50 +01:00
Marek Siarkowicz
ee6306b9f9 Migrate RemoveMember and AddMember to V3 API 2022-01-24 17:01:22 +01:00
Eng Zer Jun
e9edc5432c
*: use T.TempDir to create temporary test directory
The directory created by `T.TempDir()` and is automatically removed when
the test and all its subtests complete.

Reference: https://pkg.go.dev/testing#T.TempDir
Signed-off-by: Eng Zer Jun <engzerjun@gmail.com>
2022-01-25 00:00:46 +08:00
Marek Siarkowicz
3788523a3e tests: Move revision tests out of concurrency 2022-01-24 15:33:30 +01:00
Marek Siarkowicz
a53074542b test: Run v2 discovery tests on previous version binary 2022-01-20 14:10:09 +01:00
Marek Siarkowicz
264fdbb6a1 test: Remove separation between V2 and V3 cluster in integration tests 2022-01-20 14:10:09 +01:00
Marek Siarkowicz
7b365e48d3 test: Remove usage of V2 Put API in tests 2022-01-20 14:10:09 +01:00
Marek Siarkowicz
de30257d79 test: Always run server with grpc enabled 2022-01-20 14:10:09 +01:00
Marek Siarkowicz
51f72915e4 test: Move UseGRPC to member config 2022-01-20 14:10:09 +01:00
Marek Siarkowicz
87c8e8b868 test: Migrate to ClusterV3 cluster in integration tests 2022-01-20 14:10:09 +01:00
Marek Siarkowicz
69fc517e56 test: Add StrictReconfigCheck to cluster 2022-01-20 14:10:09 +01:00
Marek Siarkowicz
98242da5f1 test: Handle adding new members for clusters with TCP enabled 2022-01-20 14:10:09 +01:00
Marek Siarkowicz
5bcbf77980 tests: Move client to member struct 2022-01-20 14:10:09 +01:00
Piotr Tabor
fdd98477ef Update dep: require gopkg.in/yaml.v2 v2.2.8 -> v2.4.0 due to: CVE-2019-11254 2022-01-17 16:52:58 +01:00
Piotr Tabor
19cb0a4252
Merge pull request #13519 from ahrtr/enhance_make_mirror_command
Add a new flag "--rev" to make-mirror command to support incremental mirror
2022-01-15 17:02:12 +01:00
Piotr Tabor
1237b3576c
Merge pull request #13487 from mrueg/go-1.17.3
*: Bump to go 1.17.6
2022-01-15 17:01:17 +01:00
Piotr Tabor
b2f6ffdd81
Merge pull request #13595 from serathius/enable-v2
server: --enable-v2 and --enable-v2v3 is decomissioned
2022-01-15 16:48:29 +01:00
Piotr Tabor
f75549d53b
Merge pull request #13571 from yank1/update-cobra-version
Update Cobra version to 1.2.1
2022-01-14 14:54:28 +01:00
Marek Siarkowicz
ee5ef42c5c server: --enable-v2 and --enable-v2v3 is decomissioned 2022-01-14 13:19:30 +01:00
Marek Siarkowicz
eac6d71352 tests: Add integration test for revision monotonic under failure injection 2022-01-12 11:51:12 +01:00
Manuel Rüger
ce086a4ba6 *: Bump to go 1.17.6
Signed-off-by: Manuel Rüger <manuel@rueg.eu>
2022-01-12 03:13:27 +01:00
Manuel Rüger
746c0ea276 tests/Dockerfile: Update base to ubuntu 21.10
Signed-off-by: Manuel Rüger <manuel@rueg.eu>
2022-01-12 03:00:08 +01:00
Manuel Rüger
cf7e8b3535 go.mod: Bump golang.org/x/net dependency; regenerate go.sum
Bumps golang.org/x/net dependency due to fix CVE-2021-44716
as requested in https://github.com/etcd-io/etcd/pull/13487#issuecomment-997065540

Signed-off-by: Manuel Rüger <manuel@rueg.eu>
2022-01-12 03:00:08 +01:00
Manuel Rüger
ce50f68166 *: Bump to go 1.17.5 2022-01-12 03:00:08 +01:00
Yap Sok Ann
17fd2e7282 Disable auth gracefully without impacting existing watchers
This attempts to fix a special case of the problem described in #12385,
where trying to do `clientv3.Watch` with an expired token would result
in `ErrGRPCPermissionDenied`, due to the failing authorization check in
`isWatchPermitted`. Furthermore, the client can't auto recover, since
`shouldRefreshToken` rightly returns false for the permission denied
error.

In this case, we would like to have a runbook to dynamically disable
auth, without causing any disruption. Doing so would immediately expire
all existing tokens, which would then cause the behavior described
above. This means existing watchers would still work for a period of
time after disabling auth, until they have to reconnect, e.g. due to a
rolling restart of server nodes.

This commit adds a client-side fix and a server-side fix, either of
which is sufficient to get the added test case to pass. Note that it is
an e2e test case instead of an integration one, as the reconnect only
happens if the server node is stopped via SIGINT or SIGTERM.

A generic fix for the problem described in #12385 would be better, as
that shall also fix this special case. However, the fix would likely be
a lot more involved, as some untangling of authn/authz is required.
2021-12-31 14:39:46 +07:00
Your Name
77bf0a5a9e update cobra version to 1.2.1
Signed-off-by: yankay <kay.yan@daocloud.io>
2021-12-29 17:35:25 +08:00
ahrtr
661e0a91ef added a new flag --rev to make-mirror command to support incremental mirror 2021-12-22 16:59:44 +08:00
Marek Siarkowicz
7d10899d7f server: Require either cluster version v3.6 or --experimental-enable-lease-checkpoint-persist to persist lease remainingTTL
To avoid inconsistant behavior during cluster upgrade we are feature
gating persistance behind cluster version. This should ensure that
all cluster members are upgraded to v3.6 before changing behavior.

To allow backporting this fix to v3.5 we are also introducing flag
--experimental-enable-lease-checkpoint-persist that will allow for
smooth upgrade in v3.5 clusters with this feature enabled.
2021-12-02 12:26:47 +01:00
Piotr Resztak
e24796e8eb e2e: Call WithStopSignal on proxyV2 object 2021-12-02 01:02:24 +01:00
Michał Jasionowski
fd77b2700c etcdserver,integration: Store remaining TTL on checkpoint
To extend lease checkpointing mechanism to cases when the whole etcd
cluster is restarted.
2021-11-26 15:17:22 +01:00
Michał Jasionowski
48a360aad0 lease,integration: add checkpoint scheduling after leader change
Current checkpointing mechanism is buggy. New checkpoints for any lease
are scheduled only until the first leader change. Added fix for that
and a test that will check it.
2021-11-26 14:34:19 +01:00
Kushal Pisavadia
71493bde3e *: Upgrade to use go.opentelemetry.io/otel@v1.2.0
Upgrading from v1.0.1.

Upgrading related dependencies
------------------------------

The following dependencies also had to be upgraded:

- go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.26.1
  From v0.25.0. This gets rid of a transitive dependency on go.opentelemetry.io/otel@v1.0.1.
- google.golang.org/genproto@v0.0.0-20211118181313-81c1377c94b1
2021-11-24 16:03:33 +00:00
Sam Batschelet
29c3b0f307
Merge pull request #13377 from hexfusion/add-learner-limit-flag
Add experimental-max-learners flag
2021-11-15 09:49:18 -05:00
Chao Chen
b5e4c2d3c4 client/v2: remove unsafe json-iterator/reflect2 2021-11-09 11:16:40 -08:00
Sam Batschelet
63a1cc3fe4 add --experimental-max-learner flag
Signed-off-by: Sam Batschelet <sbatsche@redhat.com>
2021-11-09 09:52:00 -05:00
Piotr Tabor
6c2f5dc78a
Merge pull request #13405 from serathius/downgrade-b
Implement single node downgrades
2021-10-29 23:22:10 +02:00
Piotr Tabor
9c28e07588
Merge pull request #13447 from Juneezee/deprecate-ioutil
*: move from io/ioutil to io and os packages
2021-10-29 23:18:36 +02:00