forgejo/models/packages
Mathieu Fenniak e6119b89c3 fix: remove duplicate indexes in package_blob table (#12836)
Table `package_blob` has both unique indexes, and standard indexes, defined on each of its hash columns.  This PR removes the standard indexes and leaves just the unique indexes, which will reduce disk space usage and improve performance on writing to the table.

Manual testing: confirmed that the indexes are removed by inspecting the database table in my dev environment before and after the migration.

I've reviewed other database tables for similar situations where a unique index is present and non-unique indexes are present but therefore not needed.  I've found no other cases.

Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/12836
Reviewed-by: Andreas Ahlenstorf <aahlenst@noreply.codeberg.org>
2026-05-30 20:59:46 +02:00
..
alpine chore: branding import path (#7337) 2025-03-27 19:40:14 +00:00
alt chore: branding import path (#7337) 2025-03-27 19:40:14 +00:00
conan chore: branding import path (#7337) 2025-03-27 19:40:14 +00:00
conda chore: branding import path (#7337) 2025-03-27 19:40:14 +00:00
container chore: branding import path (#7337) 2025-03-27 19:40:14 +00:00
cran chore: branding import path (#7337) 2025-03-27 19:40:14 +00:00
debian fix: debian package cleanup failure due to xorm connection corruption (#12764) 2026-05-27 17:47:11 +02:00
nuget refactor: replace Value() from Option[T] with Get() & ValueOrZeroValue() (#11218) 2026-02-10 16:41:21 +01:00
rpm chore: branding import path (#7337) 2025-03-27 19:40:14 +00:00
descriptor.go ci: detect and prevent empty case statements in Go code (#11593) 2026-03-10 02:50:28 +01:00
main_test.go chore: move all test blank imports in a single package (#10662) 2026-01-02 05:32:32 +01:00
package.go chore: upgrade to https://code.forgejo.org/xorm/xorm v1.4.0 (#12639) 2026-05-20 20:20:08 +02:00
package_blob.go fix: remove duplicate indexes in package_blob table (#12836) 2026-05-30 20:59:46 +02:00
package_blob_test.go chore: merge tests.AddFixtures and unittest.OverrideFixtures (#7648) 2025-04-25 09:14:33 +00:00
package_blob_upload.go chore: unify the usage of CryptoRandomString (#10110) 2025-11-15 13:24:53 +01:00
package_cleanup_rule.go chore: branding import path (#7337) 2025-03-27 19:40:14 +00:00
package_file.go fix: maven use groupId:artifactId for package name concatenation (#6352) 2025-06-01 09:02:29 +02:00
package_property.go chore: branding import path (#7337) 2025-03-27 19:40:14 +00:00
package_test.go fix: package_blob.has_blake2b may be null (#7520) 2025-04-11 12:28:03 +00:00
package_version.go fix: duplicate key violates unique constraint in concurrent debian package uploads (#11776) 2026-03-26 21:50:25 +01:00