Washington (CNN) The Senate rejected a proposal from Republican lawmakers to repeal Obamacare on Wednesday, marking a significant milestone in the Republican Party's years-long political crusade to gut former President Barack Obama's legacy health care law.

The vote was 45-55, with seven Republicans opposing the measure.

The failed effort was a remarkable contrast from less than two years ago, when a Republican-controlled House and Senate passed an identical measure and sent it to Obama. He vetoed the bill. In 2015, the passage of that legislation was largely viewed as a political messaging exercise: GOP lawmakers were keenly aware that Obama would not sign it into law.

But now, with Republican President Donald Trump in the White House and ready to sign a bill, the stakes are real -- as are the realities of voting to repeal the current health care law without a replacement in place. The failure crystalized the new reality for Republicans: more than seven years after the enactment of Obamacare, there is growing recognition within the GOP that a straight repeal of the law is not viable.

Later Wednesday, Senate Minority Leader Chuck Schumer said Democrats will not offer any more amendments on health care until they know what the final bill will be.

Read More