Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-pages.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2023-11-06Update interface signatureJaime Martinez
2023-10-18Remove FF_CONFIGURABLE_ROOT_DIR Feature Flagjanis
2023-06-08Use pages root directory from APIJanis Altherr
2023-05-08Upgrade golangci-lint to v1.52.2 on CIJaime Martinez
2023-04-12Update golangci-lint toolKassio Borges
2023-02-14Revert back to archive/zipKassio Borges
2022-07-25Merge branch 'sh-log-zfs-corruption-error' into 'master'Stan Hu
chore: log ZIP archive corruption error See merge request gitlab-org/gitlab-pages!821
2022-07-23Chore: log ZIP archive corruption errorsh-log-zfs-corruption-errorStan Hu
When a ZIP file cannot be opened for some reason, we previously would discard the error after attempting to retrieve it from the cache. While this error is logged in another message, it would be helpful to have the same message tied with the "archive corrupted" log entry. Relates to https://gitlab.com/gitlab-org/gitlab-pages/-/issues/690 Changelog: changed
2022-07-15Revert: open files lazily when serving contentVladimir Shushlin
This reverts merge request https://gitlab.com/gitlab-org/gitlab-pages/-/merge_requests/803 because it caused an incident when serving large compressed files Changelog: fixed
2022-07-07Open files lazily when serving contentfeistel
Changelog: performance
2022-07-04Null out file slicefeistel
2022-07-04Convert archive field to a local variablefeistel
2022-07-04Null out zip reader after reading archivefeistel
2022-06-28Improve consistency of log fieldsfeistel
2022-06-21Merge branch 'jv-clear-timezone' into 'master'Vladimir Shushlin
Clear timezones from cached zip entries See merge request gitlab-org/gitlab-pages!791
2022-06-21Clear timezones from cached zip entriesJacob Vosmaer
In https://gitlab.com/gitlab-org/gitlab-pages/-/issues/702 we discovered that by caching many `*zip.File` instances, we end up storing many Go timezone objects on the heap: one per cached `*zip.File`. This adds up to about 25% of the heap size. In this commit we set the timestamp of `*zip.File` to UTC. Because Go re-uses a single timezone object for UTC, this causes the original timezone objects of the `*zip.File` instances to be garbage collected. This reduces the heap size. Here is an example program that demonstrates the effect: ```golang package main import ( "archive/zip" "log" "os" "runtime/pprof" ) func main() { if err := load(os.Args[1]); err != nil { log.Fatal(err) } log.Printf("load finished: %d archives", len(readers)) pprof.WriteHeapProfile(os.Stdout) } var readers []*zip.ReadCloser func load(filename string) error { for i := 0; i < 1000; i++ { zr, err := zip.OpenReader(filename) if err != nil { return err } if os.Getenv("FORCE_UTC") == "1" { for _, zf := range zr.File { zf.Modified = zf.Modified.UTC() } } readers = append(readers, zr) } return nil } ```
2022-06-17Properly handle io.copy errorsfeistel
Changelog: added
2022-05-16Add logs for more visibility in 404s and archive corruption eventVishal Tak
2022-03-14add flag to parameterize zip http client timeoutvtak
Changelog: added
2022-03-11Add correlation_id to all exception capturesKassio Borges
2022-02-03test: migrate to assertions using modern error checkingfeistel
2022-02-02lint: fix linter issuesfeistel
2022-02-01fix: Fix 500 errors when clients disconnectVladimir Shushlin
When clients disconnect, we now logging 500 error due to Context.Cancelled error. This leads to alerts and uses up our error budgets. This reverts merge request !676 Changelog: fixed
2022-01-31chore: return early for head requestsJaime Martinez
2022-01-29fix: catch io.copy errors when serving contentfeistel
2022-01-26Merge branch 'feat/errorlint' into 'master'Jaime Martinez
build: enable errorlint and use modern error checking See merge request gitlab-org/gitlab-pages!648
2022-01-24test: replace tmpdir workaround with native T tmpfeistel
2022-01-24lint: fix errorlint issuesfeistel
2022-01-24lint: fix gci issuesfeistel
2022-01-20lint: solve internal/vfs/serving linter issuesfeistel
2021-12-16fix: update vfs/zip implementation to ensure minimum range requests for go1.17Arran Walker
Using `gitlab.com/gitlab-org/golang-archive-zip` instead of the `archive/zip` package from the stdlib. Changelog: changed
2021-12-14Merge branch 'fix/sha-lookups' into 'master'Jaime Martinez
test: add sha256 to mocked lookups and fix tests See merge request gitlab-org/gitlab-pages!634
2021-12-14refactor: promote missingcachekey error to a static errorfeistel
2021-12-13fix: return an error if the cacheKey is emptyfeistel
2021-12-08Merge branch 'remove-unused-ctx' into 'master'Jaime Martinez
refactor: enable unparam in .gitlabci.yml See merge request gitlab-org/gitlab-pages!631
2021-12-08test: add sha256 to mocked lookups and fix testsfeistel
2021-12-07Merge branch 'upgrade-labkit-1-11-0' into 'master'Vladimir Shushlin
chore: upgrade to labkit 1.11.0 See merge request gitlab-org/gitlab-pages!633
2021-12-07refactor: enable unparam in .golangci.ymlVladimir Shushlin
and fix offences
2021-12-07chore: upgrade to labkit 1.11.0Jaime Martinez
And report stack trace with error tracking to Sentry. Changelog: other
2021-12-06refactor: move keyFromPath our of zipVfs objectVladimir Shushlin
2021-12-01Merge branch 'refactor/limiter-new' into 'master'Jaime Martinez
refactor: make internal/lru and internal/ratelimiter metrics optional Closes #647 See merge request gitlab-org/gitlab-pages!606
2021-12-01chore: update method namesfeistel
2021-11-25refactor: add functional option to customize lru cache size and expirationfeistel
don't expose default values and keep them private.
2021-11-17Merge branch 'fix/native-fs-error' into 'master'Jaime Martinez
refactor: remove vfs.ErrNotExist and switch to go native fs error See merge request gitlab-org/gitlab-pages!569
2021-11-16refactor: move away from error '==' comparisonJaime Martinez
2021-11-16feat: handle extra headers when serving from compressed zip archivefeistel
Related to https://gitlab.com/gitlab-org/gitlab-pages/-/issues/466 Changelog: added
2021-11-15refactor: provide more context for symlink errorsBrian Williams
2021-11-11refactor: remove vfs.ErrNotExist and switch to go native fs errorfeistel
2021-11-08style: revert explicit params typeJaime Martinez
2021-11-08refactor: read and use file_sha256 as cache key for zip VFSfeistel
Now that the Rails API is serving the archive file_sha256 in the lookup response, we can move away from using the base URL as the key to cache the archive. Changelog: change