There appear to be two definitions of the word ergodic.

The dynamical systems definition says that a measure space $(X,\mathit B, \mu)$ and measure preserving transformation $T: X \mapsto X$ is *ergodic* if

the only $T$-invariant sets have measure 0 or 1.

However, a Markov chain is ergodic if

there exists $t$ such that for all $x,y \in \Omega, P^t(x,y) >0$

I've used the Markov chain notation and definition found here

I would like to know if these definitions are equivalent.

Of course, I am asking here because it seems to me that they are not. For example, if $X=\{0,1\}$, $\mathit B = \{\emptyset, \{0\},\{1\},X\}$, $\mu(\{0\})=0,\mu(\{1\})=1$ and $T(x) = 1$ for all $x\in X$, then $(X,\mathit B, \mu, T)$ is ergodic as a dynamical system, but the equivalent Markov chain is not ergodic, since the probability of traveling from $0$ to $1$ is zero.