From ad5add0e027cfbc384055c540e0b8f96c6f37543 Mon Sep 17 00:00:00 2001 From: jonmv Date: Fri, 5 Jan 2024 11:55:37 +0100 Subject: Do not retry server errors (500, 502, 504) when feeding --- .../test/java/ai/vespa/feed/client/impl/HttpRequestStrategyTest.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'vespa-feed-client/src/test/java') diff --git a/vespa-feed-client/src/test/java/ai/vespa/feed/client/impl/HttpRequestStrategyTest.java b/vespa-feed-client/src/test/java/ai/vespa/feed/client/impl/HttpRequestStrategyTest.java index 36e81ff4abb..c943e3b139f 100644 --- a/vespa-feed-client/src/test/java/ai/vespa/feed/client/impl/HttpRequestStrategyTest.java +++ b/vespa-feed-client/src/test/java/ai/vespa/feed/client/impl/HttpRequestStrategyTest.java @@ -151,7 +151,7 @@ class HttpRequestStrategyTest { assertEquals(success, serialised.get()); // Some error responses are retried. - HttpResponse serverError = HttpResponse.of(500, null); + HttpResponse serverError = HttpResponse.of(503, null); cluster.expect((__, vessel) -> vessel.complete(serverError)); assertEquals(serverError, strategy.enqueue(id1, request).get()); assertEquals(11, strategy.stats().requests()); @@ -180,7 +180,7 @@ class HttpRequestStrategyTest { codes.put(200, 4L); codes.put(400, 1L); codes.put(429, 2L); - codes.put(500, 3L); + codes.put(503, 3L); assertEquals(codes, stats.responsesByCode()); assertEquals(3, stats.exceptions()); -- cgit v1.2.3