Idiom meaning that something doesn't happen often, but happens more than needed when it does?
Solution 1:
An alternative saying to the good one suggested by @Dan Bron is:
When it rains, it pours
When something good or bad occurs, it usually occurs more than once and often within a short period of time:
- “I have a new supervisor at the office, three new assistants to train, and enough work to keep me busy for months — when it rains, it pours.” (AHD)
Solution 2:
There is the common cliché that you
“waited all day for a bus, and then three came along at once”.
Wikipedia mentions this saying.
There are many internet examples; there are many tweaks ('You wait ages for a bus... then FORTY-THREE come along ...'!), and even a scientific analysis of why it happens in a New Scientist article:
Anyone who has waited for a bus knows the routine: you wait far longer than you should, then three come along at once. The problem, called "platooning", plagues buses, trains and even elevators....
The expression is also used metaphorically; here is an example from The Wordfoolery Blog.
Solution 3:
Another idiom is either feast or famine. This refers to exactly the type of situation you describe. One experiences a dearth of something they need (a metaphorical famine), except at those times when they receive an overabundance (a feast), possibly including more of the needed thing than they have any use for.