A Go API for data migration.
- Run
make debugto run application on http://localhost:30100 - Run
make debug-watchto have your changes rebuild the application that is running - Run
make helpto see full list of make targets
To run some of our tests you will need additional tooling:
We use reflex to do rebuilds, which you will need to install.
We use dis-vulncheck to do auditing, which you will need to install.
We use v2 of golangci-lint, which you will need to install.
- No further dependencies other than those defined in
go.mod
To validate the swagger specification you can do this via:
make validate-specificationTo run this, you will need to run Node > v22 and have redocly CLI v2 installed:
npm install -g @redocly/cli| Environment variable | Default | Description |
|---|---|---|
| BIND_ADDR | :30100 | The host and port to bind to |
| DATASET_API_URL | localhost:20000 | Address for Dataset API |
| ENABLE_MOCK_CLIENTS | false | Boolean to inject mock clients to allow for faster development |
| FILES_API_URL | localhost:26900 | Address for File API |
| GRACEFUL_SHUTDOWN_TIMEOUT | 5s | The graceful shutdown timeout in seconds (time.Duration format) |
| HEALTHCHECK_INTERVAL | 30s | Time between self-healthchecks (time.Duration format) |
| HEALTHCHECK_CRITICAL_TIMEOUT | 90s | Time to wait until an unhealthy dependent propagates its state to make this app unhealthy (time.Duration format) |
| MIGRATION_SERVICE_URL | http://localhost:30100 | Host address used for deriving HATEOS link defaults |
| OTEL_EXPORTER_OTLP_ENDPOINT | localhost:4317 | Endpoint for OpenTelemetry service |
| OTEL_SERVICE_NAME | dis-migration-service | Label of service for OpenTelemetry service |
| OTEL_BATCH_TIMEOUT | 5s | Timeout for OpenTelemetry |
| OTEL_ENABLED | false | Feature flag to enable OpenTelemetry |
| REDIRECT_API_URL | localhost:29900 | Address for the Redirect API |
| UPLOAD_SERVICE_URL | localhost:25100 | Address for Upload Service |
| ZEBEDEE_URL | localhost:8082 | Address for Zebedee |
See CONTRIBUTING for details.
Copyright © 2025, Office for National Statistics (https://www.ons.gov.uk)
Released under MIT license, see LICENSE for details.