Skip to content

Bazel bzlmod support for grpc-web.#1456

Merged
sampajano merged 7 commits intogrpc:masterfrom
gonzojive:bzlmod
Aug 27, 2024
Merged

Bazel bzlmod support for grpc-web.#1456
sampajano merged 7 commits intogrpc:masterfrom
gonzojive:bzlmod

Conversation

@gonzojive
Copy link
Copy Markdown
Contributor

@gonzojive gonzojive commented Aug 4, 2024

Update the bazel-based build of grpc-web to use bzlmod. Delete the WORKSPACE file since it is unused.

Output of bazel mod graph:

<root> ([email protected])
├───[email protected] 
│   ├───[email protected] (*) 
│   ├───[email protected] (*) 
│   ├───[email protected] (*) 
│   ├───[email protected] 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   └───[email protected] (*) 
│   ├───[email protected] 
│   │   ├───[email protected] (*) 
│   │   └───[email protected] (*) 
│   ├───[email protected] 
│   │   └───[email protected] (*) 
│   ├───[email protected] 
│   │   ├───[email protected] (*) 
│   │   └───[email protected] (*) 
│   ├───[email protected] 
│   │   ├───[email protected] (*) 
│   │   └───[email protected] (*) 
│   ├───[email protected] 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   └───[email protected] (*) 
│   ├───[email protected] 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] 
│   │   │   ├───[email protected] (*) 
│   │   │   └───[email protected] (*) 
│   │   └───[email protected] 
│   │       ├───[email protected] (*) 
│   │       ├───[email protected] (*) 
│   │       └───[email protected] (*) 
│   ├───[email protected] 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   └───[email protected] 
│   │       ├───[email protected] (*) 
│   │       ├───[email protected] (*) 
│   │       ├───[email protected] (*) 
│   │       ├───[email protected] (*) 
│   │       ├───[email protected] (*) 
│   │       └───[email protected] (*) 
│   ├───[email protected] 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   ├───re2@2023-09-01 (*) 
│   │   └───[email protected] (*) 
│   ├───[email protected] 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] 
│   │   │   └───[email protected] (*) 
│   │   ├───[email protected] 
│   │   ├───[email protected] 
│   │   │   └───[email protected] (*) 
│   │   ├───[email protected] 
│   │   └───[email protected] 
│   │       ├───[email protected] (*) 
│   │       ├───[email protected] (*) 
│   │       ├───[email protected] (*) 
│   │       ├───[email protected] (*) 
│   │       ├───[email protected] (*) 
│   │       ├───[email protected] (*) 
│   │       ├───[email protected] (*) 
│   │       └───[email protected] (*) 
│   ├───[email protected] 
│   │   └───[email protected] (*) 
│   ├───[email protected] 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   └───[email protected] (*) 
│   ├───re2@2023-09-01 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   └───[email protected] 
│   │       ├───[email protected] (*) 
│   │       └───[email protected] (*) 
│   ├───[email protected] 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   └───[email protected] 
│   │       ├───[email protected] (*) 
│   │       ├───[email protected] (*) 
│   │       ├───[email protected] (*) 
│   │       ├───[email protected] (*) 
│   │       ├───[email protected] (*) 
│   │       ├───[email protected] (*) 
│   │       ├───[email protected] (*) 
│   │       └───[email protected] (*) 
│   ├───[email protected] 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   └───[email protected] (*) 
│   ├───[email protected] 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   └───[email protected] (*) 
│   ├───[email protected] 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   └───[email protected] (*) 
│   └───[email protected] 
│       ├───[email protected] (*) 
│       └───[email protected] (*) 
├───[email protected] 
│   ├───[email protected] (*) 
│   ├───[email protected] (*) 
│   ├───[email protected] (*) 
│   ├───[email protected] (*) 
│   ├───[email protected] (*) 
│   ├───[email protected] (*) 
│   ├───[email protected] (*) 
│   ├───[email protected] (*) 
│   ├───[email protected] 
│   ├───[email protected] 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] (*) 
│   │   ├───[email protected] 
│   │   │   ├───[email protected] (*) 
│   │   │   ├───[email protected] (*) 
│   │   │   ├───[email protected] (*) 
│   │   │   ├───[email protected] (*) 
│   │   │   ├───[email protected] (*) 
│   │   │   ├───[email protected] (*) 
│   │   │   ├───[email protected] (*) 
│   │   │   └───[email protected] (*) 
│   │   └───[email protected] 
│   │       ├───[email protected] (*) 
│   │       ├───[email protected] (*) 
│   │       └───[email protected] (*) 
│   └───[email protected] 
│       ├───[email protected] (*) 
│       ├───[email protected] (*) 
│       └───[email protected] (*) 
├───[email protected] 
│   └───[email protected] (*) 
└───[email protected] 
    ├───[email protected] (*) 
    ├───[email protected] (*) 
    ├───[email protected] 
    │   └───[email protected] (*) 
    └───[email protected] 

fixes #1457

Updates the bazel-based build of grpc-web to use bzlmod.

The WORKSPACE file is retained for now, but it should probably be deleted since
it should be unused.
Copy link
Copy Markdown
Collaborator

@sampajano sampajano left a comment

Choose a reason for hiding this comment

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

@gonzojive Thanks so much for helping with modernizing our build system!!

