J. David Lowe
8552d8ec20
etcdserver: don't activate alarm w/missing AlarmType
...
Narrowly prevent etcd from crashing when given a bad ACTIVATE payload, e.g.:
$ curl -d "{\"action\":\"ACTIVATE\"}" ${ETCD}/v3/maintenance/alarm
curl: (52) Empty reply from server
2021-06-04 12:18:56 -07:00
Gyuho Lee
57034e1b51
Merge pull request #13075 from wilsonwang371/no-unnecessary-proto_size
...
server: skip unnecessary sprintf which executes proto.Size()
2021-06-03 13:10:11 -07:00
Wilson Wang
11edc76b15
server: skip unnecessary sprintf which executes proto.Size()
2021-06-03 12:58:42 -07:00
Piotr Tabor
404efd70f7
Upgrade of prometheous deps.
...
For now we need to depend on unstable: prometheus/client_golang
2021-06-03 16:07:01 +02:00
Piotr Tabor
edcfe575cf
Update dependencies:
...
- github.com/coreos/go-systemd/v22 v22.3.2
- github.com/google/btree v1.0.1
- github.com/json-iterator/go v1.1.11
- github.com/mattn/go-runewidth v0.0.13
- github.com/prometheus/client_golang v1.10.0
- github.com/prometheus/common v0.26.0
- github.com/sirupsen/logrus v1.8.1
2021-06-03 13:03:01 +02:00
Piotr Tabor
b240625d21
Update bbolt to v1.3.6.
...
`./scripts/update_dep.sh go.etcd.io/bbolt v1.3.6`
2021-06-03 12:39:53 +02:00
Piotr Tabor
90cea7d4e7
Update zap to v1.17.0.
2021-06-03 12:37:43 +02:00
Marek Siarkowicz
182aef6e6b
etcdserver: Fix invalid count returned on Range with Limit
2021-06-01 15:04:28 +02:00
Piotr Tabor
f15e0b8237
integration.BeforeTest can be run without leak-detection.
2021-05-27 20:55:11 +02:00
Piotr Tabor
71934ff244
Merge pull request #13010 from ipixiu/imp/store-scheduleCompaction-lock
...
limit tx lock scope in store.scheduleCompaction
2021-05-26 08:51:44 +02:00
Gyuho Lee
adecd73975
Merge pull request #13039 from ptabor/20210525-make-logger-public
...
Expose clientv3.CreateDefaultZapLoggerConfig
2021-05-25 14:42:42 -07:00
Piotr Tabor
bda32db121
Expose clientv3.CreateDefaultZapLoggerConfig
...
Need raised in
f3f4259d3f
.
BTW: Alligned the implementation of grpclogs with what we use in embed
server, so reduced the client code dependencies.
2021-05-25 22:59:08 +02:00
Sahdev Zala
05674c87fb
Merge pull request #13018 from ipixiu/feature/bolt-compaction-sleep-interval
...
add bolt compaction sleep interval
2021-05-25 10:06:47 -04:00
Gyuho Lee
7a7b668edb
Merge pull request #12933 from wilsonwang371/shared_txReadBuffer
...
server: set multiple concurrentReadTx instances share one txReadBuffer
2021-05-24 16:38:14 -07:00
Wilson Wang
9c82e8c72b
server: set multiple concurrentReadTx instances share one txReadBuffer.
2021-05-24 15:16:53 -07:00
赵延
64b01a7a8d
Enhance the root permission, when root role exist, it always return rootPerm. ( #13006 )
...
etcdctl role grant-permission root readwrite foo.
see etcdctl role get root output.
Before:
Role root
KV Read:
foo
KV Write:
foo
After:
Role root
KV Read:
[, <open ended>
KV Write:
[, <open ended>
2021-05-24 14:58:00 -07:00
AlexStocks
184b0e5d49
add sleep interval
2021-05-24 16:22:00 +08:00
Pavan BG
d9c5e1f0a2
*: Replace internal testutil AssertEqual function in favour of github.com/stretchr/testify/assert.Equals
...
To maintain uniformity in testing methodology, assert.Equals has been used everywhere while replacing testutil.AssertEqual
Fixes #13015
2021-05-20 19:55:45 +05:30
Piotr Tabor
e299264cf3
Merge pull request #13011 from lilic/socket-options-file
...
WIP: client,server: Expose reuse-port and reuse-address so they can be configured via a config file
2021-05-20 13:50:21 +02:00
Lili Cosic
7957f4461d
server/embed/config_test.go: Add unit test for socket options
2021-05-20 10:00:27 +02:00
Gábor Lipták
204e87cfb8
Correct typo
...
Signed-off-by: Gábor Lipták gliptak@gmail.com
2021-05-19 17:53:00 -04:00
Lili Cosic
73c530de83
client,server: Expose reuse-port and reuse-address so they can be
...
configured via a config file.
2021-05-19 18:41:21 +02:00
AlexStocks
6d68f7841a
limit tx lock scope
2021-05-19 23:47:46 +08:00
Piotr Tabor
788bc5359d
Merge pull request #13000 from ptabor/20210519-shouldApplyV3
...
applyV2 should apply on backend only once
2021-05-19 02:09:36 +02:00
Piotr Tabor
0a972a3f05
applyV2 should reapply on backend only once
...
During review of: https://github.com/etcd-io/etcd/pull/12988 spotted
that PUT is actially writing to v3-backend.
If we are replaying WAL log, it might happened that backend's
applied_index is > than the WAL's log entry. In such situation we should
skip applying on backend V3.
I think both the methods (setVersion, setMembersAttributes) are in
practice idempotent so its not that 'serious' problem, but for
formal correctness adding the proper checks.
2021-05-18 20:55:05 +02:00
Piotr Tabor
46b49a6ecf
Merge pull request #12991 from ptabor/20210519-mlmhl-buffer-seq
...
Represent bucket as object instead of []byte name.
2021-05-18 19:32:01 +02:00
Piotr Tabor
66752fef2f
Represent bucket as object instead of []byte name.
...
Thanks to this change:
- all the maps bucket -> buffer are indexed by int's instead of
string. No need to do: byte[] -> string -> hash conversion on each
access.
- buckets are strongly typed in backend/mvcc API.
2021-05-18 18:58:53 +02:00
Piotr Tabor
62b731909f
Merge pull request #12587 from mlmhl/buffer-search
...
backend: fix buffer range bug
2021-05-18 10:54:30 +02:00
Gyuho Lee
1af7cb22f2
Merge pull request #12988 from chaochn47/updateClusterVersionV2
...
use v2 api to update cluster version
2021-05-17 13:43:36 -07:00
Chao Chen
783c5ad2d2
use v2 api to update cluster version
2021-05-17 11:45:54 -07:00
Piotr Tabor
eebe67d87d
Rename seq to bucket2seq.
2021-05-17 17:29:44 +02:00
Piotr Tabor
4a2ffc2cbe
Minor formatting fix on top of https://github.com/etcd-io/etcd/pull/12568
2021-05-17 17:08:00 +02:00
mlmhl
79eafb9719
backend: set seq flag for each bucket buffer
2021-05-17 17:08:00 +02:00
Piotr Tabor
d99d0df5a5
Adding etcdutl test coverage.
2021-05-17 11:54:03 +02:00
Piotr Tabor
f82b5cb776
Bring back original NewZapCoreLoggerBuilder api. ( #12973 )
...
The funcion signature has been changed in:
eafbc8c57efc716644c328f63677ca7eadeebdfe .
Instead we should have added new method `NewZapLoggerBuilder()`.
2021-05-16 10:26:10 -07:00
Piotr Tabor
3ed0cb1dfc
Update modules to more stable versions. ( #12975 )
2021-05-15 23:32:27 -07:00
Piotr Tabor
85341e08f2
Merge pull request #12968 from serathius/logger-simplify
...
server: Simplify passing logger setup by passing only logger
2021-05-15 15:58:00 +02:00
Piotr Tabor
00c6090110
Refactor common code from etcdctl (v2,v3) to pkg/corbautl.
...
Preparation for etcdutl split.
2021-05-14 14:16:53 +02:00
Marek Siarkowicz
41ed74824e
server: Simplify passing logger setup by passing only logger
2021-05-14 13:14:48 +02:00
Piotr Tabor
ab586cd463
Persists Term in the (bbolt) Backend.
...
Additional layer of protection, that allows to validate whether we
start replaying log not only from the proper 'index', but also of the
right 'term'.
2021-05-13 21:29:01 +02:00
Piotr Tabor
e44fb40be5
Merge pull request #12962 from ptabor/20210513-write-conf-state
...
Save raftpb.ConfState in the backend.
2021-05-13 19:22:28 +02:00
Gyuho Lee
e2d67f2e3b
Merge pull request #12956 from gyuho/rename-to-main
...
*: rename "master" branch references to "main" in source code
2021-05-13 08:26:33 -07:00
Piotr Tabor
865df75714
Save raftpb.ConfState in the backend.
...
This makes (bbolt) backend a full feature snapshot in term of WAL/raft,
i.e. carries:
- commit : (applied_index)
- confState
Benefits:
- Backend will be a sufficient point in time definition sufficient to
start replaying WAL. We have applied_index & confState in consistent
state.
- In case of emergency a backend state can be used for recovery
2021-05-13 14:29:36 +02:00
Piotr Tabor
3cb1ba4b2b
Merge pull request #12954 from serathius/logger-new-ctx-client
...
client: Add logger argument to NewCtxClient
2021-05-13 09:03:38 +02:00
Gyuho Lee
77c8033739
server: rename "master" branch references
...
Signed-off-by: Gyuho Lee <leegyuho@amazon.com>
2021-05-12 10:37:35 -07:00
Piotr Tabor
ead81df948
Disallow -v2-deprecation>'not-yet' combined with --enable-v2
2021-05-12 18:09:34 +02:00
Piotr Tabor
7c508741b3
Adding --v2-deprecation flag.
2021-05-12 18:09:34 +02:00
Piotr Tabor
f3b4a3e578
Detecting whether v2store is "empty" (metadata only).
2021-05-12 18:09:34 +02:00
Marek Siarkowicz
1189ee3f3d
client: Add logger argument to NewCtxClient
2021-05-12 16:40:55 +02:00
Piotr Tabor
1929aa0a36
Merge pull request #12948 from serathius/logger
...
client: Allow setting zap logger in config
2021-05-12 13:49:48 +02:00