mudler/luet

Bottleneck on sort finalizer

geaaru opened this issue · 2 comments

Luet version:
all versions

Describe the bug
Trying to sort the dependencies of every package available on the solution of the installed packages is not the best solution.

Every package takes about 3/4 secs and for single packages solution with ~1000 pkgs means about 4000 secs also when there aren't finalizer. This means that the time to install the packages is less of the phase to sort the finalizer.

https://github.com/mudler/luet/blob/master/pkg/installer/installer.go#L749

Maybe if we have already the right order of the packages installed it's possible to optimize a bit this phase.

Maybe a first workaround could be to avoid sorting the deps if the package that is under analysis is without finalizers?

this is drastically changed over almost a year, and there seems to be no interest. I'll close this one in favor of creating new ones, if needed over the current implementation.