CaFe$_{2}$O$_{4}$ is an $S=5/2$ antiferromagnet exhibiting two magnetic orders which shows regions of coexistence at some temperatures. Using a Greens function formalism, we model neutron scattering data of the spin wave excitations in this material, ellucidating the microscopic spin Hamiltonian. In doing so, we suggest that the low temperature A phase order $(uparrowuparrowdownarrowdownarrow)$ finds its origins in the freezing of antiphase boundaries created by thermal fluctuations in a parent B phase order $(uparrowdownarrowuparrowdownarrow)$. The low temperature magnetic order observed in CaFe$_{2}$O$_{4}$ is thus the result of a competition between the exchange coupling along $c$, which favors the B phase, and the single-ion anisotropy which stabilizes thermally-generated antiphase boundaries, leading to static metastable A phase order at low temperatures.