-
Notifications
You must be signed in to change notification settings - Fork 29
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add indexes to db migration scripts (#777)
* Add indexes to db migration scripts * Rename all scripts * Update latestMigrationVersion value
- Loading branch information
1 parent
fec5ddc
commit afb5571
Showing
29 changed files
with
76 additions
and
48 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 2 additions & 0 deletions
2
storage/postgres/migrations/20220711100000_broker_labels_broker_id_index.down.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
DROP INDEX IF EXISTS broker_labels_broker_id_index; | ||
|
3 changes: 3 additions & 0 deletions
3
storage/postgres/migrations/20220711100000_broker_labels_broker_id_index.up.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
CREATE INDEX IF NOT EXISTS broker_labels_broker_id_index | ||
on broker_labels (broker_id); | ||
|
1 change: 1 addition & 0 deletions
1
...age/postgres/migrations/20220711110000_notification_labels_notification_id_index.down.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
DROP INDEX IF EXISTS notification_labels_notification_id_index; |
2 changes: 2 additions & 0 deletions
2
storage/postgres/migrations/20220711110000_notification_labels_notification_id_index.up.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
CREATE INDEX IF NOT EXISTS notification_labels_notification_id_index | ||
on notification_labels (notification_id); |
2 changes: 2 additions & 0 deletions
2
storage/postgres/migrations/20220711120000_operation_labels_operation_id_index.down.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
DROP INDEX IF EXISTS operation_labels_operation_id_index; | ||
|
3 changes: 3 additions & 0 deletions
3
storage/postgres/migrations/20220711120000_operation_labels_operation_id_index.up.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
CREATE INDEX IF NOT EXISTS operation_labels_operation_id_index | ||
on operation_labels (operation_id); | ||
|
2 changes: 2 additions & 0 deletions
2
storage/postgres/migrations/20220711130000_operations_resource_id_index.down.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
DROP INDEX IF EXISTS operations_resource_id_index; | ||
|
3 changes: 3 additions & 0 deletions
3
storage/postgres/migrations/20220711130000_operations_resource_id_index.up.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
CREATE INDEX IF NOT EXISTS operations_resource_id_index | ||
on operations (resource_id); | ||
|
1 change: 1 addition & 0 deletions
1
storage/postgres/migrations/20220711140000_platform_labels_platform_id_index.down.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
DROP INDEX IF EXISTS platform_labels_platform_id_index; |
2 changes: 2 additions & 0 deletions
2
storage/postgres/migrations/20220711140000_platform_labels_platform_id_index.up.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
CREATE INDEX IF NOT EXISTS platform_labels_platform_id_index | ||
on platform_labels (platform_id); |
1 change: 1 addition & 0 deletions
1
...stgres/migrations/20220711150000_service_binding_labels_service_binding_id_index.down.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
DROP INDEX IF EXISTS service_binding_labels_service_binding_id_index; |
2 changes: 2 additions & 0 deletions
2
...postgres/migrations/20220711150000_service_binding_labels_service_binding_id_index.up.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
CREATE INDEX IF NOT EXISTS service_binding_labels_service_binding_id_index | ||
on service_binding_labels (service_binding_id); |
1 change: 1 addition & 0 deletions
1
storage/postgres/migrations/20220711160000_service_instance_labels_key_val_index.down.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
DROP INDEX IF EXISTS service_instance_labels_key_val_index; |
2 changes: 2 additions & 0 deletions
2
storage/postgres/migrations/20220711160000_service_instance_labels_key_val_index.up.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
CREATE INDEX IF NOT EXISTS service_instance_labels_key_val_index | ||
on service_instance_labels (key, val); |
1 change: 1 addition & 0 deletions
1
...gres/migrations/20220711170000_service_instance_labels_service_instance_id_index.down.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
DROP INDEX IF EXISTS service_instance_labels_service_instance_id_index; |
2 changes: 2 additions & 0 deletions
2
...stgres/migrations/20220711170000_service_instance_labels_service_instance_id_index.up.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
CREATE INDEX IF NOT EXISTS service_instance_labels_service_instance_id_index | ||
on service_instance_labels (service_instance_id); |
2 changes: 2 additions & 0 deletions
2
storage/postgres/migrations/20220711171000_service_instances_service_plan_id_index.down.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
DROP INDEX IF EXISTS service_instances_service_plan_id_index; | ||
|
3 changes: 3 additions & 0 deletions
3
storage/postgres/migrations/20220711171000_service_instances_service_plan_id_index.up.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
CREATE INDEX IF NOT EXISTS service_instances_service_plan_id_index | ||
on service_instances (service_plan_id); | ||
|
2 changes: 2 additions & 0 deletions
2
...gres/migrations/20220711172000_service_offering_labels_service_offering_id_index.down.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
DROP INDEX IF EXISTS service_offering_labels_service_offering_id_index; | ||
|
3 changes: 3 additions & 0 deletions
3
...stgres/migrations/20220711172000_service_offering_labels_service_offering_id_index.up.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
CREATE INDEX IF NOT EXISTS service_offering_labels_service_offering_id_index | ||
on service_offering_labels (service_offering_id); | ||
|
2 changes: 2 additions & 0 deletions
2
storage/postgres/migrations/20220711173000_service_offerings_catalog_name_index.down.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
DROP INDEX IF EXISTS service_offerings_catalog_name_index; | ||
|
3 changes: 3 additions & 0 deletions
3
storage/postgres/migrations/20220711173000_service_offerings_catalog_name_index.up.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
CREATE INDEX IF NOT EXISTS service_offerings_catalog_name_index | ||
on service_offerings (catalog_name); | ||
|
1 change: 1 addition & 0 deletions
1
...age/postgres/migrations/20220711180000_service_plan_labels_service_plan_id_index.down.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
DROP INDEX IF EXISTS service_plan_labels_service_plan_id_index; |
2 changes: 2 additions & 0 deletions
2
storage/postgres/migrations/20220711180000_service_plan_labels_service_plan_id_index.up.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
CREATE INDEX IF NOT EXISTS service_plan_labels_service_plan_id_index | ||
on service_plan_labels (service_plan_id); |
1 change: 1 addition & 0 deletions
1
storage/postgres/migrations/20220711181000_service_plans_catalog_name_index.down.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
DROP INDEX IF EXISTS service_plans_catalog_name_index; |
2 changes: 2 additions & 0 deletions
2
storage/postgres/migrations/20220711181000_service_plans_catalog_name_index.up.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
CREATE INDEX IF NOT EXISTS service_plans_catalog_name_index | ||
on service_plans (catalog_name); |