thswlsqls opened a new pull request, #9969: URL: https://github.com/apache/paimon/pull/9969
### Purpose fix #9968 - Following the README, an `ARRAY<FLOAT>` es-index whose `dimension` is passed only through `sys.create_global_index(... options => ...)` fails every `vector_search`, `full_text_search` and companion-column `WHERE` query with "Vector field 'embedding' requires a positive dimension": `ESIndexGlobalIndexer` parses `ESIndexOptions` in its constructor, while the core read paths create it from the table options only. - Defer the parse to `createWriter`, so invalid build options still fail there with the same message instead of in the constructor. `ESIndexGlobalIndexReader` uses the persisted field configuration and requires the current options only for legacy offset-only metadata. - Resolve the configured vector metric from the options directly so `metric()` works before a reader is registered. ### Tests - Added `ESIndexVectorMetricTest#readerDoesNotRequireCurrentOptionsToDescribeBuild`, `#writerStillRejectsOptionsThatCannotDescribeBuild`, `#legacyMetadataStillRequiresCurrentOptions`; all three fail on master in the `ESIndexGlobalIndexer` constructor. - `mvn -Ppaimon-eslib -pl paimon-eslib clean install` (JDK 11, checkstyle and spotless included): BUILD SUCCESS, 0 failures; `ESIndexVectorMetricTest` 7/7. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
