Support Questions

Find answers, ask questions, and share your expertise

Trying to build NiFi from Dev Source

avatar
Contributor

On Mac using http://nifi.apache.org/quickstart.html. Basically, I just want to try one of the features added later than 1.0.0, so thought this would be a straightforward way to do that. Keep running into the following error:

[ERROR] COMPILATION ERROR :
[ERROR] /Users/me/Documents/Workspace/nifi-docs/nifi/nifi-nar-bundles/nifi-riemann-bundle/nifi-riemann-processors/src/main/java/org/apache/nifi/processors/riemann/PutRiemann.java:[300,23] error: cannot access GeneratedMessage
[ERROR]   class file for com.google.protobuf.GeneratedMessage not found
/Users/me/Documents/Workspace/nifi-docs/nifi/nifi-nar-bundles/nifi-riemann-bundle/nifi-riemann-processors/src/main/java/org/apache/nifi/processors/riemann/PutRiemann.java:[334,35] error: cannot access MessageOrBuilder
[ERROR]   class file for com.google.protobuf.MessageOrBuilder not found
/Users/me/Documents/Workspace/nifi-docs/nifi/nifi-nar-bundles/nifi-riemann-bundle/nifi-riemann-processors/src/main/java/org/apache/nifi/processors/riemann/PutRiemann.java:[338,15] error: cannot access Builder
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.2:compile (default-compile) on project nifi-riemann-processors: Compilation failure: Compilation failure:
[ERROR] /Users/me/Documents/Workspace/nifi-docs/nifi/nifi-nar-bundles/nifi-riemann-bundle/nifi-riemann-processors/src/main/java/org/apache/nifi/processors/riemann/PutRiemann.java:[300,23] error: cannot access GeneratedMessage
[ERROR] class file for com.google.protobuf.GeneratedMessage not found
[ERROR] /Users/me/Documents/Workspace/nifi-docs/nifi/nifi-nar-bundles/nifi-riemann-bundle/nifi-riemann-processors/src/main/java/org/apache/nifi/processors/riemann/PutRiemann.java:[334,35] error: cannot access MessageOrBuilder
[ERROR] class file for com.google.protobuf.MessageOrBuilder not found
[ERROR] /Users/me/Documents/Workspace/nifi-docs/nifi/nifi-nar-bundles/nifi-riemann-bundle/nifi-riemann-processors/src/main/java/org/apache/nifi/processors/riemann/PutRiemann.java:[338,15] error: cannot access Builder

Any ideas/help appreciated!

1 ACCEPTED SOLUTION

avatar
Master Guru

did you do a full mvn clean?

do you have JDK 1.8 and maven 3.1 installed?

brew install protobuf

this is a helpful tool

http://sdkman.io/

View solution in original post

4 REPLIES 4

avatar
Master Guru

did you do a full mvn clean?

do you have JDK 1.8 and maven 3.1 installed?

brew install protobuf

this is a helpful tool

http://sdkman.io/

avatar
Contributor

@Timothy Spann by 'full mvn clean' -- I always did `mvn clean install` and yes to all else including double-check of:

brew install protobuf
>>Warning: protobuf-2.6.1 already installed 

avatar
Master Guru

