Boost Spring Boot Development with mica-auto: Auto-Generate Starter Configurations

mica-auto is a Spring Boot starter tool that uses annotation processing to automatically generate configuration files such as spring.factories, AutoConfiguration.imports, and spring-devtools.properties, supporting Kotlin meta‑annotations and Java SPI, with Maven and Gradle integration instructions and version compatibility details.

Java Architecture Diary
Java Architecture Diary
Java Architecture Diary
Boost Spring Boot Development with mica-auto: Auto-Generate Starter Configurations

1. Introduction

mica-auto (Spring Boot starter tool) is used to generate Spring Boot starter configuration files. It employs an Annotation Processor to scan @Component at compile time, automatically creating the appropriate configuration and supporting composite annotations. mica-auto is widely used in the mica, mica-mqtt, pig, and SpringBlade ecosystems.

2. Features

Generate spring.factories.

Support Spring Boot 2.7.x new AutoConfiguration annotation, generating entries in the new AutoConfiguration.imports configuration.

Generate spring-devtools.properties.

Generate Java SPI configuration, requiring the @AutoService annotation.

3. Update Log

✨ Support Kotlin meta‑annotation (GitHub #8), thanks to @Sunrise66 for feedback.

Version info:

Version 3.1.2 – Spring Boot 3.x – Java 17

Version 2.3.3 – Spring Boot 1.x ~ 3.x – Java 1.8

Note: mica-auto does not enforce a Spring Boot dependency; it only bundles spring-boot-configuration-processor for convenience.

4. Usage

Note:

If your project uses Lombok, place the mica-auto dependency after Lombok.

Maven

<dependency>
  <groupId>net.dreamlu</groupId>
  <artifactId>mica-auto</artifactId>
  <version>${mica-auto.version}</version>
  <scope>provided</scope>
</dependency>

Gradle >= 5.x

annotationProcessor("net.dreamlu:mica-auto:$micaAutoVersion}")

Gradle < 5.x

compileOnly "net.dreamlu:mica-auto:$micaAutoVersion"

5. Effect

mica-auto effect image 1
mica-auto effect image 1
mica-auto effect image 2
mica-auto effect image 2

Using mica-auto to automatically generate Spring Boot starter configurations frees your hands and prevents missing or incorrect configurations that could cause service startup failures. Give it a try!

Original Source

Signed-in readers can open the original source through BestHub's protected redirect.

Sign in to view source
Republication Notice

This article has been distilled and summarized from source material, then republished for learning and reference. If you believe it infringes your rights, please contactadmin@besthub.devand we will review it promptly.

ConfigurationGradleSpring BootAnnotation Processor
Java Architecture Diary
Written by

Java Architecture Diary

Committed to sharing original, high‑quality technical articles; no fluff or promotional content.

0 followers
Reader feedback

How this landed with the community

Sign in to like

Rate this article

Was this worth your time?

Sign in to rate
Discussion

0 Comments

Thoughtful readers leave field notes, pushback, and hard-won operational detail here.