1 Kings 2:22
And king Solomon answered and said unto his mother, And why dost thou ask Abishag the Shunammite for Adonijah? ask for him the kingdom also; for he is mine elder brother; even for him, and for Abiathar the priest, and for Joab the son of Zeruiah.
Adonijah's unholy ambition sought to take advantage of the king's old age with Joab's disloyal support, but Nathan opposed it according to the Lord's will and the king's mind so that Solomon was crowned king, and a little later Adonijah and Joab were slain, while Shimei who had cursed David was also put to death for failing to abide by his conditions of life. This belongs to Solomon's execution of David's charge to secure the throne after David's death.
When his mother asked that Abishag the Shunammite be given to Adonijah, Solomon treated the request as a political bid for the kingdom. He pointed out that Adonijah was his elder brother, and he linked the request with Abiathar the priest and Joab the son of Zeruiah, who were associated with Adonijah and had supported his attempt to be made king. He regarded it as a shrewd attempt to claim the kingdom, since possessing the former king's concubine could strengthen Adonijah's claim among the people.
Adonijah had been pardoned at first for his challenge to Solomon's rule, but Solomon rejected the request for Abishag as a renewed attempt to claim the throne. It was a later offense and insult to the king, and the plot ended in Adonijah's overthrow and death. The history shows how the judgments announced after David's sin concerning Uriah were fulfilled, fulfilling the warning that the sword would not depart from David's house. Apart from that setting in the history of the judgments for David's sin, no further explanation of the verse itself is given.
Adonijah's rebellion and death were part of the retribution that followed David's wicked conduct toward Uriah. Through all the rest of his life and principally in his own family, as seen in Amnon and Tamar and in the rebellion and crimes of Absalom, David received back in kind for the wrongs he committed. Wrongdoing brings calamity and sorrow on the wrongdoer, the very kind of evil caused to others coming back on himself, for what a man sows he reaps and sin pays in its own kind.