Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ load("@gazelle//:def.bzl", "gazelle")

# gazelle:prefix github.com/uber/submitqueue

# gazelle:go_naming_convention go_default_library

# Exclude nested worktrees (created under .claude/worktrees) so gazelle does not
# index them as duplicate rule definitions and corrupt the canonical BUILD files.
# gazelle:exclude .claude
Expand Down
6 changes: 3 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -144,19 +144,19 @@ integration-test: build-all-linux ## Run all integration tests (auto-builds bina

integration-test-submitqueue-consumer: ## Run Consumer integration tests
@echo "Running Consumer integration tests..."
@$(BAZEL) test //test/integration/submitqueue/core/consumer:consumer_test --test_output=streamed
@$(BAZEL) test //test/integration/submitqueue/core/consumer:go_default_test --test_output=streamed

integration-test-extensions: ## Run extension integration tests (runs in parallel)
@echo "Running extension integration tests (parallel)..."
@$(BAZEL) test //test/integration/submitqueue/extension/... //test/integration/extension/... --test_output=errors

integration-test-submitqueue-gateway: build-submitqueue-gateway-linux ## Run Gateway integration tests (auto-builds binary)
@echo "Running Gateway integration tests..."
@$(BAZEL) test //test/integration/submitqueue/gateway:gateway_test --test_output=streamed
@$(BAZEL) test //test/integration/submitqueue/gateway:go_default_test --test_output=streamed

integration-test-submitqueue-orchestrator: build-submitqueue-orchestrator-linux ## Run Orchestrator integration tests (auto-builds binary)
@echo "Running Orchestrator integration tests..."
@$(BAZEL) test //test/integration/submitqueue/orchestrator:orchestrator_test --test_output=streamed
@$(BAZEL) test //test/integration/submitqueue/orchestrator:go_default_test --test_output=streamed

license-fix: ## Add missing license headers to source files
@$(BAZEL) run //tool/linter/licenseheader -- --fix
Expand Down
6 changes: 3 additions & 3 deletions api/base/change/protopb/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
load("@rules_go//go:def.bzl", "go_library")

go_library(
name = "protopb",
name = "go_default_library",
srcs = ["change.pb.go"],
importpath = "github.com/uber/submitqueue/api/base/change/protopb",
visibility = ["//visibility:public"],
deps = [
"@org_golang_google_protobuf//reflect/protoreflect",
"@org_golang_google_protobuf//runtime/protoimpl",
"@org_golang_google_protobuf//reflect/protoreflect:go_default_library",

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.

how this is supposed to work? it is an external dependency.

@roychying roychying Jul 2, 2026

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

these external dependences have :go_default_library alias. Not strictly required, just want to keep consistency across all imported packages

bazel query --output=build "@org_golang_google_protobuf//reflect/protoreflect:go_default_library"
INFO: Invocation ID: 6887c543-e59d-40a1-9a29-57ccc312b3aa
# /home/user/.cache/bazel/_bazel_chenghan.ying/9fe95cfc2da7ac7338edf63ca6b444da/external/gazelle++go_deps+org_golang_google_protobuf/reflect/protoreflect/BUILD.bazel:24:6
alias(
  name = "go_default_library",
  visibility = ["//visibility:public"],
  actual = "@org_golang_google_protobuf//reflect/protoreflect:protoreflect",
)

@roychying roychying Jul 2, 2026

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

actually changes in external packages are guaranteed. Setting # gazelle:go_naming_convention go_default_library for our own local targets unintentionally also renames every external dependency reference to :go_default_library, because Gazelle's default import_alias convention for external repos falls back to whatever the local naming convention is when no go_naming_convention_external directive is explicitly set.
If we manually revert back to the short name, make gazelle will just update it again to go_default_library

"@org_golang_google_protobuf//runtime/protoimpl:go_default_library",
],
)
6 changes: 3 additions & 3 deletions api/base/mergestrategy/protopb/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
load("@rules_go//go:def.bzl", "go_library")

go_library(
name = "protopb",
name = "go_default_library",
srcs = ["mergestrategy.pb.go"],
importpath = "github.com/uber/submitqueue/api/base/mergestrategy/protopb",
visibility = ["//visibility:public"],
deps = [
"@org_golang_google_protobuf//reflect/protoreflect",
"@org_golang_google_protobuf//runtime/protoimpl",
"@org_golang_google_protobuf//reflect/protoreflect:go_default_library",
"@org_golang_google_protobuf//runtime/protoimpl:go_default_library",
],
)
8 changes: 4 additions & 4 deletions api/base/messagequeue/protopb/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
load("@rules_go//go:def.bzl", "go_library")

