redpanda-data / redpanda-data/console
Filesystem proto parser doesn't allow "service" in package paths within gRPC services
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 4.3k
- Forks
- 432
- Avg merge
- 3d 6h
- Merged PRs (30d)
- 40
Description
I have proto files that are mix of Protobuf messages and gRPC service definitions. Unfortunately, parser doesn't allow for .service. string in package path. For example, this Proto:
service StreamService {
rpc Consume(
vendor.stream.v1.messages.StreamRequest // <-- line 9
) returns (
stream vendor.stream.v1.messages.StreamPayload
);
}
causes a startup error of Redpanda Console:
2025-09-22 17:16:28 {"time":"2025-09-22T15:16:28.910647048Z","level":"WARN","msg":"failed to parse proto file to descriptor","logger":"proto_service","file":"vendor/stream_service.proto","line":9,"error":"vendor/stream_service.proto:9:12: syntax error: unexpected \"stream\""}
2025-09-22 17:16:28 {"time":"2025-09-22T15:16:28Z","level":"ERROR","msg":"failed to start API","!BADKEY":"start console service: failed to start proto service: failed to create proto registry: failed to compile proto files to descriptors: failed to parse proto files to descriptors: parse failed: invalid proto source"}
If you change the package name to something else, like streamz - it will work.
protoc builds descriptors for the original variant without issues, command for the repo below:
protoc \
--proto_path=proto \
--include_imports \
--descriptor_set_out=schema.desc \
proto/**/*.proto
Reproduction
Reproduction repository: https://github.com/sienkiewiczkm/reproduction-redpanda-parsing
For a "fix" highlighting a problem see branch fix/demo: https://github.com/sienkiewiczkm/reproduction-redpanda-parsing/commit/75fa0dea6369f0b29f2921d8c14b3d146ad03dda
After applying a "fix" you'll see in logs:
2025-09-22 17:23:18 {"time":"2025-09-22T15:23:18.705975585Z","level":"INFO","msg":"successfully loaded all files from filesystem into cache","logger":"proto_service","provider":"file_provider","loaded_files":3}
2025-09-22 17:23:18 {"time":"2025-09-22T15:23:18.710163502Z","level":"INFO","msg":"registered proto types in Console's local proto registry","logger":"proto_service","registered_types":3}
2025-09-22 17:23:18 {"time":"2025-09-22T15:23:18.710179669Z","level":"INFO","msg":"checked whether all mapped proto types also exist in the local registry","logger":"proto_service","types_found":1,"types_missing":0,"registered_types":3,"operation_duration":4162959}
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the filesystem proto parser and compare its handling of the reproduction repository with protoc, using the provided proto example and the fix branch as references. Done means valid package paths containing "service" parse successfully and Redpanda Console starts with the files loaded into its local proto registry.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- grpc
- Domain
- api, backend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100