From 7a49d63e7318436ad652bf73475efd9018d83eeb Mon Sep 17 00:00:00 2001 From: "gcf-owl-bot[bot]" <78513119+gcf-owl-bot[bot]@users.noreply.github.com> Date: Mon, 27 Nov 2023 17:24:43 -0500 Subject: [PATCH] feat: [dataplex] added DataQualityResult.score, dimension_score, column_score (#10064) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * feat: added DataQualityResult.score, dimension_score, column_score feat: new event types GOVERNANCE_RULE_MATCHED_RESOURCES, GOVERNANCE_RULE_SEARCH_LIMIT_EXCEEDS, GOVERNANCE_RULE_ERRORS chore: updated service and timeout settings PiperOrigin-RevId: 583444130 Source-Link: https://github.com/googleapis/googleapis/commit/2f91fd52dee784043e4acda6d007b4c36128c662 Source-Link: https://github.com/googleapis/googleapis-gen/commit/84ec5be98819f2b7e4b8bbacade268ef500bf7f0 Copy-Tag: eyJwIjoiamF2YS1kYXRhcGxleC8uT3dsQm90LnlhbWwiLCJoIjoiODRlYzViZTk4ODE5ZjJiN2U0YjhiYmFjYWRlMjY4ZWY1MDBiZjdmMCJ9 * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md --------- Co-authored-by: Owl Bot --- java-dataplex/README.md | 2 +- .../cloud/dataplex/v1/DataScanEvent.java | 1157 +++++++++++++++-- .../cloud/dataplex/v1/GovernanceEvent.java | 66 + .../google/cloud/dataplex/v1/LogsProto.java | 203 +-- .../proto/google/cloud/dataplex/v1/logs.proto | 31 + 5 files changed, 1297 insertions(+), 162 deletions(-) diff --git a/java-dataplex/README.md b/java-dataplex/README.md index 266ac5264ff7..06ffd8a18f1c 100644 --- a/java-dataplex/README.md +++ b/java-dataplex/README.md @@ -20,7 +20,7 @@ If you are using Maven with [BOM][libraries-bom], add this to your pom.xml file: com.google.cloud libraries-bom - 26.26.0 + 26.27.0 pom import diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScanEvent.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScanEvent.java index a1342dfe80cd..265bac33a87e 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScanEvent.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScanEvent.java @@ -1410,6 +1410,180 @@ public interface DataQualityResultOrBuilder * map<string, bool> dimension_passed = 3; */ boolean getDimensionPassedOrThrow(java.lang.String key); + + /** + * + * + *
+     * The table-level data quality score for the data scan job.
+     *
+     * The data quality score ranges between [0, 100] (up to two decimal
+     * points).
+     * 
+ * + * float score = 4; + * + * @return The score. + */ + float getScore(); + + /** + * + * + *
+     * The score of each dimension for data quality result.
+     * The key of the map is the name of the dimension.
+     * The value is the data quality score for the dimension.
+     *
+     * The score ranges between [0, 100] (up to two decimal
+     * points).
+     * 
+ * + * map<string, float> dimension_score = 5; + */ + int getDimensionScoreCount(); + /** + * + * + *
+     * The score of each dimension for data quality result.
+     * The key of the map is the name of the dimension.
+     * The value is the data quality score for the dimension.
+     *
+     * The score ranges between [0, 100] (up to two decimal
+     * points).
+     * 
+ * + * map<string, float> dimension_score = 5; + */ + boolean containsDimensionScore(java.lang.String key); + /** Use {@link #getDimensionScoreMap()} instead. */ + @java.lang.Deprecated + java.util.Map getDimensionScore(); + /** + * + * + *
+     * The score of each dimension for data quality result.
+     * The key of the map is the name of the dimension.
+     * The value is the data quality score for the dimension.
+     *
+     * The score ranges between [0, 100] (up to two decimal
+     * points).
+     * 
+ * + * map<string, float> dimension_score = 5; + */ + java.util.Map getDimensionScoreMap(); + /** + * + * + *
+     * The score of each dimension for data quality result.
+     * The key of the map is the name of the dimension.
+     * The value is the data quality score for the dimension.
+     *
+     * The score ranges between [0, 100] (up to two decimal
+     * points).
+     * 
+ * + * map<string, float> dimension_score = 5; + */ + float getDimensionScoreOrDefault(java.lang.String key, float defaultValue); + /** + * + * + *
+     * The score of each dimension for data quality result.
+     * The key of the map is the name of the dimension.
+     * The value is the data quality score for the dimension.
+     *
+     * The score ranges between [0, 100] (up to two decimal
+     * points).
+     * 
+ * + * map<string, float> dimension_score = 5; + */ + float getDimensionScoreOrThrow(java.lang.String key); + + /** + * + * + *
+     * The score of each column scanned in the data scan job.
+     * The key of the map is the name of the column.
+     * The value is the data quality score for the column.
+     *
+     * The score ranges between [0, 100] (up to two decimal
+     * points).
+     * 
+ * + * map<string, float> column_score = 6; + */ + int getColumnScoreCount(); + /** + * + * + *
+     * The score of each column scanned in the data scan job.
+     * The key of the map is the name of the column.
+     * The value is the data quality score for the column.
+     *
+     * The score ranges between [0, 100] (up to two decimal
+     * points).
+     * 
+ * + * map<string, float> column_score = 6; + */ + boolean containsColumnScore(java.lang.String key); + /** Use {@link #getColumnScoreMap()} instead. */ + @java.lang.Deprecated + java.util.Map getColumnScore(); + /** + * + * + *
+     * The score of each column scanned in the data scan job.
+     * The key of the map is the name of the column.
+     * The value is the data quality score for the column.
+     *
+     * The score ranges between [0, 100] (up to two decimal
+     * points).
+     * 
+ * + * map<string, float> column_score = 6; + */ + java.util.Map getColumnScoreMap(); + /** + * + * + *
+     * The score of each column scanned in the data scan job.
+     * The key of the map is the name of the column.
+     * The value is the data quality score for the column.
+     *
+     * The score ranges between [0, 100] (up to two decimal
+     * points).
+     * 
+ * + * map<string, float> column_score = 6; + */ + float getColumnScoreOrDefault(java.lang.String key, float defaultValue); + /** + * + * + *
+     * The score of each column scanned in the data scan job.
+     * The key of the map is the name of the column.
+     * The value is the data quality score for the column.
+     *
+     * The score ranges between [0, 100] (up to two decimal
+     * points).
+     * 
+ * + * map<string, float> column_score = 6; + */ + float getColumnScoreOrThrow(java.lang.String key); } /** * @@ -1449,6 +1623,10 @@ protected com.google.protobuf.MapField internalGetMapField(int number) { switch (number) { case 3: return internalGetDimensionPassed(); + case 5: + return internalGetDimensionScore(); + case 6: + return internalGetColumnScore(); default: throw new RuntimeException("Invalid map field number: " + number); } @@ -1615,105 +1793,412 @@ public boolean getDimensionPassedOrThrow(java.lang.String key) { return map.get(key); } - private byte memoizedIsInitialized = -1; - + public static final int SCORE_FIELD_NUMBER = 4; + private float score_ = 0F; + /** + * + * + *
+     * The table-level data quality score for the data scan job.
+     *
+     * The data quality score ranges between [0, 100] (up to two decimal
+     * points).
+     * 
+ * + * float score = 4; + * + * @return The score. + */ @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; + public float getScore() { + return score_; } - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (rowCount_ != 0L) { - output.writeInt64(1, rowCount_); - } - if (passed_ != false) { - output.writeBool(2, passed_); - } - com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( - output, internalGetDimensionPassed(), DimensionPassedDefaultEntryHolder.defaultEntry, 3); - getUnknownFields().writeTo(output); + public static final int DIMENSION_SCORE_FIELD_NUMBER = 5; + + private static final class DimensionScoreDefaultEntryHolder { + static final com.google.protobuf.MapEntry defaultEntry = + com.google.protobuf.MapEntry.newDefaultInstance( + com.google.cloud.dataplex.v1.LogsProto + .internal_static_google_cloud_dataplex_v1_DataScanEvent_DataQualityResult_DimensionScoreEntry_descriptor, + com.google.protobuf.WireFormat.FieldType.STRING, + "", + com.google.protobuf.WireFormat.FieldType.FLOAT, + 0F); } - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; + @SuppressWarnings("serial") + private com.google.protobuf.MapField dimensionScore_; - size = 0; - if (rowCount_ != 0L) { - size += com.google.protobuf.CodedOutputStream.computeInt64Size(1, rowCount_); - } - if (passed_ != false) { - size += com.google.protobuf.CodedOutputStream.computeBoolSize(2, passed_); - } - for (java.util.Map.Entry entry : - internalGetDimensionPassed().getMap().entrySet()) { - com.google.protobuf.MapEntry dimensionPassed__ = - DimensionPassedDefaultEntryHolder.defaultEntry - .newBuilderForType() - .setKey(entry.getKey()) - .setValue(entry.getValue()) - .build(); - size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, dimensionPassed__); + private com.google.protobuf.MapField + internalGetDimensionScore() { + if (dimensionScore_ == null) { + return com.google.protobuf.MapField.emptyMapField( + DimensionScoreDefaultEntryHolder.defaultEntry); } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; + return dimensionScore_; } + public int getDimensionScoreCount() { + return internalGetDimensionScore().getMap().size(); + } + /** + * + * + *
+     * The score of each dimension for data quality result.
+     * The key of the map is the name of the dimension.
+     * The value is the data quality score for the dimension.
+     *
+     * The score ranges between [0, 100] (up to two decimal
+     * points).
+     * 
+ * + * map<string, float> dimension_score = 5; + */ @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; + public boolean containsDimensionScore(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); } - if (!(obj instanceof com.google.cloud.dataplex.v1.DataScanEvent.DataQualityResult)) { - return super.equals(obj); + return internalGetDimensionScore().getMap().containsKey(key); + } + /** Use {@link #getDimensionScoreMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map getDimensionScore() { + return getDimensionScoreMap(); + } + /** + * + * + *
+     * The score of each dimension for data quality result.
+     * The key of the map is the name of the dimension.
+     * The value is the data quality score for the dimension.
+     *
+     * The score ranges between [0, 100] (up to two decimal
+     * points).
+     * 
+ * + * map<string, float> dimension_score = 5; + */ + @java.lang.Override + public java.util.Map getDimensionScoreMap() { + return internalGetDimensionScore().getMap(); + } + /** + * + * + *
+     * The score of each dimension for data quality result.
+     * The key of the map is the name of the dimension.
+     * The value is the data quality score for the dimension.
+     *
+     * The score ranges between [0, 100] (up to two decimal
+     * points).
+     * 
+ * + * map<string, float> dimension_score = 5; + */ + @java.lang.Override + public float getDimensionScoreOrDefault(java.lang.String key, float defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); } - com.google.cloud.dataplex.v1.DataScanEvent.DataQualityResult other = - (com.google.cloud.dataplex.v1.DataScanEvent.DataQualityResult) obj; - - if (getRowCount() != other.getRowCount()) return false; - if (getPassed() != other.getPassed()) return false; - if (!internalGetDimensionPassed().equals(other.internalGetDimensionPassed())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; + java.util.Map map = internalGetDimensionScore().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; } - + /** + * + * + *
+     * The score of each dimension for data quality result.
+     * The key of the map is the name of the dimension.
+     * The value is the data quality score for the dimension.
+     *
+     * The score ranges between [0, 100] (up to two decimal
+     * points).
+     * 
+ * + * map<string, float> dimension_score = 5; + */ @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; + public float getDimensionScoreOrThrow(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + ROW_COUNT_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getRowCount()); - hash = (37 * hash) + PASSED_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getPassed()); - if (!internalGetDimensionPassed().getMap().isEmpty()) { - hash = (37 * hash) + DIMENSION_PASSED_FIELD_NUMBER; - hash = (53 * hash) + internalGetDimensionPassed().hashCode(); + java.util.Map map = internalGetDimensionScore().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; + return map.get(key); } - public static com.google.cloud.dataplex.v1.DataScanEvent.DataQualityResult parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); + public static final int COLUMN_SCORE_FIELD_NUMBER = 6; + + private static final class ColumnScoreDefaultEntryHolder { + static final com.google.protobuf.MapEntry defaultEntry = + com.google.protobuf.MapEntry.newDefaultInstance( + com.google.cloud.dataplex.v1.LogsProto + .internal_static_google_cloud_dataplex_v1_DataScanEvent_DataQualityResult_ColumnScoreEntry_descriptor, + com.google.protobuf.WireFormat.FieldType.STRING, + "", + com.google.protobuf.WireFormat.FieldType.FLOAT, + 0F); } - public static com.google.cloud.dataplex.v1.DataScanEvent.DataQualityResult parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); + @SuppressWarnings("serial") + private com.google.protobuf.MapField columnScore_; + + private com.google.protobuf.MapField + internalGetColumnScore() { + if (columnScore_ == null) { + return com.google.protobuf.MapField.emptyMapField( + ColumnScoreDefaultEntryHolder.defaultEntry); + } + return columnScore_; + } + + public int getColumnScoreCount() { + return internalGetColumnScore().getMap().size(); + } + /** + * + * + *
+     * The score of each column scanned in the data scan job.
+     * The key of the map is the name of the column.
+     * The value is the data quality score for the column.
+     *
+     * The score ranges between [0, 100] (up to two decimal
+     * points).
+     * 
+ * + * map<string, float> column_score = 6; + */ + @java.lang.Override + public boolean containsColumnScore(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + return internalGetColumnScore().getMap().containsKey(key); + } + /** Use {@link #getColumnScoreMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map getColumnScore() { + return getColumnScoreMap(); + } + /** + * + * + *
+     * The score of each column scanned in the data scan job.
+     * The key of the map is the name of the column.
+     * The value is the data quality score for the column.
+     *
+     * The score ranges between [0, 100] (up to two decimal
+     * points).
+     * 
+ * + * map<string, float> column_score = 6; + */ + @java.lang.Override + public java.util.Map getColumnScoreMap() { + return internalGetColumnScore().getMap(); + } + /** + * + * + *
+     * The score of each column scanned in the data scan job.
+     * The key of the map is the name of the column.
+     * The value is the data quality score for the column.
+     *
+     * The score ranges between [0, 100] (up to two decimal
+     * points).
+     * 
+ * + * map<string, float> column_score = 6; + */ + @java.lang.Override + public float getColumnScoreOrDefault(java.lang.String key, float defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetColumnScore().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + /** + * + * + *
+     * The score of each column scanned in the data scan job.
+     * The key of the map is the name of the column.
+     * The value is the data quality score for the column.
+     *
+     * The score ranges between [0, 100] (up to two decimal
+     * points).
+     * 
+ * + * map<string, float> column_score = 6; + */ + @java.lang.Override + public float getColumnScoreOrThrow(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetColumnScore().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (rowCount_ != 0L) { + output.writeInt64(1, rowCount_); + } + if (passed_ != false) { + output.writeBool(2, passed_); + } + com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( + output, internalGetDimensionPassed(), DimensionPassedDefaultEntryHolder.defaultEntry, 3); + if (java.lang.Float.floatToRawIntBits(score_) != 0) { + output.writeFloat(4, score_); + } + com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( + output, internalGetDimensionScore(), DimensionScoreDefaultEntryHolder.defaultEntry, 5); + com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( + output, internalGetColumnScore(), ColumnScoreDefaultEntryHolder.defaultEntry, 6); + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (rowCount_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(1, rowCount_); + } + if (passed_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(2, passed_); + } + for (java.util.Map.Entry entry : + internalGetDimensionPassed().getMap().entrySet()) { + com.google.protobuf.MapEntry dimensionPassed__ = + DimensionPassedDefaultEntryHolder.defaultEntry + .newBuilderForType() + .setKey(entry.getKey()) + .setValue(entry.getValue()) + .build(); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, dimensionPassed__); + } + if (java.lang.Float.floatToRawIntBits(score_) != 0) { + size += com.google.protobuf.CodedOutputStream.computeFloatSize(4, score_); + } + for (java.util.Map.Entry entry : + internalGetDimensionScore().getMap().entrySet()) { + com.google.protobuf.MapEntry dimensionScore__ = + DimensionScoreDefaultEntryHolder.defaultEntry + .newBuilderForType() + .setKey(entry.getKey()) + .setValue(entry.getValue()) + .build(); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, dimensionScore__); + } + for (java.util.Map.Entry entry : + internalGetColumnScore().getMap().entrySet()) { + com.google.protobuf.MapEntry columnScore__ = + ColumnScoreDefaultEntryHolder.defaultEntry + .newBuilderForType() + .setKey(entry.getKey()) + .setValue(entry.getValue()) + .build(); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, columnScore__); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.dataplex.v1.DataScanEvent.DataQualityResult)) { + return super.equals(obj); + } + com.google.cloud.dataplex.v1.DataScanEvent.DataQualityResult other = + (com.google.cloud.dataplex.v1.DataScanEvent.DataQualityResult) obj; + + if (getRowCount() != other.getRowCount()) return false; + if (getPassed() != other.getPassed()) return false; + if (!internalGetDimensionPassed().equals(other.internalGetDimensionPassed())) return false; + if (java.lang.Float.floatToIntBits(getScore()) + != java.lang.Float.floatToIntBits(other.getScore())) return false; + if (!internalGetDimensionScore().equals(other.internalGetDimensionScore())) return false; + if (!internalGetColumnScore().equals(other.internalGetColumnScore())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + ROW_COUNT_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getRowCount()); + hash = (37 * hash) + PASSED_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getPassed()); + if (!internalGetDimensionPassed().getMap().isEmpty()) { + hash = (37 * hash) + DIMENSION_PASSED_FIELD_NUMBER; + hash = (53 * hash) + internalGetDimensionPassed().hashCode(); + } + hash = (37 * hash) + SCORE_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits(getScore()); + if (!internalGetDimensionScore().getMap().isEmpty()) { + hash = (37 * hash) + DIMENSION_SCORE_FIELD_NUMBER; + hash = (53 * hash) + internalGetDimensionScore().hashCode(); + } + if (!internalGetColumnScore().getMap().isEmpty()) { + hash = (37 * hash) + COLUMN_SCORE_FIELD_NUMBER; + hash = (53 * hash) + internalGetColumnScore().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dataplex.v1.DataScanEvent.DataQualityResult parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.DataScanEvent.DataQualityResult parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.dataplex.v1.DataScanEvent.DataQualityResult parseFrom( @@ -1826,6 +2311,10 @@ protected com.google.protobuf.MapField internalGetMapField(int number) { switch (number) { case 3: return internalGetDimensionPassed(); + case 5: + return internalGetDimensionScore(); + case 6: + return internalGetColumnScore(); default: throw new RuntimeException("Invalid map field number: " + number); } @@ -1836,6 +2325,10 @@ protected com.google.protobuf.MapField internalGetMutableMapField(int number) { switch (number) { case 3: return internalGetMutableDimensionPassed(); + case 5: + return internalGetMutableDimensionScore(); + case 6: + return internalGetMutableColumnScore(); default: throw new RuntimeException("Invalid map field number: " + number); } @@ -1865,6 +2358,9 @@ public Builder clear() { rowCount_ = 0L; passed_ = false; internalGetMutableDimensionPassed().clear(); + score_ = 0F; + internalGetMutableDimensionScore().clear(); + internalGetMutableColumnScore().clear(); return this; } @@ -1913,6 +2409,17 @@ private void buildPartial0( result.dimensionPassed_ = internalGetDimensionPassed(); result.dimensionPassed_.makeImmutable(); } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.score_ = score_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.dimensionScore_ = internalGetDimensionScore(); + result.dimensionScore_.makeImmutable(); + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.columnScore_ = internalGetColumnScore(); + result.columnScore_.makeImmutable(); + } } @java.lang.Override @@ -1972,6 +2479,13 @@ public Builder mergeFrom(com.google.cloud.dataplex.v1.DataScanEvent.DataQualityR } internalGetMutableDimensionPassed().mergeFrom(other.internalGetDimensionPassed()); bitField0_ |= 0x00000004; + if (other.getScore() != 0F) { + setScore(other.getScore()); + } + internalGetMutableDimensionScore().mergeFrom(other.internalGetDimensionScore()); + bitField0_ |= 0x00000010; + internalGetMutableColumnScore().mergeFrom(other.internalGetColumnScore()); + bitField0_ |= 0x00000020; this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -2023,6 +2537,36 @@ public Builder mergeFrom( bitField0_ |= 0x00000004; break; } // case 26 + case 37: + { + score_ = input.readFloat(); + bitField0_ |= 0x00000008; + break; + } // case 37 + case 42: + { + com.google.protobuf.MapEntry dimensionScore__ = + input.readMessage( + DimensionScoreDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + internalGetMutableDimensionScore() + .getMutableMap() + .put(dimensionScore__.getKey(), dimensionScore__.getValue()); + bitField0_ |= 0x00000010; + break; + } // case 42 + case 50: + { + com.google.protobuf.MapEntry columnScore__ = + input.readMessage( + ColumnScoreDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + internalGetMutableColumnScore() + .getMutableMap() + .put(columnScore__.getKey(), columnScore__.getValue()); + bitField0_ |= 0x00000020; + break; + } // case 50 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -2334,6 +2878,461 @@ public Builder putAllDimensionPassed( return this; } + private float score_; + /** + * + * + *
+       * The table-level data quality score for the data scan job.
+       *
+       * The data quality score ranges between [0, 100] (up to two decimal
+       * points).
+       * 
+ * + * float score = 4; + * + * @return The score. + */ + @java.lang.Override + public float getScore() { + return score_; + } + /** + * + * + *
+       * The table-level data quality score for the data scan job.
+       *
+       * The data quality score ranges between [0, 100] (up to two decimal
+       * points).
+       * 
+ * + * float score = 4; + * + * @param value The score to set. + * @return This builder for chaining. + */ + public Builder setScore(float value) { + + score_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + /** + * + * + *
+       * The table-level data quality score for the data scan job.
+       *
+       * The data quality score ranges between [0, 100] (up to two decimal
+       * points).
+       * 
+ * + * float score = 4; + * + * @return This builder for chaining. + */ + public Builder clearScore() { + bitField0_ = (bitField0_ & ~0x00000008); + score_ = 0F; + onChanged(); + return this; + } + + private com.google.protobuf.MapField dimensionScore_; + + private com.google.protobuf.MapField + internalGetDimensionScore() { + if (dimensionScore_ == null) { + return com.google.protobuf.MapField.emptyMapField( + DimensionScoreDefaultEntryHolder.defaultEntry); + } + return dimensionScore_; + } + + private com.google.protobuf.MapField + internalGetMutableDimensionScore() { + if (dimensionScore_ == null) { + dimensionScore_ = + com.google.protobuf.MapField.newMapField( + DimensionScoreDefaultEntryHolder.defaultEntry); + } + if (!dimensionScore_.isMutable()) { + dimensionScore_ = dimensionScore_.copy(); + } + bitField0_ |= 0x00000010; + onChanged(); + return dimensionScore_; + } + + public int getDimensionScoreCount() { + return internalGetDimensionScore().getMap().size(); + } + /** + * + * + *
+       * The score of each dimension for data quality result.
+       * The key of the map is the name of the dimension.
+       * The value is the data quality score for the dimension.
+       *
+       * The score ranges between [0, 100] (up to two decimal
+       * points).
+       * 
+ * + * map<string, float> dimension_score = 5; + */ + @java.lang.Override + public boolean containsDimensionScore(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + return internalGetDimensionScore().getMap().containsKey(key); + } + /** Use {@link #getDimensionScoreMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map getDimensionScore() { + return getDimensionScoreMap(); + } + /** + * + * + *
+       * The score of each dimension for data quality result.
+       * The key of the map is the name of the dimension.
+       * The value is the data quality score for the dimension.
+       *
+       * The score ranges between [0, 100] (up to two decimal
+       * points).
+       * 
+ * + * map<string, float> dimension_score = 5; + */ + @java.lang.Override + public java.util.Map getDimensionScoreMap() { + return internalGetDimensionScore().getMap(); + } + /** + * + * + *
+       * The score of each dimension for data quality result.
+       * The key of the map is the name of the dimension.
+       * The value is the data quality score for the dimension.
+       *
+       * The score ranges between [0, 100] (up to two decimal
+       * points).
+       * 
+ * + * map<string, float> dimension_score = 5; + */ + @java.lang.Override + public float getDimensionScoreOrDefault(java.lang.String key, float defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetDimensionScore().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + /** + * + * + *
+       * The score of each dimension for data quality result.
+       * The key of the map is the name of the dimension.
+       * The value is the data quality score for the dimension.
+       *
+       * The score ranges between [0, 100] (up to two decimal
+       * points).
+       * 
+ * + * map<string, float> dimension_score = 5; + */ + @java.lang.Override + public float getDimensionScoreOrThrow(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetDimensionScore().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + public Builder clearDimensionScore() { + bitField0_ = (bitField0_ & ~0x00000010); + internalGetMutableDimensionScore().getMutableMap().clear(); + return this; + } + /** + * + * + *
+       * The score of each dimension for data quality result.
+       * The key of the map is the name of the dimension.
+       * The value is the data quality score for the dimension.
+       *
+       * The score ranges between [0, 100] (up to two decimal
+       * points).
+       * 
+ * + * map<string, float> dimension_score = 5; + */ + public Builder removeDimensionScore(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + internalGetMutableDimensionScore().getMutableMap().remove(key); + return this; + } + /** Use alternate mutation accessors instead. */ + @java.lang.Deprecated + public java.util.Map getMutableDimensionScore() { + bitField0_ |= 0x00000010; + return internalGetMutableDimensionScore().getMutableMap(); + } + /** + * + * + *
+       * The score of each dimension for data quality result.
+       * The key of the map is the name of the dimension.
+       * The value is the data quality score for the dimension.
+       *
+       * The score ranges between [0, 100] (up to two decimal
+       * points).
+       * 
+ * + * map<string, float> dimension_score = 5; + */ + public Builder putDimensionScore(java.lang.String key, float value) { + if (key == null) { + throw new NullPointerException("map key"); + } + + internalGetMutableDimensionScore().getMutableMap().put(key, value); + bitField0_ |= 0x00000010; + return this; + } + /** + * + * + *
+       * The score of each dimension for data quality result.
+       * The key of the map is the name of the dimension.
+       * The value is the data quality score for the dimension.
+       *
+       * The score ranges between [0, 100] (up to two decimal
+       * points).
+       * 
+ * + * map<string, float> dimension_score = 5; + */ + public Builder putAllDimensionScore(java.util.Map values) { + internalGetMutableDimensionScore().getMutableMap().putAll(values); + bitField0_ |= 0x00000010; + return this; + } + + private com.google.protobuf.MapField columnScore_; + + private com.google.protobuf.MapField + internalGetColumnScore() { + if (columnScore_ == null) { + return com.google.protobuf.MapField.emptyMapField( + ColumnScoreDefaultEntryHolder.defaultEntry); + } + return columnScore_; + } + + private com.google.protobuf.MapField + internalGetMutableColumnScore() { + if (columnScore_ == null) { + columnScore_ = + com.google.protobuf.MapField.newMapField(ColumnScoreDefaultEntryHolder.defaultEntry); + } + if (!columnScore_.isMutable()) { + columnScore_ = columnScore_.copy(); + } + bitField0_ |= 0x00000020; + onChanged(); + return columnScore_; + } + + public int getColumnScoreCount() { + return internalGetColumnScore().getMap().size(); + } + /** + * + * + *
+       * The score of each column scanned in the data scan job.
+       * The key of the map is the name of the column.
+       * The value is the data quality score for the column.
+       *
+       * The score ranges between [0, 100] (up to two decimal
+       * points).
+       * 
+ * + * map<string, float> column_score = 6; + */ + @java.lang.Override + public boolean containsColumnScore(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + return internalGetColumnScore().getMap().containsKey(key); + } + /** Use {@link #getColumnScoreMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map getColumnScore() { + return getColumnScoreMap(); + } + /** + * + * + *
+       * The score of each column scanned in the data scan job.
+       * The key of the map is the name of the column.
+       * The value is the data quality score for the column.
+       *
+       * The score ranges between [0, 100] (up to two decimal
+       * points).
+       * 
+ * + * map<string, float> column_score = 6; + */ + @java.lang.Override + public java.util.Map getColumnScoreMap() { + return internalGetColumnScore().getMap(); + } + /** + * + * + *
+       * The score of each column scanned in the data scan job.
+       * The key of the map is the name of the column.
+       * The value is the data quality score for the column.
+       *
+       * The score ranges between [0, 100] (up to two decimal
+       * points).
+       * 
+ * + * map<string, float> column_score = 6; + */ + @java.lang.Override + public float getColumnScoreOrDefault(java.lang.String key, float defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetColumnScore().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + /** + * + * + *
+       * The score of each column scanned in the data scan job.
+       * The key of the map is the name of the column.
+       * The value is the data quality score for the column.
+       *
+       * The score ranges between [0, 100] (up to two decimal
+       * points).
+       * 
+ * + * map<string, float> column_score = 6; + */ + @java.lang.Override + public float getColumnScoreOrThrow(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetColumnScore().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + public Builder clearColumnScore() { + bitField0_ = (bitField0_ & ~0x00000020); + internalGetMutableColumnScore().getMutableMap().clear(); + return this; + } + /** + * + * + *
+       * The score of each column scanned in the data scan job.
+       * The key of the map is the name of the column.
+       * The value is the data quality score for the column.
+       *
+       * The score ranges between [0, 100] (up to two decimal
+       * points).
+       * 
+ * + * map<string, float> column_score = 6; + */ + public Builder removeColumnScore(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + internalGetMutableColumnScore().getMutableMap().remove(key); + return this; + } + /** Use alternate mutation accessors instead. */ + @java.lang.Deprecated + public java.util.Map getMutableColumnScore() { + bitField0_ |= 0x00000020; + return internalGetMutableColumnScore().getMutableMap(); + } + /** + * + * + *
+       * The score of each column scanned in the data scan job.
+       * The key of the map is the name of the column.
+       * The value is the data quality score for the column.
+       *
+       * The score ranges between [0, 100] (up to two decimal
+       * points).
+       * 
+ * + * map<string, float> column_score = 6; + */ + public Builder putColumnScore(java.lang.String key, float value) { + if (key == null) { + throw new NullPointerException("map key"); + } + + internalGetMutableColumnScore().getMutableMap().put(key, value); + bitField0_ |= 0x00000020; + return this; + } + /** + * + * + *
+       * The score of each column scanned in the data scan job.
+       * The key of the map is the name of the column.
+       * The value is the data quality score for the column.
+       *
+       * The score ranges between [0, 100] (up to two decimal
+       * points).
+       * 
+ * + * map<string, float> column_score = 6; + */ + public Builder putAllColumnScore(java.util.Map values) { + internalGetMutableColumnScore().getMutableMap().putAll(values); + bitField0_ |= 0x00000020; + return this; + } + @java.lang.Override public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GovernanceEvent.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GovernanceEvent.java index 84c5375d4e3c..dfe24d3502a6 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GovernanceEvent.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GovernanceEvent.java @@ -203,6 +203,36 @@ public enum EventType implements com.google.protobuf.ProtocolMessageEnum { * ACCESS_POLICY_UPDATE = 14; */ ACCESS_POLICY_UPDATE(14), + /** + * + * + *
+     * Number of resources matched with particular Query.
+     * 
+ * + * GOVERNANCE_RULE_MATCHED_RESOURCES = 15; + */ + GOVERNANCE_RULE_MATCHED_RESOURCES(15), + /** + * + * + *
+     * Rule processing exceeds the allowed limit.
+     * 
+ * + * GOVERNANCE_RULE_SEARCH_LIMIT_EXCEEDS = 16; + */ + GOVERNANCE_RULE_SEARCH_LIMIT_EXCEEDS(16), + /** + * + * + *
+     * Rule processing errors.
+     * 
+ * + * GOVERNANCE_RULE_ERRORS = 17; + */ + GOVERNANCE_RULE_ERRORS(17), UNRECOGNIZED(-1), ; @@ -336,6 +366,36 @@ public enum EventType implements com.google.protobuf.ProtocolMessageEnum { * ACCESS_POLICY_UPDATE = 14; */ public static final int ACCESS_POLICY_UPDATE_VALUE = 14; + /** + * + * + *
+     * Number of resources matched with particular Query.
+     * 
+ * + * GOVERNANCE_RULE_MATCHED_RESOURCES = 15; + */ + public static final int GOVERNANCE_RULE_MATCHED_RESOURCES_VALUE = 15; + /** + * + * + *
+     * Rule processing exceeds the allowed limit.
+     * 
+ * + * GOVERNANCE_RULE_SEARCH_LIMIT_EXCEEDS = 16; + */ + public static final int GOVERNANCE_RULE_SEARCH_LIMIT_EXCEEDS_VALUE = 16; + /** + * + * + *
+     * Rule processing errors.
+     * 
+ * + * GOVERNANCE_RULE_ERRORS = 17; + */ + public static final int GOVERNANCE_RULE_ERRORS_VALUE = 17; public final int getNumber() { if (this == UNRECOGNIZED) { @@ -387,6 +447,12 @@ public static EventType forNumber(int value) { return BIGQUERY_POLICY_TAG_SET_IAM_POLICY; case 14: return ACCESS_POLICY_UPDATE; + case 15: + return GOVERNANCE_RULE_MATCHED_RESOURCES; + case 16: + return GOVERNANCE_RULE_SEARCH_LIMIT_EXCEEDS; + case 17: + return GOVERNANCE_RULE_ERRORS; default: return null; } diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/LogsProto.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/LogsProto.java index bfa5f54b3d9a..6d4595261eae 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/LogsProto.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/LogsProto.java @@ -87,6 +87,14 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_dataplex_v1_DataScanEvent_DataQualityResult_DimensionPassedEntry_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_cloud_dataplex_v1_DataScanEvent_DataQualityResult_DimensionPassedEntry_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataplex_v1_DataScanEvent_DataQualityResult_DimensionScoreEntry_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_DataScanEvent_DataQualityResult_DimensionScoreEntry_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataplex_v1_DataScanEvent_DataQualityResult_ColumnScoreEntry_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_DataScanEvent_DataQualityResult_ColumnScoreEntry_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_cloud_dataplex_v1_DataScanEvent_DataProfileAppliedConfigs_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable @@ -184,8 +192,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\"=\n\006Engine\022\026\n\022ENGINE_UNSPECIFIED\020\000\022\r\n\tSP" + "ARK_SQL\020\001\022\014\n\010BIGQUERY\020\002\"S\n\tEventType\022\032\n\026" + "EVENT_TYPE_UNSPECIFIED\020\000\022\t\n\005START\020\001\022\010\n\004S" - + "TOP\020\002\022\t\n\005QUERY\020\003\022\n\n\006CREATE\020\004B\010\n\006detail\"\255" - + "\006\n\017GovernanceEvent\022\017\n\007message\030\001 \001(\t\022G\n\ne" + + "TOP\020\002\022\t\n\005QUERY\020\003\022\n\n\006CREATE\020\004B\010\n\006detail\"\232" + + "\007\n\017GovernanceEvent\022\017\n\007message\030\001 \001(\t\022G\n\ne" + "vent_type\030\002 \001(\01623.google.cloud.dataplex." + "v1.GovernanceEvent.EventType\022E\n\006entity\030\003" + " \001(\01320.google.cloud.dataplex.v1.Governan" @@ -194,7 +202,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "ity\022P\n\013entity_type\030\002 \001(\0162;.google.cloud." + "dataplex.v1.GovernanceEvent.Entity.Entit" + "yType\"A\n\nEntityType\022\033\n\027ENTITY_TYPE_UNSPE" - + "CIFIED\020\000\022\t\n\005TABLE\020\001\022\013\n\007FILESET\020\002\"\230\003\n\tEve" + + "CIFIED\020\000\022\t\n\005TABLE\020\001\022\013\n\007FILESET\020\002\"\205\004\n\tEve" + "ntType\022\032\n\026EVENT_TYPE_UNSPECIFIED\020\000\022\036\n\032RE" + "SOURCE_IAM_POLICY_UPDATE\020\001\022\031\n\025BIGQUERY_T" + "ABLE_CREATE\020\002\022\031\n\025BIGQUERY_TABLE_UPDATE\020\003" @@ -205,84 +213,95 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "QUERY_POLICY_TAG_CREATE\020\013\022\036\n\032BIGQUERY_PO" + "LICY_TAG_DELETE\020\014\022&\n\"BIGQUERY_POLICY_TAG" + "_SET_IAM_POLICY\020\r\022\030\n\024ACCESS_POLICY_UPDAT" - + "E\020\016B\t\n\007_entity\"\257\020\n\rDataScanEvent\022\023\n\013data" - + "_source\030\001 \001(\t\022\016\n\006job_id\030\002 \001(\t\022/\n\013create_" - + "time\030\014 \001(\0132\032.google.protobuf.Timestamp\022." - + "\n\nstart_time\030\003 \001(\0132\032.google.protobuf.Tim" - + "estamp\022,\n\010end_time\030\004 \001(\0132\032.google.protob" - + "uf.Timestamp\022>\n\004type\030\005 \001(\01620.google.clou" - + "d.dataplex.v1.DataScanEvent.ScanType\022<\n\005" - + "state\030\006 \001(\0162-.google.cloud.dataplex.v1.D" - + "ataScanEvent.State\022\017\n\007message\030\007 \001(\t\022\024\n\014s" - + "pec_version\030\010 \001(\t\022@\n\007trigger\030\t \001(\0162/.goo" - + "gle.cloud.dataplex.v1.DataScanEvent.Trig" - + "ger\022<\n\005scope\030\n \001(\0162-.google.cloud.datapl" - + "ex.v1.DataScanEvent.Scope\022Q\n\014data_profil" - + "e\030e \001(\01329.google.cloud.dataplex.v1.DataS" - + "canEvent.DataProfileResultH\000\022Q\n\014data_qua" - + "lity\030f \001(\01329.google.cloud.dataplex.v1.Da" - + "taScanEvent.DataQualityResultH\000\022b\n\024data_" - + "profile_configs\030\311\001 \001(\0132A.google.cloud.da" - + "taplex.v1.DataScanEvent.DataProfileAppli" - + "edConfigsH\001\022b\n\024data_quality_configs\030\312\001 \001" - + "(\0132A.google.cloud.dataplex.v1.DataScanEv" - + "ent.DataQualityAppliedConfigsH\001\022_\n\030post_" - + "scan_actions_result\030\013 \001(\0132=.google.cloud" - + ".dataplex.v1.DataScanEvent.PostScanActio" - + "nsResult\032&\n\021DataProfileResult\022\021\n\trow_cou" - + "nt\030\001 \001(\003\032\330\001\n\021DataQualityResult\022\021\n\trow_co" - + "unt\030\001 \001(\003\022\016\n\006passed\030\002 \001(\010\022h\n\020dimension_p" - + "assed\030\003 \003(\0132N.google.cloud.dataplex.v1.D" - + "ataScanEvent.DataQualityResult.Dimension" - + "PassedEntry\0326\n\024DimensionPassedEntry\022\013\n\003k" - + "ey\030\001 \001(\t\022\r\n\005value\030\002 \001(\010:\0028\001\032p\n\031DataProfi" - + "leAppliedConfigs\022\030\n\020sampling_percent\030\001 \001" - + "(\002\022\032\n\022row_filter_applied\030\002 \001(\010\022\035\n\025column" - + "_filter_applied\030\003 \001(\010\032Q\n\031DataQualityAppl" - + "iedConfigs\022\030\n\020sampling_percent\030\001 \001(\002\022\032\n\022" - + "row_filter_applied\030\002 \001(\010\032\346\002\n\025PostScanAct" - + "ionsResult\022r\n\026bigquery_export_result\030\001 \001" - + "(\0132R.google.cloud.dataplex.v1.DataScanEv" - + "ent.PostScanActionsResult.BigQueryExport" - + "Result\032\330\001\n\024BigQueryExportResult\022g\n\005state" - + "\030\001 \001(\0162X.google.cloud.dataplex.v1.DataSc" - + "anEvent.PostScanActionsResult.BigQueryEx" - + "portResult.State\022\017\n\007message\030\002 \001(\t\"F\n\005Sta" - + "te\022\025\n\021STATE_UNSPECIFIED\020\000\022\r\n\tSUCCEEDED\020\001" - + "\022\n\n\006FAILED\020\002\022\013\n\007SKIPPED\020\003\"I\n\010ScanType\022\031\n" - + "\025SCAN_TYPE_UNSPECIFIED\020\000\022\020\n\014DATA_PROFILE" - + "\020\001\022\020\n\014DATA_QUALITY\020\002\"b\n\005State\022\025\n\021STATE_U" - + "NSPECIFIED\020\000\022\013\n\007STARTED\020\001\022\r\n\tSUCCEEDED\020\002" - + "\022\n\n\006FAILED\020\003\022\r\n\tCANCELLED\020\004\022\013\n\007CREATED\020\005" - + "\"?\n\007Trigger\022\027\n\023TRIGGER_UNSPECIFIED\020\000\022\r\n\t" - + "ON_DEMAND\020\001\022\014\n\010SCHEDULE\020\002\"9\n\005Scope\022\025\n\021SC" - + "OPE_UNSPECIFIED\020\000\022\010\n\004FULL\020\001\022\017\n\013INCREMENT" - + "AL\020\002B\010\n\006resultB\020\n\016appliedConfigs\"\351\006\n\031Dat" - + "aQualityScanRuleResult\022\016\n\006job_id\030\001 \001(\t\022\023" - + "\n\013data_source\030\002 \001(\t\022\016\n\006column\030\003 \001(\t\022\021\n\tr" - + "ule_name\030\004 \001(\t\022O\n\trule_type\030\005 \001(\0162<.goog" - + "le.cloud.dataplex.v1.DataQualityScanRule" - + "Result.RuleType\022Z\n\016evalution_type\030\006 \001(\0162" - + "B.google.cloud.dataplex.v1.DataQualitySc" - + "anRuleResult.EvaluationType\022\026\n\016rule_dime" - + "nsion\030\007 \001(\t\022\031\n\021threshold_percent\030\010 \001(\001\022J" - + "\n\006result\030\t \001(\0162:.google.cloud.dataplex.v" - + "1.DataQualityScanRuleResult.Result\022\033\n\023ev" - + "aluated_row_count\030\n \001(\003\022\030\n\020passed_row_co" - + "unt\030\013 \001(\003\022\026\n\016null_row_count\030\014 \001(\003\"\377\001\n\010Ru" - + "leType\022\031\n\025RULE_TYPE_UNSPECIFIED\020\000\022\030\n\024NON" - + "_NULL_EXPECTATION\020\001\022\025\n\021RANGE_EXPECTATION" - + "\020\002\022\025\n\021REGEX_EXPECTATION\020\003\022\035\n\031ROW_CONDITI" - + "ON_EXPECTATION\020\004\022\023\n\017SET_EXPECTATION\020\005\022\037\n" - + "\033STATISTIC_RANGE_EXPECTATION\020\006\022\037\n\033TABLE_" - + "CONDITION_EXPECTATION\020\007\022\032\n\026UNIQUENESS_EX" - + "PECTATION\020\010\"M\n\016EvaluationType\022\037\n\033EVALUAT" - + "ION_TYPE_UNSPECIFIED\020\000\022\013\n\007PER_ROW\020\001\022\r\n\tA" - + "GGREGATE\020\002\"8\n\006Result\022\026\n\022RESULT_UNSPECIFI" - + "ED\020\000\022\n\n\006PASSED\020\001\022\n\n\006FAILED\020\002Be\n\034com.goog" - + "le.cloud.dataplex.v1B\tLogsProtoP\001Z8cloud" - + ".google.com/go/dataplex/apiv1/dataplexpb" - + ";dataplexpbb\006proto3" + + "E\020\016\022%\n!GOVERNANCE_RULE_MATCHED_RESOURCES" + + "\020\017\022(\n$GOVERNANCE_RULE_SEARCH_LIMIT_EXCEE" + + "DS\020\020\022\032\n\026GOVERNANCE_RULE_ERRORS\020\021B\t\n\007_ent" + + "ity\"\363\022\n\rDataScanEvent\022\023\n\013data_source\030\001 \001" + + "(\t\022\016\n\006job_id\030\002 \001(\t\022/\n\013create_time\030\014 \001(\0132" + + "\032.google.protobuf.Timestamp\022.\n\nstart_tim" + + "e\030\003 \001(\0132\032.google.protobuf.Timestamp\022,\n\010e" + + "nd_time\030\004 \001(\0132\032.google.protobuf.Timestam" + + "p\022>\n\004type\030\005 \001(\01620.google.cloud.dataplex." + + "v1.DataScanEvent.ScanType\022<\n\005state\030\006 \001(\016" + + "2-.google.cloud.dataplex.v1.DataScanEven" + + "t.State\022\017\n\007message\030\007 \001(\t\022\024\n\014spec_version" + + "\030\010 \001(\t\022@\n\007trigger\030\t \001(\0162/.google.cloud.d" + + "ataplex.v1.DataScanEvent.Trigger\022<\n\005scop" + + "e\030\n \001(\0162-.google.cloud.dataplex.v1.DataS" + + "canEvent.Scope\022Q\n\014data_profile\030e \001(\01329.g" + + "oogle.cloud.dataplex.v1.DataScanEvent.Da" + + "taProfileResultH\000\022Q\n\014data_quality\030f \001(\0132" + + "9.google.cloud.dataplex.v1.DataScanEvent" + + ".DataQualityResultH\000\022b\n\024data_profile_con" + + "figs\030\311\001 \001(\0132A.google.cloud.dataplex.v1.D" + + "ataScanEvent.DataProfileAppliedConfigsH\001" + + "\022b\n\024data_quality_configs\030\312\001 \001(\0132A.google" + + ".cloud.dataplex.v1.DataScanEvent.DataQua" + + "lityAppliedConfigsH\001\022_\n\030post_scan_action" + + "s_result\030\013 \001(\0132=.google.cloud.dataplex.v" + + "1.DataScanEvent.PostScanActionsResult\032&\n" + + "\021DataProfileResult\022\021\n\trow_count\030\001 \001(\003\032\234\004" + + "\n\021DataQualityResult\022\021\n\trow_count\030\001 \001(\003\022\016" + + "\n\006passed\030\002 \001(\010\022h\n\020dimension_passed\030\003 \003(\013" + + "2N.google.cloud.dataplex.v1.DataScanEven" + + "t.DataQualityResult.DimensionPassedEntry" + + "\022\r\n\005score\030\004 \001(\002\022f\n\017dimension_score\030\005 \003(\013" + + "2M.google.cloud.dataplex.v1.DataScanEven" + + "t.DataQualityResult.DimensionScoreEntry\022" + + "`\n\014column_score\030\006 \003(\0132J.google.cloud.dat" + + "aplex.v1.DataScanEvent.DataQualityResult" + + ".ColumnScoreEntry\0326\n\024DimensionPassedEntr" + + "y\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(\010:\0028\001\0325\n\023Dim" + + "ensionScoreEntry\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002" + + " \001(\002:\0028\001\0322\n\020ColumnScoreEntry\022\013\n\003key\030\001 \001(" + + "\t\022\r\n\005value\030\002 \001(\002:\0028\001\032p\n\031DataProfileAppli" + + "edConfigs\022\030\n\020sampling_percent\030\001 \001(\002\022\032\n\022r" + + "ow_filter_applied\030\002 \001(\010\022\035\n\025column_filter" + + "_applied\030\003 \001(\010\032Q\n\031DataQualityAppliedConf" + + "igs\022\030\n\020sampling_percent\030\001 \001(\002\022\032\n\022row_fil" + + "ter_applied\030\002 \001(\010\032\346\002\n\025PostScanActionsRes" + + "ult\022r\n\026bigquery_export_result\030\001 \001(\0132R.go" + + "ogle.cloud.dataplex.v1.DataScanEvent.Pos" + + "tScanActionsResult.BigQueryExportResult\032" + + "\330\001\n\024BigQueryExportResult\022g\n\005state\030\001 \001(\0162" + + "X.google.cloud.dataplex.v1.DataScanEvent" + + ".PostScanActionsResult.BigQueryExportRes" + + "ult.State\022\017\n\007message\030\002 \001(\t\"F\n\005State\022\025\n\021S" + + "TATE_UNSPECIFIED\020\000\022\r\n\tSUCCEEDED\020\001\022\n\n\006FAI" + + "LED\020\002\022\013\n\007SKIPPED\020\003\"I\n\010ScanType\022\031\n\025SCAN_T" + + "YPE_UNSPECIFIED\020\000\022\020\n\014DATA_PROFILE\020\001\022\020\n\014D" + + "ATA_QUALITY\020\002\"b\n\005State\022\025\n\021STATE_UNSPECIF" + + "IED\020\000\022\013\n\007STARTED\020\001\022\r\n\tSUCCEEDED\020\002\022\n\n\006FAI" + + "LED\020\003\022\r\n\tCANCELLED\020\004\022\013\n\007CREATED\020\005\"?\n\007Tri" + + "gger\022\027\n\023TRIGGER_UNSPECIFIED\020\000\022\r\n\tON_DEMA" + + "ND\020\001\022\014\n\010SCHEDULE\020\002\"9\n\005Scope\022\025\n\021SCOPE_UNS" + + "PECIFIED\020\000\022\010\n\004FULL\020\001\022\017\n\013INCREMENTAL\020\002B\010\n" + + "\006resultB\020\n\016appliedConfigs\"\351\006\n\031DataQualit" + + "yScanRuleResult\022\016\n\006job_id\030\001 \001(\t\022\023\n\013data_" + + "source\030\002 \001(\t\022\016\n\006column\030\003 \001(\t\022\021\n\trule_nam" + + "e\030\004 \001(\t\022O\n\trule_type\030\005 \001(\0162<.google.clou" + + "d.dataplex.v1.DataQualityScanRuleResult." + + "RuleType\022Z\n\016evalution_type\030\006 \001(\0162B.googl" + + "e.cloud.dataplex.v1.DataQualityScanRuleR" + + "esult.EvaluationType\022\026\n\016rule_dimension\030\007" + + " \001(\t\022\031\n\021threshold_percent\030\010 \001(\001\022J\n\006resul" + + "t\030\t \001(\0162:.google.cloud.dataplex.v1.DataQ" + + "ualityScanRuleResult.Result\022\033\n\023evaluated" + + "_row_count\030\n \001(\003\022\030\n\020passed_row_count\030\013 \001" + + "(\003\022\026\n\016null_row_count\030\014 \001(\003\"\377\001\n\010RuleType\022" + + "\031\n\025RULE_TYPE_UNSPECIFIED\020\000\022\030\n\024NON_NULL_E" + + "XPECTATION\020\001\022\025\n\021RANGE_EXPECTATION\020\002\022\025\n\021R" + + "EGEX_EXPECTATION\020\003\022\035\n\031ROW_CONDITION_EXPE" + + "CTATION\020\004\022\023\n\017SET_EXPECTATION\020\005\022\037\n\033STATIS" + + "TIC_RANGE_EXPECTATION\020\006\022\037\n\033TABLE_CONDITI" + + "ON_EXPECTATION\020\007\022\032\n\026UNIQUENESS_EXPECTATI" + + "ON\020\010\"M\n\016EvaluationType\022\037\n\033EVALUATION_TYP" + + "E_UNSPECIFIED\020\000\022\013\n\007PER_ROW\020\001\022\r\n\tAGGREGAT" + + "E\020\002\"8\n\006Result\022\026\n\022RESULT_UNSPECIFIED\020\000\022\n\n" + + "\006PASSED\020\001\022\n\n\006FAILED\020\002Be\n\034com.google.clou" + + "d.dataplex.v1B\tLogsProtoP\001Z8cloud.google" + + ".com/go/dataplex/apiv1/dataplexpb;datapl" + + "expbb\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -448,7 +467,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_cloud_dataplex_v1_DataScanEvent_DataQualityResult_descriptor, new java.lang.String[] { - "RowCount", "Passed", "DimensionPassed", + "RowCount", "Passed", "DimensionPassed", "Score", "DimensionScore", "ColumnScore", }); internal_static_google_cloud_dataplex_v1_DataScanEvent_DataQualityResult_DimensionPassedEntry_descriptor = internal_static_google_cloud_dataplex_v1_DataScanEvent_DataQualityResult_descriptor @@ -460,6 +479,26 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new java.lang.String[] { "Key", "Value", }); + internal_static_google_cloud_dataplex_v1_DataScanEvent_DataQualityResult_DimensionScoreEntry_descriptor = + internal_static_google_cloud_dataplex_v1_DataScanEvent_DataQualityResult_descriptor + .getNestedTypes() + .get(1); + internal_static_google_cloud_dataplex_v1_DataScanEvent_DataQualityResult_DimensionScoreEntry_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dataplex_v1_DataScanEvent_DataQualityResult_DimensionScoreEntry_descriptor, + new java.lang.String[] { + "Key", "Value", + }); + internal_static_google_cloud_dataplex_v1_DataScanEvent_DataQualityResult_ColumnScoreEntry_descriptor = + internal_static_google_cloud_dataplex_v1_DataScanEvent_DataQualityResult_descriptor + .getNestedTypes() + .get(2); + internal_static_google_cloud_dataplex_v1_DataScanEvent_DataQualityResult_ColumnScoreEntry_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dataplex_v1_DataScanEvent_DataQualityResult_ColumnScoreEntry_descriptor, + new java.lang.String[] { + "Key", "Value", + }); internal_static_google_cloud_dataplex_v1_DataScanEvent_DataProfileAppliedConfigs_descriptor = internal_static_google_cloud_dataplex_v1_DataScanEvent_descriptor.getNestedTypes().get(2); internal_static_google_cloud_dataplex_v1_DataScanEvent_DataProfileAppliedConfigs_fieldAccessorTable = diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/logs.proto b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/logs.proto index 0691afbbbafd..768d79b6e89f 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/logs.proto +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/logs.proto @@ -382,6 +382,15 @@ message GovernanceEvent { // Access policy update event. ACCESS_POLICY_UPDATE = 14; + + // Number of resources matched with particular Query. + GOVERNANCE_RULE_MATCHED_RESOURCES = 15; + + // Rule processing exceeds the allowed limit. + GOVERNANCE_RULE_SEARCH_LIMIT_EXCEEDS = 16; + + // Rule processing errors. + GOVERNANCE_RULE_ERRORS = 17; } // The log message. @@ -475,6 +484,28 @@ message DataScanEvent { // The value is the bool value depicting whether the dimension result was // `pass` or not. map dimension_passed = 3; + + // The table-level data quality score for the data scan job. + // + // The data quality score ranges between [0, 100] (up to two decimal + // points). + float score = 4; + + // The score of each dimension for data quality result. + // The key of the map is the name of the dimension. + // The value is the data quality score for the dimension. + // + // The score ranges between [0, 100] (up to two decimal + // points). + map dimension_score = 5; + + // The score of each column scanned in the data scan job. + // The key of the map is the name of the column. + // The value is the data quality score for the column. + // + // The score ranges between [0, 100] (up to two decimal + // points). + map column_score = 6; } // Applied configs for data profile type data scan job.