See Also: Canon-Zoom-Lens-Reviews
When Canon discontinues a lens, it is usually because they have introduced a better version of that lens. Unfortunately, that better lens version often carries a significantly higher price tag. So, for some, buying a used discontinued Canon lens is the necessary choice.
A newer version of a lens does not reduce the quality of the older version in any way. But, it seldom reduces the price of the older model. The newer lens version's higher price tag may increase the demand for the supply-capped older version. And increased demand without increased supply results in increased price. The price of the older lens may, sometimes, actually increase. Those upgrading to the newer lens version can increase the supply in the used marketplace, somewhat balancing the price.
The Canon EF, EF-S and TS-E lens lineups are mature enough that there are now many discontinued lenses to choose from. Ultimately, you need to know the new version of the lens gives you over the older model. Then decide if the advantages are worth the price difference. Use one of the eBay links to find the lens you are interested in.
Note that the repair lifetime of a discontinued lens is limited.