Commit Graph
316 Commits
Author SHA1 Message Date
lukaszraczylo 6f604367da fix(websocket): start the event loop and throttle drop warnings
The app built the websocket server but never called Start, so nothing read the 256-slot broadcast channel. After the first 256 events every event was dropped with a warning, and dashboard clients blocked forever on the unbuffered register channel, leaking a goroutine per connection and never receiving events. Run now starts the loop with the other workers. Dropped events are counted in gohoarder_websocket_events_dropped_total and warned about at most once a minute.
v0.1.304
2026-11-23 12:56:32 +00:00
lukaszraczylo c98720c02e docs: describe cache.idle_ttl and the cleanup run
Document the new idle_ttl key in the example config and the README.
Explain that artifacts never expire by age and that metadata entries
refresh after default_ttl.
v0.1.303
2026-11-23 12:50:01 +00:00
lukaszraczylo 9a44683fbd feat(ui): note the idle eviction window on the stats page
The stats page now reads idle_ttl from the stats API. It shows
"Cached items not requested for 7 days are removed." in an info alert.
The note stays hidden when idle eviction is off.
2026-11-23 12:50:00 +00:00
lukaszraczylo d6edd40d79 feat(cache): evict items idle past cache.idle_ttl
Every cached item got a 7-day expiry at store time. A popular tarball
left the cache seven days after it was cached, however often clients
requested it.

Artifacts now get no age-based expiry. Cleanup removes any item whose
last_accessed is older than cache.idle_ttl (default 168h, 0 disables).
It reads the items in bounded batches of 500 through the indexed
last_accessed column and deletes them through deletePackage. Metadata
entries keep the freshness expiry from default_ttl.

