[ 
https://issues.apache.org/jira/browse/ATLAS-294?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15010439#comment-15010439
 ] 

Thiyagarajan Gnanasekaran commented on ATLAS-294:
-------------------------------------------------

[~suma.shivaprasad] I changed the code base of the function 
assertEntityIsRegistered().

assertEntityIsRegistered() function is a private function and can onlyl be 
called by other functions internally within the class.

All the assert functions in the test case like 

1) assertColumnIsRegistered(), 
2) assertProcessIsRegistered(), 
3) assertTableIsRegistered(), 
4) assertDatabaseIsRegistered(), 
5) assertPartitionIsRegistered() 

in turn call the assertEntityIsRegistered() function in their method body to 
assert their registrations.



> Select queries(ex: from DB select DB.name) response contains column names as 
> "_col_x" instead of the actual names requested in the query.
> -----------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: ATLAS-294
>                 URL: https://issues.apache.org/jira/browse/ATLAS-294
>             Project: Atlas
>          Issue Type: Bug
>    Affects Versions: 0.6-incubating
>            Reporter: Ayub Khan
>            Assignee: Thiyagarajan Gnanasekaran
>              Labels: patch
>             Fix For: 0.6-incubating
>
>         Attachments: apache-294.patch
>
>
> Select queries(ex: from DB select DB.name) response contains column names as 
> "_col_x" instead of the actual names requested in the query.
> For example: 
> {noformat}
> curl 
> 'http://52.27.169.250:3208/api/atlas/discovery/search?query=from+DB+select+DB.name,+DB.locationUri,+DB.owner,+DB.description'
>  -H 'Accept: application/json, text/plain, */*' -H 'Connection: keep-alive' 
> -H 'Accept-Encoding: gzip, deflate, sdch' -H 'Referer: 
> http://52.27.169.250:3208/' -H 'Accept-Language: en-US,en;q=0.8' -H 
> 'User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_5) 
> AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2490.80 Safari/537.36' 
> --compressed | python -m json.tool
>   % Total    % Received % Xferd  Average Speed   Time    Time     Time  
> Current
>                                  Dload  Upload   Total   Spent    Left  Speed
> 100  1318    0  1318    0     0    643      0 --:--:--  0:00:02 --:--:--   643
> {
>     "count": 2,
>     "dataType": {
>         "attributeDefinitions": [
>             {
>                 "dataTypeName": "string",
>                 "isComposite": false,
>                 "isIndexable": true,
>                 "isUnique": false,
>                 "multiplicity": {
>                     "isUnique": false,
>                     "lower": 0,
>                     "upper": 1
>                 },
>                 "name": "_col_0",
>                 "reverseAttributeName": null
>             },
>             {
>                 "dataTypeName": "string",
>                 "isComposite": false,
>                 "isIndexable": true,
>                 "isUnique": false,
>                 "multiplicity": {
>                     "isUnique": false,
>                     "lower": 0,
>                     "upper": 1
>                 },
>                 "name": "_col_1",
>                 "reverseAttributeName": null
>             },
>             {
>                 "dataTypeName": "string",
>                 "isComposite": false,
>                 "isIndexable": true,
>                 "isUnique": false,
>                 "multiplicity": {
>                     "isUnique": false,
>                     "lower": 0,
>                     "upper": 1
>                 },
>                 "name": "_col_2",
>                 "reverseAttributeName": null
>             },
>             {
>                 "dataTypeName": "string",
>                 "isComposite": false,
>                 "isIndexable": true,
>                 "isUnique": false,
>                 "multiplicity": {
>                     "isUnique": false,
>                     "lower": 0,
>                     "upper": 1
>                 },
>                 "name": "_col_3",
>                 "reverseAttributeName": null
>             }
>         ],
>         "typeName": "__tempQueryResultStruct892"
>     },
>     "query": "from DB select DB.name, DB.locationUri, DB.owner, 
> DB.description",
>     "queryType": "dsl",
>     "requestId": "qtp1879648991-168 - 4f2f4de0-e57a-4283-8dbb-8c2ad3ce00e8",
>     "results": [
>         {
>             "$typeName$": "__tempQueryResultStruct892",
>             "_col_0": "Sales",
>             "_col_1": "hdfs://host:8000/apps/warehouse/sales",
>             "_col_2": "John ETL",
>             "_col_3": "Sales Database"
>         },
>         {
>             "$typeName$": "__tempQueryResultStruct892",
>             "_col_0": "Reporting",
>             "_col_1": "hdfs://host:8000/apps/warehouse/reporting",
>             "_col_2": "Jane BI",
>             "_col_3": "reporting database"
>         }
>     ]
> }
> {noformat}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to