diff --git a/classes/OpenXdmod/Shredder/aCloud.php b/classes/OpenXdmod/Shredder/aCloud.php index 24e110d6a1..dab3ed2ce7 100644 --- a/classes/OpenXdmod/Shredder/aCloud.php +++ b/classes/OpenXdmod/Shredder/aCloud.php @@ -50,7 +50,7 @@ public function shredDirectory($directory) return false; } - Utilities::runEtlPipeline(array('jobs-common','jobs-cloud-common','ingest-organizations', 'ingest-resource-types', 'ingest-resources'), $this->logger); + Utilities::runEtlPipeline(array('jobs-common', 'ingest-organizations', 'ingest-resource-types', 'ingest-resources', 'jobs-cloud-common'), $this->logger); Utilities::runEtlPipeline( $this->etlPipelines, $this->logger, diff --git a/configuration/etl/etl_action_defs.d/cloud_common/initialize_unknown_dimension_values.json b/configuration/etl/etl_action_defs.d/cloud_common/initialize_unknown_dimension_values.json index 27fb92c261..a54316b1f1 100644 --- a/configuration/etl/etl_action_defs.d/cloud_common/initialize_unknown_dimension_values.json +++ b/configuration/etl/etl_action_defs.d/cloud_common/initialize_unknown_dimension_values.json @@ -40,7 +40,7 @@ "source_query": { "records": { "resource_id": "rf.id", - "unknown_id": -1, + "unknown_id": 1, "unknown_key": "'unknown'", "unknown_display": "'Unknown'" }, diff --git a/configuration/etl/etl_tables.d/cloud_common/account.json b/configuration/etl/etl_tables.d/cloud_common/account.json index 3ead2def06..dda57f128f 100644 --- a/configuration/etl/etl_tables.d/cloud_common/account.json +++ b/configuration/etl/etl_tables.d/cloud_common/account.json @@ -41,6 +41,7 @@ "#": "is calculated as MAX(auto_increment_column) + 1 WHERE prefix=given-prefix. This is", "#": "useful when you want to put data into ordered groups.", "#": "See [MyISAM Notes](https://dev.mysql.com/doc/refman/5.7/en/example-auto-increment.html)", + "#": "and https://www.ryadel.com/en/mysql-two-columns-primary-key-with-auto-increment/", "indexes": [ { @@ -52,14 +53,10 @@ "is_unique": true }, { - "#": "The ordering of autoincrement id + resource_id is explicit and mandatory.", - "#": "This is because MyISAM mandates that composite keys containing an", - "#": "autoincrement value have said value as the first key.", - "#": "See the following for details: https://www.ryadel.com/en/mysql-two-columns-primary-key-with-auto-increment/", "name": "autoincrement_key", "columns": [ - "account_id", - "resource_id" + "resource_id", + "account_id" ], "is_unique": true }, diff --git a/configuration/etl/etl_tables.d/cloud_common/asset.json b/configuration/etl/etl_tables.d/cloud_common/asset.json index 309992414a..d1025c7c79 100644 --- a/configuration/etl/etl_tables.d/cloud_common/asset.json +++ b/configuration/etl/etl_tables.d/cloud_common/asset.json @@ -95,8 +95,8 @@ "name": "autoincrement_key", "columns": [ - "asset_id", - "resource_id" + "resource_id", + "asset_id" ], "is_unique": true } diff --git a/configuration/etl/etl_tables.d/cloud_common/avail_zone.json b/configuration/etl/etl_tables.d/cloud_common/avail_zone.json index 2b759f17d2..529aa35ac0 100644 --- a/configuration/etl/etl_tables.d/cloud_common/avail_zone.json +++ b/configuration/etl/etl_tables.d/cloud_common/avail_zone.json @@ -64,8 +64,8 @@ "#": "See the following for details: https://www.ryadel.com/en/mysql-two-columns-primary-key-with-auto-increment/", "name": "autoincrement_key", "columns": [ - "avail_zone_id", - "resource_id" + "resource_id", + "avail_zone_id" ], "is_unique": true } diff --git a/configuration/etl/etl_tables.d/cloud_common/host.json b/configuration/etl/etl_tables.d/cloud_common/host.json index 7732ee3379..e011a2843c 100644 --- a/configuration/etl/etl_tables.d/cloud_common/host.json +++ b/configuration/etl/etl_tables.d/cloud_common/host.json @@ -45,15 +45,11 @@ "#": "is calculated as MAX(auto_increment_column) + 1 WHERE prefix=given-prefix. This is", "#": "useful when you want to put data into ordered groups.", "#": "See [MyISAM Notes](https://dev.mysql.com/doc/refman/5.7/en/example-auto-increment.html)", - - "#": "The ordering of autoincrement id + resource_id is explicit and mandatory.", - "#": "This is because MyISAM mandates that composite keys containing an", - "#": "autoincrement value have said value as the first key.", - "#": "See the following for details: https://www.ryadel.com/en/mysql-two-columns-primary-key-with-auto-increment/", + "#": "and https://www.ryadel.com/en/mysql-two-columns-primary-key-with-auto-increment/", "name": "autoincrement_key", "columns": [ - "host_id", - "resource_id" + "resource_id", + "host_id" ], "is_unique": true } diff --git a/configuration/etl/etl_tables.d/cloud_common/image.json b/configuration/etl/etl_tables.d/cloud_common/image.json index 2eeb8da9f5..6ed413efe0 100644 --- a/configuration/etl/etl_tables.d/cloud_common/image.json +++ b/configuration/etl/etl_tables.d/cloud_common/image.json @@ -45,15 +45,11 @@ "#": "is calculated as MAX(auto_increment_column) + 1 WHERE prefix=given-prefix. This is", "#": "useful when you want to put data into ordered groups.", "#": "See [MyISAM Notes](https://dev.mysql.com/doc/refman/5.7/en/example-auto-increment.html)", - - "#": "The ordering of autoincrement id + resource_id is explicit and mandatory.", - "#": "This is because MyISAM mandates that composite keys containing an", - "#": "autoincrement value have said value as the first key.", - "#": "See the following for details: https://www.ryadel.com/en/mysql-two-columns-primary-key-with-auto-increment/", + "#": "https://www.ryadel.com/en/mysql-two-columns-primary-key-with-auto-increment/", "name": "autoincrement_key", "columns": [ - "image_id", - "resource_id" + "resource_id", + "image_id" ], "is_unique": true } diff --git a/configuration/etl/etl_tables.d/cloud_common/instance.json b/configuration/etl/etl_tables.d/cloud_common/instance.json index 7d4ef57fe7..52e95f9906 100644 --- a/configuration/etl/etl_tables.d/cloud_common/instance.json +++ b/configuration/etl/etl_tables.d/cloud_common/instance.json @@ -59,15 +59,11 @@ "#": "is calculated as MAX(auto_increment_column) + 1 WHERE prefix=given-prefix. This is", "#": "useful when you want to put data into ordered groups.", "#": "See [MyISAM Notes](https://dev.mysql.com/doc/refman/5.7/en/example-auto-increment.html)", - - "#": "The ordering of autoincrement id + resource_id is explicit and mandatory.", - "#": "This is because MyISAM mandates that composite keys containing an", - "#": "autoincrement value have said value as the first key.", - "#": "See the following for details: https://www.ryadel.com/en/mysql-two-columns-primary-key-with-auto-increment/", + "#": "https://www.ryadel.com/en/mysql-two-columns-primary-key-with-auto-increment/", "name": "increment_key", "columns": [ - "instance_id", - "resource_id" + "resource_id", + "instance_id" ], "is_unique": true } diff --git a/configuration/etl/etl_tables.d/cloud_common/instance_type.json b/configuration/etl/etl_tables.d/cloud_common/instance_type.json index 7c37e866f9..f7d4e39e16 100644 --- a/configuration/etl/etl_tables.d/cloud_common/instance_type.json +++ b/configuration/etl/etl_tables.d/cloud_common/instance_type.json @@ -97,8 +97,8 @@ "name": "increment_key", "columns": [ - "instance_type_id", - "resource_id" + "resource_id", + "instance_type_id" ], "is_unique": true } diff --git a/configuration/etl/etl_tables.d/cloud_common/region.json b/configuration/etl/etl_tables.d/cloud_common/region.json index ff108e9863..cd04f915da 100644 --- a/configuration/etl/etl_tables.d/cloud_common/region.json +++ b/configuration/etl/etl_tables.d/cloud_common/region.json @@ -52,15 +52,11 @@ "#": "is calculated as MAX(auto_increment_column) + 1 WHERE prefix=given-prefix. This is", "#": "useful when you want to put data into ordered groups.", "#": "See [MyISAM Notes](https://dev.mysql.com/doc/refman/5.7/en/example-auto-increment.html)", - - "#": "The ordering of autoincrement id + resource_id is explicit and mandatory.", - "#": "This is because MyISAM mandates that composite keys containing an", - "#": "autoincrement value have said value as the first key.", - "#": "See the following for details: https://www.ryadel.com/en/mysql-two-columns-primary-key-with-auto-increment/", + "#": "https://www.ryadel.com/en/mysql-two-columns-primary-key-with-auto-increment/", "name": "autoincrement_key", "columns": [ - "region_id", - "resource_id" + "resource_id", + "region_id" ], "is_unique": true } diff --git a/open_xdmod/modules/xdmod/integration_tests/lib/Controllers/UsageExplorerTest.php b/open_xdmod/modules/xdmod/integration_tests/lib/Controllers/UsageExplorerTest.php index 6e89394f92..3127528b38 100644 --- a/open_xdmod/modules/xdmod/integration_tests/lib/Controllers/UsageExplorerTest.php +++ b/open_xdmod/modules/xdmod/integration_tests/lib/Controllers/UsageExplorerTest.php @@ -608,8 +608,8 @@ public function provideFilterIdLookup() 'realm' => 'Cloud', 'filters' => array( array( - array('project' => '2'), - array('project_filter' => '2'), + array('project' => '3'), + array('project_filter' => '3'), array('project_filter'=> '"zealous"') ) ), @@ -656,7 +656,7 @@ public function provideFilterIdLookup() 'realm' => 'Cloud', 'filters' => array( array( - array('project_filter' => '1,2,3'), + array('project_filter' => '2,3,4'), array('project_filter'=> '\'zealous\',\'youthful\',\'zen\'') ) ),