NASHVILLE, Tenn. — The New York Yankees have acquired Starlin Castro from the Chicago Cubs to be their new second baseman.

The Yankees will send pitcher Adam Warren and a player to be named later to the Cubs.

Second baseman Brendan Ryan is the player to be named, according to ESPN sources and multiple reports.

Castro, a three-time All-Star, fits the Yankees’ goal to become younger and more athletic. The 25-year-old hits right-handed, which is another Yankees need, as the team struggled last season against left-handed pitching.

In 2015, Castro hit .265 with a .671 OPS. He is owed $38 million over the next four seasons. He also has a team option for $16 million in 2020. He will be teamed with shortstop Didi Gregorius to form a young, potentially dynamic core in the Yankees infield.

The Yankees had played up the idea of using prospect Robert Refsnyder and veteran Dustin Ackley at second. Both, though, are considered defensively challenged. Refsnyder does have potential upside as a hitter.

Refsnyder, a rookie last season, did well enough that by the end of the campaign, he was the starting second baseman against lefties. He began the wild-card game at second against the Houston AstrosDallas Keuchel. Refsnyder turns 25 in March.

Fox Sports first tweeted about the trade talks between the Yankees and Cubs on Tuesday.

The Yankees have continually said this winter that they will not be in the big-money free-agent market and that the trade market is where they will look to improve.

Castro also gives the Yankees a backup to Gregorius, because he began his career as a shortstop.

Warren shuttled back and forth between being a starter and a reliever with the Yankees. He was dependable, but the Yankees never fully trusted him as a starter. He finished last season at 7-7 with a 3.29 ERA.