diff options
Diffstat (limited to 'vespaclient-container-plugin')
-rw-r--r-- | vespaclient-container-plugin/src/main/java/com/yahoo/vespa/http/server/FeedReplyReader.java | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/vespaclient-container-plugin/src/main/java/com/yahoo/vespa/http/server/FeedReplyReader.java b/vespaclient-container-plugin/src/main/java/com/yahoo/vespa/http/server/FeedReplyReader.java index 3762d52ba19..2fbb80d9fcc 100644 --- a/vespaclient-container-plugin/src/main/java/com/yahoo/vespa/http/server/FeedReplyReader.java +++ b/vespaclient-container-plugin/src/main/java/com/yahoo/vespa/http/server/FeedReplyReader.java @@ -15,9 +15,13 @@ import com.yahoo.vespa.http.client.core.ErrorCode; import com.yahoo.vespa.http.client.core.OperationStatus; import java.util.Map; +import java.util.Optional; +import java.util.function.Predicate; import java.util.logging.Level; import java.util.logging.Logger; +import static java.util.function.Predicate.not; + /** * Catch message bus replies and make the available to a given session. * @@ -71,6 +75,8 @@ public class FeedReplyReader implements ReplyHandler { private static boolean updateNotFound(Reply reply) { return reply instanceof UpdateDocumentReply && ! ((UpdateDocumentReply) reply).wasFound() + && reply.getMessage() instanceof UpdateDocumentMessage + && ((UpdateDocumentMessage) reply.getMessage()).getDocumentUpdate() != null && ! ((UpdateDocumentMessage) reply.getMessage()).getDocumentUpdate().getCreateIfNonExistent(); } |