Quickstart

Get runtime configuration hot-swap working in your Spring Boot application in under 60 seconds.

Step 1: Add the dependency

<dependency>
    <groupId>com.mymarz</groupId>
    <artifactId>marz-spring-boot-starter</artifactId>
    <version>0.1.0</version>
</dependency>

Step 2: Annotate your field

@Service
public class CheckoutService {

    @Marz(key = "feature.checkout.enabled",
          source = "file://config/features.yml")
    private volatile boolean newCheckoutEnabled = false;

    public void processOrder(Order order) {
        if (newCheckoutEnabled) {
            // New checkout flow
        } else {
            // Legacy flow
        }
    }
}

Step 3: Create your config file

# config/features.yml
feature:
  checkout:
    enabled: false

Step 4: Change the value — no restart needed

Edit config/features.yml and change enabled: false to enabled: true. MARZ detects the file change via OS-level WatchService in ~50ms and updates the volatile field in memory. Your next request sees the new value. No restart. No proxy. No actuator call.