Class Tm1Timeouts.Builder
java.lang.Object
io.skipcheck.tm1.client.session.Tm1Timeouts.Builder
- Enclosing class:
Tm1Timeouts
Builds
Tm1Timeouts. Written by hand rather than with Lombok's
@Builder, so its methods can carry Javadoc.-
Method Summary
Modifier and TypeMethodDescriptionbuild()The timeouts.Sets the close timeout.Sets the connect timeout.Sets the login timeout.refusedLogin(Duration refusedLogin) Sets how long a refused login is remembered.Sets the request idle timeout.
-
Method Details
-
connect
Sets the connect timeout.- Parameters:
connect- how long to wait for a connection, including TLS- Returns:
- this builder
-
login
Sets the login timeout.- Parameters:
login- how long to wait for a login response- Returns:
- this builder
-
request
Sets the request idle timeout.- Parameters:
request- how long a request may go without receiving any data- Returns:
- this builder
-
close
Sets the close timeout.- Parameters:
close- how long to wait for TM1 to close the session- Returns:
- this builder
-
refusedLogin
Sets how long a refused login is remembered.- Parameters:
refusedLogin- how long requests fail at once after TM1 refused a login; zero to log in again straight away- Returns:
- this builder
-
build
The timeouts.- Returns:
- the timeouts, with unset values at their defaults
- Throws:
IllegalArgumentException- if a timeout is zero or negative
-