By the time Billy Joel entered the studio for his 12th album, River of Dreams, he had sold millions of records, toured the world, won Grammy Awards and had a wife and family. By all appearances, he seemed happy, fulfilled and poised for another two decades of success.

Behind the scenes, however, Joel was struggling.

Some of the difficulties Joel experienced during the months and years leading up to River of Dreams had very little to do with music – including a pair of high-profile lawsuits that found him attempting to obtain millions of dollars in judgments against his former lawyer and manager. The overall crisis of faith caused by his troubles, however, still cast a pall over his songwriting.

"There's a song in [the Broadway musical] The Most Happy Fella called 'I Like Everybody I've Met,'" Joel told the Philadelphia Daily News in 1993. "That was me – very serendipitous, happy-go-lucky, trusting everyone. I was burned before but shrugged it off. But this time, I lost faith in my own judgment: 'Who am I to write about anything?' I thought. 'Who am I to tell people what's right and wrong?'"

Those feelings bled into a set of songs whose protagonists found themselves grappling with – and often losing to – emotional turmoil, doubt and depression. A lot of Billy Joel's early work could certainly be described as serious or even pensive, but there's a noticeable dark streak running through the material that ended up on River of Dreams.

That's particularly true over the first six tracks, as Joel vents about everything from suburban sprawl (album opener "No Man's Land") to personal betrayal ("The Great Wall of China") to the increasing ambiguity of middle age ("Shades of Grey"). It isn't until the seventh track, "Lullabye (Goodnight, My Angel)," that the record's tension truly seems to let up and start to find a release.

Watch Billy Joel's 'River of Dreams' Video

This was a deliberate decision on Joel's part. River of Dreams was "a song cycle" that was "written and recorded pretty much in the order it's presented on the album," Joel told the Daily News.

"It begins with a crisis of faith, a search for justice. In the end, the guy realizes there's no justice, only faith," he added. "Mozart, Brahms, Liszt and Schumann all had their rough days, but they didn't deny the rest of humanity their art just because they had the blues. In fact, some of the most eloquent expressions of 'Sturm und Drang' came out of their despair. Not that I set this situation up to write, but in the end, I think the inspiration did work for me."

First, Billy Joel had to endure a series of false starts in the studio, including an aborted run at self-producing the record that ended when he hired Danny Kortchmar (whose previous credits included Don Henley's first three solo albums) to take over. Moving the sessions into New York's Hit Factory studio and jettisoning the remaining members of Joel's longtime band in favor of a huge list of session players, Kortchmar took Joel's dark night of the soul and helped mold it into a radio-ready collection.

River of Dreams topped the charts, sold more than five million copies in the U.S. alone, and spun off three charting singles (including the adult-contemporary No. 1 hit title track) on its way to earning four Grammy nominations. Danny Kortchmar, for one, wasn't surprised.

"It sounds like he's playing with a rock band," Kortchmar pointed out in the River of Dreams press kit. "It's his songs, rendered with a real fire and intensity. It's not over-thought or overproduced. It's a real straight-ahead thing. Billy's first bands were all East Coast rock bands in the style of the Young Rascals and the Vagrants, and so were my first bands. We're from the same school."

Watch Billy Joel's 'It's All About Soul' Video

Not everyone was happy with the results – including drummer Liberty DeVitto, who'd been part of Billy Joel's band since 1976's Turnstiles. He said he learned he'd been exiled from sessions for River of Dreams only by calling Joel and being promised, "I have to try this. I'm only going to do a song to see what happens."

DeVitto insisted that he believed he'd hear the wisdom of Kortchmar's decision when he listened to the final album, but was ultimately disappointed. "I drove out there expecting to call the bass player and say he was right, he did the right thing. 'It's unbelievable!' You know?" DeVitto said. "I put the headphones on and [Joel] says, 'Go in the living room, sit by yourself ...' a little Walkman he gave me ... and I started laughing when I listened to it. I'm like, 'Oh my God, this sucks.'"

The album's commercial performance served as a fairly emphatic rebuttal to DeVitto's response, but it later became apparent that River of Dreams found Joel at a creative and personal crossroads.

In the years following its release, his marriage split up, and he announced his retirement from pop songwriting, spending years working on a series of classical compositions (eventually released in 2001 as Fantasies and Delusions) while settling into life as a sporadic touring act. He'd go on to release various non-album tracks, but River of Dreams – which concludes with the prophetic track "Famous Last Words" – remained Joel's last collection of pop material.

Billy Joel's withdrawal from the charts may have seemed abrupt to some listeners, but the seeds for his decision were already sown. "It's agony," he told the Los Angeles Times in 1993 when asked to describe songwriting. "It's hell. I get cranky and moody. I get in this strange state. I even dream a lot of the music. I wake up and recall bits and pieces of stuff. That triggers other ideas. I slowly put it all together. It's like pulling teeth."

Asked to identify the scariest part of the process, Joel mused: "When I go through all that agony and come up empty. I think maybe the well has run dry. All writers fear that. We all think we've gone to the well once too often. Every album I do, I think it may be my last."

Final Albums: 41 of Rock's Most Memorable Farewells

From 'Abbey Road' and 'Icky Thump' to 'Goodbye' and 'Everything Must Go.'

More From 104-5 KDAT