The activity and changing configuration of the immune system is intimately connected with aging in a number of ways. In early life, exposure to infections that require an energetic immune response in effect burns your candle faster by generating more biochemical damage to your body in the process of defending it from the effects of disease. In later life, when the immune system runs beyond its evolutionary warranty, it falls into a state of constant, futile activation and damage - and that damage also adds up.
When you look at the reliability theory of aging, or any like consideration of aging as the consequences of accumulating damage to a complex system, it becomes clear that the immune system is an important component in the model. For example, it is generally accepted that much of the improvement in life expectancy over past centuries stems from a reduction in infectious disease - a process that is by no means complete, given what we still suffer from quiet, persistent infections like cytomegalovirus. But fewer infections mean less activation of the immune system in early life and less damage carried into later life. That leads to both improved health, a physiologically younger body at a given chronological age - and an immune system that declines more slowly, and later in life.
Here is an open access paper in which researchers directly demonstrate (in insects) the principle that early immune activity means a shorter life expectancy:
The pathology of many of the world's most important infectious diseases is caused by the immune response. Additionally age-related disease is often attributed to inflammatory responses. Consequently a reduction in infections and hence inflammation early in life has been hypothesized to explain the rise in lifespan in industrialized societies.
Here we demonstrate experimentally for the first time that eliciting an immune response early in life accelerates ageing. We use the beetle Tenebrio molitor as an inflammation model. We provide a proof of principle for the effects of early infection on morbidity late in life and demonstrate a long-lasting cost of immunopathology.
Like many investigations into the roots of aging, this is more a pointer towards areas where future development of rejuvenation biotechnology should focus than something of direct and immediate use. Results like this add more weight to work on reversing damage in the immune system, and preventing the immune system from falling into a chronic inflammatory state. There isn't anything we can do about our past exposure to infection and persistent agents like cytomegalovirus, but we can help to accelerate the development of ways to fix the resulting damage that we carry with us.