atlas-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Keval Bhatt (JIRA)" <>
Subject [jira] [Assigned] (ATLAS-1521) Update UI to eliminate REST calls to obtain schema data
Date Fri, 03 Feb 2017 13:50:51 GMT


Keval Bhatt reassigned ATLAS-1521:

    Assignee: Keval Bhatt

> Update UI to eliminate REST calls to obtain schema data
> -------------------------------------------------------
>                 Key: ATLAS-1521
>                 URL:
>             Project: Atlas
>          Issue Type: Improvement
>          Components: atlas-webui
>    Affects Versions: 0.8-incubating
>            Reporter: Madhan Neethiraj
>            Assignee: Keval Bhatt
> When rendering entity details page, UI makes a REST API call to /schema/{guid} to obtain
the schema data. For entity types that don't support the notion of schema, this REST API call
returns an error. When such error is returned, UI does not add 'Schema' tab to the details
page. When the call returns data, UI renders the data in 'Schema' tab.
> Given that only few entity-types (like hive_table) support schema, most calls to retrieve
schema return an error. Having additional schema related information in the type can eliminate
the need for unnecessary REST calls. ATLAS-1517 introduces additional data in 'typeDefOptions'
attribute of entity-type definition. UI can use the following logic to render the schema tab
> # Does an entity-type support schema?
>   Is {{entityDef.typeDefOptions\[schemaElementsAttribute]}} set and its value non empty?
If yes, schema is supported else not-supported. For hive_table type, this will be set to 'columns'
- as shown below:
> {code}
>       "typeDefOptions": {
>         "schemaElementsAttribute": "columns"
>       }
> {code}
> # How does UI get the data to display in schema tab?
>   Value of {{entityDef.typeDefOptions\[schemaElementsAttribute]}} will be the name of
the attribute in the entity being rendered. This attribute should be of type array. The value
of this attribute will have the data needed to render the schema tab
> # What are the columns to display in schema tab?
>   Each element of the array attribute value will hold an entity/struct instance.For example,
In case of hive_table, columns attribute will have an array of hive_column objects. From each
such element, UI should get value of attributes listed in {{elementDef.typeDefOptions\[schemaAttributes]}}
to render the schema table. For example, hive_column will have the following:
> {code}
>       "typeDefOptions": {
>         "schemaAttributes": "[\"name\", \"description\", \"owner\", \"type\", \"comment\",
>       }
> {code}
> The value will be a json-ified string array.

This message was sent by Atlassian JIRA

View raw message