1. 14 Apr, 2021 3 commits
  2. 09 Apr, 2021 1 commit
  3. 22 Mar, 2021 1 commit
    • David Edmundson's avatar
      Use shared instance of the process list · 43b07b18
      David Edmundson authored and David Redondo's avatar David Redondo committed
      We might want to present the process list in several different views.
      The process list is quite expensive, so if we ref-count the core we can
      use it in multiple places.
      Timers remain in their respecitive views as Processes has it's own
      internal throttling mechanism.
      Because that leaves us with a ref-counting issue on which plugin
      attributes are enabled or not, that is changed to be implicit based on
      whether we have dataChanged connected or not; which actually simplifies
      some code.
      Co-authored-by: David Redondo's avatarDavid Redondo <kde@david-redondo.de>
  4. 04 Mar, 2021 1 commit
    • David Edmundson's avatar
      Move CGroup pid fetching callback to the controller · 18937f39
      David Edmundson authored
      The CGroup class started out as a dumb data store, that did some
      fetching of relevant data.
      It then gained a more complex async operation. The lifepsan of the
      CGgroup object is managed by the model, so could get deleted whilst the
      runnable was running. QRunnables and non-qobjects leds to a lot of
      potential problems. There was a complex mutex and a wait condition, yet
      it still misses a case only solvable with yet more mutexes.
      By moving the callback handling logic to the controller, we can guard
      everything in a safer more Qt manner without any overhead and with
      simpler code.
      There is a behavioural change if you call pids whilst things are
      loading, but given a signal is emitted when pids load that's fine.
      This class is exported, but the header was never installed.
      Whilst technically it is an ABI break it pragmantically will have no
      impact whatsoever.
      BUG: 430615
  5. 04 Feb, 2021 1 commit
    • David Edmundson's avatar
      Add method CGroupDataModel::isAvailable · 6d429604
      David Edmundson authored
      This returns true if the root is pointing to a valid path. The idea
      being that non-systemd systems won't have applications scoped correctly,
      nor a relevant user slice.
      By communicating this we can dislpay the entry as not working in the UI.
  6. 25 Jan, 2021 2 commits
  7. 21 Jan, 2021 1 commit
    • David Edmundson's avatar
      Use faster file system searcing for iterating process groups · ae21f67c
      David Edmundson authored
      This was showing in hotspot as 14ms per update.
      It turns out QDir creates a full QFileSystem entry on every file, even
      using QDirIterator and with all features turned off.
      This isn't really useful when iterating through /sys which has simpler
      Using a lower level API brings that down to 2ms.
  8. 12 Jan, 2021 1 commit
  9. 08 Oct, 2020 1 commit
  10. 03 Sep, 2020 1 commit
  11. 12 Aug, 2020 1 commit
  12. 11 Aug, 2020 1 commit
  13. 01 Jul, 2020 1 commit
  14. 26 Jun, 2020 1 commit
    • David Edmundson's avatar
      Introduce API for handling cgroups · beae8176
      David Edmundson authored
      A model is exposed that groups processes by cgroup and provides grouped
      The model can be started and stopped and can be set to follow a given
      root. All system units, all users, or a specific slice within that.
      Information for all pids is calcuated totalled and included via the
      ProcessAttribute helpers.
      Cgroups are set to handle applications that follow
      https://systemd.io/DESKTOP_ENVIRONMENTS for grouping of applications. A
      convenience model ApplicationDataModel subclass exposes this directly.
      The exposed model is a 1:1 mapping of ProcessDataModel for easy drop-in.