Nancy Morris in The American Heritage:
From the observation deck of the Aloha Tower there is a panoramic view of the Honolulu waterfront and a once infamous district known as Iwilei. Looking for local color, Somerset Maugham went slumming there and wrote this in his notebook: “You go down side-streets by the harbour, in the darkness, across a rickety bridge, and you come to a road, all ruts and holes; a little farther … there is a certain stir, an air of expectant agitation; you turn down a narrow alley, either to the right or to the left, and find yourself in the district… . The pretty bungalows are divided into two lodgings; each is inhabited by a woman, and each consists of two rooms and a kitchenette.”
A prostitute named Sadie Thompson, Maugham was to find, lived in one of those bungalows. Shortly after Maugham’s Iwilei adventure, the police shut down the district. Sadie was out of business and sailed off to Samoa. As it turned out, Maugham was on board that ship too and suffered through her loud gramophone and late-night trysts. In Samoa, temporarily stranded by a storm, he found himself in the same boardinghouse as Sadie. There was a reallife hypocritical missionary staying in the boardinghouse too, although he seems not to have met the final grim end of Maugham’s character Davidson. Sadie’s adventures became Maugham’s most famous short story, “Rain.” The writer did not even bother to change her name: Passenger lists published in the Pacific Commercial Advertiser record a “Somerset Maugham” and a “Miss Thompson” departing Honolulu for Pago Pago on the Sonoma, December 4, 1916.
More here.