go_library(
name = "protopb",
name = "go_default_library",
srcs = ["messagequeue.pb.go"],
importpath = "github.com/uber/submitqueue/api/base/messagequeue/protopb",
visibility = ["//visibility:public"],
deps = [
"@org_golang_google_protobuf//reflect/protoreflect",
"@org_golang_google_protobuf//runtime/protoimpl",
"@org_golang_google_protobuf//types/descriptorpb",
"@org_golang_google_protobuf//reflect/protoreflect:go_default_library",
"@org_golang_google_protobuf//runtime/protoimpl:go_default_library",
"@org_golang_google_protobuf//types/descriptorpb:go_default_library",
],
)
28 changes: 14 additions & 14 deletions api/runway/messagequeue/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,32 +1,32 @@
load("@rules_go//go:def.bzl", "go_library", "go_test")

go_library(
name = "messagequeue",
name = "go_default_library",
srcs = [
"merge.go",
"topics.go",
],
importpath = "github.com/uber/submitqueue/api/runway/messagequeue",
visibility = ["//visibility:public"],
deps = [
"//api/base/messagequeue/protopb", # keep
"//api/runway/messagequeue/protopb", # keep
"//platform/consumer",
"@org_golang_google_protobuf//encoding/protojson",
"@org_golang_google_protobuf//proto",
"//api/base/messagequeue/protopb:go_default_library",
"//api/runway/messagequeue/protopb:go_default_library",
"//platform/consumer:go_default_library",
"@org_golang_google_protobuf//encoding/protojson:go_default_library",
"@org_golang_google_protobuf//proto:go_default_library",
],
)

go_test(
name = "messagequeue_test",
name = "go_default_test",
srcs = ["merge_test.go"],
embed = [":messagequeue"],
embed = [":go_default_library"],
deps = [
"//api/base/change/protopb",
"//api/base/mergestrategy/protopb",
"//api/runway/messagequeue/protopb",
"@com_github_stretchr_testify//assert",
"@com_github_stretchr_testify//require",
"@org_golang_google_protobuf//proto",
"//api/base/change/protopb:go_default_library",
"//api/base/mergestrategy/protopb:go_default_library",
"//api/runway/messagequeue/protopb:go_default_library",
"@com_github_stretchr_testify//assert:go_default_library",
"@com_github_stretchr_testify//require:go_default_library",
"@org_golang_google_protobuf//proto:go_default_library",
],
)
12 changes: 6 additions & 6 deletions api/runway/messagequeue/protopb/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
load("@rules_go//go:def.bzl", "go_library")

go_library(
name = "protopb",
name = "go_default_library",
srcs = ["merge.pb.go"],
importpath = "github.com/uber/submitqueue/api/runway/messagequeue/protopb",
visibility = ["//visibility:public"],
deps = [
"//api/base/change/protopb",
"//api/base/mergestrategy/protopb",
"//api/base/messagequeue/protopb", # keep
"@org_golang_google_protobuf//reflect/protoreflect",
"@org_golang_google_protobuf//runtime/protoimpl",
"//api/base/change/protopb:go_default_library",
"//api/base/mergestrategy/protopb:go_default_library",
"//api/base/messagequeue/protopb:go_default_library",
"@org_golang_google_protobuf//reflect/protoreflect:go_default_library",
"@org_golang_google_protobuf//runtime/protoimpl:go_default_library",
],
)
26 changes: 13 additions & 13 deletions api/runway/protopb/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
load("@rules_go//go:def.bzl", "go_library")

