openresty / openresty/openresty

access_by_lua_block cannot modify proxy_pass

Open
#568 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C
Stars
14k
Forks
1.6k
PR merge metrics
No merged PRs in 30d

Description

I'm trying to modify proxy_pass upstream servers with access_by_lua_block and balancer_by_lua_block, but it seems it has no effect to upstream itself. I can modify headers from variables, but not upstream servers itself, looks like it is done when nginx starts and never changes.

nginx_conf.txt

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

Start by reproducing the reported behavior using the attached nginx_conf.txt configuration, focusing on access_by_lua_block, balancer_by_lua_block, and proxy_pass. Trace when the upstream server is selected and compare header changes with upstream changes. Done means establishing whether dynamic upstream modification is supported and either correcting the behavior or documenting the limitation.

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
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.