Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
atlas
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
dataplatform
atlas
Commits
a86f0f3e
Commit
a86f0f3e
authored
Mar 23, 2015
by
Venkatesh Seetharam
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add Hive Bridge with major refactoring
parent
e747e2ae
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
26 additions
and
10 deletions
+26
-10
pom.xml
addons/hive-bridge/pom.xml
+12
-5
HiveMetaStoreBridge.java
...ache/hadoop/metadata/hive/bridge/HiveMetaStoreBridge.java
+0
-0
HiveDataModelGenerator.java
...he/hadoop/metadata/hive/model/HiveDataModelGenerator.java
+0
-0
HiveDataTypes.java
.../org/apache/hadoop/metadata/hive/model/HiveDataTypes.java
+9
-4
HiveImporter.java
...va/org/apache/hadoop/metadata/hivetypes/HiveImporter.java
+5
-1
hive-data-model.json
src/main/examples/hive-data-model.json
+0
-0
No files found.
addons/hive-bridge/pom.xml
View file @
a86f0f3e
...
...
@@ -34,10 +34,22 @@
<properties>
<hive.version>
0.14.0
</hive.version>
<hadoop.version>
2.5.0
</hadoop.version>
</properties>
<dependencies>
<dependency>
<groupId>
org.apache.hadoop.metadata
</groupId>
<artifactId>
metadata-client
</artifactId>
</dependency>
<dependency>
<groupId>
org.apache.hadoop
</groupId>
<artifactId>
hadoop-client
</artifactId>
<version>
${hadoop.version}
</version>
</dependency>
<dependency>
<groupId>
org.apache.hive
</groupId>
<artifactId>
hive-metastore
</artifactId>
<version>
${hive.version}
</version>
...
...
@@ -96,11 +108,6 @@
</dependency>
<dependency>
<groupId>
org.apache.hadoop
</groupId>
<artifactId>
hadoop-client
</artifactId>
</dependency>
<dependency>
<groupId>
log4j
</groupId>
<artifactId>
log4j
</artifactId>
</dependency>
...
...
addons/hive-bridge/src/main/java/org/apache/hadoop/metadata/hive/bridge/HiveMetaStoreBridge.java
0 → 100644
View file @
a86f0f3e
This diff is collapsed.
Click to expand it.
addons/hive-bridge/src/main/java/org/apache/hadoop/metadata/hive/model/HiveDataModelGenerator.java
View file @
a86f0f3e
This diff is collapsed.
Click to expand it.
addons/hive-bridge/src/main/java/org/apache/hadoop/metadata/hive/model/HiveDataTypes.java
View file @
a86f0f3e
...
...
@@ -24,10 +24,10 @@ package org.apache.hadoop.metadata.hive.model;
public
enum
HiveDataTypes
{
// Enums
HIVE_OBJECTTYPE
,
HIVE_PRINCIPALTYPE
,
HIVE_RESOURCETYPE
,
HIVE_FUNCTIONTYPE
,
HIVE_OBJECT
_
TYPE
,
HIVE_PRINCIPAL
_
TYPE
,
HIVE_RESOURCE
_
TYPE
,
HIVE_FUNCTION
_
TYPE
,
// Structs
HIVE_SERDE
,
...
...
@@ -47,4 +47,9 @@ public enum HiveDataTypes {
HIVE_TYPE
,
HIVE_PROCESS
,
// HIVE_VIEW,
;
public
String
getName
()
{
return
name
().
toLowerCase
();
}
}
addons/hive-bridge/src/main/java/org/apache/hadoop/metadata/hivetypes/HiveImporter.java
View file @
a86f0f3e
...
...
@@ -46,6 +46,10 @@ import org.slf4j.LoggerFactory;
import
java.util.ArrayList
;
import
java.util.List
;
/**
* todo - this needs to be removed.
*/
@Deprecated
public
class
HiveImporter
{
private
static
final
Logger
LOG
=
...
...
@@ -158,7 +162,7 @@ public class HiveImporter {
LOG
.
debug
(
"creating instance of type "
+
typeName
+
" dataType "
+
dataType
);
ITypedReferenceableInstance
instance
=
(
ITypedReferenceableInstance
)
dataType
.
convert
(
ref
,
Multiplicity
.
OPTIONAL
);
String
guid
=
graphRepository
.
createEntity
(
instance
,
typeName
);
String
guid
=
graphRepository
.
createEntity
(
instance
);
System
.
out
.
println
(
"creating instance of type "
+
typeName
+
" dataType "
+
dataType
+
", guid: "
+
guid
);
...
...
src/main/examples/hive-data-model.json
View file @
a86f0f3e
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment