Deal with MatrixBuilds and Update startup sequence

Fixes:

[JENKINS-8597] Deal with matrix builds better

And:

PrioritySorter was created before all jobs was loaded, 
this created a race condition when checking legacy.

Also making sure vital parts are running as SYSTEM user.