Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add versionIdentifier and initial Digital Service OMAS APIs #6986

Merged
merged 5 commits into from
Oct 9, 2022

Conversation

mandy-chessell
Copy link
Contributor

Description

  • Some initial APIs for Digital Service OMAS are included
  • A new property for Asset called versionIdentifier was added to the open metadata types and the beans for it were updated to support it.

Related Issue(s)

#6526

Testing

FVT and open metadata labs

Release Notes & Documentation

New attribute has been added to the egeria-docs site both in the open metadata types description and the release notes.

Additional notes

Signed-off-by: Mandy Chessell <mandy.e.chessell@gmail.com>
Signed-off-by: Mandy Chessell <mandy.e.chessell@gmail.com>
Signed-off-by: Mandy Chessell <mandy.e.chessell@gmail.com>
Signed-off-by: Mandy Chessell <mandy.e.chessell@gmail.com>
assetExtendedProperties = new HashMap<>();
}

assetExtendedProperties.put(OpenMetadataAPIMapper.FILE_NAME_PROPERTY_NAME, this.getFileName(fullPath));

Check warning

Code scanning / CodeQL

Dereferenced variable may be null

Variable [assetExtendedProperties](1) may be null here as suggested by [this](2) null guard.
*
* @param elementHeader element header object
*/
public void setElementHeader(ElementHeader elementHeader)

Check notice

Code scanning / CodeQL

Missing Override annotation

This method overrides [MetadataElement.setElementHeader](1); it is advisable to add an Override annotation.
*
* @return element header object
*/
public ElementHeader getElementHeader()

Check notice

Code scanning / CodeQL

Missing Override annotation

This method overrides [MetadataElement.getElementHeader](1); it is advisable to add an Override annotation.
", owner='" + getOwner() + '\'' +
", ownerTypeName='" + getOwnerTypeName() + '\'' +
", ownerPropertyName='" + getOwnerPropertyName() + '\'' +
", ownerType=" + getOwnerType() +

Check notice

Code scanning / CodeQL

Deprecated method or constructor invocation

Invoking [AssetProperties.getOwnerType](1) should be avoided because it has been deprecated.
@mandy-chessell mandy-chessell merged commit a6beb7d into odpi:master Oct 9, 2022
return true;
}

return (typeNames.contains(OpenMetadataAPIMapper.INCIDENT_REPORT_TYPE_NAME));
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

UnnecessaryParentheses: These grouping parentheses are unnecessary; it is unlikely the code will be misinterpreted without them


Suggested change
return (typeNames.contains(OpenMetadataAPIMapper.INCIDENT_REPORT_TYPE_NAME));
return typeNames.contains(OpenMetadataAPIMapper.INCIDENT_REPORT_TYPE_NAME);

ℹ️ Learn about @sonatype-lift commands

You can reply with the following commands. For example, reply with @sonatype-lift ignoreall to leave out all findings.

Command Usage
@sonatype-lift ignore Leave out the above finding from this PR
@sonatype-lift ignoreall Leave out all the existing findings from this PR
@sonatype-lift exclude <file|issue|path|tool> Exclude specified file|issue|path|tool from Lift findings by updating your config.toml file

Note: When talking to LiftBot, you need to refresh the page to see its response.
Click here to add LiftBot to another repo.


