aboutsummaryrefslogtreecommitdiffstats
path: root/vespaclient-container-plugin
diff options
context:
space:
mode:
authorJon Bratseth <bratseth@oath.com>2018-05-25 14:01:39 +0200
committerJon Bratseth <bratseth@oath.com>2018-05-25 14:01:39 +0200
commitda778405d6e8888f0f90444dc4a3610c5bf9f1bc (patch)
treecade483795b041b93bfebe43788af093de0af2d2 /vespaclient-container-plugin
parent5db3df1e1c76922c8f9c66f2036f32bf0808012f (diff)
More document JSON validation to improve error messages
Diffstat (limited to 'vespaclient-container-plugin')
-rw-r--r--vespaclient-container-plugin/src/main/java/com/yahoo/vespa/http/server/ClientFeederV3.java11
1 files changed, 3 insertions, 8 deletions
diff --git a/vespaclient-container-plugin/src/main/java/com/yahoo/vespa/http/server/ClientFeederV3.java b/vespaclient-container-plugin/src/main/java/com/yahoo/vespa/http/server/ClientFeederV3.java
index 0d8cde234eb..cd491073a1c 100644
--- a/vespaclient-container-plugin/src/main/java/com/yahoo/vespa/http/server/ClientFeederV3.java
+++ b/vespaclient-container-plugin/src/main/java/com/yahoo/vespa/http/server/ClientFeederV3.java
@@ -150,11 +150,7 @@ class ClientFeederV3 {
log.log(LogLevel.WARNING, "Unhandled exception while feeding: "
+ Exceptions.toMessageString(e), e);
} finally {
- try {
- replies.add(createOperationStatus("-", "-", ErrorCode.END_OF_FEED, false, null));
- } catch (InterruptedException e) {
- // NOP, we are already exiting the thread
- }
+ replies.add(createOperationStatus("-", "-", ErrorCode.END_OF_FEED, false, null));
}
return new FeedResponse(200, replies, 3 /* protocol version */, clientId, outstandingOperations.get(), hostName);
} finally {
@@ -266,8 +262,8 @@ class ClientFeederV3 {
}
}
- private OperationStatus createOperationStatus(String id, String message, ErrorCode code, boolean isConditionNotMet, Message msg)
- throws InterruptedException {
+ private OperationStatus createOperationStatus(String id, String message,
+ ErrorCode code, boolean isConditionNotMet, Message msg) {
String traceMessage = msg != null && msg.getTrace() != null && msg.getTrace().getLevel() > 0
? msg.getTrace().toString()
: "";
@@ -288,7 +284,6 @@ class ClientFeederV3 {
}
DocumentOperationMessageV3 msg = DocumentOperationMessageV3.create(operation, operationId, metric);
- xxx
if (msg == null) {
// typical end of feed
return null;