I like dance music, but I also like other styles. The composers try different formulas and variations, but no one knows for sure if a specific song will be popular with the audience. Sometimes they write a song for a singer, but the music is turned down and afterward offered to another singer, and it is a massive success.
That is the case of the music Umbrella, written for Britney Spears at first, who rejected the music, and that Rihanna turned it into a big hit.