-
Notifications
You must be signed in to change notification settings - Fork 427
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’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Feature Request]: Apache Nifi 2 support ( Java 21 version ) #1984
Comments
Could it be that the Nifi API changed? The major version change usually indicates that. I would assume you need to update the code of the adapter to the new version and API. |
I'm sorry if I gave the impression that I was using PLC4X with custom development. I'm actually using the .nar from https://mvnrepository.com/artifact/org.apache.plc4x/plc4j-nifi-plc4x-nar/0.12.0. I also tested building the .nar 0.13 from the plc4x-extras repository, but the same error occurred. I ran a clean version of Apache NiFi in Docker with versions 1.28.0, 2.0.0, and 2.1.0 using the following Dockerfile: services: I checked the logs, and when I click on the processors in the NiFi UI, this error occurs. Additionally, PLC4X is not found among the available processors. 2025-01-22 23:57:43,138 INFO [main] org.apache.nifi.runtime.Application Started Application in 20.611 seconds (20611807389 ns) Running these tests with a minimal setup, I realized that my first error, "validated against 'Any Property' is invalid because Processor is of type," occurred because the processor was not installed because the error above, and I have many processgroups using PLC4X processors. |
there is a related PR to that, might be related apache/plc4x-extras#52 |
Yes, this is likely the problem. I will keep the production Apache NiFi at version 1.28.1 and hope that version 0.13, when officially released, will support nifi 2.x versions. I tried to build this PR locally for testing, but I'm encountering compilation errors. As my knowledge of Java is minimal, I can't provide much assistance, but I'm available to help test the new release before its official launch. Thanks for the responses, everyone ! |
To me it looks as if one module can only support NiFi 1 or NiFi 2, but not both ... I hope the PR is adding a second module for 2.0 but even if not, it should not be hard to update it to do so. However I am not sure there's currently anyone working on the PR ... also do I not know if it's finished for testing ... |
Certainly, I believe it's not that difficult to compile for version 2. I ran a mvn clean package inside the NiFi folder from the branch with the possible fix, but errors occurred during the build. Maybe later I'll try to build it again and take a closer look at what was going wrong. For now, NiFi 1.28.1 is working very well, and the update would be more about exploring the new features and keeping it on the latest version. I'll see if I can generate a .nar for Java 21 that runs on NiFi 2 in the coming days. |
I did notice a day ago that I needed to build the plc4x-maven-plugin in order to build PLC4X and that I needed to downgrade to Java 21 from 23 to have the build running ... perhals this is also what you need to do? |
Hello! I used Java 21 to build the project, but I’m unsure whether I correctly built the plc4x-maven-plugin. I will attempt the build again tomorrow and update this issue with the results. |
What would you like to happen?
Plc4x runs with Java 11, and Apache NiFi versions 1.x also use Java 11. However, after I updated Apache NiFi to the latest version (Version 2), Plc4x stopped working.
The error message is as follows:
GhostProcessor[id=018f1016-372a-13ca-dfb0-0a1b9d02d9d0] Encountering difficulty starting. (Validation State is INVALID: ['Missing Processor' validated against 'Any Property' is invalid because Processor is of type org.apache.plc4x.nifi.Plc4xSourceRecordProcessor, but this is not a valid Processor type]). Will continue trying to start.
Programming Languages
Protocols
The text was updated successfully, but these errors were encountered: