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
d9d487bc
Commit
d9d487bc
authored
Dec 08, 2016
by
apoorvnaik
Committed by
Suma Shivaprasad
Dec 08, 2016
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ATLAS-1357: NPE Fix for search filter changes & callAPI related fixes
parent
28410df5
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
16 additions
and
9 deletions
+16
-9
SearchFilter.java
intg/src/main/java/org/apache/atlas/model/SearchFilter.java
+7
-1
release-log.txt
release-log.txt
+1
-0
EntityJerseyResourceIT.java
...rg/apache/atlas/web/resources/EntityJerseyResourceIT.java
+3
-3
TypesJerseyResourceIT.java
...org/apache/atlas/web/resources/TypesJerseyResourceIT.java
+5
-5
No files found.
intg/src/main/java/org/apache/atlas/model/SearchFilter.java
View file @
d9d487bc
...
@@ -73,7 +73,13 @@ public class SearchFilter {
...
@@ -73,7 +73,13 @@ public class SearchFilter {
}
}
public
String
getParam
(
String
name
)
{
public
String
getParam
(
String
name
)
{
return
getParams
(
name
).
get
(
0
);
String
ret
=
null
;
if
(
name
!=
null
&&
params
!=
null
)
{
ret
=
params
.
getFirst
(
name
);
}
return
ret
;
}
}
public
List
<
String
>
getParams
(
String
name
)
{
public
List
<
String
>
getParams
(
String
name
)
{
...
...
release-log.txt
View file @
d9d487bc
...
@@ -9,6 +9,7 @@ ATLAS-1060 Add composite indexes for exact match performance improvements for al
...
@@ -9,6 +9,7 @@ ATLAS-1060 Add composite indexes for exact match performance improvements for al
ATLAS-1127 Modify creation and modification timestamps to Date instead of Long(sumasai)
ATLAS-1127 Modify creation and modification timestamps to Date instead of Long(sumasai)
ALL CHANGES:
ALL CHANGES:
ATLAS-1358 NPE Fix for search filter changes & callAPI related fixes (apoorvnaik via sumasai)
ATLAS-1357: Fixes for test failures from ATLAS-1307 (apoorvnaik via sumasai)
ATLAS-1357: Fixes for test failures from ATLAS-1307 (apoorvnaik via sumasai)
ATLAS-1307: Integration test calls routing via the Client. (apoorvnaik via sumasai)
ATLAS-1307: Integration test calls routing via the Client. (apoorvnaik via sumasai)
ATLAS-1355: Fix for bad error translation from V2 API (apoorvnaik via sumasai)
ATLAS-1355: Fix for bad error translation from V2 API (apoorvnaik via sumasai)
...
...
webapp/src/test/java/org/apache/atlas/web/resources/EntityJerseyResourceIT.java
View file @
d9d487bc
...
@@ -429,10 +429,10 @@ public class EntityJerseyResourceIT extends BaseResourceIT {
...
@@ -429,10 +429,10 @@ public class EntityJerseyResourceIT extends BaseResourceIT {
@Test
(
expectedExceptions
=
AtlasServiceException
.
class
)
@Test
(
expectedExceptions
=
AtlasServiceException
.
class
)
public
void
testGetEntityListForBadEntityType
()
throws
Exception
{
public
void
testGetEntityListForBadEntityType
()
throws
Exception
{
M
ap
<
String
,
String
>
queryParams
=
new
HashMap
<>
();
M
ultivaluedMap
<
String
,
String
>
queryParams
=
new
MultivaluedMapImpl
();
queryParams
.
put
(
"type"
,
"blah"
);
queryParams
.
add
(
"type"
,
"blah"
);
JSONObject
response
=
serviceClient
.
callAPIWith
Body
(
AtlasClient
.
API
.
GET_ENTITY
,
queryParams
);
JSONObject
response
=
serviceClient
.
callAPIWith
QueryParams
(
AtlasClient
.
API
.
GET_ENTITY
,
queryParams
);
assertNotNull
(
response
);
assertNotNull
(
response
);
Assert
.
assertNotNull
(
response
.
get
(
AtlasClient
.
ERROR
));
Assert
.
assertNotNull
(
response
.
get
(
AtlasClient
.
ERROR
));
Assert
.
assertNotNull
(
response
.
get
(
AtlasClient
.
STACKTRACE
));
Assert
.
assertNotNull
(
response
.
get
(
AtlasClient
.
STACKTRACE
));
...
...
webapp/src/test/java/org/apache/atlas/web/resources/TypesJerseyResourceIT.java
View file @
d9d487bc
...
@@ -20,6 +20,7 @@ package org.apache.atlas.web.resources;
...
@@ -20,6 +20,7 @@ package org.apache.atlas.web.resources;
import
com.google.common.collect.ImmutableList
;
import
com.google.common.collect.ImmutableList
;
import
com.google.common.collect.ImmutableSet
;
import
com.google.common.collect.ImmutableSet
;
import
com.sun.jersey.core.util.MultivaluedMapImpl
;
import
org.apache.atlas.AtlasClient
;
import
org.apache.atlas.AtlasClient
;
import
org.apache.atlas.AtlasServiceException
;
import
org.apache.atlas.AtlasServiceException
;
import
org.apache.atlas.typesystem.TypesDef
;
import
org.apache.atlas.typesystem.TypesDef
;
...
@@ -41,12 +42,11 @@ import org.testng.annotations.AfterClass;
...
@@ -41,12 +42,11 @@ import org.testng.annotations.AfterClass;
import
org.testng.annotations.BeforeClass
;
import
org.testng.annotations.BeforeClass
;
import
org.testng.annotations.Test
;
import
org.testng.annotations.Test
;
import
javax.ws.rs.core.MultivaluedMap
;
import
javax.ws.rs.core.Response
;
import
javax.ws.rs.core.Response
;
import
java.util.ArrayList
;
import
java.util.ArrayList
;
import
java.util.Arrays
;
import
java.util.Arrays
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.List
;
import
java.util.Map
;
import
static
org
.
apache
.
atlas
.
typesystem
.
types
.
utils
.
TypesUtil
.
createOptionalAttrDef
;
import
static
org
.
apache
.
atlas
.
typesystem
.
types
.
utils
.
TypesUtil
.
createOptionalAttrDef
;
import
static
org
.
testng
.
Assert
.
assertEquals
;
import
static
org
.
testng
.
Assert
.
assertEquals
;
...
@@ -187,10 +187,10 @@ public class TypesJerseyResourceIT extends BaseResourceIT {
...
@@ -187,10 +187,10 @@ public class TypesJerseyResourceIT extends BaseResourceIT {
public
void
testGetTraitNames
()
throws
Exception
{
public
void
testGetTraitNames
()
throws
Exception
{
String
[]
traitsAdded
=
addTraits
();
String
[]
traitsAdded
=
addTraits
();
Map
<
String
,
String
>
queryParams
=
new
HashMap
<>
();
MultivaluedMap
<
String
,
String
>
queryParams
=
new
MultivaluedMapImpl
();
queryParams
.
put
(
"type"
,
DataTypes
.
TypeCategory
.
TRAIT
.
name
());
queryParams
.
add
(
"type"
,
DataTypes
.
TypeCategory
.
TRAIT
.
name
());
JSONObject
response
=
serviceClient
.
callAPIWith
Body
(
AtlasClient
.
API
.
LIST_TYPES
,
queryParams
);
JSONObject
response
=
serviceClient
.
callAPIWith
QueryParams
(
AtlasClient
.
API
.
LIST_TYPES
,
queryParams
);
Assert
.
assertNotNull
(
response
);
Assert
.
assertNotNull
(
response
);
Assert
.
assertNotNull
(
response
.
get
(
AtlasClient
.
REQUEST_ID
));
Assert
.
assertNotNull
(
response
.
get
(
AtlasClient
.
REQUEST_ID
));
...
...
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