feat: bootstrap.
This commit is contained in:
@@ -2,6 +2,7 @@ package bootstrap
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
"runtime"
|
||||||
|
|
||||||
"github.com/go-kratos/kratos/v2"
|
"github.com/go-kratos/kratos/v2"
|
||||||
"github.com/go-kratos/kratos/v2/log"
|
"github.com/go-kratos/kratos/v2/log"
|
||||||
@@ -90,6 +91,8 @@ func Bootstrap(initApp InitApp, serviceName, version *string) {
|
|||||||
|
|
||||||
// run the app.
|
// run the app.
|
||||||
if err = app.Run(); err != nil {
|
if err = app.Run(); err != nil {
|
||||||
panic(err)
|
buf := make([]byte, 1024)
|
||||||
|
n := runtime.Stack(buf, false)
|
||||||
|
panic(fmt.Sprintf("Panic: %v\nStack trace:\n%s", err, string(buf[:n])))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
2
tag.bat
2
tag.bat
@@ -17,7 +17,7 @@ git tag database/influxdb/v0.0.8 --force
|
|||||||
git tag database/cassandra/v0.0.8 --force
|
git tag database/cassandra/v0.0.8 --force
|
||||||
git tag database/clickhouse/v0.0.8 --force
|
git tag database/clickhouse/v0.0.8 --force
|
||||||
|
|
||||||
git tag bootstrap/v0.0.13 --force
|
git tag bootstrap/v0.0.14 --force
|
||||||
|
|
||||||
git tag v0.5.0
|
git tag v0.5.0
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user