curious as to why a person who is "not really a hockey guy" finds himself on a hockey message board site..
but that notwithstanding, minor league hockey at the AHL level is exactly the equivalent of the AAA minors in baseball, i.e. a place for players who aren't quite ready for the NHL to get playing time in order to develop. Developmental leagues are necessary because the NHL, like baseball, drafts at age 18, and drafts many more players than will ever actually make it, but, also like baseball, the low rounds often end up producing major league talent that simply isn't evident at age 18.
the ECHL survives because apparently hockey is popular enough that people want to see professional level hockey played on smaller towns. Its true very few ECHL players make it to the NHL but its not unheard of either.
I think you are mischaracterizing junior hockey... its much more like high school sports than summer leagues or college.
as for D-league basketball, I agree, I have no idea how it survives financially unless its totally subsidized by the NBA as a means to keep marginal talent from going overseas. Also don't see the need since they only draft two rounds every year.