Remove MD queries in ElggFile::getFilestore() #9138

Closed
mrclay opened this Issue Nov 24, 2015 · 1 comment

Comments

Projects
None yet
1 participant
@mrclay
Member

mrclay commented Nov 24, 2015

Use metadata cache to pull filestore:: metadata.

@mrclay mrclay added the performance label Nov 24, 2015

@mrclay mrclay changed the title from ElggFile::getFilestore to Remove MD queries in ElggFile::getFilestore() Nov 24, 2015

mrclay added a commit to mrclay/Elgg-leaf that referenced this issue Dec 2, 2015

perf(files): ElggFile no longer queries metadata for filestore data
For each persisted `ElggFile` entity loaded, `getFilestore()` used to be called
on instantiation, which required a separate metadata query.

This refactors so `getFilestore()` is called only when needed, and typically when
Elgg's metadata cache has already been populated for the entity.

Fixes #9138
@mrclay

This comment has been minimized.

Show comment
Hide comment
Member

mrclay commented Dec 2, 2015

PR #9181

mrclay added a commit to mrclay/Elgg-leaf that referenced this issue Dec 2, 2015

perf(files): ElggFile no longer queries metadata for filestore data
For each persisted `ElggFile` entity loaded, `getFilestore()` used to be called
on instantiation, which required a separate metadata query.

This refactors so `getFilestore()` is called only when needed, and typically when
Elgg's metadata cache has already been populated for the entity.

Fixes #9138

mrclay added a commit to mrclay/Elgg-leaf that referenced this issue Dec 2, 2015

perf(files): ElggFile no longer queries metadata for filestore data
For each persisted `ElggFile` entity loaded, `getFilestore()` used to be called
on instantiation, which required a separate metadata query.

This refactors so `getFilestore()` is called only when needed, and typically when
Elgg's metadata cache has already been populated for the entity.

Fixes #9138

@mrclay mrclay closed this in #9181 Dec 4, 2015

thehereward added a commit to thehereward/Elgg that referenced this issue Dec 6, 2015

perf(files): ElggFile no longer queries metadata for filestore data
For each persisted `ElggFile` entity loaded, `getFilestore()` used to be called
on instantiation, which required a separate metadata query.

This refactors so `getFilestore()` is called only when needed, and typically when
Elgg's metadata cache has already been populated for the entity.

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