HOUSTON (AP) - Daryl Morey didn't let the market dry up while he was waiting to hear from another star free agent about coming to Houston.

The Rockets general manager locked up two important role players from last year's team on Friday, reaching agreements with swingman Corey Brewer and point guard Patrick Beverley to keep them in Houston.

Beverley got a four-year deal worth $23.4 million, agent Kevin Bradbury said. The final year is non-guaranteed.

Brewer agreed to a three-year, $24 million deal, a person with knowledge of the deal told The Associated Press. The person requested anonymity because the deal has not been officially announced. The contracts cannot be signed until July 9.

After coming over in a trade from the Timberwolves in December, Brewer gave the Rockets a boost with his energy on both ends of the court. He flourished under coach Kevin McHale, who had been an executive with the Timberwolves

Brewer averaged 11.9 points and 3.6 rebounds with the Rockets and was a key cog in their run to the Western Conference finals.

Morey also made sure he didn't lose Beverley in free agency. The tenacious defender meshes well with the offensive-minded James Harden in the Rockets backcourt, and they sorely missed his ball-handling and perimeter defense in the playoffs against Steph Curry and the Golden State Warriors.

Beverley averaged 10.1 points and shot a paltry 38 percent from the field, but he was an early-season candidate for defensive player of the year before missing the last three weeks of the regular season and the entire playoffs with an injured wrist.

Yahoo Sports first reported both agreements, which came while the Rockets waited to see if star power forward LaMarcus Aldridge would pick them over several suitors, including the Spurs, Suns, Heat, Trail Blazers and Lakers.