Skip to content

Commit 87c9d49

Browse files
authored
Merge pull request #142 from mrigesh/feat/custom_request_id
feat: send nil as a parameter since this is not in request context
2 parents b53157f + 69586c2 commit 87c9d49

File tree

3 files changed

+8
-5
lines changed

3 files changed

+8
-5
lines changed

boot.go

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,13 @@ import (
1010
"context"
1111
"embed"
1212
"fmt"
13-
"github.com/rookie-ninja/rk-entry/v2/entry"
14-
"github.com/rookie-ninja/rk-entry/v2/middleware"
15-
"go.uber.org/zap"
1613
"os"
1714
"path/filepath"
1815
"runtime/debug"
16+
17+
rkentry "github.com/rookie-ninja/rk-entry/v2/entry"
18+
rkmid "github.com/rookie-ninja/rk-entry/v2/middleware"
19+
"go.uber.org/zap"
1920
)
2021

2122
type hookFuncM map[string]map[string]func(ctx context.Context)
@@ -80,7 +81,7 @@ func NewBoot(opts ...BootOption) *Boot {
8081
defer syncLog("N/A")
8182

8283
boot := &Boot{
83-
EventId: rkmid.GenerateRequestId(),
84+
EventId: rkmid.GenerateRequestId(nil),
8485
beforeHookF: newHookFuncM(),
8586
afterHookF: newHookFuncM(),
8687
pluginEntries: map[string]map[string]rkentry.Entry{},

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ module github.com/rookie-ninja/rk-boot/v2
33
go 1.18
44

55
require (
6-
github.com/rookie-ninja/rk-entry/v2 v2.2.17
6+
github.com/rookie-ninja/rk-entry/v2 v2.2.18
77
github.com/stretchr/testify v1.8.0
88
go.uber.org/zap v1.21.0
99
)

go.sum

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -230,6 +230,8 @@ github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFR
230230
github.com/rogpeppe/go-internal v1.6.1 h1:/FiVV8dS/e+YqF2JvO3yXRFbBLTIuSDkuC7aBOAvL+k=
231231
github.com/rookie-ninja/rk-entry/v2 v2.2.17 h1:cRy6xtjD7B8p5Z1Is0/vrnveDWWOP/3Ouclk4G/rU5Y=
232232
github.com/rookie-ninja/rk-entry/v2 v2.2.17/go.mod h1:P/Fd6Oyvvx0ITbEU2lzO3KkQ9miWVwd84aPaC0LMD0o=
233+
github.com/rookie-ninja/rk-entry/v2 v2.2.18 h1:eGByO/Ycb6BbSsdrfIJwfxy9cdjM+5So7JHaBu6bMko=
234+
github.com/rookie-ninja/rk-entry/v2 v2.2.18/go.mod h1:P/Fd6Oyvvx0ITbEU2lzO3KkQ9miWVwd84aPaC0LMD0o=
233235
github.com/rookie-ninja/rk-logger v1.2.13 h1:ERxeNZUmszlY4xehHcJRXECPtbjYIXzN8yRIyYyLGsg=
234236
github.com/rookie-ninja/rk-logger v1.2.13/go.mod h1:0ZiGn1KsHKOmCv+FHMH7k40DWYSJcj5yIR3EYcjlnLs=
235237
github.com/rookie-ninja/rk-query v1.2.14 h1:aYNyMXixpsEYRfEOz9Npt5QG3A6BQlo9vKjYc78x7bc=

0 commit comments

Comments
 (0)