-
Notifications
You must be signed in to change notification settings - Fork 151
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
add set_peer_weight api #5
base: master
Are you sure you want to change the base?
Conversation
@rockiee281 Thank you for looking into this! Several comments though:
Thanks! |
Hi, @agentzh ,add some commits to update I'll try to add some test case later. But I cannot find any example in this project, where can I find them? |
@rockiee281 It already comes with a test suite: https://github.com/openresty/lua-upstream-nginx-module/tree/master/t |
@agentzh add some test case for this feature |
@rockiee281 Thank you very much! I'll look into this as soon as I can manage :) |
There's an implement here😂 I just made an implement myself these days |
I remember there was already a PR for this feature. Check the pull request list of this repos? |
@agentzh we are talking under that PR right now. My newly post mention the functions I added to the lua upstream module. Take a look if you like. http://blog.jamespan.me/2015/11/27/fastest-first-load-balancer-for-nginx-with-lua/ I use three functions to update weight, current weight, and effective weight respectively. So I wander if I need to finish the test suit and push another PR. |
@jamespan Thanks for the efforts. I will have a closer look at your PR later. Currently busy with the PRs implementing the |
It's been almost 3 years. What are folks doing to change weights via lua? Or is there a better way/module to that? |
add new api for upstream module for #4 , change backen weight dynamic