blob: d9eaff40d746e173e62c8076577ff83610b561fb (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
package ai.vespa.feed.client;
import java.util.Optional;
/**
* Signals that the document API in the feed container returned a failure result for a feed operation.
*
* @author jonmv
*/
public class ResultException extends FeedException {
private final String trace;
public ResultException(DocumentId documentId, String message, String trace) {
super(documentId, message);
this.trace = trace;
}
/** Holds the trace, if the failed operation had a {@link OperationParameters#tracelevel(int)} higher than 0. */
public Optional<String> getTrace() {
return Optional.ofNullable(trace);
}
}
|