"Come now you who say, 'Today or tomorrow we will go to such and such a city and spend a year there and engage in business and make a profit'. Yet you do not know what your life will be like tomorrow. You are just a vapour that appears for a little while and then vanishes away. Instead you ought to say, 'If the Lord wills we will live and also do this or that' " (Jas4:13-15)
Someone who understood this was David , illustrated in the way he dealt with the terminal illness and ultimate death of his son in 2 Samuel 12:15-23.
When his son was gravely ill David prayed to God, lay all night on the ground and refused to eat (vs16,17). Such was his obvious distress that his servants feared to tell him when the boy actually died in case David "did himself harm" (v18).
When they do eventually tell him they are astonished at the way he reacts. He gets up, washes and clothes himself, worships God, has something to eat and basically gets on with his life again (v20) saying:
"While the child was still alive I fasted and wept, for I said 'Who knows, the Lord may be gracious to me that the child may live'. But now he has died, why should I fast? Can I bring him back again?...." (vs22,23)
This was a man who knew that he never really "had" anything in the first place, only what God granted him. All he could do was pray. He did that and accepted God's answer.