Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Register
  • Sign in
  • gnome-software gnome-software
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 230
    • Issues 230
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 12
    • Merge requests 12
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Releases
  • Packages and registries
    • Packages and registries
    • Container Registry
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • GNOMEGNOME
  • gnome-softwaregnome-software
  • Merge requests
  • !1607

Asynchronous remote icon download

  • Review changes

  • Download
  • Email patches
  • Plain diff
Merged Georges Basile Stavracas Neto requested to merge gbsneto/icon-downloader into main Jan 26, 2023
  • Overview 30
  • Commits 7
  • Pipelines 4
  • Changes 10

See commits. The motivation for this merge request is that, while profiling GNOME Software, downloading icons is by far the biggest offender to the fluidity of the app. That's because it blocks the refine operation, which is the operation performed while navigating through categories and whatnot.

This merge request introduces a new object made specifically for the purpose of asynchronously downloading remote icons. GsIconDownloader needs to live in the libgnome-software library because it needs access to private GsApp API; but it has to be public object because GsPluginIcon needs to create a single instance of it.

I think the current API is... okay. It doesn't spark joy in my heart, but I could at least convince myself that it's thread-safe and won't lead to corrupted icons under any circumstance.

With this patchset, loading categories is noticeably faster - my fingers could count 8~10 seconds of waiting for the "Development" category before these patches, and now it's ~2 seconds. That's because we now show the full list of apps before icons are downloaded, and keep downloading them on the fly.

Here's how it looks so far - notice the icons showing up on the fly:

Gravação_de_tela_de_2023-01-26_17-08-22

Let's do a quick performance comparison:

Before After
before after

To be reviewed:

  • GsIconDownloader API and internal design - is it enough? Is it wrong?
  • The 3-dot icon 2. Needs Design
Edited Feb 21, 2023 by Georges Basile Stavracas Neto
Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: gbsneto/icon-downloader