implement Save

Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
This commit is contained in:
2021-05-08 17:07:32 +03:00
parent cd518afea3
commit afb3ef068d
2 changed files with 17 additions and 0 deletions

View File

@@ -1,6 +1,8 @@
package consul
import (
"time"
"github.com/hashicorp/consul/api"
"github.com/unistack-org/micro/v3/config"
)
@@ -36,3 +38,9 @@ func TLSConfig(t *tls.Config) config.Option {
return config.SetOption(tlsConfigKey{}, t)
}
*/
type timeoutKey struct{}
func Timeout(td time.Duration) config.Option {
return config.SetOption(timeoutKey{}, td)
}