mirror of
https://github.com/gomods/athens
synced 2026-02-03 11:00:32 +00:00
Add tracing defaults for jaeger (#934)
* Add tracing defaults for jaeger * Fix tests * Add comment in config file as well
This commit is contained in:
+8
-6
@@ -119,15 +119,17 @@ GithubToken = ""
|
||||
# Env override: ATHENS_HGRC_PATH
|
||||
HGRCPath = ""
|
||||
|
||||
# TraceExporterURL is the URL to which Athens populates distributed tracing
|
||||
# information such as Jaeger. In Stackdriver, use this as the GCP ProjectID.
|
||||
# Env override: ATHENS_TRACE_EXPORTER_URL
|
||||
TraceExporterURL = ""
|
||||
|
||||
# Tracing is not a requirement for Athens. If the infrastructure is not set up,
|
||||
# Athens will keep on running and traces won't be exported.
|
||||
# TraceExporter is the service to which the data collected by OpenCensus can be exported to.
|
||||
# Possible values are: jaeger, datadog, and stackdriver.
|
||||
# Env overide: ATHENS_TRACE_EXPORTER
|
||||
TraceExporter = ""
|
||||
TraceExporter = "jaeger"
|
||||
|
||||
# TraceExporterURL is the URL to which Athens populates distributed tracing
|
||||
# information such as Jaeger. In Stackdriver, use this as the GCP ProjectID.
|
||||
# Env override: ATHENS_TRACE_EXPORTER_URL
|
||||
TraceExporterURL = "http://localhost:14268"
|
||||
|
||||
[Storage]
|
||||
# Only storage backends that are specified in Proxy.StorageType are required here
|
||||
|
||||
@@ -208,12 +208,14 @@ func TestParseExampleConfig(t *testing.T) {
|
||||
TimeoutConf: TimeoutConf{
|
||||
Timeout: 300,
|
||||
},
|
||||
StorageType: "memory",
|
||||
GlobalEndpoint: "http://localhost:3001",
|
||||
Port: ":3000",
|
||||
BasicAuthUser: "",
|
||||
BasicAuthPass: "",
|
||||
Storage: expStorage,
|
||||
StorageType: "memory",
|
||||
GlobalEndpoint: "http://localhost:3001",
|
||||
Port: ":3000",
|
||||
BasicAuthUser: "",
|
||||
BasicAuthPass: "",
|
||||
Storage: expStorage,
|
||||
TraceExporterURL: "http://localhost:14268",
|
||||
TraceExporter: "jaeger",
|
||||
}
|
||||
|
||||
absPath, err := filepath.Abs(exampleConfigPath)
|
||||
@@ -240,7 +242,6 @@ func getEnvMap(config *Config) map[string]string {
|
||||
"BUFFALO_LOG_LEVEL": config.BuffaloLogLevel,
|
||||
"ATHENS_CLOUD_RUNTIME": config.CloudRuntime,
|
||||
"ATHENS_TIMEOUT": strconv.Itoa(config.Timeout),
|
||||
"ATHENS_TRACE_EXPORTER": config.TraceExporterURL,
|
||||
}
|
||||
|
||||
envVars["ATHENS_STORAGE_TYPE"] = config.StorageType
|
||||
|
||||
Reference in New Issue
Block a user