You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ranger.apache.org by Madhan Neethiraj <ma...@apache.org> on 2022/10/03 04:49:38 UTC

Re: Review Request 74119: User REST API /users/firstnames returns only null with status code 204

-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/74119/#review224728
-----------------------------------------------------------


Ship it!




Ship It!

- Madhan Neethiraj


On Sept. 14, 2022, 10:17 a.m., Ramachandran Krishnan wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/74119/
> -----------------------------------------------------------
> 
> (Updated Sept. 14, 2022, 10:17 a.m.)
> 
> 
> Review request for ranger, Abhay Kulkarni, Madhan Neethiraj, Nikhil P, Pradeep Agrawal, Ramesh Mani, Selvamohan Neethiraj, Sailaja Polavarapu, and Velmurugan Periasamy.
> 
> 
> Bugs: RANGER-3885
>     https://issues.apache.org/jira/browse/RANGER-3885
> 
> 
> Repository: ranger
> 
> 
> Description
> -------
> 
> According to the documentation, the API resource_UserREST_suggestUserFirstName_GET should return status code 200 when a request is made, but the API always returns a status code 204 No Content.
> From the code, it is clear that the API call just returns null without performing any operations.
> 
> @GET
> 	@Path("/firstnames")
> 	@Produces({ "application/json", "application/xml" })
> 	public String suggestUserFirstName(@QueryParam("letters") String letters,
> 			@Context HttpServletRequest req) {
> 		return null;
> 	}
>     
>    The below API it does not make any sense https://ranger.apache.org/apidocs/resource_UserREST.html#resource_UserREST_suggestUserFirstName_GET 
>    It seems this API was added very long back .Better we can remove it from our Ranger code .
> 
> 
> Diffs
> -----
> 
>   security-admin/src/main/java/org/apache/ranger/rest/UserREST.java 83da29d8b 
>   security-admin/src/main/java/org/apache/ranger/security/context/RangerAPIList.java 18afe8521 
>   security-admin/src/test/java/org/apache/ranger/rest/TestUserREST.java 3c3051b39 
> 
> 
> Diff: https://reviews.apache.org/r/74119/diff/1/
> 
> 
> Testing
> -------
> 
> Verified the build and it works fine .
> 
> 
> Thanks,
> 
> Ramachandran Krishnan
> 
>