Separate all user-oriented metadata from ModelObject into MetadataObjectDescription or MetadataObjectInfo.
Note: It is Metadata* not Model* because it will describe non-logical objects as well in the future.
Reasons for the change:
more straightforward localization
simpler cloning of objects
better maintainability of the code
aligned with future metadata repository plans
easier to have immutable model objects (#282)
Attributes to be extracted into "info/description" structure:
name: str – name of the metadata object this description describes. Same as ModelObject.name
label: str – human-readable object name, should default to name
description: Optional[str] – human readable object description
tags: List[str] – list of tags that can be used for metadata discovery
extra: JSONType – currently called info
locale: Optional[str] – name of the locale the description is written in
Requirements
The information in the MetadataObjectDescription should not affect the query execution
Server should not be impacted – we would combine metadata object and it's description structure together when exporting
JSON model should not be impacted - we would separate the description metadata into it's own structure upon creation
Storage and retrieval
There are two possibilities how we are going to store/retrieve the description: from a common catalog of metadata (currently the best place is Workspace, in the future it will be metadata repository) or from within the object graph (would be good temporary solution, to keep it easier).
EDIT: Changed the name of the metadata description object to MetadataObjectDescription/*Info (undecided). Added more detailed description of desired attributes. Added requirements.
Separate all user-oriented metadata from
ModelObject
intoMetadataObjectDescription
orMetadataObjectInfo
.Note: It is
Metadata*
notModel*
because it will describe non-logical objects as well in the future.Reasons for the change:
Attributes to be extracted into "info/description" structure:
name: str
– name of the metadata object this description describes. Same asModelObject.name
label: str
– human-readable object name, should default toname
description: Optional[str]
– human readable object descriptiontags: List[str]
– list of tags that can be used for metadata discoveryextra: JSONType
– currently calledinfo
locale: Optional[str]
– name of the locale the description is written inRequirements
MetadataObjectDescription
should not affect the query executionStorage and retrieval
There are two possibilities how we are going to store/retrieve the description: from a common catalog of metadata (currently the best place is Workspace, in the future it will be metadata repository) or from within the object graph (would be good temporary solution, to keep it easier).
Currently:
Proposed temporary:
Proposed metadata repository:
EDIT: Changed the name of the metadata description object to
MetadataObjectDescription
/*Info
(undecided). Added more detailed description of desired attributes. Added requirements.