NFO] --- maven-install-plugin:2.5.2:install (default-install) @ nifi-assembly --- [INFO] Installing /Volumes/Transcend/projects/nifi/nifi-assembly/pom.xml to /Users/tspann/.m2/repository/org/apache/nifi/nifi-assembly/1.1.0-SNAPSHOT/nifi-assembly-1.1.0-SNAPSHOT.pom [INFO] ------------------------------------------------------------------------ [INFO] Reactor Summary: [INFO] [INFO] nifi ............................................... SUCCESS [ 0.947 s] [INFO] nifi-api ........................................... SUCCESS [ 18.126 s] [INFO] nifi-framework-api ................................. SUCCESS [ 12.108 s] [INFO] nifi-commons ....................................... SUCCESS [ 0.539 s] [INFO] nifi-security-utils ................................ SUCCESS [ 12.961 s] [INFO] nifi-utils ......................................... SUCCESS [ 26.998 s] [INFO] nifi-data-provenance-utils ......................... SUCCESS [ 6.681 s] [INFO] nifi-flowfile-packager ............................. SUCCESS [ 19.166 s] [INFO] nifi-expression-language ........................... SUCCESS [ 49.708 s] [INFO] nifi-logging-utils ................................. SUCCESS [ 11.279 s] [INFO] nifi-properties .................................... SUCCESS [ 19.457 s] [INFO] nifi-socket-utils .................................. SUCCESS [ 11.359 s] [INFO] nifi-web-utils ..................................... SUCCESS [ 9.211 s] [INFO] nifi-nar-bundles ................................... SUCCESS [ 0.423 s] [INFO] nifi-standard-services ............................. SUCCESS [ 0.191 s] [INFO] nifi-ssl-context-service-api ....................... SUCCESS [ 4.366 s] [INFO] nifi-processor-utils ............................... SUCCESS [ 15.559 s] [INFO] nifi-write-ahead-log ............................... SUCCESS [ 37.596 s] [INFO] nifi-framework-bundle .............................. SUCCESS [ 0.186 s] [INFO] nifi-framework ..................................... SUCCESS [ 8.725 s] [INFO] nifi-client-dto .................................... SUCCESS [ 9.048 s] [INFO] nifi-site-to-site-client ........................... SUCCESS [ 43.232 s] [INFO] nifi-hl7-query-language ............................ SUCCESS [ 32.272 s] [INFO] nifi-hadoop-utils .................................. SUCCESS [ 16.190 s] [INFO] nifi-bootstrap ..................................... SUCCESS [ 4.862 s] [INFO] nifi-mock .......................................... SUCCESS [ 10.900 s] [INFO] nifi-nar-utils ..................................... SUCCESS [ 5.801 s] [INFO] nifi-framework-authorization ....................... SUCCESS [ 2.918 s] [INFO] nifi-framework-core-api ............................ SUCCESS [ 6.668 s] [INFO] NiFi Properties Loader ............................. SUCCESS [ 5.558 s] [INFO] nifi-documentation ................................. SUCCESS [ 11.866 s] [INFO] nifi-runtime ....................................... SUCCESS [ 5.656 s] [INFO] nifi-security ...................................... SUCCESS [ 8.986 s] [INFO] nifi-user-actions .................................. SUCCESS [ 3.050 s] [INFO] nifi-administration ................................ SUCCESS [ 8.153 s] [INFO] nifi-site-to-site .................................. SUCCESS [ 31.641 s] [INFO] nifi-framework-cluster-protocol .................... SUCCESS [ 21.261 s] [INFO] nifi-framework-core ................................ SUCCESS [03:23 min] [INFO] nifi-web ........................................... SUCCESS [ 1.357 s] [INFO] nifi-web-security .................................. SUCCESS [ 22.575 s] [INFO] nifi-web-optimistic-locking ........................ SUCCESS [ 2.002 s] [INFO] nifi-framework-cluster ............................. SUCCESS [ 12.125 s] [INFO] nifi-file-authorizer ............................... SUCCESS [ 9.513 s] [INFO] nifi-custom-ui-utilities ........................... SUCCESS [ 3.049 s] [INFO] nifi-web-content-access ............................ SUCCESS [ 7.045 s] [INFO] nifi-ui-extension .................................. SUCCESS [ 1.506 s] [INFO] nifi-authorizer .................................... SUCCESS [ 5.066 s] [INFO] nifi-provenance-repository-bundle .................. SUCCESS [ 0.116 s] [INFO] nifi-volatile-provenance-repository ................ SUCCESS [ 9.860 s] [INFO] nifi-web-api

It worked for me

export MAVEN_OPTS="-Xms1024m -Xmx3076m -XX:MaxPermSize=256m"

mvn -T C2.0 clean install

Apache Maven 3.3.9 (bb52d8502b132ec0a5a3f4c09453c07478323dc5; 2015-11-10T11:41:47-05:00) Maven home: /Users/tspann/.sdkman/candidates/maven/current Java version: 1.8.0_91, vendor: Oracle Corporation Java home: /Library/Java/JavaVirtualMachines/jdk1.8.0_91.jdk/Contents/Home/jre Default locale: en_US, platform encoding: UTF-8 OS name: "mac os x", version: "10.12.1", arch: "x86_64", family: "mac"

avatar

Hi Ben, can you please provide the Maven command you ran and the entire output (this will be long, so posting as a GitHub Gist can be helpful)? That dependency is brought in by the Hadoop jars, but it should be available to you.