Anyone who has studied meteorology or depends on it for their livelihood understands that weather is annoyingly unpredictable. The more that we learn through science, the more we realise just how many climatic factors are involved and why seasons are a far too simplistic principle.
Traditionally, diversification was the key to reliable food supply. In wetter years, grain crops and fruiting trees might do well. When it was drier, natural harvest from native vegetation, local fishing or grazing livestock, might do better. Being part of a community, were you could trade, barter and buy from others who have employed different tactics over the growing season to gain different produce was simply an addition to this diversity. In this way, groups of people were able adjust regardless of the varying weather from year to year.
If, over decades, the weather patterns began to shift towards a certain trend, such as conditions that favoured fruit and grain production, such communities would have more seed available and tend to favour fruit and grain production. Likewise, if the conditions tended to favour certain livestock, more focus would be placed on livestock production, leading to great population of the animal(s).
Some members of the community who have better lands or access to water than others may continue to grow produce that is unfavourable under the current climate conditions (it can be profitable in exploiting a slightly varied niche market), however, if the effort to maintain such production becomes too much, eventually the produce might disappear from the local community altogether – with the only hope of reintroduction being from outside traders.
By diversifying food production, such communities had developed contingency methods that allowed them to meet a varying climate. In much the same way, genetic diversity within a population allows from greater variations in offspring to meet the challenges of a varying climate and environmental conditions.
Where climate conditions are fluctuating, you will find generations fluctuating in gene prevalence, but overall little change to the available gene pool. Even more expensive gene traits will remain in low concentrations if members that carry them are able to persist and successfully pass them on.
Gene diversity is lost when climate change occurs that is so great that most members of the species are unable to persist (not so common), but more likely due to bottlenecking.
Bottlenecking can occur for many reasons. Population collapse due to disease, a catastrophic event, and a few more closely related members being irreversibly isolated from the large gene pool (eg. islandisation) are a few main ways that a gene pool is bottlenecked.
As with mono-culture agriculture, when the times favour the available traits / crops, survival in a bottlenecked community can persist quite easily. However, when environmental factors do not favour the available traits / crop, persistence becomes increasingly expensive. Effectively, in both cases, the result is a genetic desert, without meaningful contingencies in an endlessly varying climate (more on Minimum viable population).
Food security used to be maintained simply because many members of the community were able to employ difference contingencies and as a whole community, this created great diversity in options, regardless of most climate conditions. Likewise, it is not only the biodiversity, as discussed in previous chapter that assists persistence, but also having enough members of a species to allow a genetically diverse pool of traits.
Looking at diversity as a whole, it becomes easy to understand why there is such concern not only of increasing extinction rates, but also depleting fish communities, fragmentation / islandisation of remnant vegetation and declining populations of many species. At some point, pressures, both directly and indirectly the result of human activity has pushed many species beyond the point of no return and continues to do so without meaningful effort to reduce such pressures. Genetic diversity needs to be maintained as climate continues to shift.