Skip to content

Releases: devspexx/ConfigurationAPI

ConfigurationAPI v1.3.2

11 Apr 12:32
85dbe23

Choose a tag to compare

API Restructure

  • Reorganized package structure for better separation between plugin internals and public API
  • Improved overall readability and maintainability

New API Access Pattern

  • Introduced ConfigurationProvider as the main entry point
  • Simplifies usage and removes direct dependency on internal classes

Naming & Consistency

  • Fixed naming inconsistencies across API and internal classes
  • Clarified distinction between plugin entry and API layer

Watcher Improvements

  • Fixed file deletion handling
  • Prevented checksum errors when files are removed
  • Improved stability of file watching system

Documentation

  • Updated Javadocs across the API
  • Improved clarity for developers integrating the API

This refactor does not introduce breaking behavior, but changes how the API is accessed (via ConfigurationProvider)
Existing integrations may require minor adjustments.

import dev.spexx.configurationAPI.api.ConfigurationProvider;
import org.bukkit.plugin.java.JavaPlugin;
import org.jetbrains.annotations.NotNull;

public final class MyPlugin extends JavaPlugin {

    private ConfigurationProvider configurationProvider;

    public @NotNull ConfigManager getConfigurationProvider() {
        return configurationProvider.api();
    }

    @Override
    public void onEnable() {
        setupConfigurationProvider();
    }

    public void setupConfigurationProvider() {

        // Initialize ConfigurationProvider for this plugin.
        // Passing "this" binds the provider to this plugin's lifecycle.
        configurationProvider = new ConfigurationProvider(this);
        configurationProvider.api().startFileWatcher();
    }
}

What's Changed

Full Changelog: v1.3.1...v1.3.2

ConfigurationAPI 1.3.1

10 Apr 19:27
1992576

Choose a tag to compare

What's Changed

  • refactor: remove redundant in pom.xml by @devspexx in #18
  • refactor: remove PermissionChecker by @devspexx in #19
  • refactor: add experimental getByPath() by @devspexx in #20
  • refactor: implement bootstrap & loader and reorganize structure by @devspexx in #21
  • refactor: bumped version from 1.3.0 to 1.3.1 by @devspexx in #22

Full Changelog: v1.3.0...v1.3.1

ConfigurationAPI 1.3.0

06 Apr 19:15
b89f77e

Choose a tag to compare

This release introduces a major internal rewrite of the ConfigurationAPI, focusing on performance, reliability, and a more modern, event-driven architecture.

  • The configuration system has been fully rewritten
  • Some internal APIs and behaviors may have changed — review your integrations before upgrading

What's Changed

  • refactor(docs): remove # and place slashes as comments by @devspexx in #14
  • refactor!: rewrite configuration API and introduce event-driven reload system by @devspexx in #15
  • removed config.yml by @devspexx in #16
  • refactor: optimize watcher and improve thread-safety by @devspexx in #17

Full Changelog: 1.2.0...v1.3.0

ConfigurationAPI 1.2.0

05 Apr 12:45

Choose a tag to compare

1.2.0 — Configuration API Improvements

Added

  • Added strict validation to ConfigLoadResult
  • Enforces valid state combinations (status, config, error)
  • Added ConfigManager#shutdown() for proper watcher lifecycle management
  • Added safer internal config loading via getInternal(...)
  • Improved YAML validation in GlobalConfigWatcher
  • Prevents invalid/empty YAML from overwriting valid configs
  • Added rollback protection on reload failure

Improved

  • Improved configuration reload stability and safety
  • Enhanced debounce handling for file system events
  • Reduced unnecessary reloads using checksum comparison
  • Improved event firing logic (only fires on valid state transitions)
  • Better logging for reload failures and invalid YAML

Internal

  • Strengthened immutability guarantees for YamlConfig
  • Improved thread-safety clarity and consistency
  • Cleaner watcher registration logic (putIfAbsent)
  • Refactored internal loading flow in ConfigManager

Documentation

  • Full Javadoc overhaul across entire API
  • Added @since to all public methods and classes
  • Made Javadoc fully doclint-compliant
  • Fixed HTML issues (@apiNote, @implSpec, etc.)
  • Improved clarity, structure, and consistency of documentation

Build

  • Fixed Maven Javadoc build failures
  • Ensured javadoc:jar passes without warnings/errors

What's Changed

  • refactor(docs): standardize Javadoc across API and improve internal documentation by @devspexx in #13

Full Changelog: v1.1.0...1.2.0

Java CI With Maven: https://github.com/devspexx/ConfigurationAPI/actions/runs/24002413257/job/70000500882

ConfigurationAPI 1.1.0

05 Apr 11:39
f0084e2

Choose a tag to compare

Overview

Refactors and improves the configuration management API with a focus on safety, clarity, and structured loading behavior.

Changes

  • Introduced structured config loading results (ConfigLoadResult, ConfigLoadStatus)
  • Improved ConfigManager API:
    • clearer separation between get, load, and create operations
    • added safe tryLoad and tryCreate methods
  • Added internal loading flow (loadInternal) to centralize logic
  • Improved file handling and directory creation logic
  • Refactored method naming for better readability and intent

YamlConfig Improvements

  • Added safe typed access methods using Optional
  • Added default-based getters (getXOrDefault)
  • Eliminated silent fallback issues from Bukkit API

Build / Docs

  • Fixed Javadoc doclint issues (build was failing)
  • Standardized documentation across all public APIs

