compiling
- Repo stars 340
- License Apache-2.0
- Author repo skywalking-banyandb
- Domain
- Engineering
- Author-declared agents
- No explicit declaration found; this is not inferred or tested compatibility
- Static check
- 94 / 100 · heuristic scan, not runtime safety proof
- Runtime evidence
- Not run; no isolated runtime test evidence is currently recorded
- Author / version / license
- @apache · Apache-2.0
- Token usage
- Lean
- Setup complexity
- Plug-and-play
- External API key
- Not required
- Operating systems
- Unspecified (assume cross-platform)
- Runtime requirements
- No explicit requirements detected
- Detected file/system behavior
-
- Read-only
- Write / modify
- Network behavior
- Local-only
- Install commands
- None (reference only)
Heads up: Tool permissions are not declared; actual access depends on the runtime.
Step 1: Generate protobuf and mock code
Run `make generate` first. This regenerates `.pb.go` files from `.proto` definitions and mock files via mockgen. This step is required whenever: Proto files (`.proto`) have been added or modified Go interfaces used by mockgen have changed If generate fails, check:
Step 2: Build all binaries
Run `make build` to compile all project components: ui, banyand, bydbctl, mcp, fodc/agent, fodc/proxy. Binaries are output to each component's `build/bin/dev/` directory.
# Compiling SkyWalking BanyanDB
Follow these steps to compile the project.
## Step 1: Generate protobuf and mock code
Run `make generate` first. This regenerates `.pb.go` files from `.proto` definitions and mock files via mockgen.
This step is **required** whenever:
- Proto files (`.proto`) have been added or modified
- Go interfaces used by mockgen have changed
If generate fails, check:
- `protoc` and Go protobuf plugins are installed
- Proto file syntax is valid
- Interface signatures match mock expectations
## Step 2: Build all binaries
Run `make build` to compile all project components: ui, banyand, bydbctl, mcp, fodc/agent, fodc/proxy.
Binaries are output to each component's `build/bin/dev/` directory.
## Troubleshooting
- **Missing fields in .pb.go**: Proto files were updated but `make generate` was not run. Run it first.
- **Mock generation failures**: An interface changed but the mock wasn't regenerated. `make generate` fixes this.
- **Import errors**: Check import aliases match CLAUDE.md conventions (e.g., `commonv1`, `databasev1`).
## Other useful targets
- `make clean` — clean all build artifacts
- `make clean-build` — clean only build binaries
- `make lint` — run linters
- `make test` — run tests
Sections and files
Listed in source order.
sections -> Step 1: Generate protobuf and mock code → Step 2: Build all binaries → Troubleshooting → Other useful targets
terms -> required · Missing fields in .pb.go · Mock generation failures · Import errors
files/cmd -> make generate · .pb.go · .proto · protoc · make build · build/bin/dev/ · commonv1 · databasev1
body sha256 -> 2b31c9a193f0
Step 1: Generate protobuf and mock code
Run
make generatefirst. This regenerates.pb.gofiles from.protodefinitions and mock files via mockgen. This step is required whenever: Proto files (.proto) have been added or modified Go interfaces used by mockgen have changed If generate fails, check:Step 2: Build all binaries
Run
make buildto compile all project components: ui, banyand, bydbctl, mcp, fodc/agent, fodc/proxy. Binaries are output to each component'sbuild/bin/dev/directory.Troubleshooting
Missing fields in .pb.go: Proto files were updated but
make generatewas not run. Run it first. Mock generation failures: An interface changed but the mock wasn't regenerated.make generatefixes this. Import errors: Check import aliases match CLAUDE.md conventions (e.g.,commonv1,databasev1).Other useful targets
make clean— clean all build artifactsmake clean-build— clean only build binariesmake lint— run lintersmake test— run tests