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




agents-common/src/main/java/org/apache/ranger/plugin/model/RangerGds.java
Lines 876 (patched)
<https://reviews.apache.org/r/75347/#comment315459>

    - DatasetSummaryWrapper => DatasetsSummary
    - instead of datasetSummary as a member, consider extending from 
PList<DatasetSummary>
    - add default constructor i.e. with no arguments. This might be necessary 
for deserialization.



security-admin/src/main/java/org/apache/ranger/biz/GdsDBStore.java
Lines 123 (patched)
<https://reviews.apache.org/r/75347/#comment315460>

    aggregatedLabels   => labelCounts
    aggregatedKeywords => keywordCounts


- Madhan Neethiraj


On Jan. 31, 2025, 3:15 a.m., Radhika Kundam wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/75347/
> -----------------------------------------------------------
> 
> (Updated Jan. 31, 2025, 3:15 a.m.)
> 
> 
> Review request for ranger, Madhan Neethiraj and Ramesh Mani.
> 
> 
> Bugs: RANGER-5111
>     https://issues.apache.org/jira/browse/RANGER-5111
> 
> 
> Repository: ranger
> 
> 
> Description
> -------
> 
> The Summary API should support distinct filtering capabilities that include 
> all unique labels and keywords associated with the datashares returned in the 
> response. Additionally, the API should provide the count of datashares linked 
> to each specific label and keyword. This enhancement ensures that the data 
> can be effectively utilized for advanced filtering on the UI.
> 
> 
> Diffs
> -----
> 
>   agents-common/src/main/java/org/apache/ranger/plugin/model/RangerGds.java 
> 260ebc0a8 
>   security-admin/src/main/java/org/apache/ranger/biz/GdsDBStore.java 
> 7916f0818 
>   security-admin/src/main/java/org/apache/ranger/rest/GdsREST.java 0d3ef3d76 
> 
> 
> Diff: https://reviews.apache.org/r/75347/diff/4/
> 
> 
> Testing
> -------
> 
> Tested locally.
> 
> Summary view with additionalInfo(Labels & Keywords) of DataShares in GDS:
> ------------------------------------------------------------------------
> Request:
> -------
> curl -X GET -u <username>:<pwd> '<ranger 
> url>/service/gds/dataset/enhancedsummary?pageSize=1
> 
> Response: 
> --------
> Response consists of datasetSummary and filters
> datasetSummary: list of all datasets
> filters: map with relevant labels and keywords with dataset counts
> 
> {
>     "datasetSummary": {
>         "startIndex": 0,
>         "pageSize": 1,
>         "totalCount": 8,
>         "resultSize": 1,
>         "sortType": "asc",
>         "sortBy": "datasetId",
>         "queryTimeMS": 1737664148576,
>         "list": [
>             {
>                 "id": 1,
>                 "guid": "87662f8e-57af-40e3-8c92-45c108d474ac",
>                 "isEnabled": true,
>                 "createdBy": "Admin",
>                 "updatedBy": "Admin",
>                 "createTime": 1736362927000,
>                 "updateTime": 1736362927000,
>                 "version": 1,
>                 "name": "dataset-1",
>                 "permissionForCaller": "ADMIN",
>                 "principalsCount": {
>                     "USER": 1,
>                     "GROUP": 1,
>                     "ROLE": 0
>                 },
>                 "aclPrincipalsCount": {
>                     "USER": 1,
>                     "GROUP": 0,
>                     "ROLE": 0
>                 },
>                 "projectsCount": 0,
>                 "totalResourceCount": 4,
>                 "dataShares": [
>                     {
>                         "id": 1,
>                         "guid": "d4596038-122d-476f-a5e5-55937e87e011",
>                         "isEnabled": true,
>                         "createdBy": "Admin",
>                         "updatedBy": "Admin",
>                         "createTime": 1736362834000,
>                         "updateTime": 1736362834000,
>                         "version": 1,
>                         "dataShareId": 1,
>                         "dataShareName": "datashare-1",
>                         "serviceId": 6,
>                         "serviceName": "cm_hive",
>                         "zoneName": " ",
>                         "resourceCount": 4,
>                         "shareStatus": "ACTIVE",
>                         "approver": "admin"
>                     }
>                 ]
>             }
>         ],
>         "listSize": 1
>     },
>     "additionalInfo": {
>         "aggregatedKeywords": {
>             "kw1": 2,
>             "testKW1": 1,
>             "kw2": 2,
>             "kw21": 3,
>             "kw11": 3
>         },
>         "aggregatedLabels": {
>             "abc1": 2,
>             "test2": 2,
>             "test21": 3,
>             "abc111": 3,
>             "testLabel1": 1
>         }
>     }
> }
> 
> 
> Thanks,
> 
> Radhika Kundam
> 
>

Reply via email to