public class SnapshotsStatusRequest extends MasterNodeRequest<SnapshotsStatusRequest>
TransportRequest.Empty
DEFAULT_MASTER_NODE_TIMEOUT, masterNodeTimeout
Constructor and Description |
---|
SnapshotsStatusRequest() |
SnapshotsStatusRequest(java.lang.String repository)
Constructs a new get snapshots request with given repository name
|
SnapshotsStatusRequest(java.lang.String repository,
java.lang.String[] snapshots)
Constructs a new get snapshots request with given repository name and list of snapshots
|
Modifier and Type | Method and Description |
---|---|
boolean |
ignoreUnavailable()
Returns whether the request permits unavailable snapshots to be ignored.
|
SnapshotsStatusRequest |
ignoreUnavailable(boolean ignoreUnavailable)
Set to
true to ignore unavailable snapshots, instead of throwing an exception. |
void |
readFrom(StreamInput in)
Set this object's fields from a StreamInput.
|
java.lang.String |
repository()
Returns repository name
|
SnapshotsStatusRequest |
repository(java.lang.String repository)
Sets repository name
|
java.lang.String[] |
snapshots()
Returns the names of the snapshots.
|
SnapshotsStatusRequest |
snapshots(java.lang.String[] snapshots)
Sets the list of snapshots to be returned
|
ActionRequestValidationException |
validate() |
void |
writeTo(StreamOutput out)
Write this object's fields to a StreamOutput.
|
masterNodeTimeout, masterNodeTimeout, masterNodeTimeout
getShouldStoreResult
getParentTask, setParentTask
remoteAddress, remoteAddress
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
createTask, getDescription, setParentTask
public SnapshotsStatusRequest()
public SnapshotsStatusRequest(java.lang.String repository, java.lang.String[] snapshots)
repository
- repository namesnapshots
- list of snapshotspublic SnapshotsStatusRequest(java.lang.String repository)
repository
- repository namepublic ActionRequestValidationException validate()
validate
in class ActionRequest
public SnapshotsStatusRequest repository(java.lang.String repository)
repository
- repository namepublic java.lang.String repository()
public java.lang.String[] snapshots()
public SnapshotsStatusRequest snapshots(java.lang.String[] snapshots)
public SnapshotsStatusRequest ignoreUnavailable(boolean ignoreUnavailable)
true
to ignore unavailable snapshots, instead of throwing an exception.
Defaults to false
, which means unavailable snapshots cause an exception to be thrown.ignoreUnavailable
- whether to ignore unavailable snapshotspublic boolean ignoreUnavailable()
public void readFrom(StreamInput in) throws java.io.IOException
Streamable
readFrom
in interface Streamable
readFrom
in class MasterNodeRequest<SnapshotsStatusRequest>
java.io.IOException
public void writeTo(StreamOutput out) throws java.io.IOException
Streamable
writeTo
in interface Streamable
writeTo
in class MasterNodeRequest<SnapshotsStatusRequest>
java.io.IOException