David acts quickly and independently without consulting God and Joab does the same.
Fortunately God brings out a good outcome for David but I think lessons can be learned.