Query letters are absolutely worth writing.
I cannot say self-publishing is NOT viable, but I think the success rate is even more abysmal than finding an agent and getting "traditionally" published. You can look at other answers to "self-publishing" on the site; I've quoted before the average earnings are around $100 or something, and the majority earn zero.
The problem is the relatively new communications culture; we are drowning in hype, advertisements, and hundreds of venues with free stuff to read, much of it written by paid professionals (living off the advertising income).
This makes readers highly selective and numb to advertising; we just ignore them completely and 99% we never read, and of those we do read 95% we never even click out of curiosity. The same goes for spam.
But actual book sales are still going strong, and bookstores are nowhere near empty. Part of the response to the deluge of advertising and free information is specific attention in consumers; when they want to buy a book (or a car or tax help or whatever), they go looking for trusted vendors and shop there. But they are unlikely to find the fine website you built; for books they are more likely to use some kind of filter mechanism. A physical book store is one such mechanism; so are online sites like Yelp, or other lists filtered by book critics or fellow consumers.
Agents and traditional publishers are not dummies, they have learned to navigate this new sales environment as it has arisen, so they can get your book sold.
Of the two, agents are very much in the business of finding new authors and getting them published. So while they too are swamped by queries, and have to reject 90%+ of them out of hand (because they don't have the time to coddle or meet non-standard requests), they still read their queries (or at least start to read them until they find something dumb in the query letter), and will still read some pages of your story to see if you are a real writer, and will still read your book if you pass the first two tests, and if the book is good, they will do the work of trying to sell it for you.
Some publishers will take queries, but they have the same problem of being overwhelmed; and one filter they can employ, because it costs them nothing, is to listen to good agents that have done their job and only bring them viable works. The concentration of good material is far higher, the agent has filtered out 95% of the dreck.
Using an agent, you don't have to run a business of selling, contracting production, advertising, and negotiating with bookstores, or movie producers, or audio voice talent. You don't have to learn any of that, you can write books and sell them. You are far more likely to get a bestseller using an agent and traditional publisher than you are by self-publishing or selling e-books.
If you aren't good enough at query letters (or writing) to traditionally publish, I still wouldn't recommend self-publishing. I'd recommend you try to get better at writing!