GH-1611: Add health indicators for Qdrant and Weaviate#5553
Closed
DDINGJOO wants to merge 1 commit intospring-projects:mainfrom
Closed
GH-1611: Add health indicators for Qdrant and Weaviate#5553DDINGJOO wants to merge 1 commit intospring-projects:mainfrom
DDINGJOO wants to merge 1 commit intospring-projects:mainfrom
Conversation
Closes #1611 Signed-off-by: ddingjoo <ddingsha9@teambind.co.kr>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR adds Actuator health indicators for two external vector stores:
The indicators are conditionally auto-configured and can be disabled with:
management.health.qdrant.enabled=falsemanagement.health.weaviate.enabled=falseWhy
Issue #1611 requests health indicators for vector stores that can become unavailable independently from the application.
Changes
QdrantVectorStoreHealthAutoConfigurationWeaviateVectorStoreHealthAutoConfigurationAutoConfiguration.importsorg.springframework.boot:spring-boot-healthin both autoconfigure modulesBehavior
Qdrant health indicator:
QdrantClient.healthCheckAsync(Duration.ofSeconds(5))UPwith details (title,version, optionalcommit,host,port)DOWNon exceptionWeaviate health indicator:
weaviateClient.misc().liveChecker().run()UPwhen result is true and no errorsDOWNwhen response has errors, result is false/null, or exception occurslive,hasErrors, optionalerror,host)Tests
Qdrant:
management.health.qdrant.enabled=falseqdrantHealthIndicatorbean is providedWeaviate:
run()throwsmanagement.health.weaviate.enabled=falseweaviateHealthIndicatorbean is providedBuild Verification
./mvnw -pl auto-configurations/vector-stores/spring-ai-autoconfigure-vector-store-qdrant -Dmaven.build.cache.enabled=false -Denforcer.skip=true -Dkotlin.compiler.skip=true test./mvnw -pl auto-configurations/vector-stores/spring-ai-autoconfigure-vector-store-weaviate -Dmaven.build.cache.enabled=false -Denforcer.skip=true -Dkotlin.compiler.skip=true testRelated to #1611