Skip to content

perf: reduce startup and feed rendering work#515

Merged
barrydeen merged 3 commits intomainfrom
fix/tab-switch-jank
May 4, 2026
Merged

perf: reduce startup and feed rendering work#515
barrydeen merged 3 commits intomainfrom
fix/tab-switch-jank

Conversation

@barrydeen
Copy link
Copy Markdown
Owner

Summary

  • load NSpam classifier off the startup path and attach it to notifications once ready
  • reuse shared OkHttp clients for media, link previews, NIP-05/NIP-11, exchange rates, and downloads
  • move NIP-05 verification out of composition, cache rich-content grouping and media placeholders, and coalesce notification rebuilds

Test

  • JAVA_HOME=/home/barry/Downloads/android-studio/jbr ./gradlew :app:compileDebugKotlin

barrydeen added 3 commits May 4, 2026 08:08
…notif rebuild

- give getNip05Client a dedicated 5/10s client (was aliasing the 10/15s
  general client); slow .well-known/nostr.json endpoints no longer tie
  up verification threads
- add getDownloadClient (30/60s) for MediaDownloader; the shared media
  client (10/30s) is fine for ExoPlayer streaming but its read timeout
  is too tight for full-file downloads on flaky networks
- tighten notification rebuild coalesce window from 50ms to one frame
  (16ms) so single-arrival updates feel responsive
- add NotificationRepository.shutdown() and call it from
  FeedViewModel.onCleared() so rebuildScope doesn't outlive the VM
@barrydeen barrydeen merged commit 04501e4 into main May 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant