You can configure the server to reduce the number of component versions by archiving
them. You can specify global cleanup settings, cleanup settings for individual components, and
cleanup settings for specific environments.
About this task
The server archives a full or incremental component version if the version does not meet
any of the criteria for versions to keep. When archiving versions, the server retrieves the settings
from the options first. Then it retrieves the settings for the individual components, which
override the system settings. Finally, it checks the settings on the environments to which the
component has been deployed. If any of these settings specify to keep the component version, it is
not archived.
These settings include a number of days for which to retain versions and a number of
versions to keep. The server settings and the component settings refer to the creation date of the
version. For example, if the server settings or component settings keep versions for 30 days, a
version is not archived until its creation date is more than 30 days in the past. Similarly, if the
server settings or component settings keep the 10 most recent versions, a version is not archived
until there are 10 more recently created versions. Component settings override server settings for
that component.
By contrast, the environment settings refer to the most recent deployment date
of the version. For example, if the environment settings keep versions for 30 days, a version is not
archived if it has been deployed in the last 30 days. If an environment does not have settings, the
server uses the system settings instead. For example, if the server settings keep versions for 30
days and the version was created more than 30 days ago but was deployed to an environment within 30
days, the version is kept.
The server uses the following criteria to determine which versions
to keep and which to archive:
First, the server checks the settings on the component. If the
component has settings to keep versions, the server uses those settings. Otherwise, the server uses
the defaults in the server settings.
- If the number of days to keep versions is set to -1, the version is kept.
- If the number of versions to keep is set to -1, the version is kept.
- If the version was created within the number of days to keep versions, it is kept.
- Based on the number of versions to keep, if the version is in the most recently created
versions, it is kept.
Then, the server checks the settings for each environment to which the component version has
been deployed. If an environment does not have settings, the server uses the system settings for
that environment. In the context of environments, the settings refer not to the creation date of the
component but the date of the most recent deployment of that component. For example, if the system
settings keep the 20 most recent versions, and the version is one of the 20 most recently deployed
versions in an environment, the version is kept. Using these settings, the server uses the following criteria:
- If the version is currently deployed to any environment or is listed in the inventory of any
resource, it is kept.
- If the version is part of any snapshot, it is kept.
- If the number of days to keep versions is set to -1 in any of the environments, the version is
kept.
- If the number of versions to keep is set to -1 in any of the environments, the version is
kept.
- If the version has been deployed within the number of days to keep versions, it is kept.
- Based on the number of versions to keep, if the version is in the most recently deployed
versions, it is kept.
If none of these criteria are true, the component version and the artifacts in it are
archived, even if the version was deployed to an environment in the past.
Note: Beginning with
version 6.1, the server stores full copies of each file in each component version, even if the files
are duplicates.