European lawmakers on Wednesday approved a revamped migration system that the pro-EU political centre promises would reduce irregular arrivals as it seeks to stem gains by the far right ahead of the bloc’s parliamentary election in June.

It aims to cut the times for security and asylum procedures at external EU borders, and increase returns to reduce unwanted immigration from the Middle East and Africa, a high priority on the bloc’s agenda.

After eight years of feuds between the bloc’s 27 member states, the compromise proposals lay out a delicate balance between the obligations of arrival countries such as Italy and help from rich destinations such as Germany.

But it has been squarely criticised by anti-immigration, eurosceptic and far-right parties for not going far enough to stop migration, while leftists and rights activists have lambasted it as a major blow to human rights.

“We will be able to better protect our external borders, the vulnerable and refugees, swiftly return those not eligible to stay, with mandatory solidarity between member states,” said top EU migration official, Home Affairs Commissioner Ylva Johansson.

The vote came as the broad political EU centre feels under pressure from the far right, which is expected to gain seats in the bloc-wide European Parliament election in two months.

Migration has been a hot-button issue since more than a million people – mostly Syrian refugees – arrived across the Mediterranean in 2015, catching the EU unprepared.

The EU has since tightened its borders and asylum laws to prevent any repeat of the chaos, and vows to stay the course.

LONG IMPLEMENTATION

More than 46,000 people have entered the wealthy bloc of some 450 million inhabitants so far this year outside of regular border crossings, according to U.N. data. Some 400 people are estimated to have perished while attempting to get in.

“The EU is demonstrating that united, we can establish this needed reform,” said the head of the liberal faction, Valérie Hayer.

“Now, it is all about the implementation,” she said, adding that was the responsibility of the member states and that human rights violations must be punished.

The vote was briefly interrupted by protesters in public galleries calling on the lawmakers to “Vote no!”, while rights groups expressed criticism of the new system.

Caritas said it was “concerned about its potential negative impact on thousands of people’s lives, as the new rules clearly limit access to protection for those in need”.

Activists say the changes allowed for large-scale internment, including of children, and give member states the option to buy themselves out of hosting new arrivals. They criticise the EU for asking foreign states to handle migrants without what they say would be sufficient rights safeguards.

Poland said after the vote that it would not accept an EU immigrant relocation scheme but, alone, it cannot stop the revamp when the majority of member states are expected to rubber-stamped it later this month.

EU states would then have two years to implement it, though analysts warn not to expect major changes on the ground overnight.