Skip to content

v2.23.0

Latest

Choose a tag to compare

@hepeichun hepeichun released this 21 Jul 09:22
· 12 commits to master since this release

v2.23.0

This release introduces target URL deduplication for short links and improves the project documentation.

New Features

  • Added domain-level duplicate URL policies:
    • deny: Return an existing short link for the same target URL.
    • allow: Always create a new short link.
    • by_request: Let each creation request decide. This is the default policy.
  • Added the find_if_exists parameter to single and batch short-link creation APIs.
  • Added the is_existing response field to indicate whether an existing short link was returned.
  • Added duplicate URL policy settings and a deduplication switch to the admin interface.
  • Short links with custom codes are excluded from deduplication.
  • Deduplication only reuses active, unexpired, non-deleted links within the same workspace and domain.

Database Changes

  • Added the url_hash column and a composite index to the short_links table.
  • Added the duplicate_policy column to the domains table.
  • URL hashes for existing short links are backfilled asynchronously after the upgrade.
  • MySQL, PostgreSQL, and SQLite are supported.

Other Improvements

  • Refactored the README and deployment documentation.
  • Added test coverage for short-link deduplication.

Upgrade Instructions

Back up your database, configuration, and data directories before upgrading:

docker compose pull
docker compose up -d

Database migrations run automatically when the service starts. Existing domains use the by_request policy by default, so short-link creation behavior remains unchanged unless deduplication is enabled.

For installations with a large number of short links, index creation and URL hash backfilling may temporarily increase database load. Upgrading during off-peak hours is recommended.