Skip to content
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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(plugins): attempt to extract plugin from current node on startup #10422

Merged
merged 1 commit into from Apr 18, 2023

Conversation

thalesmg
Copy link
Contributor

@thalesmg thalesmg commented Apr 17, 2023

Fixes https://emqx.atlassian.net/browse/EMQX-9605

Fixes emqx/emqx-elixir-plugin#25

If an user happens to configure a plugin in a lone-node cluster via environment variables, it would fail to start up as there are no other nodes to copy the plugin from. Here, we attempt to check if the package is present in the current node but not yet extracted.

Summary

馃 Generated by Copilot at fb9eb6e

This pull request enhances the emqx_plugins module and its test suite. It adds a test case for starting a plugin on a single node, updates the version number, improves the plugin extraction and cluster copy logic, and adds a new field to the cluster helper function.

PR Checklist

Please convert it to a draft if any of the following conditions are not met. Reviewers may skip over until all the items are checked:

  • Added tests for the changes
  • Changed lines covered in coverage report
  • Change log has been added to changes/{ce,ee}/(feat|perf|fix)-<PR-id>.en.md files
  • For internal contributor: there is a jira ticket to track this change
  • [na] If there should be document changes, a PR to emqx-docs.git is sent, or a jira ticket is created to follow up
  • [na] Schema changes are backward compatible

Checklist for CI (.github/workflows) changes

  • [na] If changed package build workflow, pass this action (manual trigger)
  • [na] Change log has been added to changes/ dir for user-facing artifacts update

@thalesmg thalesmg force-pushed the fix-plugin-sync-single-node-v50 branch 5 times, most recently from e7c6f30 to fa5ae0f Compare April 18, 2023 14:10
Fixes https://emqx.atlassian.net/browse/EMQX-9605

Fixes emqx/emqx-elixir-plugin#25

If an user happens to configure a plugin in a lone-node cluster via
environment variables, it would fail to start up as there are no other
nodes to copy the plugin from.  Here, we attempt to check if the
package is present in the current node but not yet extracted.
@thalesmg thalesmg force-pushed the fix-plugin-sync-single-node-v50 branch 2 times, most recently from 0cb057f to 89cd6cf Compare April 18, 2023 14:13
@thalesmg thalesmg marked this pull request as ready for review April 18, 2023 14:37
@thalesmg thalesmg requested review from a team, JimMoen and lafirest as code owners April 18, 2023 14:37
@thalesmg thalesmg merged commit 6a1ef5e into emqx:master Apr 18, 2023
111 checks passed
@thalesmg thalesmg deleted the fix-plugin-sync-single-node-v50 branch April 18, 2023 17:39
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.

The plugins can only work with emqx ctl, but not with environment vairable
2 participants