South Jersey native Andrew Bailey, who was an All-Star closer before being derailed by injuries, signed a minor-league contract Thursday with the Phillies.

The righthanded Bailey, 31, also received an invitation to spring training, making him the most intriguing non-roster player the Phillies have invited to Clearwater. Along with Bailey, the Phillies signed righthander Edward Mujica, an All-Star closer in 2013 with St. Louis, to a minor-league contract with an invitation to spring training.

Bailey has pitched in just 59 major-league games between 2012 and 2015. But his past success in the ninth inning could make Bailey a viable candidate to make the team after spring training. The Phillies will enter Clearwater without a closer after trading Ken Giles at last week's Winter Meetings. Bailey will be in the mix along with Mujica, David Hernandez, and others.

Bailey, a Paul VI graduate, was the American League's rookie of the year in 2009 and an All-Star with Oakland in 2009 and 2010. He converted 51 saves in those two seasons, compiling a 1.70 ERA in 132.1 innings. Bailey was traded to Boston after the 2011 season.

He missed the first half of the 2012 season after undergoing thumb surgery. Bailey closed briefly for Boston in 2013 before he underwent shoulder surgery. He signed with the New York Yankees before the 2014 season, but missed the entire year because of complications from his shoulder surgery.

Bailey spent most of last season in the minors. The righthander pitched 35 innings between rookie league and triple A. He allowed seven earned runs in 35 innings. He worked as a closer at both double A and triple A before joining the Yankees for the final month of the season.

Mujica, 31, had a 4.75 ERA in 49 games last season between Boston and Oakland. He posted 37 saves with St. Louis in 2013, but has struggled since. Like Bailey, Mujica's signing comes with little risk and the chance for a high reward.