go_library(
name = "protopb",
name = "go_default_library",
srcs = [
"runway.pb.go",
"runway.pb.yarpc.go",
Expand All @@ -10,17 +10,17 @@ go_library(
importpath = "github.com/uber/submitqueue/api/runway/protopb",
visibility = ["//visibility:public"],
deps = [
"@org_golang_google_grpc//:grpc",
"@org_golang_google_grpc//codes",
"@org_golang_google_grpc//status",
"@org_golang_google_protobuf//proto",
"@org_golang_google_protobuf//reflect/protoreflect",
"@org_golang_google_protobuf//runtime/protoimpl",
"@org_uber_go_fx//:fx",
"@org_uber_go_yarpc//:yarpc",
"@org_uber_go_yarpc//api/transport",
"@org_uber_go_yarpc//api/x/restriction",
"@org_uber_go_yarpc//encoding/protobuf/reflection",
"@org_uber_go_yarpc//encoding/protobuf/v2:protobuf",
"@org_golang_google_grpc//:go_default_library",
"@org_golang_google_grpc//codes:go_default_library",
"@org_golang_google_grpc//status:go_default_library",
"@org_golang_google_protobuf//proto:go_default_library",
"@org_golang_google_protobuf//reflect/protoreflect:go_default_library",
"@org_golang_google_protobuf//runtime/protoimpl:go_default_library",
"@org_uber_go_fx//:go_default_library",
"@org_uber_go_yarpc//:go_default_library",
"@org_uber_go_yarpc//api/transport:go_default_library",
"@org_uber_go_yarpc//api/x/restriction:go_default_library",
"@org_uber_go_yarpc//encoding/protobuf/reflection:go_default_library",
"@org_uber_go_yarpc//encoding/protobuf/v2:go_default_library",
],
)
26 changes: 13 additions & 13 deletions api/stovepipe/protopb/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
load("@rules_go//go:def.bzl", "go_library")

go_library(
name = "protopb",
name = "go_default_library",
srcs = [
"stovepipe.pb.go",
"stovepipe.pb.yarpc.go",
Expand All @@ -10,17 +10,17 @@ go_library(
importpath = "github.com/uber/submitqueue/api/stovepipe/protopb",
visibility = ["//visibility:public"],
deps = [
"@org_golang_google_grpc//:grpc",
"@org_golang_google_grpc//codes",
"@org_golang_google_grpc//status",
"@org_golang_google_protobuf//proto",
"@org_golang_google_protobuf//reflect/protoreflect",
"@org_golang_google_protobuf//runtime/protoimpl",
"@org_uber_go_fx//:fx",
"@org_uber_go_yarpc//:yarpc",
"@org_uber_go_yarpc//api/transport",
"@org_uber_go_yarpc//api/x/restriction",
"@org_uber_go_yarpc//encoding/protobuf/reflection",
"@org_uber_go_yarpc//encoding/protobuf/v2:protobuf",
"@org_golang_google_grpc//:go_default_library",
"@org_golang_google_grpc//codes:go_default_library",
"@org_golang_google_grpc//status:go_default_library",
"@org_golang_google_protobuf//proto:go_default_library",
"@org_golang_google_protobuf//reflect/protoreflect:go_default_library",
"@org_golang_google_protobuf//runtime/protoimpl:go_default_library",
"@org_uber_go_fx//:go_default_library",
"@org_uber_go_yarpc//:go_default_library",
"@org_uber_go_yarpc//api/transport:go_default_library",
"@org_uber_go_yarpc//api/x/restriction:go_default_library",
"@org_uber_go_yarpc//encoding/protobuf/reflection:go_default_library",
"@org_uber_go_yarpc//encoding/protobuf/v2:go_default_library",
],
)
30 changes: 15 additions & 15 deletions api/submitqueue/gateway/protopb/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
load("@rules_go//go:def.bzl", "go_library")

go_library(
name = "protopb",
name = "go_default_library",
srcs = [
"gateway.pb.go",
"gateway.pb.yarpc.go",
Expand All @@ -10,19 +10,19 @@ go_library(
importpath = "github.com/uber/submitqueue/api/submitqueue/gateway/protopb",
visibility = ["//visibility:public"],
deps = [
"//api/base/change/protopb",
"//api/base/mergestrategy/protopb",
"@org_golang_google_grpc//:grpc",
"@org_golang_google_grpc//codes",
"@org_golang_google_grpc//status",
"@org_golang_google_protobuf//proto",
"@org_golang_google_protobuf//reflect/protoreflect",
"@org_golang_google_protobuf//runtime/protoimpl",
"@org_uber_go_fx//:fx",
"@org_uber_go_yarpc//:yarpc",
"@org_uber_go_yarpc//api/transport",
"@org_uber_go_yarpc//api/x/restriction",
"@org_uber_go_yarpc//encoding/protobuf/reflection",
"@org_uber_go_yarpc//encoding/protobuf/v2:protobuf",
"//api/base/change/protopb:go_default_library",
"//api/base/mergestrategy/protopb:go_default_library",
"@org_golang_google_grpc//:go_default_library",
"@org_golang_google_grpc//codes:go_default_library",
"@org_golang_google_grpc//status:go_default_library",
"@org_golang_google_protobuf//proto:go_default_library",
"@org_golang_google_protobuf//reflect/protoreflect:go_default_library",
"@org_golang_google_protobuf//runtime/protoimpl:go_default_library",
"@org_uber_go_fx//:go_default_library",
"@org_uber_go_yarpc//:go_default_library",
"@org_uber_go_yarpc//api/transport:go_default_library",
"@org_uber_go_yarpc//api/x/restriction:go_default_library",
"@org_uber_go_yarpc//encoding/protobuf/reflection:go_default_library",
"@org_uber_go_yarpc//encoding/protobuf/v2:go_default_library",
],
)
26 changes: 13 additions & 13 deletions api/submitqueue/orchestrator/protopb/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
load("@rules_go//go:def.bzl", "go_library")

go_library(
name = "protopb",
name = "go_default_library",
srcs = [
"orchestrator.pb.go",
"orchestrator.pb.yarpc.go",
Expand All @@ -10,17 +10,17 @@ go_library(
importpath = "github.com/uber/submitqueue/api/submitqueue/orchestrator/protopb",
visibility = ["//visibility:public"],
deps = [
"@org_golang_google_grpc//:grpc",
"@org_golang_google_grpc//codes",
"@org_golang_google_grpc//status",
"@org_golang_google_protobuf//proto",
"@org_golang_google_protobuf//reflect/protoreflect",
"@org_golang_google_protobuf//runtime/protoimpl",
"@org_uber_go_fx//:fx",
"@org_uber_go_yarpc//:yarpc",
"@org_uber_go_yarpc//api/transport",
"@org_uber_go_yarpc//api/x/restriction",
"@org_uber_go_yarpc//encoding/protobuf/reflection",
"@org_uber_go_yarpc//encoding/protobuf/v2:protobuf",
"@org_golang_google_grpc//:go_default_library",
"@org_golang_google_grpc//codes:go_default_library",
"@org_golang_google_grpc//status:go_default_library",
"@org_golang_google_protobuf//proto:go_default_library",
"@org_golang_google_protobuf//reflect/protoreflect:go_default_library",
"@org_golang_google_protobuf//runtime/protoimpl:go_default_library",
"@org_uber_go_fx//:go_default_library",
"@org_uber_go_yarpc//:go_default_library",
"@org_uber_go_yarpc//api/transport:go_default_library",
"@org_uber_go_yarpc//api/x/restriction:go_default_library",
"@org_uber_go_yarpc//encoding/protobuf/reflection:go_default_library",
"@org_uber_go_yarpc//encoding/protobuf/v2:go_default_library",
],
)
10 changes: 5 additions & 5 deletions example/runway/client/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
load("@rules_go//go:def.bzl", "go_binary", "go_library")

go_library(
name = "client_lib",
name = "go_default_library",
srcs = ["main.go"],
importpath = "github.com/uber/submitqueue/example/runway/client",
visibility = ["//visibility:private"],
deps = [
"//api/runway/protopb",
"@org_golang_google_grpc//:grpc",
"@org_golang_google_grpc//credentials/insecure",
"//api/runway/protopb:go_default_library",
"@org_golang_google_grpc//:go_default_library",
"@org_golang_google_grpc//credentials/insecure:go_default_library",
],
)

go_binary(
name = "runway",
embed = [":client_lib"],
embed = [":go_default_library"],
visibility = ["//visibility:public"],
)
36 changes: 18 additions & 18 deletions example/runway/server/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,32 +1,32 @@
load("@rules_go//go:def.bzl", "go_binary", "go_library")

go_library(
name = "server_lib",
name = "go_default_library",
srcs = ["main.go"],
importpath = "github.com/uber/submitqueue/example/runway/server",
visibility = ["//visibility:private"],
deps = [
"//api/runway/messagequeue",
"//api/runway/protopb",
"//platform/consumer",
"//platform/errs",
"//platform/errs/generic",
"//platform/errs/mysql",
"//platform/extension/messagequeue",
"//platform/extension/messagequeue/mysql",
"//runway/controller",
"//runway/controller/merge",
"//runway/controller/mergeconflictcheck",
"@com_github_go_sql_driver_mysql//:mysql",
"@com_github_uber_go_tally//:tally",
"@org_golang_google_grpc//:grpc",
"@org_golang_google_grpc//reflection",
"@org_uber_go_zap//:zap",
"//api/runway/messagequeue:go_default_library",
"//api/runway/protopb:go_default_library",
"//platform/consumer:go_default_library",
"//platform/errs:go_default_library",
"//platform/errs/generic:go_default_library",
"//platform/errs/mysql:go_default_library",
"//platform/extension/messagequeue:go_default_library",
"//platform/extension/messagequeue/mysql:go_default_library",
"//runway/controller:go_default_library",
"//runway/controller/merge:go_default_library",
"//runway/controller/mergeconflictcheck:go_default_library",
"@com_github_go_sql_driver_mysql//:go_default_library",
"@com_github_uber_go_tally//:go_default_library",
"@org_golang_google_grpc//:go_default_library",
"@org_golang_google_grpc//reflection:go_default_library",
"@org_uber_go_zap//:go_default_library",
],
)

go_binary(
name = "runway",
embed = [":server_lib"],
embed = [":go_default_library"],
visibility = ["//visibility:public"],
)
Loading
Loading