Startup and each cleanup run clear the expiry that earlier versions set
on artifact rows. Cleanup records the idle and ttl eviction reasons and
logs the count and bytes freed. The stats API reports idle_ttl in
seconds. Package deletes are soft deletes and no history table has a
foreign key to packages, so download history stays intact.
2026-11-23 12:49:47 +00:00
lukaszraczylo 99c885cd88 fix(ui): stack package rows on phones and drop pager edge buttons
At 320px the package name shared a row with the registry badge, size and downloads, so it had about 90px and scoped names broke mid-word. Below sm the name now takes the full width with the meta row underneath. The pager's first and last buttons wrapped onto a second line inside the card; the page list already reaches the first and last pages, so the edge buttons are off.
v0.1.300
2026-11-23 12:29:40 +00:00
lukaszraczylo c022824d2b fix(ui): swap native key prompt for a dialog; add favicon v0.1.298 2026-11-23 03:18:43 +00:00
lukaszraczylo 5420480ef8 fix(metadata): keep created_at on CVE bypass edit; repair MySQL suite 2026-11-23 03:18:42 +00:00
lukaszraczylo bde9eebf3d fix(ui): show the PyPI release version in every version display 2026-11-23 03:18:42 +00:00
github-actions[bot]andGitHub f65c0cc1f3 chore(deps): update dependencies
Automated dependency update. All tests passed.
2026-11-23 03:17:22 +00:00
lukaszraczylo 947b264d94 fix(pypi): send the release version in the scanned package list
The package list builds its own payload when scanning is on, and that payload left out release_version, so the dashboard still showed file names. A helper now builds the summary and a test covers it.
v0.1.294
2026-11-23 02:47:34 +00:00
lukaszraczylo 1c9b04fba4 fix(pypi): key rows on the file name and show the release version
A PyPI row keys on the file name so each file of a release keeps its own cache and storage key. A new release_version column holds the real version and the API and dashboard show it. Startup deletes old sidecar rows with their storage and fills the release version on old file rows, keeping their storage keys. Startup also drops an empty download_events_old table. This replaces the local-version suffix.
v0.1.293
2026-11-23 02:36:53 +00:00
lukaszraczylo fb25501ae4 test(integration): build the integration suites again
The mysql and postgres suites used a removed cache rebuild method, a map for string metadata, and a shadowed metadata package. The mysql suite now sets parseTime. JSON columns pick json on mysql and jsonb elsewhere, so the mysql schema creates.
2026-11-23 02:36:51 +00:00
lukaszraczylo f0b7139a92 fix(pypi): record the release version and skip metadata sidecars
A PyPI package row held the file name as its version, and each PEP 658
sidecar became its own package. The version now comes from the file name, and
a wheel or zip adds a local-version suffix so distinct files keep distinct
cache keys. The sidecar streams from upstream without a package row. Rows
written before this change age out through the cache TTL.
2026-11-23 02:29:14 +00:00
lukaszraczylo 879ece368e fix(stats): include unaggregated downloads in the timeseries
The timeseries read only the aggregated tables. The hourly worker skips the
current hour and the daily rollup skips the current day, so fresh downloads
showed as zero. The query now merges raw download events, hourly rows and
daily rollups, with all buckets in UTC. The change in gormstore is limited to
GetTimeSeriesStats.
2026-11-23 02:29:14 +00:00
lukaszraczylo 81e3f9c74f fix(frontend): show load failures as errors and add a not-found route
A failed request left the store error set while the view kept its own
empty-list branch, so the page said nothing was cached. Every view now
checks loading, then error, then content, and the retry button refetches.
Unknown paths render a NotFound page with a link to the dashboard. The brand
shares the sidebar left edge, and a stopped socket reads Live updates paused
in a neutral tone; the client already retries with backoff.
2026-11-23 02:29:14 +00:00
lukaszraczylo 24dfb6eace chore(frontend): remove the hand-written ui kit and unused dependencies
The library provides every component, so src/components/ui, the cn helper,
the badge class helpers, tailwind.config.js and components.json go. Drop clsx,
class-variance-authority, tailwind-merge, tailwindcss-animate, lucide,
@vueuse/core, marked, reka-ui, the typography plugin and the Font Awesome
web font.
2026-11-23 02:29:14 +00:00
lukaszraczylo a5fd828410 feat(frontend): rebuild the bypass panel with library forms
Field, Input, Textarea, Checkbox, SegmentedControl and Dialog replace the
hand-written form. The status filter now applies the expired choice, which
the old click handler compared instead of assigning. Results show as toasts
and fetch failures as an ErrorState. Add a strict-mode smoke test per view.
2026-11-23 02:29:14 +00:00
lukaszraczylo 54bc809f66 feat(frontend): rebuild package, detail and vulnerable views
Package groups use Accordion with Table or DataTable in the cards layout
below sm. Delete confirmations use ConfirmDialog and results go to the
Toaster. Vulnerability descriptions render through Markdown instead of
v-html, and references use the library Link.
2026-11-23 02:29:13 +00:00
lukaszraczylo 041c6e8012 feat(frontend): rebuild the dashboard and stats on library components
KpiTile and StatGroup carry the totals, BarChart draws download activity,
ActivityFeed lists live events and DataTable lists recent packages and
registries. Loading, empty and error states use the library states. Severity
badges are StatusBadge with the tones critical danger, high warning, moderate
info and low neutral, and always print the word.
2026-11-23 02:29:13 +00:00
lukaszraczylo 0a0286df41 feat(frontend): add the perfect-design theme, shell and helpers
Install @perfect-design/ui 0.3.10 with the workbench style pack, IBM Plex
faces and the inline theme boot script. The app shell uses AppHeader, AppShell
and SidebarNav. Shared formatters, severity tones and icon data replace the
per-view copies. A test checks that main.css scans only the library
directories the app imports.
2026-11-23 02:29:13 +00:00
lukaszraczylo b88f9d2c99 chore: ignore local worktrees 2026-11-23 02:29:13 +00:00
lukaszraczylo d38eb34e06 fix(postgres): create the stats upsert indexes and partition audit_log
The hourly and daily aggregation upserts name a unique expression index that AutoMigrate does not create, so every aggregation failed on PostgreSQL. AutoMigrate also created audit_log as a plain table, so the partition step failed on every start. The partition manager now creates the two indexes and replaces an empty plain audit_log with a partitioned one.
v0.1.291
2026-11-23 02:23:35 +00:00
lukaszraczylo ea00fac0fe style: fix remaining golangci-lint findings v0.1.290 2026-11-23 01:21:16 +00:00
lukaszraczylo 1fefe03e8f fix(sqlite): stop prepared statements starving the connection pool 2026-11-23 01:21:14 +00:00
lukaszraczylo a69e96d75c ci: run the benchmark and helm chart jobs on the self-hosted runner 2026-11-23 01:19:31 +00:00
lukaszraczylo d653a32bd5 fix(metadata): read file store through os.Root to block symlink escape 2026-11-23 01:16:32 +00:00
lukaszraczylo 1d0363b247 fix(cache): cancel background scans when the manager closes 2026-11-23 01:15:19 +00:00
lukaszraczylo 380b3b9d1c fix(frontend): keep package endpoints off the dashboard proxy
The dashboard image forwarded /npm, /pypi, /go and /metrics to the
backend, so exposing the dashboard also exposed the package cache. Those
paths now return 404. The WebSocket location also matches /ws, the path
the backend serves.
v0.1.285
2026-11-23 00:32:47 +00:00
lukaszraczylo a313ac1096 fix(proxy): serve escaped npm scopes and unscanned packages
npm and pnpm request scoped packages as @scope%2fname. Fiber's adaptor
answers 404 to an escaped slash, so a route middleware now rewrites the
scope separator before the adaptor runs.

With scanning off, the cache still waited 30 s for a scan result and then
refused the package. A scanner that is off is now treated as absent.

A scan that fails on infrastructure (timeout, network error, upstream 5xx)
no longer blocks the package until its entry expires. The package is
served and the scan is retried every scan_retry_interval. Set
security.fail_closed to refuse such packages.

