[SOLVED] Max files/rows limit per folder in repository in UI

Hi community,

I have a repository, which host thousands of small files. These files are already structured by different folders, but each folder can still contain multiple thousand files.

.
├── README.md
├── enrolled
│   ├── README.md
│   └── external
│       ├── file1.yml
│       ├── file2.yml
│       ├── ...
│       └── file1600.yml
├── preview
│   ├── external-a
│   │   ├── file1.yml
│   │   ├── file2.yml
│   │   ├── ...
│   │   └── file1600.yml
│   └── external-b
│   │   ├── file1.yml
│   │   ├── file2.yml
│   │   ├── ...
│   │   └── file1600.yml
│   └── external-c
│       └── ...
└── CHANGELOG.md

The ./preview/external-*-folders are the relevant folders here. Gitlab doesn’t show more than 100 files within a folder on the UI. In an earlier installation of Gitlab, it showed a “Show more” link, to show all files. In this new installation of Gitlab, there is just nothing, as there wouldn’t be more files.

If I search for the files, they are found.

Bases on my research on this issues I’ve already set

Gitlab::Git::Repository::MAX_TREE_ENTRIES = 5000

in the Ruby console, without any effect.

Steps to reproduce

I didn’t double-check with another repository, as this seems pretty clear to be a configurable setting, based on the exact number 100 files.

Versions

GitLab              v17.2.0
GitLab Shell        14.37.0
GitLab Workhorse    v17.2.0
GitLab API          v4
GitLab KAS          17.2.0
Ruby                3.1.5p253
Rails               7.0.8.4
PostgreSQL (main)   14.11
PostgreSQL (ci)     14.11
Redis               7.0.15
Gitaly              17.2.0 / 2.45.2

Thanks for any help.

While gathering the version information for the initial post, I’ve recognized, that I was not on the latest version, which is 17.3.1 by the date of today.

This morning I’ve updated the installation to the most recent version and now I can see all files again. So it seems, that this was just a bug on an older version.

1 Like