You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@atlas.apache.org by Sidharth Mishra <si...@gmail.com> on 2020/04/21 20:22:09 UTC

Review Request 72411: ATLAS-3747: Atlas Admin Purge API should take list of guids as query param instead of body

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

Review request for atlas, Ashutosh Mestry, Madhan Neethiraj, and Sarath Subramanian.


Bugs: ATLAS-3747
    https://issues.apache.org/jira/browse/ATLAS-3747


Repository: atlas


Description
-------

ATLAS-3747: Atlas Admin Purge API should take list of guids as query param instead of body


Diffs
-----

  client/client-v2/src/main/java/org/apache/atlas/AtlasClientV2.java 5a19a0b0e 
  webapp/src/main/java/org/apache/atlas/web/resources/AdminResource.java a7d554a36 


Diff: https://reviews.apache.org/r/72411/diff/1/


Testing
-------

Manual Testing:
curl -u admin:admin123 --location --request DELETE 'http://sid-ycloud-atlas2-1.sid-ycloud-atlas2.root.hwx.site:31000/api/atlas/admin/purge/?guid=82785128-778a-4e0d-aac0-8327b4ca1e87&guid=f0cc9cfd-71af-47fc-9321-2970dfa5825f&guid=f0cc9cfd-71af-47fc-9321-2970dfa5825f' --header 'Content-Type: application/json'

Note: As local jetty was failing for couple of times, I was not able to run EntityV2JerseyResourceIT. precommit run will ensure if this passes.


Thanks,

Sidharth Mishra


Re: Review Request 72411: ATLAS-3747: Atlas Admin Purge API should take list of guids as query param instead of body

Posted by Madhan Neethiraj <ma...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/72411/#review220404
-----------------------------------------------------------


Fix it, then Ship it!





client/client-v2/src/main/java/org/apache/atlas/AtlasClientV2.java
Line 378 (original), 378 (patched)
<https://reviews.apache.org/r/72411/#comment308786>

    Consider updating callAPI() to replace List<String> with Collection<String>.  This will help avoid having to instantiate a list here.


- Madhan Neethiraj


On April 21, 2020, 8:22 p.m., Sidharth Mishra wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/72411/
> -----------------------------------------------------------
> 
> (Updated April 21, 2020, 8:22 p.m.)
> 
> 
> Review request for atlas, Ashutosh Mestry, Madhan Neethiraj, and Sarath Subramanian.
> 
> 
> Bugs: ATLAS-3747
>     https://issues.apache.org/jira/browse/ATLAS-3747
> 
> 
> Repository: atlas
> 
> 
> Description
> -------
> 
> ATLAS-3747: Atlas Admin Purge API should take list of guids as query param instead of body
> 
> 
> Diffs
> -----
> 
>   client/client-v2/src/main/java/org/apache/atlas/AtlasClientV2.java 5a19a0b0e 
>   webapp/src/main/java/org/apache/atlas/web/resources/AdminResource.java a7d554a36 
> 
> 
> Diff: https://reviews.apache.org/r/72411/diff/1/
> 
> 
> Testing
> -------
> 
> Manual Testing:
> curl -u admin:admin123 --location --request DELETE 'http://sid-ycloud-atlas2-1.sid-ycloud-atlas2.root.hwx.site:31000/api/atlas/admin/purge/?guid=82785128-778a-4e0d-aac0-8327b4ca1e87&guid=f0cc9cfd-71af-47fc-9321-2970dfa5825f&guid=f0cc9cfd-71af-47fc-9321-2970dfa5825f' --header 'Content-Type: application/json'
> 
> Note: As local jetty was failing for couple of times, I was not able to run EntityV2JerseyResourceIT. precommit run will ensure if this passes.
> 
> 
> Thanks,
> 
> Sidharth Mishra
> 
>


Re: Review Request 72411: ATLAS-3747: Atlas Admin Purge API should take list of guids as body with operation Put instead of Delete

Posted by Madhan Neethiraj <ma...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/72411/#review220408
-----------------------------------------------------------


Ship it!




Ship It!

- Madhan Neethiraj


