Bacterial blooms are a large bloom of Heterotrophic bacteria. Heterotrophic bacteria are always in our aquarium, but there are only large blooms (now so much bacteria that they populate the water column looking like a white hazy cloud) when there is excess organics (debris, uneaten food, etc.). They breakdown the organics into ammonia (which is why ammonia spikes are usually present). They do multiply extremely fast, so they can re-cloud a tank after a water change, IF there are still a lot of organics. Bacterial blooms are also common on new tanks (New Tank Syndrome), where there is little to no Autotrophic bacteria (the nitrifying beneficial bacteria we commonly refer to in our filters).
The water that was left over in your filter isn't really "infected", it would of had heterotrophic bacteria, but they would have always been present, they only multiply to a large enough population if their food source is in excess, which means there are excess organic matter in the tank. But the filter might of had excess organics within (mulm/detritus/uneaten food/etc.). It would help to vacuum out any organics, thus lowering the amount of food available for the Heterotrophic bacteria, resulting in less cloudy water. You can leave the bacterial bloom alone and they will eventually break down all the organics and their population will dwindle to the point the large population cloud is no longer present (clear water). However, knowing they break down the organics into ammonia, means you can possibly have elevated nitrogen levels that you should keep an eye on and deal with accordingly, with water changes to prevent poisoning to fish.
Well that is how bacterial blooms (white cloud) works anyway. From you reporting low nitrogen levels/water parameters, I doubt you have a bacterial bloom. The log wouldn't cause any bacterial bloom cloud, but it could leach tannins, making the water brown/tea colored.
So I suspect it might just be physical debris particles. If so, use fine mechanical filtration media, such as filter floss/polyfil batting, fine pore sponges, micron pads, etc. I am unsure if activated carbon/charcoal or Purigen would help clear up the water in that case. I know you have coarse and medium pore mechanical media, but fine pores are necessary to catch/collect fine particles.
I have also heard of cloudy water caused by precipitation. Some kind of reaction happening (should be harmless though), which I don't know too much about.
Green water is just algae.
UV's can definitely clear green water, but for other cloudy water reasons, I think a decent UV is necessary (not all are made the same/effective for certain uses - ie. UV clarifier vs sterilizer). But the one linked above looks like it would be strong enough (again depends on what the cloud actually is, if it is just physical debris particles/dust/silt, I don't think a UV will do anything to that cloud)