Skip to content

fix(plugin_config): recover plugin when plugin_config changed#4888

Merged
spacewander merged 3 commits into
apache:masterfrom
wangxiaochuang:patch-5
Aug 30, 2021
Merged

fix(plugin_config): recover plugin when plugin_config changed#4888
spacewander merged 3 commits into
apache:masterfrom
wangxiaochuang:patch-5

Conversation

@wangxiaochuang

Copy link
Copy Markdown
Contributor

fix the bug:
route plugin cannot update when the plugin_config changed in the second time

fix the bug: route plugin cannot update when the plugin_config changed in the second time

@spacewander spacewander left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you provide a test case to indicate which situation will cause the bug?

@wangxiaochuang

Copy link
Copy Markdown
Contributor Author

Could you provide a test case to indicate which situation will cause the bug?

first time:
route: {
plugin_config_id=1
}
plugin_config: {
id=1,
plugins={
NAME: {...}
}
}
second time update the plugin_config:
route: not change
plugin_config: {
id=1,
plugins={}
}

then the NAME plugin will exist always for route, unless you reload apisix

Signed-off-by: spacewander <[email protected]>
@spacewander

Copy link
Copy Markdown
Member

Good, I can confirm it with the test.

@spacewander spacewander changed the title fix: plugin_config update failed in the next time fix(plugin_config): recover plugin when plugin_config changed Aug 27, 2021
@spacewander
spacewander merged commit 3c01202 into apache:master Aug 30, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants