It was his age 37 season. He pitched 164 innings the year before that. That's more than he pitched the previous 3 years combined. Arms have a limited amount of bullets in them. Corey snuck in an additional 250 productive innings after surgery and then was toast. His 2022 season was only worth 0.8 bWAR.
If you look at his 2022 Statcast, his "stuff" looked nothing like what it was prior to surgery in 2018. He no longer had a valuable fastball or breaking ball. His whiff and k rates fell off a cliff. 19th percentile xBA. 26th percentile xSLG.
He was on his way out due to the surgery and age.