From c0fc0033ccf12b9fcf00b59141a4fd4e8cd630a8 Mon Sep 17 00:00:00 2001 From: Andrew Ross Date: Tue, 27 Aug 2024 14:35:36 -0500 Subject: [PATCH] Throw UnsupportedOperationException in unused methods (#15446) These methods infinitely recurse as currently implemented. This change makes them throw UnsupportedOperationException similar to many other methods in this class. Signed-off-by: Andrew Ross --- .../org/opensearch/index/engine/TranslogLeafReader.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/server/src/main/java/org/opensearch/index/engine/TranslogLeafReader.java b/server/src/main/java/org/opensearch/index/engine/TranslogLeafReader.java index dea389bb6a0ff..94b8c6181de4e 100644 --- a/server/src/main/java/org/opensearch/index/engine/TranslogLeafReader.java +++ b/server/src/main/java/org/opensearch/index/engine/TranslogLeafReader.java @@ -264,13 +264,13 @@ public CacheHelper getReaderCacheHelper() { } @Override - public FloatVectorValues getFloatVectorValues(String field) throws IOException { - return getFloatVectorValues(field); + public FloatVectorValues getFloatVectorValues(String field) { + throw new UnsupportedOperationException(); } @Override - public ByteVectorValues getByteVectorValues(String field) throws IOException { - return getByteVectorValues(field); + public ByteVectorValues getByteVectorValues(String field) { + throw new UnsupportedOperationException(); } @Override