There are some build failures though (log, could you help take a look please?

Thanks!!

Comment thread MODULE.bazel Outdated
Comment thread MODULE.bazel Outdated
Comment thread MODULE.bazel Outdated
Comment thread MODULE.bazel Outdated
Comment thread net/grpc/gateway/docker/prereqs/Dockerfile
@gonzojive
Copy link
Copy Markdown
Contributor Author

Would someone on the gprc-web team be interested in being the owner for the grpc-web module in the central registry? I can update https://github.com/bazelbuild/bazel-central-registry/pull/2541/files#diff-75ca774261b28f5a230b37542dc98c9611065b2ae99c7fec5430d164e8db5301 accordingly.

I think the release binaries will also need to be updated to include a zip of the source that has a guaranteed checksum (unlike github's automatic source archives).

@sampajano
Copy link
Copy Markdown
Collaborator

Would someone on the gprc-web team be interested in being the owner for the grpc-web module in the central registry? I can update https://github.com/bazelbuild/bazel-central-registry/pull/2541/files#diff-75ca774261b28f5a230b37542dc98c9611065b2ae99c7fec5430d164e8db5301 accordingly.

I think the release binaries will also need to be updated to include a zip of the source that has a guaranteed checksum (unlike github's automatic source archives).

Aha thanks for asking!

I'm not familiar with the system and not sure what the maintenance work entails..

But would be happy to help look into maintaining it for future releases once it's already been established (thanks for your PR!) and there's a clear steps to follow for keeping it up-to-date 😃

@gonzojive
Copy link
Copy Markdown
Contributor Author

Would someone on the gprc-web team be interested in being the owner for the grpc-web module in the central registry? I can update bazelbuild/bazel-central-registry#2541 (files) accordingly.
I think the release binaries will also need to be updated to include a zip of the source that has a guaranteed checksum (unlike github's automatic source archives).

Aha thanks for asking!

I'm not familiar with the system and not sure what the maintenance work entails..

But would be happy to help look into maintaining it for future releases once it's already been established (thanks for your PR!) and there's a clear steps to follow for keeping it up-to-date 😃

https://github.com/bazelbuild/bazel-central-registry/blob/main/docs/README.md has the responsibilities of a maintainer:

Every module must have a list of maintainers provided in its metadata.json file. The first contributor to a Bazel module is likely be appointed as the module maintainer. Anyone can apply to be a maintainer of some specific modules. Library authors / rule authors / Bazel users who have special interest on some projects can be module maintainers.

Responsibilities of a module maintainer

  • Review and approve changes related to the designated Bazel module.
  • Update new versions for the designated Bazel module.
  • Serve as the contact point for issues of their assigned module

There's no need to commit to any of that to submit this PR, though.

@sampajano
Copy link
Copy Markdown
Collaborator

There's no need to commit to any of that to submit this PR, though.

Oh ok!! Thanks for clarifying! Will merge it now! 😊

Copy link
Copy Markdown
Collaborator

@sampajano sampajano left a comment

Choose a reason for hiding this comment

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

Thanks a ton for the change! 😃

@sampajano sampajano merged commit 9856bfe into grpc:master Aug 27, 2024
@sampajano
Copy link
Copy Markdown
Collaborator

https://github.com/bazelbuild/bazel-central-registry/blob/main/docs/README.md has the responsibilities of a maintainer:

Every module must have a list of maintainers provided in its metadata.json file. The first contributor to a Bazel module is likely be appointed as the module maintainer. Anyone can apply to be a maintainer of some specific modules. Library authors / rule authors / Bazel users who have special interest on some projects can be module maintainers.
Responsibilities of a module maintainer

  • Review and approve changes related to the designated Bazel module.
  • Update new versions for the designated Bazel module.
  • Serve as the contact point for issues of their assigned module

There's no need to commit to any of that to submit this PR, though.

Aha and just noticed the maintainer responsibilities! Thanks for linking them!

Yeah I think i'll be happy to be the maintainer of the Bazel module (given my role :)). And I'll look into how to update the version when we make new releases.

Thanks a lot for the contribution!

gonzojive added a commit to gonzojive/grpc-web that referenced this pull request Sep 28, 2024
* Bazel bzlmod support for grpc-web.

Updates the bazel-based build of grpc-web to use bzlmod.

The WORKSPACE file is retained for now, but it should probably be deleted since
it should be unused.

* Delete WORKSPACE files.

* bazel mod tidy

* MODULE.bazel fixups

* Update version to 1.6.0.rc1 in MODULE.bazel

* Update module and dockerfile in response to pr comments about build failure and protobuf version

* Fix lint issue with MODULE.bazel
@alexeagle
Copy link
Copy Markdown

@sampajano could you cut a release? It's been 24 commits and over a year since the last one. 1.5.0...master

Still waiting on this getting into the Bazel Central Registry.

@sampajano
Copy link
Copy Markdown
Collaborator

@alexeagle Hi.. Apologize for the delays!

Sorry I was occupied with other work and not able to make progress here.

This year we're getting some new help on this project, so we're definitely going to start making progress here, and cutting a new release is first priority!

Will definitely aim to cut one soon! And will update here once we did!

Thanks for your patience!

@sampajano
Copy link
Copy Markdown
Collaborator

sampajano commented Aug 30, 2025

@alexeagle FYI - 2.0.0 is released! :) Thank you for your (great) patience! :)

@alexeagle
Copy link
Copy Markdown

Awesome, thank you! I hope engaging with the community at gRPConf helped inspire the team :)

@sampajano
Copy link
Copy Markdown
Collaborator

@alexeagle You're welcome! Oh wow nice.. I in fact missed gRPCConf.. But glad to hear that you had a positive engagement there! 😊

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Use bzlmod for bazel build

4 participants