public class NodeResponse extends Object
Modifier and Type | Field and Description |
---|---|
private com.sun.jersey.api.client.ClientResponse |
clientResponse |
private boolean |
hasCreatedResponse |
private String |
httpMethod |
private static org.slf4j.Logger |
logger |
private NodeIdentifier |
nodeId |
private long |
requestDurationNanos |
private String |
requestId |
private URI |
requestUri |
private Throwable |
throwable |
private Entity |
updatedEntity |
Constructor and Description |
---|
NodeResponse(NodeIdentifier nodeId,
String httpMethod,
URI requestUri,
com.sun.jersey.api.client.ClientResponse clientResponse,
long requestDurationNanos,
String requestId) |
NodeResponse(NodeIdentifier nodeId,
String httpMethod,
URI requestUri,
Throwable throwable) |
NodeResponse(NodeResponse example,
Entity updatedEntity) |
Modifier and Type | Method and Description |
---|---|
private javax.ws.rs.core.Response |
createResponse() |
boolean |
equals(Object obj) |
com.sun.jersey.api.client.ClientResponse |
getClientResponse()
Returns null if hasThrowable() is true; otherwise the client's response is returned.
|
String |
getHttpMethod() |
NodeIdentifier |
getNodeId() |
long |
getRequestDuration(TimeUnit timeUnit) |
String |
getRequestId() |
URI |
getRequestUri() |
javax.ws.rs.core.Response |
getResponse()
Creates a Response by mapping the ClientResponse values to it.
|
int |
getStatus() |
Throwable |
getThrowable()
Returns the throwable or null if no throwable exists.
|
Entity |
getUpdatedEntity()
If this node response has been merged returns the updated entity, otherwise null.
|
int |
hashCode() |
boolean |
hasThrowable()
Returns true if a throwable was thrown and a response was not able to be created; false otherwise.
|
boolean |
is2xx() |
boolean |
is5xx() |
String |
toString() |
private static final org.slf4j.Logger logger
private final String httpMethod
private final URI requestUri
private final com.sun.jersey.api.client.ClientResponse clientResponse
private final NodeIdentifier nodeId
private final Throwable throwable
private boolean hasCreatedResponse
private final Entity updatedEntity
private final long requestDurationNanos
private final String requestId
public NodeResponse(NodeIdentifier nodeId, String httpMethod, URI requestUri, com.sun.jersey.api.client.ClientResponse clientResponse, long requestDurationNanos, String requestId)
public NodeResponse(NodeIdentifier nodeId, String httpMethod, URI requestUri, Throwable throwable)
public NodeResponse(NodeResponse example, Entity updatedEntity)
public NodeIdentifier getNodeId()
public String getHttpMethod()
public URI getRequestUri()
public int getStatus()
public boolean is2xx()
public boolean is5xx()
public com.sun.jersey.api.client.ClientResponse getClientResponse()
public Entity getUpdatedEntity()
public javax.ws.rs.core.Response getResponse()
public Throwable getThrowable()
public boolean hasThrowable()
public long getRequestDuration(TimeUnit timeUnit)
public String getRequestId()
private javax.ws.rs.core.Response createResponse()
Copyright © 2016 Apache NiFi Project. All rights reserved.