Versioning

  • Migrated to semantic versioning (1.1.0)

Notes

  • No breaking changes to existing usage
  • Internal structure significantly improved for future extensions

What's Changed

  • feat: add safe typed access methods to YamlConfig by @devspexx in #11
  • refactor(config): improve ConfigManager API and loading flow by @devspexx in #12

Full Changelog: v1.0.6...v1.1.0

ConfigurationAPI 1.0.6

05 Apr 09:48
ea45bc4

Choose a tag to compare

What's New

  • Introduced GlobalConfigWatcher as the single source of truth
  • Simplified configuration lifecycle and architecture
  • Added path-based configuration access (getByPath, getOrLoadByPath)
  • Improved API clarity and usability

Changes

  • Removed diff tracking system (simplified design)
  • Standardized configuration handling through watcher
  • Updated README to reflect new architecture

Internal

  • Version bump to 1.0.6
  • Minor refactoring and cleanup

What's Changed

  • docs: update README to reflect new architecture and API usage by @devspexx in #7
  • feat: add path-based configuration access methods by @devspexx in #9
  • chore: bump version to 1.0.6 by @devspexx in #10

Full Changelog: v1.0.5...v1.0.6

ConfigurationAPI 1.0.5

05 Apr 08:44
5a347ea

Choose a tag to compare

Overview

This PR refactors the configuration system by introducing a single global watcher
(GlobalConfigWatcher) as the source of truth for all configuration state.

The goal is to simplify the architecture, remove duplicated state, and ensure
that configuration snapshots are always up to date.


Key Changes

Architecture

  • Introduced GlobalConfigWatcher to manage all file watching and config state
  • Removed per-config watchers in favor of a single shared watcher
  • Made the watcher the single source of truth for:
    • config instances
    • checksums
    • reload logic

ConfigManager

  • Simplified to API-only layer
  • Removed internal config cache (no duplicated state)
  • Delegates all reads to the watcher

Reload System

  • Atomic replacement of YamlConfig instances
  • SHA-256 checksum-based change detection
  • Debounce mechanism to avoid duplicate reloads
  • Synchronous Bukkit event dispatch (ConfigReloadedEvent)

Event Improvements

  • Updated ConfigReloadedEvent to include:
    • old config
    • new config
    • old checksum
    • new checksum
    • reload time (ms)

Watcher Improvements

  • Ignore untracked files (prevents unnecessary processing)
  • Added unregister() for proper cleanup
  • Improved event handling flow and readability
  • Ensured safe threading (async watcher + sync event dispatch)

Documentation

  • Standardized Javadoc across all classes
  • Improved doclint compatibility
  • Clarified lifecycle, threading, and usage expectations

Result

  • Cleaner and more maintainable architecture
  • No duplicated configuration state
  • Always-consistent config snapshots
  • Improved performance and correctness

What's Changed

  • Add README.md for ConfigurationAPI documentation by @devspexx in #3
  • docs: add Javadoc for ConfigurationAPI constructor and entry point by @devspexx in #4
  • docs: improve README with features and rationale by @devspexx in #5
  • refactor: introduce GlobalConfigWatcher and simplify config lifecycle by @devspexx in #6

Full Changelog: v1.0.4...v1.0.5

ConfigurationAPI 1.0.4

04 Apr 19:18
cd993e2

Choose a tag to compare

Summary

Improves the robustness, safety, and performance of the YamlConfigWatcher to make it production-ready.

Changes

  • Added retry mechanism for file reads to avoid partial/locked file issues
  • Introduced event throttling to prevent excessive reload triggers
  • Improved debounce handling for rapid filesystem events
  • Added diff size limit to prevent excessive memory usage
  • Hardened watcher thread lifecycle and exception handling
  • Improved logging for failure scenarios and edge cases
  • Ensured safe execution when plugin is disabled

Technical Notes

  • Maintains O(n) diff complexity with optimized line parsing
  • Avoids regex-based splitting for better performance
  • Uses defensive guards against transient filesystem states (delete/recreate)

Result

More stable, predictable, and safe configuration reload behavior under real-world conditions.

What's Changed

  • Remove unused config.yml and plugin boilerplate by @devspexx in #1
  • Harden YamlConfigWatcher for production use by @devspexx in #2

New Contributors

Full Changelog: v1.0.3...v1.0.4

ConfigurationAPI 1.0.3

04 Apr 18:36
cd993e2

Choose a tag to compare

Version 1.0.3

  • Optimized line splitting (removed regex-based split)
  • Introduced manual line parsing (splitLines) for better performance
  • Reduced memory allocations during diff computation
  • Added lazy diff allocation (only allocate when changes exist)
  • Added early-exit optimization for identical content
  • Improved overall performance for large configuration files
  • Minor Javadoc refinements and doclint compliance fixes

What's Changed

  • Remove unused config.yml and plugin boilerplate by @devspexx in #1
  • Harden YamlConfigWatcher for production use by @devspexx in #2

New Contributors

Full Changelog: v1.0.2...v1.0.3

ConfigurationAPI 1.0.2

04 Apr 18:50

Choose a tag to compare

Version 1.0.2

  • Introduced ConfigChangeSummary (replaces raw change counters)
  • Added hasChanges() and getTotalChanges() convenience methods
  • Refactored ConfigReloadedEvent to use summary object
  • Made diff list immutable (List.copyOf) for safety
  • Improved API clarity and consumer ergonomics
  • Strengthened immutability guarantees across event data