Default Rescan Behavior

Code Insight 2021 R1

When a user initiates a regular rescan (that is, does not a force a full rescan), typically only codebase files that have changed since the last scan are rescanned. However, by default, certain Code Insight events that might have occurred since the last scan will determine whether the rescan performs a scan on all files (full rescan) or on only those codebase files that have changed since the last scan.

The following table lists these events and the type of default scan performed by each analysis technique—Automated Analysis and Advanced Analysis (if this technique is configured)—during the rescan.

Note that a System Administrator can configure the scan profile associated with a project to override the default rescan behavior dictated by these listed events, so that each rescan skips unchanged files and scans only those files that have changed, despite any events that might have occurred. For more information, see Configuring Rescans to Always Skip Unchanged Files.

Default Rescan Behavior for Events

Event

Automated Analysis

Advanced Analysis

Notes

Change to codebase files

Only changed files scanned

Only changed files scanned

Changes in codebase files are determined by the MD5 hash digest of the files.

Change to Automated Analysis rule set

Full rescan

See Notes

Changes in Automated Analysis rules result in Automated Analysis performing a full rescan to reapply the changes to all files. (The rule changes are automatically pushed to your Code Insight server through an internal process and the weekly Electronic Update.)

Additionally, Advanced Analysis performs a full rescan only if rule changes have occurred and either the CL version has changed or an NG-bridge update has occurred. (See the Code Insight Installation and Configuration Guide for information about NG-bridge updates.)

Note:If an override of default rescan behavior is in effect (see Configuring Rescans to Always Skip Unchanged Files), the rules are applied to only changed files; unchanged files are skipped.

Note:Custom detection rules are applied only during the initial codebase scan and during a forced full rescan. They are not applied during a regular rescan initiated by the user.

Code Insight version change

See Notes

See Notes

Automated Analysis performs a full rescan only if the new Code Insight version includes changes to the Automated Analysis framework.

Advanced Analysis performs a full rescan only if the Code Insight version has changed and either the CL version has changed or an NG-bridge update has occurred. (See the Code Insight Installation and Configuration Guide for information about NG-bridge updates.)

Note:If an override of default rescan behavior is in effect (see Configuring Rescans to Always Skip Unchanged Files), the rescan skips unchanged files and scans only changed files, even if conditions are present to perform a full rescan for one or both analysis techniques.

Scan profile setting change

Full rescan

See Notes

A full rescan for Automated Analysis is required if one or more specific scan profile settings have changed. See Effects of Scan-Setting Changes on Rescans for more information.

Advanced Analysis also performs a full rescan only if one or more of the specific profile settings have changed and either the CL version has changed or an NG-bridge update has occurred. Keep in mind that changes to settings related to source-code matching result in an expensive full scan for Advanced Analysis. (See the Code Insight Installation and Configuration Guide for information about NG-bridge updates.)

Scan profiles are configured by the Code Insight System Administrator as described in the Code Insight Installation and Configuration Guide.

Note:If an override of default rescan behavior is in effect (see Configuring Rescans to Always Skip Unchanged Files), the rescan skips unchanged files and scans only changed files, even if scan profile settings have changed.