Was this a good recommendation?
[ 🙁 Not relevant ] - [ 😕 Won't fix ] - [ 😑 Not critical, will fix ] - [ 🙂 Critical, will fix ] - [ 😊 Critical, fixing now ]

{
File file = new File(dataFile.getDataFileProperties().getQualifiedName());
File file = new File(dataFile.getDataFileProperties().getPathName());
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PATH_TRAVERSAL_IN: This API (java/io/File.(Ljava/lang/String;)V) reads a file whose location might be specified by user input


ℹ️ Learn about @sonatype-lift commands

You can reply with the following commands. For example, reply with @sonatype-lift ignoreall to leave out all findings.

Command Usage
@sonatype-lift ignore Leave out the above finding from this PR
@sonatype-lift ignoreall Leave out all the existing findings from this PR
@sonatype-lift exclude <file|issue|path|tool> Exclude specified file|issue|path|tool from Lift findings by updating your config.toml file

Note: When talking to LiftBot, you need to refresh the page to see its response.
Click here to add LiftBot to another repo.


Was this a good recommendation?
[ 🙁 Not relevant ] - [ 😕 Won't fix ] - [ 😑 Not critical, will fix ] - [ 🙂 Critical, will fix ] - [ 😊 Critical, fixing now ]

assetExtendedProperties = new HashMap<>();
}

assetExtendedProperties.put(OpenMetadataAPIMapper.FILE_NAME_PROPERTY_NAME, this.getFileName(fullPath));
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

NULL_DEREFERENCE: object assetExtendedProperties last assigned on line 2531 could be null and is dereferenced at line 2548.


ℹ️ Learn about @sonatype-lift commands

You can reply with the following commands. For example, reply with @sonatype-lift ignoreall to leave out all findings.

Command Usage
@sonatype-lift ignore Leave out the above finding from this PR
@sonatype-lift ignoreall Leave out all the existing findings from this PR
@sonatype-lift exclude <file|issue|path|tool> Exclude specified file|issue|path|tool from Lift findings by updating your config.toml file

Note: When talking to LiftBot, you need to refresh the page to see its response.
Click here to add LiftBot to another repo.


Was this a good recommendation?
[ 🙁 Not relevant ] - [ 😕 Won't fix ] - [ 😑 Not critical, will fix ] - [ 🙂 Critical, will fix ] - [ 😊 Critical, fixing now ]

{
List<String> typeNames = new ArrayList<>();

typeNames.add(entityHeader.getType().getTypeDefName());
typeNames.add(instanceHeader.getType().getTypeDefName());
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

NULL_DEREFERENCE: object returned by instanceHeader.getType() could be null and is dereferenced at line 838.


ℹ️ Learn about @sonatype-lift commands

You can reply with the following commands. For example, reply with @sonatype-lift ignoreall to leave out all findings.

Command Usage
@sonatype-lift ignore Leave out the above finding from this PR
@sonatype-lift ignoreall Leave out all the existing findings from this PR
@sonatype-lift exclude <file|issue|path|tool> Exclude specified file|issue|path|tool from Lift findings by updating your config.toml file

Note: When talking to LiftBot, you need to refresh the page to see its response.
Click here to add LiftBot to another repo.


Was this a good recommendation?
[ 🙁 Not relevant ] - [ 😕 Won't fix ] - [ 😑 Not critical, will fix ] - [ 🙂 Critical, will fix ] - [ 😊 Critical, fixing now ]

{
return false;
}
if (modifiedTime != null ? ! modifiedTime.equals(that.modifiedTime) : that.modifiedTime != null)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💬 5 similar findings have been found in this PR


JavaUtilDate: Date has a bad API that leads to bugs; prefer java.time.Instant or LocalDate.


🔎 Expand here to view all instances of this finding
File Path Line Number
open-metadata-implementation/access-services/data-manager/data-manager-api/src/main/java/org/odpi/openmetadata/accessservices/datamanager/properties/DataStoreProperties.java 308
open-metadata-implementation/access-services/data-manager/data-manager-api/src/main/java/org/odpi/openmetadata/accessservices/datamanager/properties/ReportProperties.java 265
open-metadata-implementation/access-services/data-manager/data-manager-api/src/main/java/org/odpi/openmetadata/accessservices/datamanager/properties/ReportProperties.java 261
open-metadata-implementation/access-services/community-profile/community-profile-api/src/main/java/org/odpi/openmetadata/accessservices/communityprofile/properties/AssetProperties.java 246
open-metadata-implementation/access-services/community-profile/community-profile-api/src/main/java/org/odpi/openmetadata/accessservices/communityprofile/properties/AssetProperties.java 250

Visit the Lift Web Console to find more details in your report.


ℹ️ Learn about @sonatype-lift commands

You can reply with the following commands. For example, reply with @sonatype-lift ignoreall to leave out all findings.

Command Usage
@sonatype-lift ignore Leave out the above finding from this PR
@sonatype-lift ignoreall Leave out all the existing findings from this PR
@sonatype-lift exclude <file|issue|path|tool> Exclude specified file|issue|path|tool from Lift findings by updating your config.toml file

Note: When talking to LiftBot, you need to refresh the page to see its response.
Click here to add LiftBot to another repo.


Was this a good recommendation?
[ 🙁 Not relevant ] - [ 😕 Won't fix ] - [ 😑 Not critical, will fix ] - [ 🙂 Critical, will fix ] - [ 😊 Critical, fixing now ]

{
return false;
}
if (createTime != null ? ! createTime.equals(that.createTime) : that.createTime != null)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💬 11 similar findings have been found in this PR


UndefinedEquals: Date does not have well-defined equals behavior.


🔎 Expand here to view all instances of this finding
File Path Line Number
open-metadata-implementation/access-services/data-manager/data-manager-api/src/main/java/org/odpi/openmetadata/accessservices/datamanager/properties/ReportProperties.java 265
open-metadata-implementation/access-services/community-profile/community-profile-api/src/main/java/org/odpi/openmetadata/accessservices/communityprofile/properties/AssetProperties.java 250
open-metadata-implementation/access-services/community-profile/community-profile-api/src/main/java/org/odpi/openmetadata/accessservices/communityprofile/properties/AssetProperties.java 246
open-metadata-implementation/access-services/stewardship-action/stewardship-action-api/src/main/java/org/odpi/openmetadata/accessservices/stewardshipaction/properties/ClassificationProperties.java 175
open-metadata-implementation/access-services/stewardship-action/stewardship-action-api/src/main/java/org/odpi/openmetadata/accessservices/stewardshipaction/properties/ReferenceableProperties.java 274
open-metadata-implementation/access-services/stewardship-action/stewardship-action-api/src/main/java/org/odpi/openmetadata/accessservices/stewardshipaction/properties/ClassificationProperties.java 174
open-metadata-implementation/access-services/stewardship-action/stewardship-action-api/src/main/java/org/odpi/openmetadata/accessservices/stewardshipaction/properties/ReferenceableProperties.java 275
open-metadata-implementation/access-services/stewardship-action/stewardship-action-api/src/main/java/org/odpi/openmetadata/accessservices/stewardshipaction/properties/RelationshipProperties.java 176
open-metadata-implementation/access-services/data-manager/data-manager-api/src/main/java/org/odpi/openmetadata/accessservices/datamanager/properties/ReportProperties.java 261
open-metadata-implementation/access-services/stewardship-action/stewardship-action-api/src/main/java/org/odpi/openmetadata/accessservices/stewardshipaction/properties/RelationshipProperties.java 175

Showing 10 of 11 findings. Visit the Lift Web Console to see all.


ℹ️ Learn about @sonatype-lift commands

You can reply with the following commands. For example, reply with @sonatype-lift ignoreall to leave out all findings.

Command Usage
@sonatype-lift ignore Leave out the above finding from this PR
@sonatype-lift ignoreall Leave out all the existing findings from this PR
@sonatype-lift exclude <file|issue|path|tool> Exclude specified file|issue|path|tool from Lift findings by updating your config.toml file

Note: When talking to LiftBot, you need to refresh the page to see its response.
Click here to add LiftBot to another repo.


Was this a good recommendation?
[ 🙁 Not relevant ] - [ 😕 Won't fix ] - [ 😑 Not critical, will fix ] - [ 🙂 Critical, will fix ] - [ 😊 Critical, fixing now ]

@sonatype-lift
Copy link
Contributor

sonatype-lift bot commented Oct 9, 2022

⚠️ 107 God Classes were detected by Lift in this project. Visit the Lift web console for more details.

@planetf1 planetf1 mentioned this pull request Nov 2, 2022
31 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant