-
Notifications
You must be signed in to change notification settings - Fork 99
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
Using module in cluster architecture (many upload nodes behind LB) #25
Comments
What I usually recommend is to configure the LB to stick to a back-end based on the X-Progress-ID. I had a look to your configuration example (I'm not familiar with proxy_next_upstream) and I don't understand how it can work. Is the configuration the one on the LB (assuming it is nginx and not something else) or is it one of your upstream server configuration? |
Thanks for answer. I couldn't configure LB that way you propose, because of it balances packets Configuration example file I suggest is placed on all upload nodes behind LB, and this configuration is same for all nodes. Each of upload nodes have upstream that contains all other upload nodes except this one. My scheme works this way:
If I tested patch on a test bench of several machines, not on real highly loaded project, but intend to. |
Any thoughts? |
Your solution is interesting. |
Yep, you absolutely right. Proposed solution is not a right way to resolve a problem. But I don't see easy graceful solution for now, so, I try to use this solution in production. BTW, there are some more complicated ways:
|
I think I found a solution (somewhat obvious one). I will implement it soon and send patch to your review. I think there should be a directive, called, for example, Example configuration: Upload Node A:
Upload Node B:
Load Balancer:
|
any idea finally solve the problem? |
Closing this issue since it's awfully outdated. |
I'm using upload-progress module in cluster architecture, e.g. I have many upload servers behind load balancer (TCP level). And there is a problem, when I make upload request, I know only load balancer address, not upload server address. And there no way to get upload progress of that server, that handle current upload.
Example: 1 LB, 3 Upload Server (A, B, C). When I do upload request, it handled with, for example, server A (choosen by LB). But when I do upload progress request, it handled by server B, next request by server C, then by A (round robin manner). Obviously, I've got 2 error messages (upload ID is not found) and only one correct answer.
So, I want a mechanism to get upload progress correctly. There is native way to do this in nginx:
proxy_next_upstream
directive, which can pass request to another server when current server answers with bad HTTP code.There is my suggestion: add some way to return HTTP code from upload-progress module to make it possible to handle answer with
proxy_next_upstream
directive.There's an my patch and example configuration: seletskiy/nginx-upload-progress-module@42b6b60d
The text was updated successfully, but these errors were encountered: