Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Exception while opening a watch on etcd grpc-proxy #185

Open
marcotod1410 opened this issue Jun 29, 2023 · 0 comments
Open

Exception while opening a watch on etcd grpc-proxy #185

marcotod1410 opened this issue Jun 29, 2023 · 0 comments
Labels
bug Something isn't working

Comments

@marcotod1410
Copy link

Describe the bug
The creation of a watch client raises a RpcException (context canceled) when opening a watch on a node.
This happens only when connecting to a grpc-proxy node (reference). When connecting to a single node, or setting multiple comma-separated endpoints, the exception does not occur and the watch works regularly.

To Reproduce
Run the following code in a console application:

using Etcdserverpb;
using System;
using System.Threading.Tasks;

namespace TestEtcdWatchException
{
    internal class Program
    {
        static async Task Main(string[] args)
        {
            var connection = new dotnet_etcd.EtcdClient("http://127.0.0.1:23790");
            await connection.WatchAsync(new WatchRequest()
            {
                CreateRequest = new WatchCreateRequest()
                {
                    Key = Google.Protobuf.ByteString.CopyFromUtf8("/test-key")
                }
            }, evt =>
            {
                Console.WriteLine($"Received watch response with watch id {evt.WatchId}");
                foreach (var e in evt.Events)
                {
                    Console.WriteLine("\tReceived event " + e.Type);
                }
            });
        }
    }
}

Additional context
Testing on dotnet_etcd version 6.0.1, etcd version is 3.4.18.
etcd grpc-proxy is started with the following command (assuming there is a cluster with three nodes):
./etcd grpc-proxy start --endpoints "http://127.0.0.1:12379,http://127.0.0.1:22379,http://127.0.0.1:32379" --listen-addr "127.0.0.1:23790"

@shubhamranjan shubhamranjan added the bug Something isn't working label Oct 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants