ZHANGSHUNLIN commented on issue #216:
URL: https://github.com/apache/bifromq/issues/216#issuecomment-3709424960
Hi @richard-scott
The BifromQ plugin uses PF4J, and during its usage, there are many details
and points to note. It’s often these small details that cause various issues
for developers, such as plugins not taking effect. To prevent missing any
unexpected aspects, BifromQ provides a Maven Archetype that allows you to
generate a usable example template via the mvn command.
In previous official releases, we have already published it to the Maven
Central Repository. As of now, the latest version is 3.3.5. In a Maven
environment, you can run:
```bash
mvn archetype:generate \
-DarchetypeGroupId=com.baidu.bifromq \
-DarchetypeArtifactId=bifromq-plugin-archetype \
-DarchetypeVersion=3.3.5 \
-DgroupId=com.demo.MyPlugin \
-DartifactId=my-plugin-3-3-5 \
-Dversion=1.0.0-SNAPSHOT \
-DpluginName=MyPlugin \
-DpluginContextName=MyPluginContext \
-DbifromqVersion=3.3.5 \
-DinteractiveMode=false
```
If you want to use the plugin from the current incubating version, you need
to install the bifromq-plugin/bifromq-plugin-archetype project into your local
repository:
```bash
mvn clean install -U -Dmaven.test.skip=true -pl
bifromq-plugin/bifromq-plugin-archetype
```
After that, you can use the current version with the following command:
```bash
mvn archetype:generate \
-DarchetypeGroupId=org.apache.bifromq \
-DarchetypeArtifactId=bifromq-plugin-archetype \
-DarchetypeVersion=[current_version] \
-DgroupId=com.demo.plugin \
-DartifactId=my-plugin-name \
-Dversion=1.0.0-SNAPSHOT \
-DpluginName=MyPlugin \
-DpluginContextName=MyPluginContext \
-DbifromqVersion=[current_version] \
-DinteractiveMode=false
```
We will take note of and continue to improve based on any further usage
issues or suggestions you may have. Additionally, we have provided
documentation on this topic in the official documentation at:
[https://bifromq.apache.org/docs/plugin/plugin_practice/](https://bifromq.apache.org/docs/plugin/plugin_practice/)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]