public PutResponse PutEphemeral()

in client/Apache.ShenYu.Client/Utils/Etcd/EtcdClientUtils.cs [221:239]


        public PutResponse PutEphemeral(string key, string value)
        {
            try
            {
                PutRequest request = new PutRequest()
                {
                    Key = ByteString.CopyFromUtf8(key),
                    Value = ByteString.CopyFromUtf8(value),
                    Lease = this._globalLeaseId
                };
                var response = _client.Put(request, _metadata);
                return response;
            }
            catch (Exception ex)
            {
                _logger.LogError("putEphemeral(key:{},value:{}) error.", key, value, ex);
            }
            return null;
        }