Details
-
Type:
Bug
-
Status: Resolved
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: 0.12.0
-
Fix Version/s: 0.14.0
-
Component/s: Data Module
-
Labels:None
Description
While working on CDK-385 I came to notice that Hive repository URIs are broken when the path segment of the URI is the root path "/". The JavaDoc indicates that a URI like repo:hive://meta-host:9083/ will be equivalent to repo:hive://meta-host:9083 and use managed Hive tables. What happens instead though is it attempts to create external tables in the root directory.
I tested this with the following configuration of the kite-maven-plugin:
<goals>
<goal>create-dataset</goal>
</goals>
<configuration>
<repositoryUri>repo:hive://localhost:9083/</repositoryUri>
<datasetName>Person</datasetName>
<avroSchemaReflectClass>org.kitesdk.examples.oozie.Person</avroSchemaReflectClass>
</configuration>
The run fails trying to write a /Person directory:
[ERROR] Failed to execute goal org.kitesdk:kite-maven-plugin:0.13.0:create-dataset (create-person-dataset) on project kite-examples-oozie: Execution create-person-dataset of goal org.kitesdk:kite-maven-plugin:0.13.0:create-dataset failed: Hive table creation exception: file:/Person is not a directory or unable to create one -> [Help 1]
It seems to have been broken in a change in 0.12.0 as I tested that version as well as 0.11.0. In 0.11.0 it works as expected.