chore: retire the proto/buf toolchain, codegen, second port, and CI gen (Phase 4, #135)#207
Merged
Conversation
… second port (#135) Phase 3 (#134/#206) collapsed serving to a single HTTP listener, leaving the proto/buf machinery referenced only by generated code and the gRPC example client. This removes all of it. Deleted surfaces: - proto/ in full: milpacs.proto, tickets.proto, every generated .pb.go, .pb.gw.go, and _grpc.pb.go, plus the proto-coupled deprecation_test.go. - buf config: buf.gen.yaml, buf.lock, buf.yaml, and the codegen tool pins in tools.go. - cmd/example.go, the only non-generated proto consumer (the gRPC sample client). serve still works; root's description no longer claims gRPC. - Generated Swagger 2.0 assets (milpacs.swagger.json, tickets.swagger.json) and openapi/openapi_test.go, which asserted the 2.0 keycloak surface. Docs serving now points at the 3.1 spec. Per the #117 ruling (no consumer codegens from the served spec), the hand-owned OpenAPI 3.1 document (openapi/openapi.yaml) replaces the retired 2.0 files at the docs URL. DocsHandler serves it at /openapi.yaml with build-version stamping, and the Swagger UI shell loads it. The golden corpus already validates this document, so the public contract stays covered. Build, CI, and deploy: - Makefile and magefile drop install/generate and the buf lint/breaking targets. make lint is now go vet. - go.yml drops the buf install and make generate steps; the lint job runs go vet. - build_and_push.yml drops the release-time proto-version sed. The version reaches the spec at runtime via the build-time version var. - Dockerfile drops make install, buf install, and make generate, and stops exposing the gRPC port. docker-compose and the nginx template drop the :10000 second port and its grpc_pass block, so there is one listener in code and in config. go mod tidy shrinks the build graph from 209 to 90 modules (about 119 removed), in line with the PRD's ~100-module estimate. grpc, grpc-gateway, buf, and protoc are gone from the graph entirely. The throwaway request-log analytics and the duration= obligation were already retired with the old gateway in Phase 3, so there is nothing to remove here. *This was generated by AI*
SyniRon
added a commit
that referenced
this pull request
Jun 20, 2026
Record the rationale for retiring the split-process design now that the Phase 4 delete sweep (#135, PR #207) has landed. - New ADR 0006: single-listener net/http service with a hand-owned OpenAPI 3.1 contract. Supersedes ADR 0001 (split process) and ADR 0002 (intra-process plaintext dial); both now carry a superseded header pointing at 0006 and #135. Records the Swagger 2.0 full-retirement decision per the #117 answer (no consumer codegens from it). - CONTEXT.md: the contract is now the trio (types package, OpenAPI 3.1 spec, golden corpus); wire conventions recorded as house style; an add-an-endpoint checklist added; the Keycloak note moved to past tense. - README.md: refreshed to the post-#135 reality. Single listener, no codegen, no gRPC example client, no make generate/install/certs. *This was generated by AI*
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #135. Part of the "Goodbye gRPC" program (PRD #112), Phase 4. The Phase 3 cutover (#134) already moved serving to a single HTTP listener, and 3.0.0 has soaked, so this removes the proto/gRPC machinery that nothing reaches anymore.
What's deleted
proto/in full:milpacs.proto,tickets.proto, every generated*.pb.go/*.pb.gw.go/*_grpc.pb.go, andproto/deprecation_test.go.buf.gen.yaml,buf.lock,buf.yaml, and the codegen tool pins intools.go.cmd/example.go, the only non-generated proto consumer (the gRPC sample client).openapi/assets/{milpacs,tickets}.swagger.jsonandopenapi/openapi_test.go.Makefileandmagefile.go; the buf install andmake generatesteps in.github/workflows/go.yml; the release-time proto-versionsedinbuild_and_push.yml; themake install/buf/make generatesteps in theDockerfile; and the second:10000port plusgrpc_passblock indocker-compose.yamlanddocker/nginx/default.conf.One coordinated non-deletion change
Issue #117 resolved that no consumer generates client code from the served spec, so the docs surface is repointed from the retired Swagger 2.0 files to the hand-owned OpenAPI 3.1 document.
rest/docs.gonow servesopenapi/openapi.yaml(embedded viaopenapi.Spec) with build-version stamping,index.htmlloads it, andrest/docs_test.gois rewritten to pin the 3.1 surface and assert the 2.0 paths 404. The golden corpus (contract/spec_test.go) already validates that same document, so the public contract stays covered.Dependency delta
The build graph drops from 209 modules to 90 (about 119 removed). grpc, grpc-gateway, buf, and protoc are gone from the graph. One
google.golang.org/protobufindirect remains as a transitive dependency of the Prometheus client.Verification
go build ./...,go vet ./...(now whatmake lintruns), andgo test ./...are all green.go mod tidyis a no-op. The golden contract suite passes, which confirms the served HTTP contract survived the deletion. No buf or protoc invocation is left anywhere in the repo, CI, or build tooling.Follow-up
The
README.mdquickstart and ADRs 0001/0002 still describe the old split-process design. Superseding those belongs to #136 (the Phase 4 docs pass), so they're left for that PR.