The totalTimeout is tracked on the client and sent to the server along with the transaction in the wire protocol. The client will most likely timeout first, but the server also has the capability to timeout the transaction.
If totalTimeout is not zero and totalTimeout is reached before the transaction completes, the transaction will abort with AerospikeExceptionTimeout.
If totalTimeout is zero, there will be no total time limit.
Default for scan/query: 0 (no time limit)
Default for all other commands: 1000ms
public int totalTimeout