-
Notifications
You must be signed in to change notification settings - Fork 40
Add diff logic and parallel logger support for audit #642
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: dev
Are you sure you want to change the base?
Conversation
…Results) - based on v1.24.2
- Add branchdiff.go with RunBranchDiffAudit function - Scans target branch first, then source branch (sequential) - SCA diff handled internally by CLI - JAS diff handled by CompareJasResults - Add MergeStatusCodes for partial results filtering - Status codes merged (worst of target + source) for frogbot filtering
- Add logger field to AuditBasicParams with getter/setter - RunAudit swaps global logger if custom logger provided - Enables frogbot to capture logs per-scan for ordered output
- Add LogCollector that captures logs in isolated buffer per audit - Enables parallel audits without log interleaving - Uses goroutine-local logger from jfrog-client-go - Propagate logger to child goroutines in JAS runner and SCA scan - Remove unused diff completion log message
| ) | ||
|
|
||
| // UnifyScaAndJasResults merges SCA and JAS diff results into a single SecurityCommandResults. | ||
| func UnifyScaAndJasResults(scaResults, jasDiffResults *SecurityCommandResults) *SecurityCommandResults { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
myabe needs to be moved to frogbot considering the specific use
and selected parallel audit implementation, your call @attiasas
utils/results/diff.go
Outdated
| } | ||
|
|
||
| // MergeStatusCodes merges two ResultsStatus, taking the worst (non-zero) status for each scanner. | ||
| func MergeStatusCodes(target, source ResultsStatus) ResultsStatus { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| } | ||
| } | ||
|
|
||
| log.Debug("[DIFF] Built target fingerprint set with", len(targetKeys), "unique keys") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
honestly is it relevant?
devbranch.go vet ./....go fmt ./....Depends on: