Let $(X_i)_{i \geq 1}$ be a sequence of i.i.d. random variables with $\mathbb{E}[X_i]= \mu$ and $Var[X_i]= \sigma^2$.
Let $\tau$ be a non-negative integer-valued random variable independent of $X_i$.
Now consider $S_n:=\sum_{i=1}^n X_i$.
We want to show that $\mathbb{E}[S_{\tau} \mid \tau] = \mu \tau$ a.s. for $\mathbb{E}[\tau]< \infty$.
In the proof there first is shown that $\mathbb{E}[|S_{\tau}|]\leq \mathbb{E}[|X_i|]\mathbb{E}[\tau]$ using the monotone convergence theorem.
Then we calculate
$\mathbb{E}[S_{\tau} \mid \tau] = \mathbb{E}[S_k] \mid_{k=\tau}=\mu k \mid_{k = \tau}= \mu \tau$.
What confuses me now is: do we really need that statement above about the absolute value derived using the monotone convergence theorem? Under which circumstances is the second calculation (with the conditional expectation) valid? I would suggest that we calculated this to justify the use of dominated convergence, but where do we use dominated convergence in the following?
Then it is mentioned that we can use the tower property of conditional expectation to derive that $\mathbb{E}[S_{\tau}]= \mu \mathbb{E}[\tau]$. Do we need the above statement for this?
It is not clear a priori that $S_\tau$ is integrable, and this rests on the assumption that $\tau$ has a finite expectation. In that way, the computations are justified.
We indeed have $$\mathbb E[|S_\tau| ]=\mathbb E\left[ \sum_{j=0}^\infty\mathbf 1_{\tau=j}|S_j| \right]$$ and we need to switch the expectation with the infinite sum, which is done by monotone convergence.