Skip to content

perf(file-list): db pagination - #17505

Open
alperozturk96 wants to merge 1 commit into
masterfrom
fix/large-folder-listing
Open

perf(file-list): db pagination#17505
alperozturk96 wants to merge 1 commit into
masterfrom
fix/large-folder-listing

Conversation

@alperozturk96

Copy link
Copy Markdown
Collaborator

Issue

When user have a lot of files and/or folder in directory app crashes. Due to fetching all files at once from DB.

{
      "header": {
        "logLevel": "ERROR",
        "pid": 7829,
        "tid": 7849,
        "applicationId": "com.nextcloud.client",
        "processName": "com.nextcloud.client",
        "tag": "CursorWindow",
        "timestamp": {
          "seconds": 1787142876,
          "nanos": 504903577
        }
      },
      "message": "Failed to read row 615, column 5 from a window with 615 rows, 52 columns"
},

Changes

  • Fetch batch by batch. Batch size is 100.
  • Return ID from DB instead of FileEntity.

How to reproduce crash?

  1. Have 2K files and 2K folders in root directory.
  2. Keep scroll
  3. Crash

Signed-off-by: alperozturk96 <alper_ozturk@proton.me>
@alperozturk96 alperozturk96 added this to the Nextcloud App 35.0.0 milestone Aug 19, 2026
@alperozturk96 alperozturk96 added 3. to review performance 馃殌 Performance improvement opportunities (non-crash related) labels Aug 19, 2026
@github-actions

Copy link
Copy Markdown

blue-Light-Screenshot test failed, but no output was generated. Maybe a preliminary stage failed.

@github-actions

Copy link
Copy Markdown

Codacy

SpotBugs

CategoryBaseNew
Bad practice3232
Correctness5959
Dodgy code207207
Experimental11
Malicious code vulnerability22
Multithreaded correctness2525
Performance3939
Security1919
Total384384

@github-actions

Copy link
Copy Markdown

APK file: https://github.com/nextcloud/android/actions/runs/32258040777/artifacts/9367607142
To test this change/fix you can simply download above APK file and install and test it in parallel to your existing Nextcloud app.
qrcode (please click on link to get QR code displayed)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3. to review performance 馃殌 Performance improvement opportunities (non-crash related)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant