README.md updated for comments

This commit is contained in:
Erkan Ozsoy
2023-07-03 17:03:45 +03:00
parent 5aa726f723
commit b24255db5e
2 changed files with 14 additions and 4 deletions

View File

@@ -51,10 +51,15 @@ store := etcd.New(Config{
### Config ### Config
```go ```go
type Config struct { type Config struct {
// Endpoints is a list of URLs.
Endpoints []string Endpoints []string
// DialTimeout is the timeout for failing to establish a connection.
DialTimeout time.Duration DialTimeout time.Duration
// Username is a username for authentication.
Username string Username string
// Password is a password for authentication.
Password string Password string
// Context is the context for the client.
Context context.Context Context context.Context
} }
``` ```

View File

@@ -7,10 +7,15 @@ import (
// Config defines the config for storage. // Config defines the config for storage.
type Config struct { type Config struct {
// Endpoints is a list of URLs.
Endpoints []string Endpoints []string
// DialTimeout is the timeout for failing to establish a connection.
DialTimeout time.Duration DialTimeout time.Duration
// Username is a username for authentication.
Username string Username string
// Password is a password for authentication.
Password string Password string
// Context is the context for the client.
Context context.Context Context context.Context
} }