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

chore(NODE-6578): add misc tooling to ZSTD repo #36

Merged
merged 10 commits into from
Nov 25, 2024

Conversation

baileympearson
Copy link
Contributor

@baileympearson baileympearson commented Nov 21, 2024

Description

What is changing?

This PR contains a smattering of tooling we'll need for the SSDLC release flow (coming in the next PR):

  • A release please config and manifest has been added.
  • A new build action has been added, that builds the bindings and uploads the to GHA artifact storage (for use in the release action later, coming in a follow-up PR)
  • CodeQL has been enabled and configured for both C++ and JS.
  • A new SBOM file has been generated, which includes the correct version of zstd as our only bundled dependency.
  • The zstd C library version now is specified in the package.json and the install scripts reads the package file to install the correct version of zstd.
Is there new documentation needed for these changes?

What is the motivation for this change?

Double check the following

  • Ran npm run format:js && npm run format:rs script
  • Self-review completed using the steps outlined here
  • PR title follows the correct format: type(NODE-xxxx)[!]: description
    • Example: feat(NODE-1234)!: rewriting everything in coffeescript
  • Changes are covered by tests
  • New TODOs have a related JIRA ticket

@github-advanced-security
Copy link

This pull request sets up GitHub code scanning for this repository. Once the scans have completed and the checks have passed, the analysis results for this pull request branch will appear on this overview. Once you merge this pull request, the 'Security' tab will show more code scanning analysis results (for example, for the default branch). Depending on your configuration and choice of analysis tool, future pull requests will be annotated with code scanning analysis results. For more information about GitHub code scanning, check out the documentation.

@baileympearson baileympearson changed the title add codeql chore(NODE-6578): add misc tooling to ZSTD repo Nov 22, 2024
@baileympearson baileympearson marked this pull request as ready for review November 22, 2024 20:55
@aditi-khare-mongoDB aditi-khare-mongoDB self-assigned this Nov 22, 2024
@aditi-khare-mongoDB aditi-khare-mongoDB added the Primary Review In Review with primary reviewer, not yet ready for team's eyes label Nov 22, 2024
analyze:
name: Analyze (${{ matrix.language }})
runs-on: "ubuntu-latest"
timeout-minutes: 360
Copy link
Contributor

Choose a reason for hiding this comment

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

CodeQL only takes about 2 minutes, is there a reason we put a timeout here and chose 360?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

not really, no.

This is directly copied from mongodb-client-encryption, which was auto-generated by Github for us. I could adjust it if you want

Copy link
Contributor

Choose a reason for hiding this comment

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

No need to change it if it matches the existing code for mongodb-client-encryption!

@@ -2,13 +2,19 @@
ARG PLATFORM=arm64
ARG NODE_VERSION=16.20.1

FROM ${PLATFORM}/node:${NODE_VERSION}-alpine AS node
FROM ${PLATFORM}/node:${NODE_VERSION}-alpine AS build
Copy link
Contributor

Choose a reason for hiding this comment

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

What's the motivation behind this change?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The last line in the dockerfile:

COPY --from=build /zstd/prebuilds/ /

Requires that tag used in --from is the same as the tag here. I chose to change this to build to match Dockerfile.glibc instead of adjusting the tag below to --from=node.

Copy link
Contributor

Choose a reason for hiding this comment

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

Sounds good

@aditi-khare-mongoDB aditi-khare-mongoDB added Team Review Needs review from team and removed Primary Review In Review with primary reviewer, not yet ready for team's eyes labels Nov 25, 2024
Copy link
Contributor

@nbbeeken nbbeeken left a comment

Choose a reason for hiding this comment

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

Warning: 0:0 warning File ignored by default. Use a negated ignore pattern (like "--ignore-pattern '!<relative/path/to/filename>'") to override

Why doesn't this happen on our other repos? I'm seeing github post a warning on the .release-please-manifest.json file

package.json Outdated Show resolved Hide resolved
@baileympearson
Copy link
Contributor Author

Warning: 0:0 warning File ignored by default. Use a negated ignore pattern (like "--ignore-pattern '!<relative/path/to/filename>'") to override

Why doesn't this happen on our other repos? I'm seeing github post a warning on the .release-please-manifest.json file

We don't lint json files in our other repos. I set this up when I set up eslint and mocha - you pointed out they were malformed and we decided to lint them.

@aditi-khare-mongoDB aditi-khare-mongoDB merged commit 0a69186 into main Nov 25, 2024
40 checks passed
@aditi-khare-mongoDB aditi-khare-mongoDB deleted the ssdlc-tooling branch November 25, 2024 19:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Team Review Needs review from team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants