diff --git a/configuration/etl/etl_action_defs.d/cloud_generic/event_asset_root_volume.json b/configuration/etl/etl_action_defs.d/cloud_generic/event_asset_root_volume.json index da2c353245..f65a11ae06 100644 --- a/configuration/etl/etl_action_defs.d/cloud_generic/event_asset_root_volume.json +++ b/configuration/etl/etl_action_defs.d/cloud_generic/event_asset_root_volume.json @@ -19,10 +19,16 @@ }, "joins": [ + { + "name": "generic_cloud_staging_event", + "schema": "${SOURCE_SCHEMA}", + "alias": "staging" + }, { "name": "event", "schema": "${SOURCE_SCHEMA}", - "alias": "ev" + "alias": "ev", + "on": "ev.resource_id = staging.resource_id AND ev.instance_id = staging.instance_id AND ev.event_time_ts = staging.event_time_ts AND ev.event_type_id = staging.event_type_id" }, { "name": "instance", diff --git a/configuration/etl/etl_action_defs.d/cloud_openstack/event_asset_root_volume.json b/configuration/etl/etl_action_defs.d/cloud_openstack/event_asset_root_volume.json index 64e640c878..4d575536f3 100644 --- a/configuration/etl/etl_action_defs.d/cloud_openstack/event_asset_root_volume.json +++ b/configuration/etl/etl_action_defs.d/cloud_openstack/event_asset_root_volume.json @@ -19,10 +19,16 @@ }, "joins": [ + { + "name": "openstack_staging_event", + "schema": "${SOURCE_SCHEMA}", + "alias": "staging" + }, { "name": "event", "schema": "${SOURCE_SCHEMA}", - "alias": "ev" + "alias": "ev", + "on": "ev.resource_id = staging.resource_id AND ev.instance_id = staging.instance_id AND ev.event_time_ts = staging.event_time_ts AND ev.event_type_id = staging.event_type_id" }, { "name": "instance", diff --git a/configuration/etl/etl_tables.d/cloud_common/asset.json b/configuration/etl/etl_tables.d/cloud_common/asset.json index d1025c7c79..e0009bd84d 100644 --- a/configuration/etl/etl_tables.d/cloud_common/asset.json +++ b/configuration/etl/etl_tables.d/cloud_common/asset.json @@ -99,6 +99,14 @@ "asset_id" ], "is_unique": true + }, + { + "name": "idx_provider_identifier", + "columns": [ + "resource_id", + "provider_identifier" + ], + "is_unique": false } ] }