Maximizing the aggregate network performance over constrained computing and communication resources has been an active research area. Real-time wireless sensor network (RTWSN) is an important application of real-time and networked embedded systems. Due to the severe resources constraints and associated real-time requirements, new challenges arise in RTWSN. In this paper, we study an integrated scheme to optimize the total system performance of real-time flows over an RTWSN by exploiting multi-path routing and dynamic sampling rate assignment. We formally model the problem using nonlinear optimization and design an online distributed algorithm to obtain the optimal rate assignments on multiple paths. Extensive simulation studies demonstrates the significant performance improvements over existing proposals.