-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Repo indexer - Max file size #3457
Comments
|
Thank you for your fast answer @lafriks . Then, what about the fixed "store" file size? I am trying to indexing a big project, and some of the files was indexed, but seems to be that not everyone, and I supposed that it depends maybe from the "file size" |
how big is file that was not indexed? |
Only 9KB, and is a Java file |
Do you see any errors in log file? and why do you think it was not indexed? |
No errors in log file. I am sure that the file was not indexed because I am trying to look also for other strings inside this file, but no results appear. |
I just replicated the problem. If I create a new repository with just this file and just this repo, then the file is indexed correctly. I think that the problem is the max "store" file size |
I don't think there is maximal size for store file |
You can try to replicate the problem by cloning the repo: https://github.com/Xilinx/u-boot-xlnx |
@ethantkoenig can you check this? |
@ethantkoenig @lafriks Thank you. I also want to add an additional information: with the same repository occured also an access violation during repo indexing: Exception |
In my experience, bleve does not do well once index files approach/exceed 1 GB (although it may be different for other machines and OS's). I do recall seeing similar behavior at some point (where an index file remained the exact same size as more content was added to it), but wasn't able to figure out what was going on. I have found that using sharded indices (not natively supported by bleve) allows bleve to scale more gracefully. Perhaps this is something to consider using in gitea. |
Thank you for your answer @ethantkoenig . Are there any workaround to avoid this behavior? |
I also want to add some external links to boltdb: |
@ethantkoenig an additional information: your lasts commit on master, changed the store max size to 524.288 KB, instead of, for "v1.4.0-rc1" the size is fixed to 1.048.576 KB |
@ethantkoenig @lafriks After hours of reverse engineering I think that I found the problem about max store sizing on gitea v1.4.0-rc1. On monday I will test mine tricky-hack on production gitea, and I will let you know about it here |
@giudon that's great to hear |
@ethantkoenig @lafriks Now I can confirm my analisys: there is a problem in boltdb. In particular it happens in such particular cases, when is needed to remap the store file after 1GB. The problem is still present in the master version, because I seen that on gitea we are using this db.go version https://github.com/boltdb/bolt/blob/ccd680d8c1a0179ac3d68f692b01e1a1589cbfc7/db.go (this commit was done by @lunny , and after this there is only one commit more, that doesn't change the remap logic on db.go). My little tricky-hack to let it works, is to comment the following red lines inside "mmapSize" method: What do you think about it guys? |
@giudon great bug hunting :) can you report this upstream to boltdb? |
@lafriks did it |
Bolt have become archived/unmaintained. Proposed alternative seems to be https://github.com/etcd-io/bbolt. Perhaps it's worth taking a look at it? |
It's outdated and now the latest version depends on go.etcd.io/bbolt indirectly. |
gitea v1.4.0-rc1
I am trying to change the repo indexer max file size. I setted it to 5242880, but the repo file size is fixed to:
Seems that the setting doesn't be load correctly:
I also tried to change the setting, and erased the repo folder, but anyway the size seems to be fixed.
Regards
The text was updated successfully, but these errors were encountered: