Skip to content
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

feat: prosast component data upload #1639

Merged
merged 3 commits into from
Jun 10, 2024

Conversation

jon-stewart
Copy link
Contributor

@jon-stewart jon-stewart commented Jun 6, 2024

Summary

ProSAST must upload with the UrlType of ProSast.

Improved resourceGroup integration test by telling user how to recover.

How did you test this change?

Unit test

Issue

https://lacework.atlassian.net/browse/COD-3355

@jon-stewart jon-stewart self-assigned this Jun 6, 2024
@jon-stewart jon-stewart marked this pull request as ready for review June 6, 2024 14:25
@jon-stewart jon-stewart requested a review from a team as a code owner June 6, 2024 14:25
@@ -70,6 +71,10 @@ func (svc *ComponentDataService) UploadSastTables(
return svc.doUploadFiles(name, []string{"sast"}, paths, URL_TYPE_SAST_TABLES)
}

func (svc *ComponentDataService) UploadProSast(name string, paths []string) (string, error) {
return svc.doUploadFiles(name, []string{"sast"}, paths, URL_TYPE_PROSAST)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds like you are using the same tag as the other one. Will it not have any impact?

func (svc *ComponentDataService) UploadSastTables(
	name string, paths []string) (string, error) {
	return svc.doUploadFiles(name, []string{"sast"}, paths, URL_TYPE_SAST_TABLES)
}

Do you need a separate tag?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for reviewing this @hemanthgk10. It is strange that there are 2 'type' fields - legacy code.

The tags are used here to distinguish between SCA/IAC and SAST RedPanda topics.

The UrlType is used here to select a S3 key prefix.

I hope you can see from this PR that if I want to choose a different S3 key prefix I need to use the UrlType. The sast tag doesn't need to change.

@jon-stewart jon-stewart merged commit 635f2d3 into main Jun 10, 2024
12 checks passed
@jon-stewart jon-stewart deleted the jon-stewart/COD-3355/prosast-component-data branch June 10, 2024 12:51
@lacework-releng lacework-releng mentioned this pull request Jun 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants