Technology is a funny thing. Back in 80 something I bought a very nice TT rig at the dawn of the CD era......practically over night record stores dried up and many of the larger labels stopped making them altogether. It got very difficult to find new vinyl....and I was SERIOUSLY P'ssd. Keep in mind, this was pre-internet, so online shopping hadn't been invented yet. Today I see the same thing happening with streaming/downloading music. Companies have a financial interest in pushing the newest technology that they have invested in........often at the expense of those who choose not to board the train.
Take heart, CD's are NOT going away any year soon, although, like vinyl, new releases will probably become harder to find........One of the advantages of CD vs vinyl is that unless abused, they really should play as well in 20 years as they do today, so buying used is unlikely to be a major problem.
What I CAN see becoming an issue is playback hardware and it's already starting. I think that soon you will have two choices if you still want to spin discs.............low budget, low performance or more money than you might want to part with for a good machine. I expect most of the in-between machines to go away.
Myself, I just purchased a new, high end machine, at least as high end as I can reasonably afford. I expect it and I to grow old together, with or without downloading anything.
Lots of nice, used CDP's available now because many people are jumping ship to the latest and greatest. ..........If you have a tight budget, pick up a good quality used machine........or even two if you really have a ton of discs that you still want to be able to play. Put the second one in a box in the basement until the first one dies. You'll be set for years.
As for sound quality, I think it's already about as good as it can reasonably get. Red book CD, which I mostly listen to, can sound extremely good.....on a good system, which I have.....Many of the blogs and reviewers that I've read don't seem to "hear" much or any advantage to HQ, MQA, DSD, upsampling, etc.....vs the lowly red book on a good system.............At some point more bits are simply more bits..........I do have SACD and on some discs it does sound a little better than red book, but many of my better red book discs sound close enough that I don't have much of a preference. To a large degree, it's system dependent. If you have an amazing set up, you may hear more of a difference.....I don't.
The latest and greatest, often isn't...........people still routinely compare even the best digital gear to the poor old , hissy, poppy, 33 1/3 rpm record......Quite a compliment when you consider how far technology has come in 30 years...........Technology will always move forward because it CAN, but newer isn't necessarily better, just different.