In this article, we model the distributed relay assignment network as a many-to-one matching market with peer effects. We discuss two scenarios for throughput optimization of relay networks: the scenario of aggregate throughput optimization and the scenario of fairness performance optimization. For the first scenario, we propose a Mutual Benefit-based Deferred Acceptance (MBDA) algorithm to increase the aggregate network throughput. For the second scenario, instead of using the alternative matching scheme, a non-substitution matching algorithm (NSA) is designed to solve the fairness problem. The NSA improves the fairness performance. We prove that both two algorithms converge to a globally stable matching, and discuss the practical implementation. Simulation results show that the performance of MBDA algorithm outperforms existing schemes and is almost the same with the optimal solution in terms of aggregate throughput. Meanwhile, the proposed NSA improves fairness as the scale of the relay network expands.