Since history is so revisionist that is taught in schools these days, I am sure that many people do not know the facts I am about to share.
Until very recently people who were either aristocrats or at least financially well to do (as the middle class grew and became a source of potential wealth) the occupations of the sons were pretty much assigned to them. It was not a matter of choice. This is because the first son had to be the heir to the father, hence he was totally concerned with managing the family and his future inheritance. The second son would go into the military. This was so that the one who "just missed out on being the heir" could develop skills, societal ranking, and court connections that would enable him to make his living and support a family. The third son would go to the clergy. Yes, the third son of virtually every upper or middle class family would be destined for the clergy, which was viewed as a very "honorable occupation."
So you must realize that many of the burgeoning numbers of priests that we had during the flowering of the Roman Catholic Church was supplied not via a personal calling or call to "vocation" as we see today, but because it was viewed as the most desirable "occupation" after being heir or soldier. It was not because of the monetary potential, obviously, but because families, regardless of their secular antics in power struggles and finances, were extremely pious. It was a great honor to have a priest or religious in the family. So this was the third son's likely and probable occupation (unless he was favorably matched in a marriage, which really was only an aristocratic concern, not affecting the middle class at all, who would not have been allowed to "marry above them" anyway).
I hope this helps some light bulbs go off among the more thoughtful of you. It is not as simple a problem as "oh gosh, men nowadays want families/sex and that is why men are not becoming priests as much as they used to." Um, duh, until a hundred years ago when the west started becoming so industrialized and secularized, each family planned the entry of at least one son into the clergy! It was viewed as the third most honorable "profession!" So like it or not (as far as marriage) many men entered the priesthood as their occupation in addition to their vocation. This does not mean they were any less pious than men who enter the priesthood today (in fact, since society as a whole was much more pious than today, even men who were "destined" for the priesthood tended to be very true to the faith.) However, I hope this also helps some secular geniuses of today who like to make smart remarks about orgy monks and infidelity throughout the history of the Church. Certainly when many men were sent into the priesthood without a personal calling, temptation was greater than it is today. But when you think about it, there has been a remarkable virtuous army of men with fidelity who served the Church even if they were "destined" rather than "chose" their priestly vocation.
Today when men only become priests due to their personal calling there is even less excuse for infidelity and lack of chastity in their vows. Up until several generations ago one could kind of understand that many priests were open to temptation because they did not entirely choose their own vocation.
So I have to burst the bubble that the fact there were thousands and thousands of priests in every generation until recently is due to wanting sex or marriage. There was a huge societal "draft" into the clergy (and of course in Anglican and Protestant faiths the clergy could marry) that supplied many Catholic priests by virtue of them being third, or sometimes second, sons in large middle to upper class or aristocratic families.
This birth order influence can even be remembered as a saying: "Heir, soldier, priest."