AMMAN, Jordan (AP) — Jordan's King Abdullah II lashed out at Israel's prime minister on Thursday, saying everyone in the kingdom was "infuriated" by what he called "unacceptable and provocative behavior" in connection with a deadly shooting at Israel's Embassy in Amman earlier this week.

The monarch's unusually harsh language appeared aimed, in part, at defusing widespread anger in Jordan over the shooting in which an Israeli Embassy guard killed two Jordanians, including a 16-year-old.

Authorities have said the guard opened fire after the teen attacked him with a screw driver during a furniture delivery.

The guard returned to Israel a day later because of diplomatic immunity. Prime Minister Benjamin Netanyahu received the guard warmly at his office and said he had acted "calmly."

The guard's speedy return home and Netanyahu's praise of him further inflamed public opinion in Jordan where a 1994 peace treaty with Israel remains deeply unpopular.

On the government level, Israel and Jordan cooperate closely, if discreetly, on security.

Shared interests have helped the relationship survive, despite repeated crises, including the embassy shooting and, in parallel, the escalating Israeli-Palestinian dispute over a major Jerusalem shrine that is holy to Muslims and Jews.

Jordan is the custodian of the Muslim shrine and was involved in behind-the-scenes negotiations to end the latest escalation.

Abdullah, who was abroad during the twin crises, returned home on Thursday and convened top Jordanian government and security officials.

The king said it would behoove Netanyahu to take legal action, including putting the guard on trial, instead of "dealing with this crime ... to achieve personal political gains."

"Such unacceptable and provocative behavior at all levels infuriates all of us, leads to insecurity and fuels extremism in the region," the king warned.

Netanyahu and Abdullah had spoken by phone on Monday evening, just before the return of the guard to Israel. Several hours later, Israel removed metal detectors it had installed at the Jerusalem shrine, in response to a deadly July 14 shooting attack there in which three Israeli Arab gunmen killed two Israeli police officers.

The metal detectors had triggered widespread Muslim protests, amid allegations that Israel was trying to expand its control at the site under the guise of security — a claim it denied.

Still, the sequence of events — return of the guard, then the removal of the metal detectors — led to widespread speculation of a tradeoff. The optics appeared to be problematic for both leaders.

As Netanyahu fended off criticism at home that he had surrendered to Muslim pressure over the metal detectors, he went out of his way to portray the return of the guard as an achievement — to the dismay of the Jordanians.

The king told Thursday's gathering that Israel's handling of the embassy shooting, among other issues, "will have a direct impact on the nature of our relations."

The monarch also paid a condolence visit to the family of the slain teen, Mohammed Jawawdeh.