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
7de696cc
Commit
7de696cc
authored
9 years ago
by
Venkatesh Seetharam
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
BUG-38312 create class with empty name returns a 500 - take 2
parent
4982dfeb
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
3 deletions
+8
-3
DefaultMetadataService.java
...ache/hadoop/metadata/services/DefaultMetadataService.java
+8
-3
No files found.
repository/src/main/java/org/apache/hadoop/metadata/services/DefaultMetadataService.java
View file @
7de696cc
...
@@ -220,14 +220,19 @@ public class DefaultMetadataService implements MetadataService {
...
@@ -220,14 +220,19 @@ public class DefaultMetadataService implements MetadataService {
private
ITypedReferenceableInstance
deserializeClassInstance
(
private
ITypedReferenceableInstance
deserializeClassInstance
(
String
entityInstanceDefinition
)
throws
MetadataException
{
String
entityInstanceDefinition
)
throws
MetadataException
{
final
Referenceable
entityInstance
=
InstanceSerialization
.
fromJsonReferenceable
(
final
Referenceable
entityInstance
;
entityInstanceDefinition
,
true
);
try
{
entityInstance
=
InstanceSerialization
.
fromJsonReferenceable
(
entityInstanceDefinition
,
true
);
}
catch
(
Exception
e
)
{
// exception from deserializer
LOG
.
error
(
"Unable to deserialize json={}"
,
entityInstanceDefinition
,
e
);
throw
new
IllegalArgumentException
(
"Unable to deserialize json"
);
}
final
String
entityTypeName
=
entityInstance
.
getTypeName
();
final
String
entityTypeName
=
entityInstance
.
getTypeName
();
ParamChecker
.
notEmpty
(
entityTypeName
,
"Entity type cannot be null"
);
ParamChecker
.
notEmpty
(
entityTypeName
,
"Entity type cannot be null"
);
ClassType
entityType
=
typeSystem
.
getDataType
(
ClassType
.
class
,
entityTypeName
);
ClassType
entityType
=
typeSystem
.
getDataType
(
ClassType
.
class
,
entityTypeName
);
return
entityType
.
convert
(
entityInstance
,
Multiplicity
.
REQUIRED
);
return
entityType
.
convert
(
entityInstance
,
Multiplicity
.
REQUIRED
);
}
}
/**
/**
...
...
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