Skip to main content

Garbage collection

GarbageCollectionModule

This section describes how to configure the Garbage Collection. Garbage collection is used to remove historical inventory data from the Inventory database.

propertyName

Description

IsEnabled

Set to true, garbage collection will run.

Set to false, no garbage collection will run.

Default = true

Note:

  • It is recommended not to disable this feature because the database accumulates an unmanageable quantity of data, which uses up much hard drive space and slows the processing speed.

  • If the feature is disabled by chance for a long time, it is recommended to change the configuration setting SqlCommandTimeOut either to a higher value or zero to complete the job. This may take days based on the quantity of the accumulated data. After the job is done, set the configuration to a reasonable value.

Interval

Specifies the time that must pass since the prior run of the garbage collector has been completed. This value is specified in the hh:mm:ss format.

Default = 02:00:00

SqlCommandTimeOut

Set the time limit of duration (in seconds) for how long garbage collection will run for each individual query to the database. When set to 0 , the duration has no limit (infinite duration).

Default = 180

DaysOfCumulativeTableHistoryToKeep

Set the number of days to keep historical data of user login, metering, metering concurrency, and cloud metering.

Default = 90

DaysOfMetricHistoryToKeep

Set the number of days to keep statistical troubleshooting data.

Default = 30

Note: This data can only be read by Snow Software staff.

DaysToKeepAssignedIdsWithoutData

Set the number of days the garbage collector will keep the entries for the devices that tried to reach Snow Inventory but never reported a full inventory scan, before being removed.

BatchSize

Set the number of rows that can be removed from a database table in a single transaction.

DaysToRetain

Set the number of days to retain data in the inv.ClientStorageData database table, overriding the default value set by the related scanner.

Example 20.
<ModuleConfiguration>
    <Module typeName="GarbageCollectionModule">
      <Setter propertyName="IsEnabled">true</Setter>
      <Setter propertyName="Interval">"02:00:00"</Setter>
      <Setter propertyName="DaysOfCumulativeTableHistoryToKeep">90</Setter>
      <Setter propertyName="DaysOfMetricHistoryToKeep">30</Setter>
      <Setter propertyName="DaysToKeepAssignedIdsWithoutData">7</Setter>
      <Setter propertyName="SqlCommandTimeOut">180</Setter>
      <Setter propertyName="BatchSize">2000000</Setter>
      <Setter propertyName="DaysToRetain">30</Setter>
    </Module>
</ModuleConfiguration>