etcd3-py icon indicating copy to clipboard operation
etcd3-py copied to clipboard

support multi endpoint

Open Revolution1 opened this issue 6 years ago • 8 comments

  • [ ] auto retry between endpoint
  • [ ] auto balance between endpoint

Revolution1 avatar Mar 27 '18 15:03 Revolution1

Hi, some questions:

  1. will there be an option to choose endpoint and switch only when endpoint failure occurs?
  2. what's the timeline for this feature? When will it be ready?

gszpura avatar Jun 04 '18 14:06 gszpura

@gszpura Of course, that is exactly what i'm going to do

As for the timeline, since I thought it's not a urgent feature, currently i'm working on a demo app of etcd3-py. If you truly need it, maybe I can write it first.

Also, thank you for using this lib and welcome to contribute to this project 😀

Revolution1 avatar Jun 05 '18 04:06 Revolution1

Reconnection is needed for my usecase since my etcd HA cluster consists of 3 nodes and I would like to auto switch nodes when current one is failing.

If you have an idea and time for writing that I would appreciate it ;]

gszpura avatar Jun 05 '18 16:06 gszpura

@gszpura Of course, that is exactly what i'm going to do

As for the timeline, since I thought it's not a urgent feature, currently i'm working on a demo app of etcd3-py. If you truly need it, maybe I can write it first.

Also, thank you for using this lib and welcome to contribute to this project 😀

@Revolution1 Are there any contribution guide about this project? I want to do something about this feature. Could you give me some advice?

stupidchen avatar Feb 22 '19 08:02 stupidchen

@stupidchen you can just write your thoughts about this feature under this issue

I have some ideas about this feature:

Add a EnpointManager to control which endpoint should the client use.

Discover endpoint:

  • user provide
  • by dns resolve
  • by etcd3 member_list api

Auto select a heathy endpoint

  • switch after connection fails
  • active health-check

Of course you can just start coding and create a pull request 😆

The only guide is write clean and readable code (and PEP8 formatted) .

ps: don't forget the test~

Revolution1 avatar Feb 22 '19 09:02 Revolution1

@stupidchen you can just write your thoughts about this feature under this issue

I have some ideas about this feature:

Add a EnpointManager to control which endpoint should the client use.

Discover endpoint:

  • user provide
  • by dns resolve
  • by etcd3 member_list api

Auto select a heathy endpoint

  • switch after connection fails
  • positive health-check

Of course you can just start coding and create a pull request 😆

The only guide is write clean and readable code (and PEP8 formatted) .

ps: don't forget the test~

Thanks for your advice! I will start coding in few days!

stupidchen avatar Feb 25 '19 04:02 stupidchen

I've submitted #55 which gives BaseClient the ability to failover between endpoints

dariko avatar Feb 25 '19 09:02 dariko

How does the current version support clustering? No solution?Release 0.2.0…. It seems so far off in the future

boylegu avatar Nov 28 '19 07:11 boylegu