File tree Expand file tree Collapse file tree 2 files changed +3
-8
lines changed
qa/vector/src/main/java/org/elasticsearch/test/knn Expand file tree Collapse file tree 2 files changed +3
-8
lines changed Original file line number Diff line number Diff line change @@ -177,13 +177,8 @@ public static void main(String[] args) throws Exception {
177177 cmdLineArgs .vectorSpace (),
178178 cmdLineArgs .numDocs ()
179179 );
180- if (Files .exists (indexPath ) == false ) {
181- if (cmdLineArgs .reindex () == false ) {
182- throw new IllegalArgumentException ("Index path does not exist: " + indexPath );
183- }
184- if (cmdLineArgs .forceMerge ()) {
185- throw new IllegalArgumentException ("Force merging without an existing index in: " + indexPath );
186- }
180+ if (cmdLineArgs .reindex () == false && Files .exists (indexPath ) == false ) {
181+ throw new IllegalArgumentException ("Index path does not exist: " + indexPath );
187182 }
188183 if (cmdLineArgs .reindex ()) {
189184 knnIndexer .createIndex (result );
Original file line number Diff line number Diff line change @@ -304,7 +304,7 @@ private void readNext() throws IOException {
304304 bytes .position (0 );
305305 // wrap around back to the start of the file if we hit the end:
306306 logger .warn ("VectorReader hit EOF when reading " + this .input + "; now wrapping around to start of file again" );
307- this . input .position (position );
307+ input .position (position );
308308 bytesRead = Channels .readFromFileChannel (this .input , position , bytes );
309309 if (bytesRead < bytes .capacity ()) {
310310 throw new IllegalStateException (
You can’t perform that action at this time.
0 commit comments