Your explanation doesn't fit the passage.
From enduringword.com,
"Many commentators believe this is a psalm of David and is his prayer and trust in God in his latter years under the crisis of Absalom’s rebellion."
Here's more of the Psalm:
(Psalms 71:17-21 NIV) Since my youth, O God, you have taught me, and to this day I declare your marvelous deeds. {18} Even when I am old and gray, do not forsake me, O God, till I declare your power to the next generation, your might to all who are to come. {19} Your righteousness reaches to the skies, O God, you who have done great things. Who, O God, is like you? {20} Though you have made me see troubles, many and bitter, you will restore my life again; from the depths of the earth you will again bring me up. {21} You will increase my honor and comfort me once again.