Class BlockingQueryOptions
java.lang.Object
io.vertx.ext.consul.BlockingQueryOptions
Options used to perform blocking query that used to wait for a potential change using long polling.
- Author:
- Ruslan Sennov
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionDefault constructorBlockingQueryOptions(JsonObject options) Constructor from JSONBlockingQueryOptions(BlockingQueryOptions options) Copy constructor -
Method Summary
-
Constructor Details
-
BlockingQueryOptions
public BlockingQueryOptions()Default constructor -
BlockingQueryOptions
Copy constructor- Parameters:
options- the one to copy
-
BlockingQueryOptions
Constructor from JSON- Parameters:
options- the JSON
-
-
Method Details
-
toJson
-
getIndex
public long getIndex()Get index- Returns:
- the index
-
setIndex
Set index indicating that the client wishes to wait for any changes subsequent to that index.- Parameters:
index- the index- Returns:
- reference to this, for fluency
-
getWait
-
setWait
Specifying a maximum duration for the blocking request. This is limited to 10 minutes. If not set, the wait time defaults to 5 minutes. This value can be specified in the form of "10s" or "5m" (i.e., 10 seconds or 5 minutes, respectively).- Parameters:
wait- wait period- Returns:
- reference to this, for fluency
-