The OSV api_url default and the docs named the host, which answers 404 to a
query. They now name https://api.osv.dev/v1/query, and a bare host is
completed with the query path.
2026-11-23 00:31:47 +00:00
lukaszraczylo 65b2f23486 fix(pypi): serve the PEP 691 JSON simple API with upload-time
The proxy returned HTML pages only. uv with --exclude-newer drops files
that carry no upload time, so every file was filtered out. The handler
now negotiates the representation from the Accept header, as PyPI does.
It passes the upstream JSON through, including PEP 700 upload-time, and
rewrites only the file URLs. HTML clients keep HTML. The handler also
fetches the PEP 658 metadata sidecar and trusts the configured upstream
host for file URLs.
2026-11-23 00:31:40 +00:00
lukaszraczylo cfab914a24 fix(sqlite): take the write lock at transaction start
Read-then-write transactions began deferred. SQLite returns SQLITE_BUSY
for these at once and ignores busy_timeout, so concurrent requests logged
"database is locked". The DSN now sets _txlock=immediate and a 15 s
busy_timeout, so writers queue. A concurrency test covers this.
2026-11-23 00:31:37 +00:00
github-actions[bot]andGitHub 00a2d2f6ed chore(deps): update dependencies
Automated dependency update. All tests passed.
v0.1.281
2026-11-22 03:15:48 +00:00
github-actions[bot]andGitHub 379fd53c73 chore(deps): update dependencies
Automated dependency update. All tests passed.
v0.1.280
2026-11-21 03:14:29 +00:00
github-actions[bot]andGitHub de75f67720 chore(deps): update dependencies
Automated dependency update. All tests passed.
v0.1.279
2026-11-20 03:15:12 +00:00
github-actions[bot]andGitHub 6a37d56e33 chore(deps): update dependencies
Automated dependency update. All tests passed.
v0.1.278
2026-11-19 03:16:42 +00:00
github-actions[bot]andGitHub 57cbdcdb67 chore(deps): update dependency @vue/test-utils to v2.6.0
Automated dependency update. All tests passed.
v0.1.277
2026-11-17 03:15:17 +00:00
github-actions[bot]andGitHub 951f501ff6 chore(deps): update dependencies
Automated dependency update. All tests passed.
v0.1.276
2026-11-16 03:14:45 +00:00
github-actions[bot]andGitHub c57c4ccfb0 chore(deps): update dependencies
Automated dependency update. All tests passed.
v0.1.275
2026-11-15 03:13:55 +00:00
github-actions[bot]andGitHub 138edbede7 chore(deps): update dependencies
Automated dependency update. All tests passed.
v0.1.274
2026-11-14 03:49:04 +00:00
github-actions[bot]andGitHub 3ae90aa0ee chore(deps): update dependencies
Automated dependency update. All tests passed.
v0.1.273
2026-11-13 03:14:52 +00:00
github-actions[bot]andGitHub d71371674d chore(deps): update dependencies
Automated dependency update. All tests passed.
v0.1.272
2026-11-12 03:17:59 +00:00
github-actions[bot]andGitHub cc0f56f6db chore(deps): update dependency jsdom to v31
Automated dependency update. All tests passed.
v0.1.271
2026-11-10 03:17:34 +00:00
github-actions[bot]andGitHub a174afee73 chore(deps): update dependencies
Automated dependency update. All tests passed.
2026-11-10 03:14:46 +00:00
github-actions[bot]andGitHub 046e074be5 chore(deps): update dependencies
Automated dependency update. All tests passed.
v0.1.269
2026-11-09 03:25:01 +00:00
lukaszraczylo 2e0f095ea9 ci(runners): run shared workflows on self-hosted runners
The pr, autoupdate and release workflows now pass runner: self-hosted. The macOS and Windows release legs stay on GitHub-hosted runners.
v0.1.268
2026-11-08 03:55:12 +00:00
github-actions[bot]andGitHub c38916aebb chore(deps): update dependencies
Automated dependency update. All tests passed.
v0.1.267
2026-11-08 03:17:55 +00:00
github-actions[bot]andGitHub 015f48b468 chore(deps): update dependencies
Automated dependency update. All tests passed.
v0.1.266
2026-11-07 03:19:25 +00:00
github-actions[bot]andGitHub ad5b03ba60 chore(deps): update dependencies
Automated dependency update. All tests passed.
v0.1.265
2026-11-06 03:18:12 +00:00
github-actions[bot]andGitHub 819465e83f chore(deps): update dependencies
Automated dependency update. All tests passed.
v0.1.264
2026-11-05 03:15:22 +00:00
github-actions[bot]andGitHub eec24a5894 chore(deps): update dependencies
Automated dependency update. All tests passed.
v0.1.263
2026-11-03 03:17:52 +00:00