skipcheck

TM1 client · Docs · Sessions and logins

Tm1Timeouts

using Skipcheck.Tm1.Client.Session;

How long the session waits, by kind of work. TM1 answers some calls only when the work is done, so one timeout for everything is either too short for processes or too long for a login.

// Let a request go two hours without data, for a long process run synchronously
var timeouts = Tm1Timeouts.Builder().Request(TimeSpan.FromHours(2)).Build();

A builder leaves unset values at the defaults below.

Members

Defaults staticThe defaults.
Tm1Timeouts constructorTimeouts, each positive (or, for refusedLogin, not negative).
Connect propertyHow long to wait for a connection, including TLS.
Login propertyHow long to wait for a login response.
Request propertyHow long a request may go without receiving any data, unless the request sets its own (Tm1Request{T}.WithTimeout).
Close propertyHow long to wait for TM1 to close the session.
RefusedLogin propertyHow long a login TM1 refused (wrong credentials, an unknown or disabled user, impersonation not allowed) is remembered.
Builder staticA builder starting from the defaults.
ToBuilderA builder starting from these timeouts, to change some of them.

Defaults

static
Tm1Timeouts Defaults

The defaults: 10 s to connect, 30 s for a login, 10 min without data for a request, 5 s to close, and a refused login remembered for 30 s.

Tm1Timeouts

constructor
Tm1Timeouts(TimeSpan connect, TimeSpan login, TimeSpan request, TimeSpan close, TimeSpan refusedLogin)

Timeouts, each positive (or, for refusedLogin, not negative).

Throws

ArgumentException
A timeout is out of range.

Connect

property
TimeSpan Connect

How long to wait for a connection, including TLS. Default 10 s.

Login

property
TimeSpan Login

How long to wait for a login response. Short, because a TM1 that is still loading accepts connections and never answers. The authenticator gets as long again to supply the credentials first, since it may ask another server, such as Cognos for a passport. Default 30 s.

Request

property
TimeSpan Request

How long a request may go without receiving any data, unless the request sets its own (Tm1Request{T}.WithTimeout). An idle timeout, not a limit on the whole response, so a large collection that keeps streaming isn't cut off. Default 10 min.

Close

property
TimeSpan Close

How long to wait for TM1 to close the session. Default 5 s.

RefusedLogin

property
TimeSpan RefusedLogin

How long a login TM1 refused (wrong credentials, an unknown or disabled user, impersonation not allowed) is remembered. Until then, requests fail at once with the same error instead of logging in again: every attempt leaves a session behind on TM1, so retrying a refusal at once would pile them up. Zero turns this off. Default 30 s.

Builder

static
TimeoutsBuilder Builder()

A builder starting from the defaults.

ToBuilder

TimeoutsBuilder ToBuilder()

A builder starting from these timeouts, to change some of them.