On April 21, 2020, 9:45 p.m., Sidharth Mishra wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/72411/
> -----------------------------------------------------------
> 
> (Updated April 21, 2020, 9:45 p.m.)
> 
> 
> Review request for atlas, Ashutosh Mestry, Madhan Neethiraj, and Sarath Subramanian.
> 
> 
> Bugs: ATLAS-3747
>     https://issues.apache.org/jira/browse/ATLAS-3747
> 
> 
> Repository: atlas
> 
> 
> Description
> -------
> 
> ATLAS-3747: Atlas Admin Purge API should take list of guids as query param instead of body
> 
> 
> Diffs
> -----
> 
>   client/client-v2/src/main/java/org/apache/atlas/AtlasClientV2.java 5a19a0b0e 
>   webapp/src/main/java/org/apache/atlas/web/resources/AdminResource.java a7d554a36 
> 
> 
> Diff: https://reviews.apache.org/r/72411/diff/2/
> 
> 
> Testing
> -------
> 
> Manual Testing:
> 
> curl -u admin:admin123 --location --request PUT 'http://sid-ycloud-atlas2-1.sid-ycloud-atlas2.root.hwx.site:31000/api/atlas/admin/purge/' \
> --header 'Content-Type: application/json' \
> --header 'Content-Type: application/json' \
> --header 'Cookie: ATLASSESSIONID=node0g7w7rpfe6o0a1e4e7hk5cth4d2.node0' \
> --data-raw '["bd7262f6-fed5-40f3-9f72-f57fba6b1193", "24c4df6e-b27a-4c60-b85a-67ed20210446", "24c4df6e-b27a-4c60-b85a-67ed20210446"]'
> 
> Note: As local jetty was failing for couple of times, I was not able to run EntityV2JerseyResourceIT. precommit run will ensure if this passes.
> 
> 
> Thanks,
> 
> Sidharth Mishra
> 
>


Re: Review Request 72411: ATLAS-3747: Atlas Admin Purge API should take list of guids as body with operation Put instead of Delete

Posted by Sarath Subramanian <sa...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/72411/#review220409
-----------------------------------------------------------


Ship it!




Ship It!

- Sarath Subramanian


On April 21, 2020, 2:45 p.m., Sidharth Mishra wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/72411/
> -----------------------------------------------------------
> 
> (Updated April 21, 2020, 2:45 p.m.)
> 
> 
> Review request for atlas, Ashutosh Mestry, Madhan Neethiraj, and Sarath Subramanian.
> 
> 
> Bugs: ATLAS-3747
>     https://issues.apache.org/jira/browse/ATLAS-3747
> 
> 
> Repository: atlas
> 
> 
> Description
> -------
> 
> ATLAS-3747: Atlas Admin Purge API should take list of guids as query param instead of body
> 
> 
> Diffs
> -----
> 
>   client/client-v2/src/main/java/org/apache/atlas/AtlasClientV2.java 5a19a0b0e 
>   webapp/src/main/java/org/apache/atlas/web/resources/AdminResource.java a7d554a36 
> 
> 
> Diff: https://reviews.apache.org/r/72411/diff/2/
> 
> 
> Testing
> -------
> 
> Manual Testing:
> 
> curl -u admin:admin123 --location --request PUT 'http://sid-ycloud-atlas2-1.sid-ycloud-atlas2.root.hwx.site:31000/api/atlas/admin/purge/' \
> --header 'Content-Type: application/json' \
> --header 'Content-Type: application/json' \
> --header 'Cookie: ATLASSESSIONID=node0g7w7rpfe6o0a1e4e7hk5cth4d2.node0' \
> --data-raw '["bd7262f6-fed5-40f3-9f72-f57fba6b1193", "24c4df6e-b27a-4c60-b85a-67ed20210446", "24c4df6e-b27a-4c60-b85a-67ed20210446"]'
> 
> Note: As local jetty was failing for couple of times, I was not able to run EntityV2JerseyResourceIT. precommit run will ensure if this passes.
> 
> 
> Thanks,
> 
> Sidharth Mishra
> 
>


Re: Review Request 72411: ATLAS-3747: Atlas Admin Purge API should take list of guids as body with operation Put instead of Delete

Posted by Sidharth Mishra <si...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/72411/
-----------------------------------------------------------

(Updated April 21, 2020, 9:45 p.m.)


Review request for atlas, Ashutosh Mestry, Madhan Neethiraj, and Sarath Subramanian.


Bugs: ATLAS-3747
    https://issues.apache.org/jira/browse/ATLAS-3747


Repository: atlas


Description
-------

ATLAS-3747: Atlas Admin Purge API should take list of guids as query param instead of body


Diffs (updated)
-----

  client/client-v2/src/main/java/org/apache/atlas/AtlasClientV2.java 5a19a0b0e 
  webapp/src/main/java/org/apache/atlas/web/resources/AdminResource.java a7d554a36 


Diff: https://reviews.apache.org/r/72411/diff/2/

Changes: https://reviews.apache.org/r/72411/diff/1-2/


Testing
-------

Manual Testing:

