9e1abbab6e
Fix goimports in all existing files. Execution of ./scripts/fix.sh
...
Signed-off-by: Piotr Tabor <ptab@google.com >
2022-12-29 09:41:31 +01:00
72cf0cc04a
etcd: modify declaring empty slices
...
declare an empty slice to var s []int replace s :=[]int{}, https://github.com/golang/go/wiki/CodeReviewComments#declaring-empty-slices
Signed-off-by: demoManito <1430482733@qq.com >
2022-09-16 14:41:14 +08:00
63346bfead
server: Use default logging configuration instead of zap production one
...
This fixes problem where logs json changes format of timestamp.
2022-04-01 10:23:42 +02:00
f978da4f4f
move the newClientCfg into clientv3 package so as to be reused by both etcdctl and v3discovery
2022-03-24 06:18:25 +08:00
1a3822f2c3
Rename ClientConfig to ConfigSpec
...
The ClientConfig is a fully declarive configuration, so it makes more
sense to rename it to ConfigSpec. It can also mitigate the confusion
between Config and ClientConfig.
2022-03-13 05:41:49 +08:00
3dcbbf62d9
Move clientconfig into clientv3 so that it can be reused by both etcdctl and v3 discovery
2022-03-12 06:38:41 +08:00
2a151c8982
*: move from io/ioutil to io and os packages
...
The io/ioutil package has been deprecated as of Go 1.16, see
https://golang.org/doc/go1.16#ioutil . This commit replaces the existing
io/ioutil functions with their new definitions in io and os packages.
Signed-off-by: Eng Zer Jun <engzerjun@gmail.com >
2021-10-28 00:05:28 +08:00
00c6090110
Refactor common code from etcdctl (v2,v3) to pkg/corbautl.
...
Preparation for etcdutl split.
2021-05-14 14:16:53 +02:00
3bb7acc8cf
Migrate dependencies pkg/foo -> client/pkg/foo
2021-04-07 00:38:47 +02:00
9312d1b077
clientv3: Bring back ETCD_CLIENT_DEBUG variable interpretation.
...
env ETCD_CLIENT_DEBUG supports log levels (debug, info, warn, error, dpanic, panic, fatal).
Only when set, overrides application-wide grpc logging settings.
2021-03-18 18:43:07 +01:00
e33c6dd9df
client/v3: Rename of imports
2020-10-20 10:13:06 +02:00
de55bb6331
pkg: Rename imports after making 'pkg' a module
...
find -name '*.go' | xargs sed --follow-symlinks -i 's|go.etcd.io/etcd/v3/pkg/|go.etcd.io/etcd/pkg/v3/|g'
go fmt ./...
2020-10-13 00:09:27 +02:00
96cce208c2
go.mod: use go.etcd.io/etcd/v3 versioning
...
This change makes the etcd package compatible with the existing Go
ecosystem for module versioning.
Used this tool to update package imports:
https://github.com/KSubedi/gomove
2020-04-28 00:57:35 +00:00
ae983523db
pkg: remove capnslog ( #11616 )
...
* pkg: remove capnslog
* CHANGELOG: function signature change
2020-02-12 11:15:41 -08:00
34bd797e67
*: revert module import paths
...
Signed-off-by: Gyuho Lee <leegyuho@amazon.com >
2019-05-28 15:39:35 -07:00
9150bf52d6
go modules: Fix module path version to include version number
2019-04-26 15:29:50 -07:00
48a2442fd7
etcdctl: fix strings.HasPrefix args order
...
Signed-off-by: Iskander Sharipov <quasilyte@gmail.com >
2019-02-02 02:39:27 +03:00
aa4313a55a
*: fix github links
2018-11-10 11:14:18 +09:00
fa35126ef8
*: add client support for discovery-srv-name
...
Signed-off-by: Sam Batschelet <sbatsche@redhat.com >
2018-11-09 10:13:04 -05:00
d37f1521b7
*: update import paths to "go.etcd.io/etcd"
...
Signed-off-by: Gyuho Lee <leegyuho@amazon.com >
2018-08-28 17:47:55 -07:00
65192fddfa
ctlv3: support TLS endpoints for move-leader command
...
Signed-off-by: Gyuho Lee <gyuhox@gmail.com >
2018-06-05 13:48:09 -07:00
dbb37f98fd
Merge pull request #9730 from mitake/user-w-colon
...
etcdctl: add --password flag to the subcommand user add
2018-05-29 11:14:46 -07:00
807dfcea78
etcdctl: fixes 9583. trim spaces in ETCDCTL_ENDPOINTS
2018-05-26 04:58:06 +05:30
8fcab98bf2
etcdctl: add flags for specifying password
...
This commit adds two flags to etcdctl:
1. `--password` flag to etcdctl as a global option. It can be used for
specifying password for authentication required for the command
execution.
2. `--new-user-password` flag to `etcdctl user add`. It can be used
for specifying password of newly created user by the command.
The main motivation of the flags is allowing user to have : in its
name.
Fix https://github.com/coreos/etcd/issues/9691
2018-05-21 16:18:01 +09:00
55001977ed
etcdctl/ctlv3/command: don't print gRPC WARNING logs by default
...
Despite holding important information, these are too noisy.
See https://github.com/coreos/etcd/pull/9623
2018-04-25 15:26:54 -07:00
9ce295a812
etcdctl/ctlv3/command: enable gRPC WARNING logs by default
2018-04-24 16:19:02 -07:00
90e5af76f3
etcdctl/ctlv3: use new snapshot package
...
Signed-off-by: Gyuho Lee <gyuhox@gmail.com >
2018-04-12 10:49:48 -07:00
021df6a827
etcdctl/ctlv3: set client-side logger
...
Signed-off-by: Gyuho Lee <gyuhox@gmail.com >
2018-04-02 13:51:22 -07:00
aece63b10e
etcdctl: use "TrustedCAFile"
...
Signed-off-by: Gyuho Lee <gyuhox@gmail.com >
2018-03-20 15:31:32 -07:00
388b7fece6
ctlv3: handle pkg/flags warnings
...
Signed-off-by: Gyuho Lee <gyuhox@gmail.com >
2018-01-14 11:15:45 -08:00
deb514989c
etcdctl/ctlv3: disable grpc client logs when --debug is off
...
Signed-off-by: Gyu-Ho Lee <gyuhox@gmail.com >
2017-11-11 20:52:33 -08:00
e80b2474fa
etcdctl/ctlv3: inherit/update flags only once in 'check' command
...
When creating multiple clients, 'mustClientFromCmd' overwrites
inherited flags with environment variables, so later clients
were printing warnings on duplicate key updates.
Signed-off-by: Gyu-Ho Lee <gyuhox@gmail.com >
2017-10-11 10:37:15 -07:00
04940efcc2
etcdctl: add keep alive time/timeout in etcdctl
...
client can switch from fault node to normal when keep alive is timeout
Fixes #7941
2017-10-09 09:51:43 +08:00
c63d6b6a25
ctlv3: print envs, configure grpc logger with debug flag
...
Signed-off-by: Gyu-Ho Lee <gyuhox@gmail.com >
2017-09-26 07:05:10 +09:00
3b3d392540
*: use grpclog.LoggerV2
...
Signed-off-by: Gyu-Ho Lee <gyuhox@gmail.com >
2017-09-08 15:26:16 -07:00
9a0f8c5917
etcdctl: add discovery-srv global flag for v3
2017-09-02 10:24:36 +08:00
7388911e0c
ctlv3: add '--debug' flag (to enable grpclog)
...
By default, grpclog is disabled. It should be configurable
for debugging purposes, as we did in v2.
Signed-off-by: Gyu-Ho Lee <gyuhox@gmail.com >
2017-04-05 17:11:31 -07:00
cccbf302f2
etcdctl/ctlv3: don't crash when we should prompt for pw.
...
when 'etcdctl --user name get blah' is invoked to
prompt for password, don't panic.
addresses the segfault part of #6343
2016-09-03 10:32:16 -07:00
6259318521
*: attach auth token as a gRPC credential
...
This commit adds a functionality of attaching an auth token to gRPC
connection as a per RPC credential.
For doing this, this commit lets clientv3.Client.Dial() create a
dedicated gRPC connection for doing authentication. With the dedicated
connection, the client calls Authenticate() RPC and obtain its
token. The token is attached to the main gRPC connection with
grpc.WithPerRPCCredentials().
This commit also adds a new option --username to etcdctl (v3). With
this option, etcdctl attaches its auth token to the main gRPC
connection (currently it is not used at all).
2016-05-17 13:26:12 +09:00
c538e0f9a9
etcdctl: update LICENSE header
2016-05-12 20:51:39 -07:00
b90e30b28e
etcdctl: respect -write-out=json for snapshot status
2016-04-13 13:37:32 -07:00
e5a2bd58ec
etcdctl: respect --write-out
...
Support got clobbered about a month ago.
2016-04-11 16:01:38 -07:00
87d9f06a45
*: combine etcdctl and etcdctlv3
2016-03-28 11:28:05 -07:00