Details
-
Improvement
-
Status: Closed
-
Major
-
Resolution: Incomplete
-
None
Description
We have some (very commonly hit) bits of code that need to read configs (for example), and thus need higher privileges. At one point, we were advised to make short-lived service sessions to handle this. We did this and found our
performance was absolutely abysmal. We're on our 3rd bottleneck that we
are working through. They have all pointed to session creation. Maybe each
creation isn't too bad, but in aggregate, it's much slower than, for
example, the actual reads or anything else.
I was able to make the code usually avoid session creation in the first 2
cases, but earlier this week we hit the third example where the answer seems to
be one of 1) make creating sessions ignorably fast even when they are
created a lot 2) cache whatever read is requiring the escalation and clean
up in event listeners (those listeners will invariably have to listen to
non-local events, but the events should be uncommon so far) 3) long-lived
sessions used for reads across threads.
Per Michael Duerig, #1 is the goal. Can we see if the current situation can be improved? Because it isn't ignorably fast today. Thanks!