curl -u admin:admin123 --location --request PUT 'http://sid-ycloud-atlas2-1.sid-ycloud-atlas2.root.hwx.site:31000/api/atlas/admin/purge/' \
--header 'Content-Type: application/json' \
--header 'Content-Type: application/json' \
--header 'Cookie: ATLASSESSIONID=node0g7w7rpfe6o0a1e4e7hk5cth4d2.node0' \
--data-raw '["bd7262f6-fed5-40f3-9f72-f57fba6b1193", "24c4df6e-b27a-4c60-b85a-67ed20210446", "24c4df6e-b27a-4c60-b85a-67ed20210446"]'

Note: As local jetty was failing for couple of times, I was not able to run EntityV2JerseyResourceIT. precommit run will ensure if this passes.


Thanks,

Sidharth Mishra


Re: Review Request 72411: ATLAS-3747: Atlas Admin Purge API should take list of guids as body with operation Put instead of Delete

Posted by Sidharth Mishra <si...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/72411/
-----------------------------------------------------------

(Updated April 21, 2020, 9:45 p.m.)


Review request for atlas, Ashutosh Mestry, Madhan Neethiraj, and Sarath Subramanian.


Summary (updated)
-----------------

ATLAS-3747: Atlas Admin Purge API should take list of guids as body with operation Put instead of Delete


Bugs: ATLAS-3747
    https://issues.apache.org/jira/browse/ATLAS-3747


Repository: atlas


Description
-------

ATLAS-3747: Atlas Admin Purge API should take list of guids as query param instead of body


Diffs
-----

  client/client-v2/src/main/java/org/apache/atlas/AtlasClientV2.java 5a19a0b0e 
  webapp/src/main/java/org/apache/atlas/web/resources/AdminResource.java a7d554a36 


Diff: https://reviews.apache.org/r/72411/diff/1/


Testing (updated)
-------

Manual Testing:

curl -u admin:admin123 --location --request PUT 'http://sid-ycloud-atlas2-1.sid-ycloud-atlas2.root.hwx.site:31000/api/atlas/admin/purge/' \
--header 'Content-Type: application/json' \
--header 'Content-Type: application/json' \
--header 'Cookie: ATLASSESSIONID=node0g7w7rpfe6o0a1e4e7hk5cth4d2.node0' \
--data-raw '["bd7262f6-fed5-40f3-9f72-f57fba6b1193", "24c4df6e-b27a-4c60-b85a-67ed20210446", "24c4df6e-b27a-4c60-b85a-67ed20210446"]'

Note: As local jetty was failing for couple of times, I was not able to run EntityV2JerseyResourceIT. precommit run will ensure if this passes.


Thanks,

Sidharth Mishra


Re: Review Request 72411: ATLAS-3747: Atlas Admin Purge API should take list of guids as query param instead of body

Posted by Sarath Subramanian <sa...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/72411/#review220405
-----------------------------------------------------------




webapp/src/main/java/org/apache/atlas/web/resources/AdminResource.java
Line 465 (original), 465 (patched)
<https://reviews.apache.org/r/72411/#comment308787>

    consider using @PUT with body of guids instead of guids in QueryParam, you are restricted with the number of guids you can supply in the query params (url length is limited). 
    
    Reference: GlossaryRest:disassociateTermAssignmentFromEntities()


- Sarath Subramanian


On April 21, 2020, 1:22 p.m., Sidharth Mishra wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/72411/
> -----------------------------------------------------------
> 
> (Updated April 21, 2020, 1:22 p.m.)
> 
> 
> Review request for atlas, Ashutosh Mestry, Madhan Neethiraj, and Sarath Subramanian.
> 
> 
> Bugs: ATLAS-3747
>     https://issues.apache.org/jira/browse/ATLAS-3747
> 
> 
> Repository: atlas
> 
> 
> Description
> -------
> 
> ATLAS-3747: Atlas Admin Purge API should take list of guids as query param instead of body
> 
> 
> Diffs
> -----
> 
>   client/client-v2/src/main/java/org/apache/atlas/AtlasClientV2.java 5a19a0b0e 
>   webapp/src/main/java/org/apache/atlas/web/resources/AdminResource.java a7d554a36 
> 
> 
> Diff: https://reviews.apache.org/r/72411/diff/1/
> 
> 
> Testing
> -------
> 
> Manual Testing:
> curl -u admin:admin123 --location --request DELETE 'http://sid-ycloud-atlas2-1.sid-ycloud-atlas2.root.hwx.site:31000/api/atlas/admin/purge/?guid=82785128-778a-4e0d-aac0-8327b4ca1e87&guid=f0cc9cfd-71af-47fc-9321-2970dfa5825f&guid=f0cc9cfd-71af-47fc-9321-2970dfa5825f' --header 'Content-Type: application/json'
> 
> Note: As local jetty was failing for couple of times, I was not able to run EntityV2JerseyResourceIT. precommit run will ensure if this passes.
> 
> 
> Thanks,
> 
> Sidharth Mishra
> 
>