You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Policy continues to dominate steady state operation #11003
Heap allocation of objects after about 2 minutes of hack/test-cmd.sh command on etcd3 with protobuf (where most of the object allocations from etcd have dropped out). 25m allocations total.
A non-trivial amount of CPU was in SetDefaults_PolicyRule on the SemanticDeepEqual which calls into reflection.
I added a metric for raw policy retrievals via the Registry (of each of the three types) and the early admin.sh test generated ~1.6k retrievals to the Registry, while 1k of ReadOnlyStorage and ~600 of Simulated.
Looks like every time we create a project we do 30-50 retrievals of the direct cluster policy and the same amount to simulated.
Do we need to do 30-50 of them (I assume 20 is the delete and 30 is the
create)?
Well, I haven't actually counted them. You have to pull all the rolebindings and then some of the roles. It's entirely possible its inefficient because someone made us use virtual objects which necessitated some pretty insane storage layers....
Activity
smarterclayton commentedon Sep 20, 2016
From a minute later at 38m total allocations, this time cumulatively sorted:
smarterclayton commentedon Sep 20, 2016
By comparison, out of 6.3gb allocated byte wise, etcd3 was 2gig and GetClusterPolicy() represented 1.2gig.
smarterclayton commentedon Sep 20, 2016
I added a metric for raw policy retrievals via the Registry (of each of the three types) and the early admin.sh test generated ~1.6k retrievals to the Registry, while 1k of ReadOnlyStorage and ~600 of Simulated.
Looks like every time we create a project we do 30-50 retrievals of the direct cluster policy and the same amount to simulated.
smarterclayton commentedon Sep 20, 2016
Is there a reason we bust through to the underlying cluster policy on project creation (specifically project request)?
deads2k commentedon Sep 20, 2016
Yes. We hit the live data to perform covers checks when adding rolebindings.
smarterclayton commentedon Sep 20, 2016
deads2k commentedon Sep 20, 2016
Well, I haven't actually counted them. You have to pull all the rolebindings and then some of the roles. It's entirely possible its inefficient because someone made us use virtual objects which necessitated some pretty insane storage layers....
deads2k commentedon Sep 20, 2016
Oh, and given 4 rolebindings, its only 8 requests per. That doesn't sound as crazy.
smarterclayton commentedon Sep 20, 2016
It hath been slain.
enj commentedon Oct 12, 2016
@mfojtik Do I actually need to do something for this issue? Seems like @smarterclayton already took care of it?
smarterclayton commentedon Oct 12, 2016
This is done.