acceldata-sdk-python 26.7.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- acceldata/__init__.py +7 -0
- acceldata/client/__init__.py +0 -0
- acceldata/client/adoc_client.py +666 -0
- acceldata/client/http_client.py +346 -0
- acceldata/client/transient_retry.py +142 -0
- acceldata/constants/__init__.py +1 -0
- acceldata/constants/constants.py +13 -0
- acceldata/exceptions/__init__.py +52 -0
- acceldata/exceptions/api_errors.py +85 -0
- acceldata/exceptions/exceptions.py +174 -0
- acceldata/exceptions/sdk_exceptions.py +98 -0
- acceldata/mappers/__init__.py +21 -0
- acceldata/mappers/catalog_executions.py +107 -0
- acceldata/models/__init__.py +0 -0
- acceldata/models/api/catalog/above_configs.py +99 -0
- acceldata/models/api/catalog/above_configs_success.py +138 -0
- acceldata/models/api/catalog/absolute_configs.py +197 -0
- acceldata/models/api/catalog/absolute_configs_fallback.py +101 -0
- acceldata/models/api/catalog/absolute_threshold_config.py +105 -0
- acceldata/models/api/catalog/analysis_job_context.py +102 -0
- acceldata/models/api/catalog/analytics_pipeline.py +385 -0
- acceldata/models/api/catalog/analytics_pipeline_endpoint.py +136 -0
- acceldata/models/api/catalog/anomaly_config.py +95 -0
- acceldata/models/api/catalog/anomaly_details.py +119 -0
- acceldata/models/api/catalog/anomaly_threshold_config.py +105 -0
- acceldata/models/api/catalog/artifact.py +92 -0
- acceldata/models/api/catalog/assembly.py +171 -0
- acceldata/models/api/catalog/asset.py +162 -0
- acceldata/models/api/catalog/asset_catalog_listing.py +159 -0
- acceldata/models/api/catalog/asset_catalog_listing_response.py +102 -0
- acceldata/models/api/catalog/asset_label_request.py +96 -0
- acceldata/models/api/catalog/asset_progress.py +96 -0
- acceldata/models/api/catalog/asset_progress_details.py +117 -0
- acceldata/models/api/catalog/asset_tag.py +124 -0
- acceldata/models/api/catalog/asset_tag_info.py +140 -0
- acceldata/models/api/catalog/asset_tag_request.py +95 -0
- acceldata/models/api/catalog/asset_tag_response.py +96 -0
- acceldata/models/api/catalog/asset_tags_response.py +102 -0
- acceldata/models/api/catalog/asset_type.py +96 -0
- acceldata/models/api/catalog/auto_anomaly_feature_analysis.py +160 -0
- acceldata/models/api/catalog/auto_anomaly_item_execution.py +133 -0
- acceldata/models/api/catalog/auto_anomaly_meta_data.py +162 -0
- acceldata/models/api/catalog/auto_anomaly_rule_execution.py +102 -0
- acceldata/models/api/catalog/auto_anomaly_summary.py +124 -0
- acceldata/models/api/catalog/backing_asset.py +126 -0
- acceldata/models/api/catalog/below_configs.py +99 -0
- acceldata/models/api/catalog/big_decimal.py +100 -0
- acceldata/models/api/catalog/big_integer.py +98 -0
- acceldata/models/api/catalog/bounds_date_time_marker_config.py +110 -0
- acceldata/models/api/catalog/bounds_file_event_marker_config.py +108 -0
- acceldata/models/api/catalog/bounds_id_marker_config.py +96 -0
- acceldata/models/api/catalog/catalog_asset_meta_data.py +128 -0
- acceldata/models/api/catalog/changes_by_config.py +105 -0
- acceldata/models/api/catalog/column_mapping.py +139 -0
- acceldata/models/api/catalog/column_metadata.py +90 -0
- acceldata/models/api/catalog/column_metric_with_anomaly_details.py +119 -0
- acceldata/models/api/catalog/column_variable.py +111 -0
- acceldata/models/api/catalog/composite_policy_execution.py +102 -0
- acceldata/models/api/catalog/composite_policy_item_execution.py +104 -0
- acceldata/models/api/catalog/connection.py +118 -0
- acceldata/models/api/catalog/connection_test_result.py +106 -0
- acceldata/models/api/catalog/connection_type.py +90 -0
- acceldata/models/api/catalog/connection_types_response.py +96 -0
- acceldata/models/api/catalog/crawler.py +88 -0
- acceldata/models/api/catalog/crawler_action_response.py +90 -0
- acceldata/models/api/catalog/crawler_execution.py +147 -0
- acceldata/models/api/catalog/crawler_execution_response.py +102 -0
- acceldata/models/api/catalog/crawler_status_response.py +90 -0
- acceldata/models/api/catalog/create_profile.py +194 -0
- acceldata/models/api/catalog/custom_sql_config.py +121 -0
- acceldata/models/api/catalog/data_bricks_spark_resource_config.py +104 -0
- acceldata/models/api/catalog/data_cadence_rule.py +236 -0
- acceldata/models/api/catalog/data_cadence_rule_details.py +125 -0
- acceldata/models/api/catalog/data_cadence_rule_execution.py +102 -0
- acceldata/models/api/catalog/data_cadence_rule_item.py +104 -0
- acceldata/models/api/catalog/data_cadence_rule_item_execution.py +158 -0
- acceldata/models/api/catalog/data_cadence_rule_response.py +98 -0
- acceldata/models/api/catalog/data_drift_execution.py +102 -0
- acceldata/models/api/catalog/data_drift_item_execution.py +121 -0
- acceldata/models/api/catalog/data_quality_engine.py +90 -0
- acceldata/models/api/catalog/data_quality_execution.py +106 -0
- acceldata/models/api/catalog/data_quality_rule.py +323 -0
- acceldata/models/api/catalog/data_quality_rule_details.py +186 -0
- acceldata/models/api/catalog/data_quality_rule_response.py +120 -0
- acceldata/models/api/catalog/data_quality_rules_response.py +102 -0
- acceldata/models/api/catalog/databricks_compute_config.py +113 -0
- acceldata/models/api/catalog/dataplane_engine.py +105 -0
- acceldata/models/api/catalog/dataplane_health_metrics.py +101 -0
- acceldata/models/api/catalog/dataplane_job.py +216 -0
- acceldata/models/api/catalog/dataplane_job_status.py +113 -0
- acceldata/models/api/catalog/dataplane_request.py +96 -0
- acceldata/models/api/catalog/dataproc_compute_config.py +106 -0
- acceldata/models/api/catalog/dataproc_spark_resource_config.py +104 -0
- acceldata/models/api/catalog/date_based_partition_marker_config.py +116 -0
- acceldata/models/api/catalog/date_partitioning_marker_config.py +113 -0
- acceldata/models/api/catalog/date_time_marker_config.py +109 -0
- acceldata/models/api/catalog/day_month_year_based_partition_marker_config.py +124 -0
- acceldata/models/api/catalog/decreased_by_config.py +105 -0
- acceldata/models/api/catalog/delete_artifact_response.py +88 -0
- acceldata/models/api/catalog/dq_rule_execution.py +248 -0
- acceldata/models/api/catalog/drift.py +121 -0
- acceldata/models/api/catalog/enable_rule_request.py +88 -0
- acceldata/models/api/catalog/engine.py +90 -0
- acceldata/models/api/catalog/execution_cancellation_response.py +92 -0
- acceldata/models/api/catalog/execution_response.py +144 -0
- acceldata/models/api/catalog/execution_result.py +126 -0
- acceldata/models/api/catalog/executions_response.py +102 -0
- acceldata/models/api/catalog/failed_asset_detail.py +90 -0
- acceldata/models/api/catalog/failed_summary.py +98 -0
- acceldata/models/api/catalog/file.py +94 -0
- acceldata/models/api/catalog/file_marker_config.py +99 -0
- acceldata/models/api/catalog/generic_config_fallback.py +101 -0
- acceldata/models/api/catalog/generic_execution.py +221 -0
- acceldata/models/api/catalog/generic_rule_execution.py +137 -0
- acceldata/models/api/catalog/global_storage_config_dto.py +172 -0
- acceldata/models/api/catalog/hosted_dp_deployment_response.py +98 -0
- acceldata/models/api/catalog/id_marker_config.py +94 -0
- acceldata/models/api/catalog/increased_by_config.py +105 -0
- acceldata/models/api/catalog/item.py +160 -0
- acceldata/models/api/catalog/item_execution.py +192 -0
- acceldata/models/api/catalog/item_segment.py +131 -0
- acceldata/models/api/catalog/job_schedule.py +118 -0
- acceldata/models/api/catalog/job_spec.py +96 -0
- acceldata/models/api/catalog/kubernetes_metrics.py +91 -0
- acceldata/models/api/catalog/label.py +97 -0
- acceldata/models/api/catalog/livy_compute_config.py +103 -0
- acceldata/models/api/catalog/livy_spark_resource_config.py +106 -0
- acceldata/models/api/catalog/look_back_config.py +90 -0
- acceldata/models/api/catalog/manual_tag_request.py +92 -0
- acceldata/models/api/catalog/mapping.py +97 -0
- acceldata/models/api/catalog/marker.py +88 -0
- acceldata/models/api/catalog/marker_config.py +349 -0
- acceldata/models/api/catalog/marker_config_fallback.py +101 -0
- acceldata/models/api/catalog/meta.py +92 -0
- acceldata/models/api/catalog/meta_data.py +92 -0
- acceldata/models/api/catalog/meta_data_item.py +94 -0
- acceldata/models/api/catalog/mini_profile_request.py +112 -0
- acceldata/models/api/catalog/notification_payload.py +114 -0
- acceldata/models/api/catalog/offset_based_marker_config.py +97 -0
- acceldata/models/api/catalog/operational_config.py +92 -0
- acceldata/models/api/catalog/pattern_configuration.py +90 -0
- acceldata/models/api/catalog/pipe_line_request.py +92 -0
- acceldata/models/api/catalog/pipeline_compute_config.py +110 -0
- acceldata/models/api/catalog/policy_execution_marker_config.py +94 -0
- acceldata/models/api/catalog/policy_execution_request.py +229 -0
- acceldata/models/api/catalog/policy_group.py +114 -0
- acceldata/models/api/catalog/policy_transform_udf.py +113 -0
- acceldata/models/api/catalog/process_metrics.py +91 -0
- acceldata/models/api/catalog/profile_anomaly_details_response.py +109 -0
- acceldata/models/api/catalog/profile_anomaly_item_execution.py +127 -0
- acceldata/models/api/catalog/profile_anomaly_rule_execution.py +102 -0
- acceldata/models/api/catalog/profile_anomaly_rule_item.py +109 -0
- acceldata/models/api/catalog/profile_cancellation_response.py +92 -0
- acceldata/models/api/catalog/profile_request.py +211 -0
- acceldata/models/api/catalog/profile_request_response.py +92 -0
- acceldata/models/api/catalog/property_template.py +178 -0
- acceldata/models/api/catalog/property_templates.py +123 -0
- acceldata/models/api/catalog/pub_sub_lookback_marker_config.py +96 -0
- acceldata/models/api/catalog/pub_sub_timestamp_marker_config.py +108 -0
- acceldata/models/api/catalog/quality_rule.py +381 -0
- acceldata/models/api/catalog/quality_rule_execution_metrics.py +114 -0
- acceldata/models/api/catalog/quality_rule_with_latest_execution.py +115 -0
- acceldata/models/api/catalog/range_configs.py +109 -0
- acceldata/models/api/catalog/reconciliation_item.py +102 -0
- acceldata/models/api/catalog/reconciliation_item_execution.py +157 -0
- acceldata/models/api/catalog/reconciliation_rule.py +339 -0
- acceldata/models/api/catalog/reconciliation_rule_details.py +225 -0
- acceldata/models/api/catalog/reconciliation_rule_execution.py +102 -0
- acceldata/models/api/catalog/reconciliation_rule_response.py +98 -0
- acceldata/models/api/catalog/reconciliation_rules_response.py +102 -0
- acceldata/models/api/catalog/relative_config.py +197 -0
- acceldata/models/api/catalog/relative_config_fallback.py +101 -0
- acceldata/models/api/catalog/relative_threshold_config.py +111 -0
- acceldata/models/api/catalog/root_cause_analysis.py +108 -0
- acceldata/models/api/catalog/rule_execution.py +327 -0
- acceldata/models/api/catalog/rule_execution_result.py +90 -0
- acceldata/models/api/catalog/rule_item_result.py +125 -0
- acceldata/models/api/catalog/rule_meta_data.py +94 -0
- acceldata/models/api/catalog/rule_spark_sql_dynamic_filter_variable_mapping.py +100 -0
- acceldata/models/api/catalog/rule_tag.py +101 -0
- acceldata/models/api/catalog/rule_threshold_configuration.py +236 -0
- acceldata/models/api/catalog/rule_threshold_configuration_fallback.py +101 -0
- acceldata/models/api/catalog/rules_with_latest_execution_response.py +102 -0
- acceldata/models/api/catalog/sample_data_api_response.py +122 -0
- acceldata/models/api/catalog/schema_drift_item_execution.py +131 -0
- acceldata/models/api/catalog/schema_drift_rule_execution.py +102 -0
- acceldata/models/api/catalog/secret_manager_configuration.py +90 -0
- acceldata/models/api/catalog/secret_manager_configuration_with_option.py +98 -0
- acceldata/models/api/catalog/security_config.py +90 -0
- acceldata/models/api/catalog/segment_metric_json.py +142 -0
- acceldata/models/api/catalog/segments_analysis.py +145 -0
- acceldata/models/api/catalog/short_segment.py +97 -0
- acceldata/models/api/catalog/simple_quality_rule_response.py +92 -0
- acceldata/models/api/catalog/snapshot_data.py +117 -0
- acceldata/models/api/catalog/source_model.py +90 -0
- acceldata/models/api/catalog/source_type.py +100 -0
- acceldata/models/api/catalog/source_types_response.py +102 -0
- acceldata/models/api/catalog/spark_job_status.py +113 -0
- acceldata/models/api/catalog/spark_resource_config.py +114 -0
- acceldata/models/api/catalog/standard_response_assembly.py +92 -0
- acceldata/models/api/catalog/standard_response_crawler_action_response.py +92 -0
- acceldata/models/api/catalog/standard_response_crawler_status_response.py +92 -0
- acceldata/models/api/catalog/standard_response_delete_artifact_response.py +92 -0
- acceldata/models/api/catalog/standard_response_list.py +96 -0
- acceldata/models/api/catalog/standard_response_map.py +88 -0
- acceldata/models/api/catalog/standard_response_meta_data.py +92 -0
- acceldata/models/api/catalog/standard_response_mini_profile_request.py +92 -0
- acceldata/models/api/catalog/standard_response_profile_request.py +92 -0
- acceldata/models/api/catalog/start_profiling_request.py +92 -0
- acceldata/models/api/catalog/tag_domain.py +116 -0
- acceldata/models/api/catalog/threshold_breach_details.py +101 -0
- acceldata/models/api/catalog/time_based_config.py +92 -0
- acceldata/models/api/catalog/time_based_threshold_config.py +105 -0
- acceldata/models/api/catalog/timestamp_based_marker_config.py +115 -0
- acceldata/models/api/catalog/udf_variable.py +97 -0
- acceldata/models/api/catalog/yunikorn_compute_config.py +133 -0
- acceldata/models/api/catalog/yunikorn_spark_resource_config.py +154 -0
- acceldata/models/api/pipeline/big_decimal.py +100 -0
- acceldata/models/api/pipeline/big_integer.py +98 -0
- acceldata/models/api/pipeline/child_span_response.py +96 -0
- acceldata/models/api/pipeline/create_span_event.py +109 -0
- acceldata/models/api/pipeline/edge.py +108 -0
- acceldata/models/api/pipeline/event_alert_object.py +95 -0
- acceldata/models/api/pipeline/generic_config_fallback.py +101 -0
- acceldata/models/api/pipeline/identifier.py +146 -0
- acceldata/models/api/pipeline/job_request.py +130 -0
- acceldata/models/api/pipeline/meta.py +107 -0
- acceldata/models/api/pipeline/meta_data.py +92 -0
- acceldata/models/api/pipeline/metric.py +103 -0
- acceldata/models/api/pipeline/node.py +201 -0
- acceldata/models/api/pipeline/node_response.py +92 -0
- acceldata/models/api/pipeline/notification_payload.py +114 -0
- acceldata/models/api/pipeline/pipeline.py +152 -0
- acceldata/models/api/pipeline/pipeline_baseline_metric.py +92 -0
- acceldata/models/api/pipeline/pipeline_details.py +118 -0
- acceldata/models/api/pipeline/pipeline_details_response.py +102 -0
- acceldata/models/api/pipeline/pipeline_input_request.py +92 -0
- acceldata/models/api/pipeline/pipeline_listing_info.py +118 -0
- acceldata/models/api/pipeline/pipeline_response.py +92 -0
- acceldata/models/api/pipeline/pipeline_run.py +136 -0
- acceldata/models/api/pipeline/pipeline_run_request.py +92 -0
- acceldata/models/api/pipeline/pipeline_runs_response.py +102 -0
- acceldata/models/api/pipeline/pipeline_summary.py +98 -0
- acceldata/models/api/pipeline/pipelines_listing_response.py +102 -0
- acceldata/models/api/pipeline/policy_summary.py +102 -0
- acceldata/models/api/pipeline/span.py +115 -0
- acceldata/models/api/pipeline/span_event.py +114 -0
- acceldata/models/api/pipeline/span_event_request.py +92 -0
- acceldata/models/api/pipeline/span_event_response.py +92 -0
- acceldata/models/api/pipeline/span_request.py +94 -0
- acceldata/models/api/pipeline/spans_response.py +96 -0
- acceldata/models/api/pipeline/tag.py +97 -0
- acceldata/models/sdk/__init__.py +0 -0
- acceldata/models/sdk/catalog/__init__.py +105 -0
- acceldata/models/sdk/catalog/asset_resource.py +112 -0
- acceldata/models/sdk/catalog/asset_source_type.py +59 -0
- acceldata/models/sdk/catalog/custom_asset_metadata.py +11 -0
- acceldata/models/sdk/catalog/datasource_resource.py +88 -0
- acceldata/models/sdk/catalog/executor.py +524 -0
- acceldata/models/sdk/catalog/policy_execution_request.py +114 -0
- acceldata/models/sdk/catalog/policy_execution_type.py +16 -0
- acceldata/models/sdk/catalog/policy_filter.py +94 -0
- acceldata/models/sdk/catalog/policy_rule_resources.py +388 -0
- acceldata/models/sdk/catalog/profile_request_resource.py +77 -0
- acceldata/models/sdk/catalog/profiling.py +82 -0
- acceldata/models/sdk/catalog/profiling_configuration_error.py +5 -0
- acceldata/models/sdk/pipeline/__init__.py +62 -0
- acceldata/models/sdk/pipeline/create_job_input.py +108 -0
- acceldata/models/sdk/pipeline/create_pipeline_input_request.py +72 -0
- acceldata/models/sdk/pipeline/events/__init__.py +5 -0
- acceldata/models/sdk/pipeline/events/generic_event.py +31 -0
- acceldata/models/sdk/pipeline/events/log_event.py +34 -0
- acceldata/models/sdk/pipeline/events/span_event.py +8 -0
- acceldata/models/sdk/pipeline/pipeline_resource.py +171 -0
- acceldata/models/sdk/pipeline/pipeline_run_input.py +84 -0
- acceldata/models/sdk/pipeline/pipeline_run_resource.py +208 -0
- acceldata/models/sdk/pipeline/pipeline_source_type.py +20 -0
- acceldata/models/sdk/pipeline/span_resource.py +327 -0
- acceldata/openapi_deserialization_patches.py +161 -0
- acceldata/openapi_repr_patches.py +62 -0
- acceldata/services/__init__.py +0 -0
- acceldata/services/api_timestamp.py +31 -0
- acceldata/services/asset_service.py +651 -0
- acceldata/services/datasource_service.py +120 -0
- acceldata/services/generic_service.py +132 -0
- acceldata/services/marker_config.py +232 -0
- acceldata/services/pipeline_big_decimal_api.py +102 -0
- acceldata/services/pipeline_response_parse.py +209 -0
- acceldata/services/pipeline_service.py +494 -0
- acceldata/services/rule_service.py +620 -0
- acceldata/urls/__init__.py +1 -0
- acceldata/urls/catalog_urls.py +137 -0
- acceldata/urls/pipeline_urls.py +55 -0
- acceldata/utils/__init__.py +6 -0
- acceldata/utils/datetime_utils.py +16 -0
- acceldata/utils/operation_ack.py +22 -0
- acceldata/utils/span_helpers.py +95 -0
- acceldata/utils/time_range_utils.py +90 -0
- acceldata_sdk_python-26.7.0.dist-info/METADATA +26 -0
- acceldata_sdk_python-26.7.0.dist-info/RECORD +303 -0
- acceldata_sdk_python-26.7.0.dist-info/WHEEL +5 -0
- acceldata_sdk_python-26.7.0.dist-info/licenses/LICENSE +22 -0
- acceldata_sdk_python-26.7.0.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Catalog Control Plane API
|
|
5
|
+
|
|
6
|
+
No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 1.0
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
from __future__ import annotations
|
|
16
|
+
import pprint
|
|
17
|
+
import re # noqa: F401
|
|
18
|
+
import json
|
|
19
|
+
|
|
20
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr
|
|
21
|
+
from typing import Any, ClassVar, Dict, List, Optional
|
|
22
|
+
from typing import Optional, Set
|
|
23
|
+
from typing_extensions import Self
|
|
24
|
+
from pydantic_core import to_jsonable_python
|
|
25
|
+
|
|
26
|
+
class IdMarkerConfig(BaseModel):
|
|
27
|
+
"""
|
|
28
|
+
IdMarkerConfig
|
|
29
|
+
""" # noqa: E501
|
|
30
|
+
base_asset_id: Optional[StrictInt] = Field(default=None, alias="baseAssetId")
|
|
31
|
+
id_column_name: StrictStr = Field(alias="idColumnName")
|
|
32
|
+
initial_offset: Optional[StrictInt] = Field(default=None, alias="initialOffset")
|
|
33
|
+
type: StrictStr
|
|
34
|
+
__properties: ClassVar[List[str]] = ["baseAssetId", "idColumnName", "initialOffset", "type"]
|
|
35
|
+
|
|
36
|
+
model_config = ConfigDict(
|
|
37
|
+
validate_by_name=True,
|
|
38
|
+
validate_by_alias=True,
|
|
39
|
+
validate_assignment=True,
|
|
40
|
+
protected_namespaces=(),
|
|
41
|
+
)
|
|
42
|
+
|
|
43
|
+
|
|
44
|
+
def to_str(self) -> str:
|
|
45
|
+
"""Returns the string representation of the model using alias"""
|
|
46
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
47
|
+
|
|
48
|
+
def to_json(self) -> str:
|
|
49
|
+
"""Returns the JSON representation of the model using alias"""
|
|
50
|
+
return json.dumps(to_jsonable_python(self.to_dict()))
|
|
51
|
+
|
|
52
|
+
@classmethod
|
|
53
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
54
|
+
"""Create an instance of IdMarkerConfig from a JSON string"""
|
|
55
|
+
return cls.from_dict(json.loads(json_str))
|
|
56
|
+
|
|
57
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
58
|
+
"""Return the dictionary representation of the model using alias.
|
|
59
|
+
|
|
60
|
+
This has the following differences from calling pydantic's
|
|
61
|
+
`self.model_dump(by_alias=True)`:
|
|
62
|
+
|
|
63
|
+
* `None` is only added to the output dict for nullable fields that
|
|
64
|
+
were set at model initialization. Other fields with value `None`
|
|
65
|
+
are ignored.
|
|
66
|
+
"""
|
|
67
|
+
excluded_fields: Set[str] = set([
|
|
68
|
+
])
|
|
69
|
+
|
|
70
|
+
_dict = self.model_dump(
|
|
71
|
+
by_alias=True,
|
|
72
|
+
exclude=excluded_fields,
|
|
73
|
+
exclude_none=True,
|
|
74
|
+
)
|
|
75
|
+
return _dict
|
|
76
|
+
|
|
77
|
+
@classmethod
|
|
78
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
79
|
+
"""Create an instance of IdMarkerConfig from a dict"""
|
|
80
|
+
if obj is None:
|
|
81
|
+
return None
|
|
82
|
+
|
|
83
|
+
if not isinstance(obj, dict):
|
|
84
|
+
return cls.model_validate(obj)
|
|
85
|
+
|
|
86
|
+
_obj = cls.model_validate({
|
|
87
|
+
"baseAssetId": obj.get("baseAssetId"),
|
|
88
|
+
"idColumnName": obj.get("idColumnName"),
|
|
89
|
+
"initialOffset": obj.get("initialOffset"),
|
|
90
|
+
"type": obj.get("type")
|
|
91
|
+
})
|
|
92
|
+
return _obj
|
|
93
|
+
|
|
94
|
+
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Catalog Control Plane API
|
|
5
|
+
|
|
6
|
+
No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 1.0
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
from __future__ import annotations
|
|
16
|
+
import pprint
|
|
17
|
+
import re # noqa: F401
|
|
18
|
+
import json
|
|
19
|
+
|
|
20
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictStr
|
|
21
|
+
from typing import Any, ClassVar, Dict, List, Optional
|
|
22
|
+
from acceldata.models.api.catalog.above_configs_success import AboveConfigsSuccess
|
|
23
|
+
from typing import Optional, Set
|
|
24
|
+
from typing_extensions import Self
|
|
25
|
+
from pydantic_core import to_jsonable_python
|
|
26
|
+
|
|
27
|
+
class IncreasedByConfig(BaseModel):
|
|
28
|
+
"""
|
|
29
|
+
IncreasedByConfig
|
|
30
|
+
""" # noqa: E501
|
|
31
|
+
direction: StrictStr = Field(description="Allowed values at generation time: ABOVE, BELOW, RANGE, CHANGES_BY, DECREASED_BY, INCREASED_BY.")
|
|
32
|
+
operator: StrictStr = Field(description="Allowed values at generation time: LEGACY, EQ, NEQ, GT, GTE, LT, LTE.")
|
|
33
|
+
success: AboveConfigsSuccess
|
|
34
|
+
unit: StrictStr = Field(description="Allowed values at generation time: PERCENTAGE, ABSOLUTE.")
|
|
35
|
+
warning: Optional[AboveConfigsSuccess] = None
|
|
36
|
+
type: StrictStr
|
|
37
|
+
__properties: ClassVar[List[str]] = ["direction", "operator", "success", "unit", "warning", "type"]
|
|
38
|
+
|
|
39
|
+
model_config = ConfigDict(
|
|
40
|
+
validate_by_name=True,
|
|
41
|
+
validate_by_alias=True,
|
|
42
|
+
validate_assignment=True,
|
|
43
|
+
protected_namespaces=(),
|
|
44
|
+
)
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
def to_str(self) -> str:
|
|
48
|
+
"""Returns the string representation of the model using alias"""
|
|
49
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
50
|
+
|
|
51
|
+
def to_json(self) -> str:
|
|
52
|
+
"""Returns the JSON representation of the model using alias"""
|
|
53
|
+
return json.dumps(to_jsonable_python(self.to_dict()))
|
|
54
|
+
|
|
55
|
+
@classmethod
|
|
56
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
57
|
+
"""Create an instance of IncreasedByConfig from a JSON string"""
|
|
58
|
+
return cls.from_dict(json.loads(json_str))
|
|
59
|
+
|
|
60
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
61
|
+
"""Return the dictionary representation of the model using alias.
|
|
62
|
+
|
|
63
|
+
This has the following differences from calling pydantic's
|
|
64
|
+
`self.model_dump(by_alias=True)`:
|
|
65
|
+
|
|
66
|
+
* `None` is only added to the output dict for nullable fields that
|
|
67
|
+
were set at model initialization. Other fields with value `None`
|
|
68
|
+
are ignored.
|
|
69
|
+
"""
|
|
70
|
+
excluded_fields: Set[str] = set([
|
|
71
|
+
])
|
|
72
|
+
|
|
73
|
+
_dict = self.model_dump(
|
|
74
|
+
by_alias=True,
|
|
75
|
+
exclude=excluded_fields,
|
|
76
|
+
exclude_none=True,
|
|
77
|
+
)
|
|
78
|
+
# override the default output from pydantic by calling `to_dict()` of success
|
|
79
|
+
if self.success:
|
|
80
|
+
_dict['success'] = self.success.to_dict()
|
|
81
|
+
# override the default output from pydantic by calling `to_dict()` of warning
|
|
82
|
+
if self.warning:
|
|
83
|
+
_dict['warning'] = self.warning.to_dict()
|
|
84
|
+
return _dict
|
|
85
|
+
|
|
86
|
+
@classmethod
|
|
87
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
88
|
+
"""Create an instance of IncreasedByConfig from a dict"""
|
|
89
|
+
if obj is None:
|
|
90
|
+
return None
|
|
91
|
+
|
|
92
|
+
if not isinstance(obj, dict):
|
|
93
|
+
return cls.model_validate(obj)
|
|
94
|
+
|
|
95
|
+
_obj = cls.model_validate({
|
|
96
|
+
"direction": obj.get("direction") if obj.get("direction") is not None else 'INCREASED_BY',
|
|
97
|
+
"operator": obj.get("operator") if obj.get("operator") is not None else 'LEGACY',
|
|
98
|
+
"success": AboveConfigsSuccess.from_dict(obj["success"]) if obj.get("success") is not None else None,
|
|
99
|
+
"unit": obj.get("unit") if obj.get("unit") is not None else 'PERCENTAGE',
|
|
100
|
+
"warning": AboveConfigsSuccess.from_dict(obj["warning"]) if obj.get("warning") is not None else None,
|
|
101
|
+
"type": obj.get("type") if obj.get("type") is not None else 'io.ad.catalog.api.model.quality.IncreasedByConfig'
|
|
102
|
+
})
|
|
103
|
+
return _obj
|
|
104
|
+
|
|
105
|
+
|
|
@@ -0,0 +1,160 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Catalog Control Plane API
|
|
5
|
+
|
|
6
|
+
No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 1.0
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
from __future__ import annotations
|
|
16
|
+
import pprint
|
|
17
|
+
import re # noqa: F401
|
|
18
|
+
import json
|
|
19
|
+
|
|
20
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr
|
|
21
|
+
from typing import Any, ClassVar, Dict, List, Optional, Union
|
|
22
|
+
from acceldata.models.api.catalog.label import Label
|
|
23
|
+
from acceldata.models.api.catalog.rule_threshold_configuration import RuleThresholdConfiguration
|
|
24
|
+
from typing import Optional, Set
|
|
25
|
+
from typing_extensions import Self
|
|
26
|
+
from pydantic_core import to_jsonable_python
|
|
27
|
+
|
|
28
|
+
class Item(BaseModel):
|
|
29
|
+
"""
|
|
30
|
+
Item
|
|
31
|
+
""" # noqa: E501
|
|
32
|
+
aggregate_type: StrictStr = Field(description="Allowed values at generation time: SUM, AVG, MIN, MAX, RULE, CUSTOM, COUNT.", alias="aggregateType")
|
|
33
|
+
associated_dq_recommendation_id: Optional[StrictInt] = Field(default=None, alias="associatedDQRecommendationId")
|
|
34
|
+
bulk_policy_dq_rule_id: Optional[StrictInt] = Field(default=None, alias="bulkPolicyDqRuleId")
|
|
35
|
+
business_explanation: Optional[StrictStr] = Field(default=None, alias="businessExplanation")
|
|
36
|
+
column_name: Optional[StrictStr] = Field(default=None, alias="columnName")
|
|
37
|
+
execution_inputs: Optional[Dict[str, Any]] = Field(default=None, alias="executionInputs")
|
|
38
|
+
execution_order: StrictInt = Field(alias="executionOrder")
|
|
39
|
+
id: Optional[StrictInt] = None
|
|
40
|
+
is_archived: StrictBool = Field(alias="isArchived")
|
|
41
|
+
is_dimension: StrictBool = Field(alias="isDimension")
|
|
42
|
+
is_warning: StrictBool = Field(alias="isWarning")
|
|
43
|
+
labels: Optional[List[Label]] = None
|
|
44
|
+
measurement_type: StrictStr = Field(description="Allowed values at generation time: MISSING_VALUES, FRESHNESS_CHECK, DATATYPE_MATCH, REGEX_MATCH, VALUES_IN_LIST, VALUES_IN_LOOKUP, DISTINCTNESS_CHECK, DUPLICATE_ROWS_CHECK, PRECISION_SCALE_CHECK, BUSINESS_MEASURE, TAG_MATCH, RANGE_MATCH, SIZE_CHECK, CUSTOM, UDF_PREDICATE, SQL_METRIC, AGGREGATES, DATA_FRESHNESS, RECORD_COUNT_TOTAL, RECORD_COUNT_DRIFT, DATA_VOLUME_TOTAL, DATA_VOLUME_DRIFT, FILE_COUNT_TOTAL, FILE_COUNT_DRIFT, CHANGE_IN_FILE_SIZE, ABSOLUTE_FILE_SIZE, RAW_ABSOLUTE_SIZE, RAW_DATA_FRESHNESS, MESSAGES_COUNT_TOTAL, MESSAGES_COUNT_DRIFT, CHANGE_IN_TOPIC_SIZE, ABSOLUTE_TOPIC_SIZE.", alias="measurementType")
|
|
45
|
+
name: StrictStr
|
|
46
|
+
result_threshold: Union[StrictFloat, StrictInt] = Field(alias="resultThreshold")
|
|
47
|
+
rule_expression: Optional[StrictStr] = Field(default=None, alias="ruleExpression")
|
|
48
|
+
rule_id: Optional[StrictInt] = Field(default=None, alias="ruleId")
|
|
49
|
+
rule_version: StrictInt = Field(alias="ruleVersion")
|
|
50
|
+
threshold_config: Optional[RuleThresholdConfiguration] = Field(default=None, alias="thresholdConfig")
|
|
51
|
+
value: Optional[Dict[str, Any]] = None
|
|
52
|
+
weightage: Union[StrictFloat, StrictInt]
|
|
53
|
+
__properties: ClassVar[List[str]] = ["aggregateType", "associatedDQRecommendationId", "bulkPolicyDqRuleId", "businessExplanation", "columnName", "executionInputs", "executionOrder", "id", "isArchived", "isDimension", "isWarning", "labels", "measurementType", "name", "resultThreshold", "ruleExpression", "ruleId", "ruleVersion", "thresholdConfig", "value", "weightage"]
|
|
54
|
+
|
|
55
|
+
model_config = ConfigDict(
|
|
56
|
+
validate_by_name=True,
|
|
57
|
+
validate_by_alias=True,
|
|
58
|
+
validate_assignment=True,
|
|
59
|
+
protected_namespaces=(),
|
|
60
|
+
)
|
|
61
|
+
|
|
62
|
+
|
|
63
|
+
def to_str(self) -> str:
|
|
64
|
+
"""Returns the string representation of the model using alias"""
|
|
65
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
66
|
+
|
|
67
|
+
def to_json(self) -> str:
|
|
68
|
+
"""Returns the JSON representation of the model using alias"""
|
|
69
|
+
return json.dumps(to_jsonable_python(self.to_dict()))
|
|
70
|
+
|
|
71
|
+
@classmethod
|
|
72
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
73
|
+
"""Create an instance of Item from a JSON string"""
|
|
74
|
+
return cls.from_dict(json.loads(json_str))
|
|
75
|
+
|
|
76
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
77
|
+
"""Return the dictionary representation of the model using alias.
|
|
78
|
+
|
|
79
|
+
This has the following differences from calling pydantic's
|
|
80
|
+
`self.model_dump(by_alias=True)`:
|
|
81
|
+
|
|
82
|
+
* `None` is only added to the output dict for nullable fields that
|
|
83
|
+
were set at model initialization. Other fields with value `None`
|
|
84
|
+
are ignored.
|
|
85
|
+
"""
|
|
86
|
+
excluded_fields: Set[str] = set([
|
|
87
|
+
])
|
|
88
|
+
|
|
89
|
+
_dict = self.model_dump(
|
|
90
|
+
by_alias=True,
|
|
91
|
+
exclude=excluded_fields,
|
|
92
|
+
exclude_none=True,
|
|
93
|
+
)
|
|
94
|
+
# override the default output from pydantic by calling `to_dict()` of each item in labels (list)
|
|
95
|
+
_items = []
|
|
96
|
+
if self.labels:
|
|
97
|
+
for _item_labels in self.labels:
|
|
98
|
+
if _item_labels:
|
|
99
|
+
_items.append(_item_labels.to_dict())
|
|
100
|
+
_dict['labels'] = _items
|
|
101
|
+
# override the default output from pydantic by calling `to_dict()` of threshold_config
|
|
102
|
+
if self.threshold_config:
|
|
103
|
+
_dict['thresholdConfig'] = self.threshold_config.to_dict()
|
|
104
|
+
# set to None if business_explanation (nullable) is None
|
|
105
|
+
# and model_fields_set contains the field
|
|
106
|
+
if self.business_explanation is None and "business_explanation" in self.model_fields_set:
|
|
107
|
+
_dict['businessExplanation'] = None
|
|
108
|
+
|
|
109
|
+
# set to None if column_name (nullable) is None
|
|
110
|
+
# and model_fields_set contains the field
|
|
111
|
+
if self.column_name is None and "column_name" in self.model_fields_set:
|
|
112
|
+
_dict['columnName'] = None
|
|
113
|
+
|
|
114
|
+
# set to None if labels (nullable) is None
|
|
115
|
+
# and model_fields_set contains the field
|
|
116
|
+
if self.labels is None and "labels" in self.model_fields_set:
|
|
117
|
+
_dict['labels'] = None
|
|
118
|
+
|
|
119
|
+
# set to None if rule_expression (nullable) is None
|
|
120
|
+
# and model_fields_set contains the field
|
|
121
|
+
if self.rule_expression is None and "rule_expression" in self.model_fields_set:
|
|
122
|
+
_dict['ruleExpression'] = None
|
|
123
|
+
|
|
124
|
+
return _dict
|
|
125
|
+
|
|
126
|
+
@classmethod
|
|
127
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
128
|
+
"""Create an instance of Item from a dict"""
|
|
129
|
+
if obj is None:
|
|
130
|
+
return None
|
|
131
|
+
|
|
132
|
+
if not isinstance(obj, dict):
|
|
133
|
+
return cls.model_validate(obj)
|
|
134
|
+
|
|
135
|
+
_obj = cls.model_validate({
|
|
136
|
+
"aggregateType": obj.get("aggregateType"),
|
|
137
|
+
"associatedDQRecommendationId": obj.get("associatedDQRecommendationId"),
|
|
138
|
+
"bulkPolicyDqRuleId": obj.get("bulkPolicyDqRuleId"),
|
|
139
|
+
"businessExplanation": obj.get("businessExplanation"),
|
|
140
|
+
"columnName": obj.get("columnName"),
|
|
141
|
+
"executionInputs": obj.get("executionInputs"),
|
|
142
|
+
"executionOrder": obj.get("executionOrder"),
|
|
143
|
+
"id": obj.get("id"),
|
|
144
|
+
"isArchived": obj.get("isArchived"),
|
|
145
|
+
"isDimension": obj.get("isDimension"),
|
|
146
|
+
"isWarning": obj.get("isWarning"),
|
|
147
|
+
"labels": [Label.from_dict(_item) for _item in obj["labels"]] if obj.get("labels") is not None else None,
|
|
148
|
+
"measurementType": obj.get("measurementType"),
|
|
149
|
+
"name": obj.get("name"),
|
|
150
|
+
"resultThreshold": obj.get("resultThreshold"),
|
|
151
|
+
"ruleExpression": obj.get("ruleExpression"),
|
|
152
|
+
"ruleId": obj.get("ruleId"),
|
|
153
|
+
"ruleVersion": obj.get("ruleVersion"),
|
|
154
|
+
"thresholdConfig": RuleThresholdConfiguration.from_dict(obj["thresholdConfig"]) if obj.get("thresholdConfig") is not None else None,
|
|
155
|
+
"value": obj.get("value"),
|
|
156
|
+
"weightage": obj.get("weightage")
|
|
157
|
+
})
|
|
158
|
+
return _obj
|
|
159
|
+
|
|
160
|
+
|
|
@@ -0,0 +1,192 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Catalog Control Plane API
|
|
5
|
+
|
|
6
|
+
No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 1.0
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
from __future__ import annotations
|
|
16
|
+
import pprint
|
|
17
|
+
import re # noqa: F401
|
|
18
|
+
import json
|
|
19
|
+
|
|
20
|
+
from datetime import datetime
|
|
21
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr
|
|
22
|
+
from typing import Any, ClassVar, Dict, List, Optional, Union
|
|
23
|
+
from acceldata.models.api.catalog.item import Item
|
|
24
|
+
from acceldata.models.api.catalog.item_segment import ItemSegment
|
|
25
|
+
from acceldata.models.api.catalog.root_cause_analysis import RootCauseAnalysis
|
|
26
|
+
from acceldata.models.api.catalog.rule_threshold_configuration import RuleThresholdConfiguration
|
|
27
|
+
from typing import Optional, Set
|
|
28
|
+
from typing_extensions import Self
|
|
29
|
+
from pydantic_core import to_jsonable_python
|
|
30
|
+
|
|
31
|
+
class ItemExecution(BaseModel):
|
|
32
|
+
"""
|
|
33
|
+
ItemExecution
|
|
34
|
+
""" # noqa: E501
|
|
35
|
+
business_item_id: Optional[StrictInt] = Field(default=None, alias="businessItemId")
|
|
36
|
+
error: Optional[StrictStr] = None
|
|
37
|
+
execution_id: StrictInt = Field(alias="executionId")
|
|
38
|
+
execution_inputs: Optional[Dict[str, Any]] = Field(default=None, alias="executionInputs")
|
|
39
|
+
finished_at: Optional[datetime] = Field(default=None, alias="finishedAt")
|
|
40
|
+
id: Optional[StrictInt] = None
|
|
41
|
+
is_warning: StrictBool = Field(alias="isWarning")
|
|
42
|
+
item: Optional[Item] = None
|
|
43
|
+
rca: Optional[List[RootCauseAnalysis]] = None
|
|
44
|
+
result: Optional[StrictStr] = None
|
|
45
|
+
result_percentage: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, alias="resultPercentage")
|
|
46
|
+
rows_failed: Optional[StrictInt] = Field(default=None, alias="rowsFailed")
|
|
47
|
+
rows_scanned: Optional[StrictInt] = Field(default=None, alias="rowsScanned")
|
|
48
|
+
rows_warning: Optional[StrictInt] = Field(default=None, alias="rowsWarning")
|
|
49
|
+
rule_item_id: StrictInt = Field(alias="ruleItemId")
|
|
50
|
+
segment_hash: Optional[StrictStr] = Field(default=None, alias="segmentHash")
|
|
51
|
+
segments: Optional[List[ItemSegment]] = None
|
|
52
|
+
started_at: datetime = Field(alias="startedAt")
|
|
53
|
+
status: Optional[StrictStr] = None
|
|
54
|
+
threshold: Union[StrictFloat, StrictInt]
|
|
55
|
+
threshold_config: Optional[RuleThresholdConfiguration] = Field(default=None, alias="thresholdConfig")
|
|
56
|
+
value: Optional[StrictStr] = None
|
|
57
|
+
weightage: Union[StrictFloat, StrictInt]
|
|
58
|
+
__properties: ClassVar[List[str]] = ["businessItemId", "error", "executionId", "executionInputs", "finishedAt", "id", "isWarning", "item", "rca", "result", "resultPercentage", "rowsFailed", "rowsScanned", "rowsWarning", "ruleItemId", "segmentHash", "segments", "startedAt", "status", "threshold", "thresholdConfig", "value", "weightage"]
|
|
59
|
+
|
|
60
|
+
model_config = ConfigDict(
|
|
61
|
+
validate_by_name=True,
|
|
62
|
+
validate_by_alias=True,
|
|
63
|
+
validate_assignment=True,
|
|
64
|
+
protected_namespaces=(),
|
|
65
|
+
)
|
|
66
|
+
|
|
67
|
+
|
|
68
|
+
def to_str(self) -> str:
|
|
69
|
+
"""Returns the string representation of the model using alias"""
|
|
70
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
71
|
+
|
|
72
|
+
def to_json(self) -> str:
|
|
73
|
+
"""Returns the JSON representation of the model using alias"""
|
|
74
|
+
return json.dumps(to_jsonable_python(self.to_dict()))
|
|
75
|
+
|
|
76
|
+
@classmethod
|
|
77
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
78
|
+
"""Create an instance of ItemExecution from a JSON string"""
|
|
79
|
+
return cls.from_dict(json.loads(json_str))
|
|
80
|
+
|
|
81
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
82
|
+
"""Return the dictionary representation of the model using alias.
|
|
83
|
+
|
|
84
|
+
This has the following differences from calling pydantic's
|
|
85
|
+
`self.model_dump(by_alias=True)`:
|
|
86
|
+
|
|
87
|
+
* `None` is only added to the output dict for nullable fields that
|
|
88
|
+
were set at model initialization. Other fields with value `None`
|
|
89
|
+
are ignored.
|
|
90
|
+
"""
|
|
91
|
+
excluded_fields: Set[str] = set([
|
|
92
|
+
])
|
|
93
|
+
|
|
94
|
+
_dict = self.model_dump(
|
|
95
|
+
by_alias=True,
|
|
96
|
+
exclude=excluded_fields,
|
|
97
|
+
exclude_none=True,
|
|
98
|
+
)
|
|
99
|
+
# override the default output from pydantic by calling `to_dict()` of item
|
|
100
|
+
if self.item:
|
|
101
|
+
_dict['item'] = self.item.to_dict()
|
|
102
|
+
# override the default output from pydantic by calling `to_dict()` of each item in rca (list)
|
|
103
|
+
_items = []
|
|
104
|
+
if self.rca:
|
|
105
|
+
for _item_rca in self.rca:
|
|
106
|
+
if _item_rca:
|
|
107
|
+
_items.append(_item_rca.to_dict())
|
|
108
|
+
_dict['rca'] = _items
|
|
109
|
+
# override the default output from pydantic by calling `to_dict()` of each item in segments (list)
|
|
110
|
+
_items = []
|
|
111
|
+
if self.segments:
|
|
112
|
+
for _item_segments in self.segments:
|
|
113
|
+
if _item_segments:
|
|
114
|
+
_items.append(_item_segments.to_dict())
|
|
115
|
+
_dict['segments'] = _items
|
|
116
|
+
# override the default output from pydantic by calling `to_dict()` of threshold_config
|
|
117
|
+
if self.threshold_config:
|
|
118
|
+
_dict['thresholdConfig'] = self.threshold_config.to_dict()
|
|
119
|
+
# set to None if error (nullable) is None
|
|
120
|
+
# and model_fields_set contains the field
|
|
121
|
+
if self.error is None and "error" in self.model_fields_set:
|
|
122
|
+
_dict['error'] = None
|
|
123
|
+
|
|
124
|
+
# set to None if rca (nullable) is None
|
|
125
|
+
# and model_fields_set contains the field
|
|
126
|
+
if self.rca is None and "rca" in self.model_fields_set:
|
|
127
|
+
_dict['rca'] = None
|
|
128
|
+
|
|
129
|
+
# set to None if result (nullable) is None
|
|
130
|
+
# and model_fields_set contains the field
|
|
131
|
+
if self.result is None and "result" in self.model_fields_set:
|
|
132
|
+
_dict['result'] = None
|
|
133
|
+
|
|
134
|
+
# set to None if segment_hash (nullable) is None
|
|
135
|
+
# and model_fields_set contains the field
|
|
136
|
+
if self.segment_hash is None and "segment_hash" in self.model_fields_set:
|
|
137
|
+
_dict['segmentHash'] = None
|
|
138
|
+
|
|
139
|
+
# set to None if segments (nullable) is None
|
|
140
|
+
# and model_fields_set contains the field
|
|
141
|
+
if self.segments is None and "segments" in self.model_fields_set:
|
|
142
|
+
_dict['segments'] = None
|
|
143
|
+
|
|
144
|
+
# set to None if status (nullable) is None
|
|
145
|
+
# and model_fields_set contains the field
|
|
146
|
+
if self.status is None and "status" in self.model_fields_set:
|
|
147
|
+
_dict['status'] = None
|
|
148
|
+
|
|
149
|
+
# set to None if value (nullable) is None
|
|
150
|
+
# and model_fields_set contains the field
|
|
151
|
+
if self.value is None and "value" in self.model_fields_set:
|
|
152
|
+
_dict['value'] = None
|
|
153
|
+
|
|
154
|
+
return _dict
|
|
155
|
+
|
|
156
|
+
@classmethod
|
|
157
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
158
|
+
"""Create an instance of ItemExecution from a dict"""
|
|
159
|
+
if obj is None:
|
|
160
|
+
return None
|
|
161
|
+
|
|
162
|
+
if not isinstance(obj, dict):
|
|
163
|
+
return cls.model_validate(obj)
|
|
164
|
+
|
|
165
|
+
_obj = cls.model_validate({
|
|
166
|
+
"businessItemId": obj.get("businessItemId"),
|
|
167
|
+
"error": obj.get("error"),
|
|
168
|
+
"executionId": obj.get("executionId"),
|
|
169
|
+
"executionInputs": obj.get("executionInputs"),
|
|
170
|
+
"finishedAt": obj.get("finishedAt"),
|
|
171
|
+
"id": obj.get("id"),
|
|
172
|
+
"isWarning": obj.get("isWarning"),
|
|
173
|
+
"item": Item.from_dict(obj["item"]) if obj.get("item") is not None else None,
|
|
174
|
+
"rca": [RootCauseAnalysis.from_dict(_item) for _item in obj["rca"]] if obj.get("rca") is not None else None,
|
|
175
|
+
"result": obj.get("result"),
|
|
176
|
+
"resultPercentage": obj.get("resultPercentage"),
|
|
177
|
+
"rowsFailed": obj.get("rowsFailed"),
|
|
178
|
+
"rowsScanned": obj.get("rowsScanned"),
|
|
179
|
+
"rowsWarning": obj.get("rowsWarning"),
|
|
180
|
+
"ruleItemId": obj.get("ruleItemId"),
|
|
181
|
+
"segmentHash": obj.get("segmentHash"),
|
|
182
|
+
"segments": [ItemSegment.from_dict(_item) for _item in obj["segments"]] if obj.get("segments") is not None else None,
|
|
183
|
+
"startedAt": obj.get("startedAt"),
|
|
184
|
+
"status": obj.get("status"),
|
|
185
|
+
"threshold": obj.get("threshold"),
|
|
186
|
+
"thresholdConfig": RuleThresholdConfiguration.from_dict(obj["thresholdConfig"]) if obj.get("thresholdConfig") is not None else None,
|
|
187
|
+
"value": obj.get("value"),
|
|
188
|
+
"weightage": obj.get("weightage")
|
|
189
|
+
})
|
|
190
|
+
return _obj
|
|
191
|
+
|
|
192
|
+
|
|
@@ -0,0 +1,131 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Catalog Control Plane API
|
|
5
|
+
|
|
6
|
+
No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 1.0
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
from __future__ import annotations
|
|
16
|
+
import pprint
|
|
17
|
+
import re # noqa: F401
|
|
18
|
+
import json
|
|
19
|
+
|
|
20
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictFloat, StrictInt, StrictStr
|
|
21
|
+
from typing import Any, ClassVar, Dict, List, Optional, Union
|
|
22
|
+
from acceldata.models.api.catalog.rule_threshold_configuration import RuleThresholdConfiguration
|
|
23
|
+
from typing import Optional, Set
|
|
24
|
+
from typing_extensions import Self
|
|
25
|
+
from pydantic_core import to_jsonable_python
|
|
26
|
+
|
|
27
|
+
class ItemSegment(BaseModel):
|
|
28
|
+
"""
|
|
29
|
+
ItemSegment
|
|
30
|
+
""" # noqa: E501
|
|
31
|
+
error: Optional[StrictStr] = None
|
|
32
|
+
execution_id: StrictInt = Field(alias="executionId")
|
|
33
|
+
execution_inputs: Optional[Dict[str, Any]] = Field(default=None, alias="executionInputs")
|
|
34
|
+
id: Optional[StrictInt] = None
|
|
35
|
+
item_execution_id: StrictInt = Field(alias="itemExecutionId")
|
|
36
|
+
result: Optional[Union[StrictFloat, StrictInt]] = None
|
|
37
|
+
rows_failed: Optional[StrictInt] = Field(default=None, alias="rowsFailed")
|
|
38
|
+
rows_scanned: StrictInt = Field(alias="rowsScanned")
|
|
39
|
+
rule_item_id: StrictInt = Field(alias="ruleItemId")
|
|
40
|
+
segment_hash: StrictStr = Field(alias="segmentHash")
|
|
41
|
+
status: Optional[StrictStr] = None
|
|
42
|
+
threshold_config: Optional[RuleThresholdConfiguration] = Field(default=None, alias="thresholdConfig")
|
|
43
|
+
value: Optional[StrictStr] = None
|
|
44
|
+
__properties: ClassVar[List[str]] = ["error", "executionId", "executionInputs", "id", "itemExecutionId", "result", "rowsFailed", "rowsScanned", "ruleItemId", "segmentHash", "status", "thresholdConfig", "value"]
|
|
45
|
+
|
|
46
|
+
model_config = ConfigDict(
|
|
47
|
+
validate_by_name=True,
|
|
48
|
+
validate_by_alias=True,
|
|
49
|
+
validate_assignment=True,
|
|
50
|
+
protected_namespaces=(),
|
|
51
|
+
)
|
|
52
|
+
|
|
53
|
+
|
|
54
|
+
def to_str(self) -> str:
|
|
55
|
+
"""Returns the string representation of the model using alias"""
|
|
56
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
57
|
+
|
|
58
|
+
def to_json(self) -> str:
|
|
59
|
+
"""Returns the JSON representation of the model using alias"""
|
|
60
|
+
return json.dumps(to_jsonable_python(self.to_dict()))
|
|
61
|
+
|
|
62
|
+
@classmethod
|
|
63
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
64
|
+
"""Create an instance of ItemSegment from a JSON string"""
|
|
65
|
+
return cls.from_dict(json.loads(json_str))
|
|
66
|
+
|
|
67
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
68
|
+
"""Return the dictionary representation of the model using alias.
|
|
69
|
+
|
|
70
|
+
This has the following differences from calling pydantic's
|
|
71
|
+
`self.model_dump(by_alias=True)`:
|
|
72
|
+
|
|
73
|
+
* `None` is only added to the output dict for nullable fields that
|
|
74
|
+
were set at model initialization. Other fields with value `None`
|
|
75
|
+
are ignored.
|
|
76
|
+
"""
|
|
77
|
+
excluded_fields: Set[str] = set([
|
|
78
|
+
])
|
|
79
|
+
|
|
80
|
+
_dict = self.model_dump(
|
|
81
|
+
by_alias=True,
|
|
82
|
+
exclude=excluded_fields,
|
|
83
|
+
exclude_none=True,
|
|
84
|
+
)
|
|
85
|
+
# override the default output from pydantic by calling `to_dict()` of threshold_config
|
|
86
|
+
if self.threshold_config:
|
|
87
|
+
_dict['thresholdConfig'] = self.threshold_config.to_dict()
|
|
88
|
+
# set to None if error (nullable) is None
|
|
89
|
+
# and model_fields_set contains the field
|
|
90
|
+
if self.error is None and "error" in self.model_fields_set:
|
|
91
|
+
_dict['error'] = None
|
|
92
|
+
|
|
93
|
+
# set to None if status (nullable) is None
|
|
94
|
+
# and model_fields_set contains the field
|
|
95
|
+
if self.status is None and "status" in self.model_fields_set:
|
|
96
|
+
_dict['status'] = None
|
|
97
|
+
|
|
98
|
+
# set to None if value (nullable) is None
|
|
99
|
+
# and model_fields_set contains the field
|
|
100
|
+
if self.value is None and "value" in self.model_fields_set:
|
|
101
|
+
_dict['value'] = None
|
|
102
|
+
|
|
103
|
+
return _dict
|
|
104
|
+
|
|
105
|
+
@classmethod
|
|
106
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
107
|
+
"""Create an instance of ItemSegment from a dict"""
|
|
108
|
+
if obj is None:
|
|
109
|
+
return None
|
|
110
|
+
|
|
111
|
+
if not isinstance(obj, dict):
|
|
112
|
+
return cls.model_validate(obj)
|
|
113
|
+
|
|
114
|
+
_obj = cls.model_validate({
|
|
115
|
+
"error": obj.get("error"),
|
|
116
|
+
"executionId": obj.get("executionId"),
|
|
117
|
+
"executionInputs": obj.get("executionInputs"),
|
|
118
|
+
"id": obj.get("id"),
|
|
119
|
+
"itemExecutionId": obj.get("itemExecutionId"),
|
|
120
|
+
"result": obj.get("result"),
|
|
121
|
+
"rowsFailed": obj.get("rowsFailed"),
|
|
122
|
+
"rowsScanned": obj.get("rowsScanned"),
|
|
123
|
+
"ruleItemId": obj.get("ruleItemId"),
|
|
124
|
+
"segmentHash": obj.get("segmentHash"),
|
|
125
|
+
"status": obj.get("status"),
|
|
126
|
+
"thresholdConfig": RuleThresholdConfiguration.from_dict(obj["thresholdConfig"]) if obj.get("thresholdConfig") is not None else None,
|
|
127
|
+
"value": obj.get("value")
|
|
128
|
+
})
|
|
129
|
+
return _obj
|
|
130
|
+
|
|
131
|
+
|