Caskara - Dabatase engine

Experimental
An API that allows database management similar to MongoDB.

File Details

Caskara-2.0.1.jar

  • R
  • Jun 10, 2026
  • 13.25 MB
  • 3
  • 0.5

File Name

Caskara-2.0.1.jar

Supported Versions

  • 0.5

๐Ÿ“ Changelog

[2.0.1] - Hotfix & Command Parsing Update

๐Ÿ› Bug Fixes

  • Command Registration Fix: Fixed a critical issue where /caskara commands were not being registered with the Hytale server during plugin initialization, rendering them inaccessible in-game.
  • Command Argument Parsing: Refactored the monolithic command structure into native Hytale SubCommands. This resolves the parsing error that incorrectly required positional arguments to use flags (e.g., --target=0) instead of typing them naturally (e.g., /caskara autobackup 0).
  • Build System Conflict: Resolved an implicit dependency conflict in build.gradle between the default jar task and shadowJar that could cause build failures during deployment.

๐Ÿ“– Documentation

  • Command Suite Guide: Updated the documentation to accurately reflect the new in-game command suite architecture.

[2.0.0] - The Hardening Update

โœจ Features

  • In-Game Command Suite: Added the comprehensive /caskara command for database administration directly within Hytale.
    • /caskara stats: View total databases, cores, memory footprint, hit rates, and disk sizes.
    • /caskara vacuum: Manually trigger a global SQL VACUUM on all connected database shells.
    • /caskara backup: Instantly perform an atomic, thread-safe backup of all databases.
    • /caskara autobackup <hours>: Adjust or disable the Auto-Backup interval on the fly.
    • /caskara dump <package_name>: Export database contents to disk for analysis.
    • /caskara scan <package_name>: Manually scan packages for @CaskaraEntity definitions.
  • Native Atomic Auto-Backups: Caskara now has a built-in background scheduler that safely backs up all active SQLite databases without causing locks or database corruption (properly handles SQLite WAL mode using native APIs). Enabled by default every 1 hour.
  • Auto-Vacuum Scheduler: Implemented a global background daemon to automatically VACUUM databases (every 12 hours by default) to keep storage footprint small.
  • Annotation-Based Configuration: Entities can now be fully configured via the @CaskaraEntity annotation.
  • Package Scanning Utility: Introduced automatic @CaskaraEntity registration via Caskara.scanPackage().
  • SQLite FTS5 Support: Ultra-fast full-text search capabilities enabled via the @FullTextSearch annotation.
  • Bulk Operations: Implemented high-performance batch save (saveAll()) and delete operations using transactions.
  • Query Expirations: expires_at is now included in element queries and can be conditionally utilized.
  • Java 25 Support: Bumped the base compilation target in gradle.properties to Java 25.

๐Ÿ› Bug Fixes

  • SQL DDL Parameterization Crash: Fixed an issue where the @Index and @Indices annotations used PreparedStatement parameter bindings (?) for creating indexes, which SQLite's schema definitions (DDL) natively block, resulting in instant startup crashes.
  • Database Connection Memory Leak: Repaired a race condition in Shell.java's initialization flow. Simultaneous multi-thread requests during boot could bypass locks, creating duplicate SQLite connections and duplicate internal TTL memory cleanup tasks. Mitigated with Double-Check Locking.
  • Stranded WAL Files on Shutdown: The Caskara.shutdown() hook neglected to invoke close() on the active database Shells. Abrupt Hytale server shutdowns previously abandoned in-memory SQLite .db-wal temporary files without checkpointing them to disk, risking data rollback.
  • Server-Wide Concurrency Crash: Fixed a critical structural flaw where internal caches (Caskara.shells and Shell.cores) used standard HashMaps. Heavy, simultaneous data operations across multiple plugins previously threw ConcurrentModificationException, crashing the entire server database layer. Resolved by migrating to ConcurrentHashMap.
  • Hot-Reload Scheduler Failure: Fixed an issue where executing Caskara.shutdown() would kill the background executor service but leave the reference dangling. Subsequent attempts to reload or restart Caskara operations (like hot-reloading) instantly crashed via RejectedExecutionException.

๐Ÿ“– Documentation & Localization

  • README Backup Warning: Added explicit warnings advising server owners that OS-level backups are still required for catastrophic hardware failures, despite Caskara's automatic backups.