Did your app support rtsp reconnect? if not, when network unavailable, the pipeline will stop running. you can refer to deepstream_source_bin.c for rtsp reconnect.
You also can monitor the memory usage if the issue caused by mem leak. please refer to DeepStream SDK FAQ - Intelligent Video Analytics / DeepStream SDK - NVIDIA Developer Forums, the script is for Jetson, but you can just have your attention on software memory usage if you are on dGPU. for dGPU, hardware memory usage, you can check nvidia-smi -l 1