U4-10385 - Examine indexing performance bottleneck: IUserService.GetProfileById which is not cached

Created by Shannon Deminick 05 Sep 2017, 06:30:38 Updated by Claus Jensen 06 Sep 2017, 07:12:32

Tags: Backport Unscheduled

Relates to: U4-10374

Subtask of: UAASSCRUM-1073

This causes N+1 queries and is a hotspot during indexing. This method is a fast SQL query but it is not cached and when there are a lot of nodes to index, this causes quite a lot of queries unnecessarily

Options:

  • Make GetProfileById actually call Get(int id) on user repo which is a cached user and then cast to IUserProfile
  • Add an IsolatedCache call into the GetProfileById method in the user repo
  • Add a cache to the EntityXmlSerializer ctor to store these profiles in during processing which would be contextual and cleared when the instance of this serializer is GC'd

Comments

Shannon Deminick 05 Sep 2017, 06:43:47

Part of this PR http://issues.umbraco.org/issue/U4-10374


Priority: Normal

Type: Bug

State: Fixed

Assignee:

Difficulty: Normal

Category:

Backwards Compatible: True

Fix Submitted:

Affected versions:

Due in version: 7.7.0

Sprint: Sprint 67

Story Points: 0.5

Cycle: