Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Feat: Add Spring Boot AutoConfiguration#260

Open
vitinh0z wants to merge 3 commits intospotify:masterspotify/github-java-client:masterfrom
vitinh0z:feature/spring-boot-autoconfigvitinh0z/github-java-client:feature/spring-boot-autoconfigCopy head branch name to clipboard
Open

Feat: Add Spring Boot AutoConfiguration#260
vitinh0z wants to merge 3 commits intospotify:masterspotify/github-java-client:masterfrom
vitinh0z:feature/spring-boot-autoconfigvitinh0z/github-java-client:feature/spring-boot-autoconfigCopy head branch name to clipboard

Conversation

@vitinh0z
Copy link

Description

This PR introduces Spring Boot AutoConfiguration to the library.
It automatically registers the GithubApiModule bean when the library is used in a Spring Boot application that has Jackson on the classpath.

Resolves

Closes #61

Changes

  • Added optional dependencies for spring-boot-autoconfigure (v2.7.18 for Java 11 compatibility).
  • Added GithubClientAutoConfiguration to conditionally register the GithubApiModule bean.
  • Registered the configuration in META-INF/spring/org.springframework.boot.autoconfigure.AutoConfiguration.imports.
  • Added GithubClientAutoConfigurationTest using ApplicationContextRunner to verify the behavior.

Verification

  • Ran mvn clean install -DskipTests locally -> BUILD SUCCESS.
  • Ran mvn test locally -> All tests passed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Spring Boot config

1 participant

Morty Proxy This is a proxified and sanitized view of the page, visit original site.