Skip to content

Use indexed query in blogs_table_exists().#80

Open
boonebgorges wants to merge 1 commit into
humanmade:masterfrom
cuny-academic-commons:indexed-blog-exists-query
Open

Use indexed query in blogs_table_exists().#80
boonebgorges wants to merge 1 commit into
humanmade:masterfrom
cuny-academic-commons:indexed-blog-exists-query

Conversation

@boonebgorges
Copy link
Copy Markdown

In #77, static caching was added for the wp_blogs existence query. Thanks very much for that change - it's a problem we had to hotfix around in the past.

The current PR suggests a further streamlining. SHOW TABLES LIKE 'wp_blogs' is slow because it results in an unindexed query against INFORMATION_SCHEMA. If we add a TABLE_SCHEMA clause, we can leverage the indexes, and the query is dramatically faster. (Alternatively, you could use DESCRIBE wp_blogs, which looks only at tablespace.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant