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
b725caaa
Commit
b725caaa
authored
8 years ago
by
Vimal Sharma
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
GET v2/types/{type}/guid/{guid} not working
parent
9683c117
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
3 deletions
+9
-3
AtlasTypeRegistry.java
...rc/main/java/org/apache/atlas/type/AtlasTypeRegistry.java
+9
-3
No files found.
intg/src/main/java/org/apache/atlas/type/AtlasTypeRegistry.java
View file @
b725caaa
...
...
@@ -731,6 +731,7 @@ class TypeCache {
}
class
TypeDefCache
<
T
extends
AtlasBaseTypeDef
>
{
private
static
final
Logger
LOG
=
LoggerFactory
.
getLogger
(
TypeDefCache
.
class
);
private
final
TypeCache
typeCache
;
private
final
Map
<
String
,
T
>
typeDefGuidMap
;
private
final
Map
<
String
,
T
>
typeDefNameMap
;
...
...
@@ -766,7 +767,6 @@ class TypeDefCache<T extends AtlasBaseTypeDef> {
}
public
T
getTypeDefByGuid
(
String
guid
)
{
return
guid
!=
null
?
typeDefGuidMap
.
get
(
guid
)
:
null
;
}
...
...
@@ -781,8 +781,14 @@ class TypeDefCache<T extends AtlasBaseTypeDef> {
if
(
typeDef
!=
null
)
{
String
currGuid
=
typeDef
.
getGuid
();
if
(!
StringUtils
.
equals
(
currGuid
,
newGuid
))
{
if
(!
typeDefGuidMap
.
containsKey
(
newGuid
)
||
!
StringUtils
.
equals
(
currGuid
,
newGuid
))
{
if
(
LOG
.
isDebugEnabled
())
{
if
(!
typeDefGuidMap
.
containsKey
(
newGuid
))
{
LOG
.
debug
(
"TypeDefGuidMap doesn't contain entry for guid {}. Adding new entry"
,
newGuid
);
}
else
{
LOG
.
debug
(
"Removing entry for guid {} and adding entry for guid {}"
,
currGuid
,
newGuid
);
}
}
if
(
currGuid
!=
null
)
{
typeDefGuidMap
.
remove
(
currGuid
);
}
...
...
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