kubescape / storage

Apache License 2.0
1 stars 6 forks source link

Vuln summary api objects #41

Closed rcohencyberarmor closed 12 months ago

rcohencyberarmor commented 12 months ago

PR Type:

Enhancement


PR Description:

This PR introduces new API objects for vulnerability summaries. It includes the creation of new Go structures, their respective functions, and the automatic generation of conversion functions. The changes are mainly in the 'softwarecomposition' package, with the addition of new tests for the implemented functionality.


PR Main Files Walkthrough:

pkg/registry/file/vulnarabilitysummarystoarge_test.go: This file contains the tests for the new Vulnerability Summary Storage implementation. It tests the different methods such as Create, Delete, Watch, GetList, GuaranteedUpdate, Count, and Get. pkg/apis/softwarecomposition/v1beta1/zz_generated.conversion.go: This file contains the auto-generated conversion functions for the new VulnerabilitySummary objects. These functions are used to convert between the internal version of the API and the v1beta1 version. pkg/apis/softwarecomposition/types.go: This file contains the definition of the new VulnerabilitySummary objects in the internal version of the API. pkg/apis/softwarecomposition/v1beta1/types.go: This file contains the definition of the new VulnerabilitySummary objects in the v1beta1 version of the API. pkg/registry/softwarecomposition/vulnerabilitysummary/strategy.go: This file contains the implementation of the specific behavior that the API server needs to have for the new VulnerabilitySummary objects. pkg/registry/softwarecomposition/vulnerabilitysummary/etcd.go: This file contains the storage interface implementation for the new VulnerabilitySummary objects. It includes the setup of the REST storage for these objects. pkg/apiserver/apiserver.go: This file contains the setup of the API group for the new VulnerabilitySummary objects. It includes the setup of the REST storage for these objects. pkg/generated/openapi/zz_generated.openapi.go: This file contains the auto-generated open API schemas for the new VulnerabilitySummary objects. pkg/generated/clientset/versioned/typed/softwarecomposition/v1beta1/vulnerabilitysummary.go: This file contains the auto-generated clientset for the new VulnerabilitySummary objects. pkg/generated/listers/softwarecomposition/v1beta1/vulnerabilitysummary.go: This file contains the auto-generated listers for the new VulnerabilitySummary objects. These listers allow to list/get VulnerabilitySummary objects from a shared index.

codiumai-pr-agent[bot] commented 12 months ago

PR Analysis

How to use

To invoke the PR-Agent, add a comment using one of the following commands: /review [-i]: Request a review of your Pull Request. For an incremental review, which only considers changes since the last review, include the '-i' option. /describe: Modify the PR title and description based on the contents of the PR. /improve [--extended]: Suggest improvements to the code in the PR. Extended mode employs several calls, and provides a more thorough feedback. /ask \<QUESTION>: Pose a question about the PR. /update_changelog: Update the changelog based on the PR's contents.

To edit any configuration parameter from configuration.toml, add --config_path=new_value For example: /review --pr_reviewer.extra_instructions="focus on the file: ..." To list the possible configuration parameters, use the /config command.

github-actions[bot] commented 12 months ago

Summary: