Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add index to group_membership to improve performance
[#129600177] https://www.pivotaltracker.com/story/show/129600177 #436
- Loading branch information
Showing
4 changed files
with
62 additions
and
5 deletions.
There are no files selected for viewing
15 changes: 15 additions & 0 deletions
15
...rg/cloudfoundry/identity/uaa/db/hsqldb/V3_9_0__Add_Index_To_GroupMembership_Member_Id.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,15 @@ | ||
-- | ||
-- Cloud Foundry | ||
-- Copyright (c) [2015] Pivotal Software, Inc. All Rights Reserved. | ||
-- | ||
-- This product is licensed to you under the Apache License, Version 2.0 (the "License"). | ||
-- You may not use this product except in compliance with the License. | ||
-- | ||
-- This product includes a number of subcomponents with | ||
-- separate copyright notices and license terms. Your use of these | ||
-- subcomponents is subject to the terms and conditions of the | ||
-- subcomponent's license, as noted in the LICENSE file. | ||
-- | ||
|
||
-- HSQLDB does not support indices with function - but we create this one to keep it in synch with the other schemas | ||
CREATE INDEX group_membership_perf_idx ON group_membership(member_id); |
16 changes: 16 additions & 0 deletions
16
...org/cloudfoundry/identity/uaa/db/mysql/V3_9_0__Add_Index_To_GroupMembership_Member_Id.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,16 @@ | ||
-- | ||
-- Cloud Foundry | ||
-- Copyright (c) [2016] Pivotal Software, Inc. All Rights Reserved. | ||
-- | ||
-- This product is licensed to you under the Apache License, Version 2.0 (the "License"). | ||
-- You may not use this product except in compliance with the License. | ||
-- | ||
-- This product includes a number of subcomponents with | ||
-- separate copyright notices and license terms. Your use of these | ||
-- subcomponents is subject to the terms and conditions of the | ||
-- subcomponent's license, as noted in the LICENSE file. | ||
-- | ||
|
||
|
||
-- in mysql we turn off lower function during queries | ||
CREATE INDEX group_membership_perf_idx ON group_membership(member_id); |
16 changes: 16 additions & 0 deletions
16
...loudfoundry/identity/uaa/db/postgresql/V3_9_0__Add_Index_To_GroupMembership_Member_Id.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,16 @@ | ||
-- | ||
-- Cloud Foundry | ||
-- Copyright (c) [2016] Pivotal Software, Inc. All Rights Reserved. | ||
-- | ||
-- This product is licensed to you under the Apache License, Version 2.0 (the "License"). | ||
-- You may not use this product except in compliance with the License. | ||
-- | ||
-- This product includes a number of subcomponents with | ||
-- separate copyright notices and license terms. Your use of these | ||
-- subcomponents is subject to the terms and conditions of the | ||
-- subcomponent's license, as noted in the LICENSE file. | ||
-- | ||
|
||
|
||
-- create an index to match the query | ||
CREATE INDEX group_membership_perf_idx ON group_membership(LOWER(member_id)); |
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