Skip to content

feat: new registration API#490

Open
holyspectral wants to merge 2 commits into
neuvector:mainfrom
holyspectral:support-new-registration-api
Open

feat: new registration API#490
holyspectral wants to merge 2 commits into
neuvector:mainfrom
holyspectral:support-new-registration-api

Conversation

@holyspectral

Copy link
Copy Markdown
Contributor

Description

Today, the scanner registration is done via ScannerRegisterStream and ScannerRegister API. The problem of these two APIs is that, scanner has to extract and send the whole cvedb to controller, and these data will be kept in controller memory until they're handled, even the cvedb is already up-to-date.

The cvedb's raw size has grown from 211.5mb (3.800) to 340.3 MB (4.196) in one year, so this becomes a huge memory pressure when scanner sends the cvedb to the same controller about the same time. If there is a memory limit like 2G in place, when all register requests are sent to the same controller, the controller can be killed immediately by OOM killer.

This PR implements a new gRPC API, ScannerRegisterV3 for scanner to send cvedb metadata first in order to register. If the cvedb is newer, controller will ask the scanner to send the whole cvedb.

Test

To test this pull request, you can run the following commands:

Additional Information

Tradeoff

Potential improvement

@holyspectral

Copy link
Copy Markdown
Contributor Author

This is ready for review, but package path in go.mod has to be changed once neuvector side is merged.

@holyspectral holyspectral marked this pull request as ready for review June 18, 2026 14:38
@holyspectral holyspectral requested a review from a team as a code owner June 18, 2026 14:38
@holyspectral holyspectral changed the title wip: feat: new registration API feat: new registration API Jun 18, 2026
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.

1 participant