This appears to be a beautiful example of Fraunhofer diffraction. It is due to the wave nature of light. The effect depends on the wavelength (that is, the color). It is most pronounced when bright light from a practically infinite distance passes through narrow slits, causing the light to spread perpendicular to the slits. This spreads a point-like beam of light into a pair of streaks.
Using a small aperture creates slit-like situations at the corners formed by adjacent blades. Thus, when you have a combination of relatively intense, pointlike, monochromatic light sources in the image and a narrow aperture, you should see a streak (of the same color) emanating from the points in two directions perpendicular to the blades. When your diaphragm is formed by straight blades, this will cause there to be twice as many streaks as blades. However, the streaks for parallel blades will coincide. Thus, for a diaphragm with an odd number of blades (where no two blades are parallel) there will be twice as many radial streaks as blades but for a diaphragm with an even number of blades (where opposite blades are parallel) the streaks overlap in pairs, giving the same number of streaks as blades (but each streak is twice as bright).
A classic example is shown in the first image in the Wikipedia article on diffraction, for Fraunhofer diffraction through a square aperture. You see four well-defined streaks.
The theory is further explained here. This explanation was published in 1967 by CA Padgham. Ken Rockwell mentions it in his discussion of bokeh.
We should expect a certain amount of diffraction always to be present. It is usually slight and averaged out in most pictures: it just contributes a tiny amount to the blurriness that is present in any image when looked at closely enough. Only in images that bring together several factors--points of intense monochromatic light, small apertures, straight diaphragm blades--will it become prominent. This information shows how you can make the stars more prominent or how you can suppress them, by altering these factors for your exposure (to the extent you can).
Finally, length of exposure is related to the occurrence of this effect, as you have observed, but only because exposures with bright points of light are almost always made much longer than needed to record the lights: you're trying to see the rest of the scene, which is much darker. The brightness of the diffraction streaks decreases so rapidly away from their sources that if you used a sufficiently short exposure to properly expose the lights themselves, the streaks would be practically invisible. For instance, there are dimmer but still prominent light sources in your background: they look like windows in the far distance. They, too, must have their own streaks, but those streaks are too dim to see. (Appropriate software filtering might be able to bring them out.)