Our Gemara on Amud Aleph discusses an interlude in King David’s life that involved getting a message about a halakha on the battlefront (symbolically represented as bringing water, Shmuel II:23). According to one version, the halakhic question had to do with whether it is permitted to destroy another person's possessions in order to save himself. The Gemara interprets David’s “pouring out the water” as quoting the halakha anonymously instead of in the messenger’s name. The apparent reason is that the courier was overzealous in risking his life, traversing dangerous battlefronts to bring the message. To discourage such misplaced bravery, he denied giving the messenger credit.
This is an important message of balance. We may surmise that Dovid Hamelech was aware that in the fog of war, there would be the urge to treat all matters as life threatening. There is the additional danger of the idolatry of nationalism, being expressed during the heat of war, as a fierce loyalty toward the king’s every whim. Dovid Hamelech wanted to counter that instinct and teach a lesson to his subjects and soldiers about reigning in improper expressions of zealotry.
The rabbis may have been hinting at this point by the actual subject of the halakhic question. After all, a person who puts his life at risk due to mistaken piety is metaphorically “saving himself” with his “friend’s money”. That is, he is mistreating his body in order to “save his soul”.
The challenge is to know when self-sacrifice is appropriate and when self-protection and self-care are appropriate. Sometimes it is simply a matter of halakha, whether it is permitted to expose oneself to danger in pursuit of a higher cause or principle, a mitzvah or to prevent sin. However, at other times it is too subtle to reduce to a yes or no answer, and requires life experience and the “Fifth Volume of Shulkhan Arukh”.