Merged in feature/versionTimestamps (pull request #98)
add GetVersionTimestamp * add GetVersionTimestamp * docs
This commit is contained in:
@@ -20,10 +20,11 @@ import (
|
||||
"math/rand"
|
||||
"os"
|
||||
"os/signal"
|
||||
"runtime/debug"
|
||||
"syscall"
|
||||
"time"
|
||||
|
||||
"queryorchestration/internal/serviceconfig/observability"
|
||||
|
||||
"queryorchestration/internal/serviceconfig/observability/prometheus"
|
||||
)
|
||||
|
||||
@@ -53,12 +54,10 @@ func getMetricsConfig() prometheus.MetricsConfig {
|
||||
}
|
||||
|
||||
func main() {
|
||||
info, ok := debug.ReadBuildInfo()
|
||||
if !ok {
|
||||
fmt.Println("Failed to read build info")
|
||||
return
|
||||
}
|
||||
fmt.Printf("Version: %s\n", info.Main.Version)
|
||||
rawVersion := observability.GetVersion()
|
||||
fmt.Printf("Version: %s\n", rawVersion)
|
||||
timeVersion := observability.GetVersionTimestamp()
|
||||
fmt.Printf("Version Timestamp: %s\n", timeVersion.String())
|
||||
|
||||
ctx, cancel := context.WithCancel(context.Background())
|
||||
defer cancel()
|
||||
|
||||
Reference in New Issue
Block a user