The Lord's convenant with David and Israel's afflictions