Support Questions

Find answers, ask questions, and share your expertise

NiFi Build Failed

avatar
Super Collaborator

build.txt

Hello all,
Any pointers would be helpful. I am trying to build NiFi from source on Centos 7. Have the preconditions met as per https://nifi.apache.org/quickstart.html

EDIT : Attached the build log

However, the build fails with the below trace :-

[INFO] dockermaven 1.6.0-SNAPSHOT ......................... SUCCESS [  0.713 s]
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 01:05 min (Wall Clock)
[INFO] Finished at: 2018-03-27T18:15:24Z
[INFO] ------------------------------------------------------------------------
Downloaded from central: https://repo1.maven.org/maven2/org/apache/curator/curator-framework/2.10.0/curator-framework-2.10.0.... (2.5 kB at 34 kB/s)
[ERROR] Failed to execute goal com.github.eirslett:frontend-maven-plugin:1.1:npm (npm install) on project nifi-web-ui: Failed to run task: 'npm --cache-min Infinity install' failed. (error code 1) -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
[ERROR]
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR]   mvn <goals> -rf :nifi-web-ui
Destroying 6 processes
Destroying process..
Destroying process..
Destroying process..
Destroying process..
Destroying process..
Destroying process..
Destroyed 6 processes
1 ACCEPTED SOLUTION

avatar
Contributor

hmmm....it looks like it is an issue with the version of npm with this distro. I recently submitted a PR to update the version of node and npm in NiFi: https://github.com/apache/nifi/pull/2571. Please cherry-pick this commit and rebuild and see if this solves your problem.

View solution in original post

8 REPLIES 8

avatar
Contributor

Hello, can you please post the full trace?

avatar
Super Collaborator

Sure, @Scott Aslan, attached the build log.

avatar
Contributor

hmmm....it looks like it is an issue with the version of npm with this distro. I recently submitted a PR to update the version of node and npm in NiFi: https://github.com/apache/nifi/pull/2571. Please cherry-pick this commit and rebuild and see if this solves your problem.

avatar
Super Collaborator

Thanks @Scott Aslan I will update you once done.

avatar
Super Collaborator

I will run again skipping the tests,

[INFO]
[INFO] --- maven-remote-resources-plugin:1.5:process (process-resource-bundles) @ nifi-solr-processors ---
[INFO] Tests run: 8, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 1.167 s - in org.apache.nifi.processors.standard.TestParseCEF
[INFO] Running org.apache.nifi.processors.standard.TestGetFile
[ERROR] Tests run: 7, Failures: 0, Errors: 3, Skipped: 0, Time elapsed: 0.138 s <<< FAILURE! - in org.apache.nifi.processors.standard.TestGetFile
[ERROR] testWithUnreadableDir(org.apache.nifi.processors.standard.TestGetFile)  Time elapsed: 0.028 s  <<< ERROR!
java.lang.NullPointerException
at org.apache.nifi.processors.standard.TestGetFile.testWithUnreadableDir(TestGetFile.java:92)
[ERROR] testWithInaccessibleDir(org.apache.nifi.processors.standard.TestGetFile)  Time elapsed: 0.006 s  <<< ERROR!
java.lang.NullPointerException
at org.apache.nifi.processors.standard.TestGetFile.testWithInaccessibleDir(TestGetFile.java:64)
[ERROR] testWithUnwritableDir(org.apache.nifi.processors.standard.TestGetFile)  Time elapsed: 0.007 s  <<< ERROR!
java.lang.NullPointerException
at org.apache.nifi.processors.standard.TestGetFile.testWithUnwritableDir(TestGetFile.java:120)
[INFO] Running org.apache.nifi.processors.standard.TestGenerateFlowFile
[INFO] Tests run: 3, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.02 s - in org.apache.nifi.processors.standard.TestGenerateFlowFile
[INFO] Running org.apache.nifi.processors.standard.TestExtractGrok

avatar
Super Collaborator

@Scott Aslan : Thanks, build successful after skipping the tests. The test failure trace is on the previous comment.

avatar

Hello @Scott Aslan

I am getting the same exception again when I try to build the latest source 1.7.1 from nifi-1.7.1-source-release.zip in AmazonLinux (AL2012 )

I tried downgrading the frontend-maven-plugin from 1.4 to 1.1 to see if that is the same error as previous, but still, it failed while building the UI.

Kindly help me fix this issue. Attaching the logs.

nifi-build-failure.txt

Thanks,

Arun

avatar

The issue is resolved and i was able to fix it by enabling network access from AL for sandbox build.