Files
spring-ai/vector-stores
Soby Chacko 9eeee6178c GH-3181: fix: Validate index name exists in CassandraVectorStore
Fixes: #3181

https://github.com/spring-projects/spring-ai/issues/3181

When using CassandraVectorStore with an invalid index name and
initializeSchema=false, the application would throw a generic
NoSuchElementException from Optional.get() with message "No value present"
when trying to access the index metadata.

Changes:
- Added explicit validation of index existence in checkSchemaValid() method
- Improved error handling in getIndexSimilarity() method to provide a clear
  error message when an index doesn't exist
- Added integration test to verify proper error handling with invalid index names

Signed-off-by: Soby Chacko <soby.chacko@broadcom.com>
2025-05-16 12:45:30 +01:00
..