Skip to content

Commit

Permalink
Merge pull request #417 from checkmarx-ltd/develop
Browse files Browse the repository at this point in the history
code merge for first scan og branched scan to be incremental
  • Loading branch information
satyamchaurasiapersistent authored Aug 16, 2024
2 parents 9446092 + 300e043 commit 001c941
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 1 deletion.
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
</parent>
<groupId>com.github.checkmarx-ltd</groupId>
<artifactId>cx-spring-boot-sdk</artifactId>
<version>0.6.13</version>
<version>0.6.14</version>


<name>cx-spring-boot-sdk</name>
Expand Down
6 changes: 6 additions & 0 deletions src/main/java/com/checkmarx/sdk/config/CxProperties.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

import com.checkmarx.sdk.utils.ScanUtils;
import com.google.common.collect.ImmutableMap;
import lombok.Builder;
import lombok.Getter;
import lombok.Setter;
import org.springframework.boot.context.properties.ConfigurationProperties;
Expand Down Expand Up @@ -33,6 +34,11 @@ public class CxProperties extends CxPropertiesBase{

private Boolean preserveXml = false;

@Getter
@Setter
@Builder.Default
private Boolean isBranchedIncremental = false;

@Getter
@Setter
private int corepoolsize;
Expand Down
3 changes: 3 additions & 0 deletions src/main/java/com/checkmarx/sdk/service/CxService.java
Original file line number Diff line number Diff line change
Expand Up @@ -2427,6 +2427,9 @@ public Integer createScan(CxScanParams params, String comment) throws CheckmarxE
else{
log.info("Scan will be incremental");
}
}else if(params.isIncremental() && !projectExistedBeforeScan && cxProperties.getIsBranchedIncremental()) {
log.info("Scan will be incremental");
params.setIncremental(true);
}
else {
log.info("Scan will be Full Scan");
Expand Down

0 comments on commit 001c941

Please sign in to comment.