That's probably exactly the right thing.

The F-22 is already partially obsolete. It lacks some important features that were introduced about 30 years ago (IRST, helmet mounted sight) and has troubles with some utterly standard air war features (datalink).

Very low observability ("stealth") technology is at a maturity point, whereas signal processing and various counter-VLO technologies make still huge improvements. The F-22's design concept has been publicly known since at the latest 1991 (YF-22) and is really a 80's concept (actually, it dates in its philosophy back to about '71!).
All competitors were developed to defeat it and its ilk, as were some air defence systems.

(The F-22 is a parallel to the F-4: Expensive, large, impressive in its technology, dependent on one specific approach to air combat and most likely very vulnerable to opponents who deny to play along (the F-4 boasted great speed, unparalleled radar effectiveness, a second crew member, a medium range air combat missile and was supposed to defeat the enemy many miles ahead - but then obsolete MiG-17s began to close in, fly circles around it and shoot at it with supposedly obsolete guns!).
Similarly, the F-22 boasts stealth, supercruise, limited thrust vectoring, a very high combat altitude and is supposed to defeat the enemy with dash & run at high altitude and over long distances.)


A fighter weakness is the best motivator for the development of a better fighter (or whatever takes over a fighter's functions) and might thus be very beneficial in the long term.
It's better to have 300 F-22 successors in 2030 than 500 F-22s.
This reduces the period of uncertain air superiority to about 2020-2030 unless the bureaucracy fails to launch and manage a timely successor program.