Skip to content

Commit

Permalink
Merge pull request #7723 from alexandra-bucur/asset-catalog-javadoc
Browse files Browse the repository at this point in the history
Add missing Javadoc to Asset Catalog and move it to Tech Preview
  • Loading branch information
Alexandra Bucur authored Jun 21, 2023
2 parents af4023a 46cef53 commit d986b09
Show file tree
Hide file tree
Showing 78 changed files with 1,186 additions and 206 deletions.
Original file line number Diff line number Diff line change
@@ -1,31 1,20 @@
<!-- SPDX-License-Identifier: CC-BY-4.0 -->
<!-- Copyright Contributors to the ODPi Egeria project. -->

![InDev](../../../images/egeria-content-status-in-development.png#pagewidth)
![TechPreview](../../../images/egeria-content-status-tech-preview.png#pagewidth)

# Asset Catalog Open Metadata Access Service (OMAS)

The Asset Catalog OMAS provides services to search for data assets including:
The Asset Catalog OMAS provides services to search for data assets.

* data stores
* event feeds
* APIs
* data sets

The search locates assets
based on the content of the Asset metadata itself and the metadata that links
to it. This includes:

* glossary terms
* schema elements
* assets
The search locates assets based on the content of the Asset metadata itself and the metadata that links
to it.

The Asset Catalog REST API supports:

* the retrieval of assets based on unique identifiers
* the retrieval of asset's relationships and classifications
* the retrieval of assets based on known classification or relationship
* to query for related assets and to retrieve an asset neighborhood
* to query for related assets
* the retrieval of assets based on their type

* [Documentation](https://egeria-project.org/services/omas/asset-catalog/overview)

Expand All @@ -43,12 32,13 @@ The module structure for the Asset Catalog OMAS is as follows:
[cohort](https://egeria-project.org/concepts/cohort-member).
* support for the access service's API and its related event management.
* [asset-catalog-spring](asset-catalog-spring) supports the REST API using the [Spring](../../../developer-resources/Spring.md) libraries.

* [asset-catalog-topic-connector](asset-catalog-topic-connector) supports asynchronous messaging through a connector
and connector provider class

### Search solution
The search will return Assets, Glossary Terms and Schema Elements that match the search criteria.
The search will return entities that match the search criteria.
As the asset search is to be performed against on one or more repositories a search engine will be used.
The search will be performed using the existing properties of the asset, glossary terms and/or schema elements.
The search will be performed using the existing properties of the entity.
Indexing will be performed by the Asset Catalog OMAS according to supported zones.
The search result will contain: guid, name (name or displayName), description, qualifiedName, classifications, zoneMembership (the basic properties of the element).

Expand All @@ -58,10 48,10 @@ This call is using the asset global identifier and the asset type.


![Figure 1: Search](docs/egeria-asset-search.png)
> Figure 1:Integration of search engine
> Figure 1: The integration of the search engine
###Other Services
Asset Catalog OMAS provides services to fetch the asset
### Other Services
Asset Catalog OMAS provides services to fetch the asset's:
* classifications
* relationships
* specific entities that connect two assets
Expand Down
Original file line number Diff line number Diff line change
@@ -1,19 1,17 @@
<!-- SPDX-License-Identifier: CC-BY-4.0 -->
<!-- Copyright Contributors to the ODPi Egeria project. -->

todo:
describe the rest model
body for search and basic model -pic

# The Asset Catalog OMAS Model

The Asset Catalog OMAS API provides the shared Java classes between the
server and client. It contains the following packages:
* api - interface and listener for interacting with asynchronous events
* exception - specific OMAS exceptions
* model - that describes the Java POJO's shared between modules.
Also, here can be found the beans for the REST endpoints.



Details about exceptions used in Asset Catalog can be found [here](../exception/README.md)

----
License: [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 9,10 @@
import org.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException;
import org.odpi.openmetadata.frameworks.connectors.ffdc.UserNotAuthorizedException;

/**
* AssetCatalogEventInterface is the interface that a client implements to
* register a listener to receive the events from the Asset Catalog OMAS's out topic.
*/
public interface AssetCatalogEventInterface {

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 8,7 @@

/**
* AssetCatalogEventListener is the interface that a client implements to
* register to receive the events from the Asset Catalog OMAS's out topic.
* process the received events from the Asset Catalog OMAS's out topic.
*/
public interface AssetCatalogEventListener {
/**
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 1,10 @@
/* SPDX-License-Identifier: Apache-2.0 */
/* Copyright Contributors to the ODPi Egeria project. */

/**
* The api package defines the Java interfaces supported by the Asset Catalog OMAS.
*
* These Java interfaces define the contract for interacting with asynchronous events passing through Asset Catalog
* OMAS' Out Topic.
*/
package org.odpi.openmetadata.accessservices.assetcatalog.api;
Original file line number Diff line number Diff line change
Expand Up @@ -26,27 26,45 @@
*/
public enum AssetCatalogErrorCode implements ExceptionMessageSet {

/**
* OMAS-ASSET-CATALOG-404-001 The error indicates that the open metadata repository services are not initialized
* for the mentioned server.
*/
OMRS_NOT_INITIALIZED(404, "OMAS-ASSET-CATALOG-404-001 ",
"The open metadata repository services are not initialized for server {0}",
"The system is unable to connect to the open metadata property server.",
"Check that the server initialized correctly. "
"Correct any errors discovered and retry the request when the open metadata services are available."),

/**
* OMAS-ASSET-CATALOG-404-011 The error indicates that the system is unable to retrieve the neighbourhood for the
* given asset.
*/
ASSET_NEIGHBORHOOD_NOT_FOUND(404, "OMAS-ASSET-CATALOG-404-011 ",
"There is no assets or relationships available in the neighbourhood of asset {0} in OMAS Server {1}",
"There are no assets or relationships available in the neighbourhood of asset {0} in OMAS Server {1}",
"The system is unable to retrieve the neighbourhood for the given asset.",
"Check that the unique identifier for the asset is correct."),

/**
* OMAS-ASSET-CATALOG-404-012 The error indicates that the system is unable to retrieve the assets neighborhood from
* the specified asset identifier.
*/
NO_ASSET_FROM_NEIGHBORHOOD_NOT_FOUND(404, "OMAS-ASSET-CATALOG-404-012 ",
"There is no assets available in the neighbourhood of asset {0} in OMAS Server {1}",
"The system is unable to retrieve the assets neighborhood from the specified asset identifier.",
"Check that the unique identifier for the asset is correct."),

/**
* OMAS-ASSET-CATALOG-404-017 The error indicates that the system is unable to retrieve assets of an unknown type/s.
*/
TYPE_DEF_NOT_FOUND(404, "OMAS-ASSET-CATALOG-404-017 ",
"The provided entity type {0} is non known to the OMAS Server",
"The system is unable to retrieve assets of an unknown type/s.",
"Check that the entity type/s provided is/are correct."),

/**
* OMAS-ASSET-CATALOG-503-001 The error indicates that the server has received a call to one of its open metadata
* access services but is unable to process it because the access service is not active for the requested server.
*/
SERVICE_NOT_INITIALIZED(503, "OMAS-ASSET-CATALOG-503-001 ",
"The access service has not been initialized for server {0} and can not support REST API calls",
"The server has received a call to one of its open metadata access services but is unable to "
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 10,8 @@
/**
* AssetCatalogException provides a checked exception for reporting errors found when using
* the Asset Catalog OMAS services.
* Typically these errors are either configuration or operational errors that can be fixed by an administrator
* or power AssetConsumerInterface. However, there may be the odd bug that surfaces here.
* Typically, these errors are either configuration or operational errors that can be fixed by an administrator
* or power AssetConsumerInterface. However, there may be the odd bug that surfaces here.
* The AssetCatalogErrorCode can be used with this exception to populate it with standard messages.
* The aim is to be able to uniquely identify the cause and remedy for the error.
*/
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 1,10 @@
/* SPDX-License-Identifier: Apache-2.0 */
/* Copyright Contributors to the ODPi Egeria project. */

/**
* The exception package is used to define first failure data capture (FFDC) for errors that occur when working
* with the Asset Catalog OMAS Services. It is used in conjunction with both Checked and Runtime (unchecked) exceptions.
*
* It also provides a checked exception for reporting errors found when using the Asset Catalog OMAS services.
*/
package org.odpi.openmetadata.accessservices.assetcatalog.exception;
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 17,9 @@
import static com.fasterxml.jackson.annotation.JsonAutoDetect.Visibility.PUBLIC_ONLY;

/**
* AssetCatalogBean object holds properties that are used for displaying details of an asset-catalog bean, plus the properties
* and classifications ans relationships.
* Also the connection to asset is available in this object.
* AssetCatalogBean object holds properties that are used for displaying details of an asset-catalog bean,
* plus the properties and classifications and relationships.
* Also, the connection to asset is available in this object.
*/
@JsonAutoDetect(getterVisibility = PUBLIC_ONLY, setterVisibility = PUBLIC_ONLY, fieldVisibility = NONE)
@JsonInclude(JsonInclude.Include.NON_NULL)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 29,16 @@
public class AssetCatalogEvent implements Serializable {

private static final long serialVersionUID = 1L;

/**
* The asset
* -- GETTER --
* Returns the structure of an asset
* @return the asset
* -- SETTER --
* Setup the structure of an asset
* @param asset the asset
*/
private Asset asset;

}
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 27,8 @@
@ToString
public class AssetCatalogItemElement extends Element {

private static final long serialVersionUID = 1L;

/**
* The context for an entity
* -- GETTER --
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,20 31,124 @@ public class Classification implements Serializable {

private static final long serialVersionUID = 1L;

/**
* The name of the classification
* -- GETTER --
* Return the classification's name
* @return the classification's name
* -- SETTER --
* Set up the name of the classification
* @param name the classification's name
*/
private String name;

/**
* The origin of the classification
* -- GETTER --
* Return the classification's origin
* @return the classification's origin
* -- SETTER --
* Set up the origin of the classification
* @param origin the classification's origin
*/
private String origin;

/**
* The origin unique identifier
* -- GETTER --
* Return the origin unique identifier
* @return the origin unique identifier
* -- SETTER --
* Set up the origin unique identifier
* @param originGUID the origin unique identifier
*/
private String originGUID;

/**
* The author of the classification
* -- GETTER --
* Return the author of the classification
* @return the author of the classification
* -- SETTER --
* Set up the author of the classification
* @param createdBy the author of the classification
*/
private String createdBy;

/**
* The creation date of the classification
* -- GETTER --
* Return the creation date of the classification
* @return the creation date of the classification
* -- SETTER --
* Set up the creation date of the classification
* @param createTime the creation date of the classification
*/
private Date createTime;

/**
* The author of the last update of the classification
* -- GETTER --
* Return the author of the last update of the classification
* @return the author of the last update of the classification
* -- SETTER --
* Set up the author of the last update of the classification
* @param updatedBy the author of the last update of the classification
*/
private String updatedBy;

/**
* The update date of the classification
* -- GETTER --
* Return the update date of the classification
* @return the update date of the classification
* -- SETTER --
* Set up the update date of the classification
* @param updateTime the update date of the classification
*/
private Date updateTime;

/**
* The version of the classification
* -- GETTER --
* Return the classification's version
* @return the classification's version
* -- SETTER --
* Set up the version of the classification
* @param version the classification's version
*/
private Long version;

/**
* The status of the classification
* -- GETTER --
* Return the classification's status
* @return the classification's status
* -- SETTER --
* Set up the status of the classification
* @param status the classification's status
*/
private String status;

/**
* The type of the classification
* -- GETTER --
* Return the classification's type
* @return the classification's type
* -- SETTER --
* Set up the type of the classification
* @param type the classification's type
*/
private Type type;

/**
* The properties of the classification
* -- GETTER --
* Return the classification's properties
* @return the classification's properties
* -- SETTER --
* Set up the properties of the classification
* @param properties the classification's properties
*/
private Map<String, String> properties;
}
Loading

0 comments on commit d986b09

Please sign in to comment.