Created 09-22-2016 08:27 PM
PutHiveQL and SelectHiveQL processors are looking for class ‘org.apache.hive.jdbc.HiveDriver’ which I guess should have already been specified into. Is there any option to specify that in HiveConnectionPool.
Error is as follows
2016-09-19 17:55:30,084 ERROR [Timer-Driven Process Thread-4] o.a.nifi.processors.hive.SelectHiveQL SelectHiveQL[id=4467ed6d-0157-1000-5114-2998b4c5f3aa] Unable to execute HiveQL select query select * from nifitest; due to org.apache.nifi.processor.exception.ProcessException: org.apache.commons.dbcp.SQLNestedException: Cannot create JDBC driver of class 'org.apache.hive.jdbc.HiveDriver' for connect URL '!connect jdbc:hive2://host.name.net:10000/;principal=hive/_HOST@EXAMPLE.COM '. No FlowFile to route to failure: org.apache.nifi.processor.exception.ProcessException: org.apache.commons.dbcp.SQLNestedException: Cannot create JDBC driver of class 'org.apache.hive.jdbc.HiveDriver' for connect URL '!connect jdbc:hive2://host.name.net:10000/;principal=hive/_HOST@EXAMPLE.COM '
Created 09-22-2016 08:31 PM
The Hive JDBC driver is included with the Hive processors. It appears your driver URL has "!connect" at the front when it should instead start with the "jdbc:hive2" prefix, removing that should fix the issue.
Created 09-22-2016 08:31 PM
The Hive JDBC driver is included with the Hive processors. It appears your driver URL has "!connect" at the front when it should instead start with the "jdbc:hive2" prefix, removing that should fix the issue.
Created on 10-03-2016 05:14 PM - edited 08-18-2019 04:15 AM
Here is new error:
Caused by: java.net.URISyntaxException: Illegal character in path at index 73: hive2://dummyhost:00000/;principal=hive/_HOST@EXAMPLE.COM at java.net.URI$Parser.fail(URI.java:2848) ~[na:1.8.0] at java.net.URI$Parser.checkChars(URI.java:3021) ~[na:1.8.0] at java.net.URI$Parser.parseHierarchical(URI.java:3105) ~[na:1.8.0] at java.net.URI$Parser.parse(URI.java:3053) ~[na:1.8.0] at java.net.URI.<init>(URI.java:588) ~[na:1.8.0] at java.net.URI.create(URI.java:850) ~[na:1.8.0] ... 33 common frames omitted
Here is the Database Connection URL:
jdbc:hive2://host.name.net:10000/;principal=hive/_HOST@EXAMPLE.COM
Created 10-03-2016 06:05 PM
It appears your URL has been scrubbed (which is fine), can you find the character at (0-based) index 73? The URL above looks ok (should recognize underscores, semicolons, the at symbol, etc.). Also if you are using the default database, try explicitly putting 'default' in the URL, so jdbc:hive2://host.name.net:10000/default;principal=hive/_HOST@EXAMPLE.COM.
You might also try adding "auth=KERBEROS" to the URL parameters, although I don't think that's required (setting the principal is all that's supposed to be needed).
Created 10-04-2016 04:09 PM
2 things Resolved the issue:
1. start with the "jdbc:hive2" prefix
jdbc:hive2://host.name.net:10000/;principal=hive/_HOST@EXAMPLE.COM
2. Add following property to hive-site.xml that is passed under HiveConnectionPool "Hive Configuration Resources" property.
<property> <name>hadoop.security.authentication</name> <value>kerberos</value> </property>