Skip to content

Release page loads slow with a lot of tags #490

Closed
@deanpcmad

Description

@deanpcmad

Copied from gogs/gogs#3094

  • Gitea version (or commit ref): 1.0
  • Git version:
  • Operating system:
  • Database (use [x]):
    • PostgreSQL
      MySQL
      SQLite
  • Can you reproduce the bug at https://try.gitea.io:
    • Yes (provide example URL)
      No
      Not relevant
  • Log gist:

Description

I've just created a mirror repository for the rails repo and upon viewing the "Releases" tab, it takes forever to load, sometimes not loading at all which can cause nginx to timeout

Please see #491 as well

Activity

added this to the 1.1.0 milestone on Dec 27, 2016
added and removed
type/enhancementAn improvement of existing functionality
on Dec 28, 2016
bkcsoft

bkcsoft commented on Dec 28, 2016

@bkcsoft
Member

not an enhancement, it's a bug. I added release pagniation a while back but I seem to have missed this for-loop here that still loop over all tags 😒 https://github.com/go-gitea/gitea/blob/master/routers/repo/release.go#L77

bkcsoft

bkcsoft commented on Dec 28, 2016

@bkcsoft
Member

Just flipping that for-loop around and using ctx.Repo.GitRepo.GetTag(r.TagName) should make it way faster, and TBH we probably don't need the caching anymore since we're not fetching all tags in one go :)

deanpcmad

deanpcmad commented on Dec 28, 2016

@deanpcmad
Author

Yeah I saw there is pagination so I did wonder why it was slow, that explains it :)

JetpackDuba

JetpackDuba commented on Dec 28, 2016

@JetpackDuba

Will you fix it for 1.0.1 or only 1.1? Imo it should be in both :P

self-assigned this
on Dec 29, 2016
lunny

lunny commented on Dec 31, 2016

@lunny
Member

@deanpcmad, could you please test if #527 resolved your problem since I think there are also some improvements should be taken in future.

deanpcmad

deanpcmad commented on Dec 31, 2016

@deanpcmad
Author

@lunny sure, is there a build for it?

lunny

lunny commented on Dec 31, 2016

@lunny
Member

https://dl.gitea.io/gitea/master/, you can find your proper version.

JetpackDuba

JetpackDuba commented on Jan 3, 2017

@JetpackDuba

I'm not who opened the issue but in my case using Windows 10 and MSSQL, I've cloned VS CODE github repo and tags page takes 8.8 seconds to load :S

deanpcmad

deanpcmad commented on Jan 3, 2017

@deanpcmad
Author

Hey, I've just tried it (version 09dabe2) but it is still very slow to load the tags page. If you want to test it yourself locally, mirror the https://github.com/rails/rails repo

reopened this on Jan 4, 2017
added a commit that references this issue on Jan 5, 2017
b9bfdc0
JetpackDuba

JetpackDuba commented on Jan 8, 2017

@JetpackDuba

Now it loads in 1sec! That's better!

lunny

lunny commented on Jan 8, 2017

@lunny
Member

Yes. But it's not perfect. It needs further improvement later.

lunny

lunny commented on Jan 14, 2017

@lunny
Member

On macOS and sqlite, rails still spent 10s.

lunny

lunny commented on Nov 1, 2017

@lunny
Member

https://try.gitea.io/lunny/rails/releases. v1.2+ have resolve this issue entirely.

locked and limited conversation to collaborators on Nov 23, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Relationships

None yet

    Development

    Participants

    @lunny@deanpcmad@bkcsoft@JetpackDuba

    Issue actions

      Release page loads slow with a lot of tags · Issue #490 · go-gitea/gitea