openresty / openresty/lua-resty-core

balancer_by_lua_block does not support keepalive_requests??

Open
#283 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Lua
Stars
853
Forks
286
Avg merge
35m
Merged PRs (30d)
1

Description

this is my config:
upstream hls_origin2_dynamic {
server 0.0.0.1; # just an invalid address as a place holder
balancer_by_lua_block {
local b = require "ngx.balancer"
--ngx.log(ngx.ERR, "wangzhao test2: ", ngx.ctx.ip_port)
assert(b.set_current_peer(ngx.ctx.ip_port))
}
keepalive 10;
keepalive_requests 500;
keepalive_timeout 120s;
}

but when i capture TCP packets , the keepalive connection only 100 request.....not 500 request.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the supplied upstream configuration using balancer_by_lua_block, ngx.balancer.set_current_peer, keepalive, keepalive_requests, and keepalive_timeout, then capture the TCP traffic as described. Compare the observed 100-request connection limit with the configured 500 requests and determine which component or directive is responsible; the issue is resolved when the supported behavior is identified and documented or corrected.

Written by the indexing model from the issue text.

Assessment

Tech stack
lua, nginx
Domain
backend, networking
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.