Skip to content

feat: migrate to new go worker#5330

Merged
michaelkedar merged 4 commits into
google:masterfrom
michaelkedar:👷🙅🐍
May 12, 2026

Hidden character warning

The head ref may contain hidden characters: "\ud83d\udc77\ud83d\ude45\ud83d\udc0d"
Merged

feat: migrate to new go worker#5330
michaelkedar merged 4 commits into
google:masterfrom
michaelkedar:👷🙅🐍

Conversation

@michaelkedar
Copy link
Copy Markdown
Member

yay 👷
Set up the entry point and Dockerfile and kubernetes yaml for the go worker to supplant the python worker.

  • The Go worker can concurrently process 10 pub/sub tasks (configurable), up from the Python's 1, so I've adjusted the horizontal scaler appropriately.
  • The go worker builds the new gcr.io/oss-vdb/osv-worker image. The old python gcr.io/oss-vdb/worker image is still being built because a number of our other images use it as a base image.
  • I haven't touched the memory/CPU limits (but I have removed unused configs), since I don't really know the memory footprint of this. Was planning to watch this on the test instance and adjust appropriately.

Merging this WILL start deploying the go worker, so best to do this right after the week's release.

another-rex
another-rex previously approved these changes May 11, 2026
Copy link
Copy Markdown
Contributor

@another-rex another-rex left a comment

Choose a reason for hiding this comment

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

Nice

Comment thread go/cmd/worker/Dockerfile
COPY ./ /src/
RUN CGO_ENABLED=0 go build -o worker ./cmd/worker

FROM gcr.io/distroless/static-debian12@sha256:20bc6c0bc4d625a22a8fde3e55f6515709b32055ef8fb9cfbddaa06d1760f838
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Just double checking running this locally works fine? no problems with musl because we are compiling on alpine because CGO is 0?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

yeah, running locally seems to work

spec:
containers:
- name: worker-private
env:
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Should we set all the envs here, even if it's the default value, just to make it easier to see all the options?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

added a bunch of defaults to the base yaml file

@michaelkedar michaelkedar merged commit b4eacc6 into google:master May 12, 2026
21 checks passed
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.

2 participants