JERUSALEM- Israel will not prosecute a guard from its embassy in Amman who killed two Jordanians in July, as had long been demanded by the kingdom, two Israeli sources said on Sunday.

Instead, the Foreign Ministry and Shin Bet security agency will review protocols surrounding the actions taken by the guard, and his conduct, "and share the results with the Jordanians", a diplomatic source said.

The killings led to a rift between the countries, which both said last week had been mended.

Jordan said Israel had apologised for the embassy deaths, would compensate the victims' next of kin and "implement and follow up legal measures" in the case.

Jordanian officials were not immediately available to comment on the diplomatic source's account. Israel's Foreign Ministry spokesman declined comment.

Amman had previously demanded a homicide trial for the guard, whose repatriation under diplomatic immunity and hero's welcome by Prime Minister Benjamin Netanyahu angered Jordanians.

Israel said in the aftermath of the incident that the guard had acted in self-defence, shooting a workman who stabbed and wounded him lightly, and that the second Jordanian was killed by stray fire.

Asked on Sunday whether criminal prosecution of the guard was possible, a second Israeli official told Reuters on condition of anonymity: "No way."

The guard's prospects of remaining in the Israeli secret service may be in doubt, however, after a Jordanian newspaper published his name and photograph.

Other fine-print elements of the reconciliation deal were designed to limit legal culpability for Israel, the diplomatic source said.

Israel would not pay damages to the next of kin directly, but instead provide a $5 million lump sum for the Jordanian government to disburse as compensation, that source said. The money is also meant to cover the needs of the family of a Jordanian shot dead by an Israeli border guard in 2014.

Two sources close to the families confirmed the payout sum.

The Israeli diplomatic source said the Netanyahu government had not apologised for the shooting of the alleged assailant but rather "voiced regret".

On Thursday, a Jordanian government spokesman said Israel had sent a memorandum stating its "deep regrets and apologies".

Yet Israel distinguishes between the two expressions of contrition, seeing in the latter a potential admission of guilt.

A deal reconciling Israel and Turkey over the killing of 10 pro-Palestinian Turks who tried to breach the Gaza blockade in 2010 included Israel voicing regret and paying $20 million into a Turkish fund that compensated the bereaved and injured.

In return, Ankara agreed not to seek the criminal prosecution of Israeli marines who raided the activists' ship.

Jordan signed a peace treaty with Israel in 1994.

Three years later, during Netanyahu's first term as prime minister, relations were strained when Israeli secret agents were caught spraying poison into the ear of Palestinian Hamas leader Khaled Meshaal on an Amman street.

The assassination team was repatriated in return for an antidote for Meshaal and the release of Hamas's spiritual leader, Ahmed Yassin, from an Israeli jail.

On Saturday night in a Twitter posting, Netanyahu expressed appreciation for behind-the-scenes efforts by U.S. envoys Jared Kushner and Jason Greenblatt to help end the crisis with Jordan.

(Additional reporting by Suleiman Al-Khalidi in Amman; Editing by Jeffrey Heller and John Stonestreet) ((dan.williams@thomsonreuters.com; +972)(0)(2 6322202; Reuters Messaging: dan.williams.reuters.com@reuters.net))