promotional bannermobile promotional banner

[DISCONTINUED] DiscordBridge [DISCONTINUED]

DiscordBridge links your Minecraft 1.21.x server chat to Discord in real-time via webhooks, enabling two-way messaging between in-game players and Discord members — no bot, no dependencies, server-side only.

File Details

discordbridge-1.1.4.jar

  • R
  • Apr 23, 2026
  • 15.35 MB
  • 45
  • 1.21.1
  • NeoForge

File Name

discordbridge-1.1.4.jar

Supported Versions

  • 1.21.1

Curse Maven Snippet

NeoForge

implementation "curse.maven:discordbridge-1486109:7974463"
Curse Maven does not yet support mods that have disabled 3rd party sharing

Learn more about Curse Maven

[1.1.4] - 2026-04-23

Added

  • Asynchronous Storage Initialization — New StorageInitializer class loads all JSON storages (VerifiedUserStorage, BanStorage, StaffUserStorage, ActiveSessionStorage) in parallel on dedicated threads. Server startup no longer blocked by file I/O.
  • Centralized Crash Handler — New CrashHandler utility generates detailed crash reports to crash-reports/discordbridge/. Each report includes: Java version, OS info, full stack trace, cause chain, thread states, and active threads summary. Two modes:
    • Fatal Crashes — Uncaught exceptions create timestamped .txt files in crash directory
    • Non-Fatal Errors — Caught exceptions logged with context for debugging
  • Comprehensive Error Handling — All event handlers (GameEventHandler), bot initialization (BotManager), and database operations (DatabaseManager) now wrapped in try-catch with proper crash reporting.
  • Enhanced Bot Error Differentiation — Distinguishes between IllegalArgumentException (invalid token) and other connection errors for better diagnostics.
  • Atomic Database Table Creation — Each CREATE TABLE statement fails independently; one table error doesn't block others.

Fixed

  • CRITICAL: Server Startup Slowdown — JSON files were loaded synchronously, blocking server startup by 5-7 seconds. Now loaded asynchronously in parallel, reducing startup time to 1-2 seconds.
  • CRITICAL: Silent Crashes — No centralized logging for uncaught exceptions. Now all crashes generate detailed reports with full diagnostics.
  • Event Handler Failures — Chat relay, player events, and death messages could crash silently. Now all event handlers properly protected with error handling.
  • Database Initialization Fragility — If one table creation failed, others weren't attempted. Now each table is independent.
  • Incomplete Bot Error Context — Discord connection errors lacked meaningful debugging info. Now includes token validation and specific error types.

Performance

  • Server Startup — ~60-70% faster (5-7s → 1-2s) due to async parallel storage loading
  • Non-Blocking I/O — All file operations happen on dedicated threads, zero impact on main server thread
  • Parallel Storage Loading — 4 storages load simultaneously on 2-thread pool instead of sequentially
  • Progress Visibility — Logs show individual storage load times for diagnostics

Technical Details

New Classes:

  • CrashHandler.java — Centralized exception logging and crash report generation
  • StorageInitializer.java — Parallel async storage initialization with progress tracking

Modified Classes:

  • DiscordBridge.java — Initialize CrashHandler first; use StorageInitializer; wrap setup in try-catch
  • BotManager.java — Distinguish IllegalArgumentException; enhance error logging with CrashHandler
  • DatabaseManager.java — Wrap table creation in try-catch per table
  • GameEventHandler.java — Wrap all event handlers in try-catch with CrashHandler logging

Documentation:

  • Documentation/17_PERFORMANCE_CRASH_OPTIMIZATION.md — Complete guide to optimizations and crash reporting

Notes

  • Crash reports stored in crash-reports/discordbridge/ with timestamps for easy investigation
  • StorageInitializer shows progress: [DiscordBridge] Storages ready for queries when complete
  • All storage operations (DB/JSON) continue to work normally during async loading phase