Skip to content

Commit

Permalink
Merge pull request #92 from dongxuny/master
Browse files Browse the repository at this point in the history
Bump up rk-entry to latest one
  • Loading branch information
dongxuny authored Dec 14, 2022
2 parents 96803e3 + 7dea0a0 commit 84fdf9a
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 451 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
- name: Setup Go
uses: actions/setup-go@v2
with:
go-version: 1.17
go-version: 1.18
- name: Setup golangci-lint
uses: golangci/[email protected]
- name: Run linter
Expand Down
22 changes: 11 additions & 11 deletions boot/grpc_entry.go
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ import (
"net"
"net/http"
"net/http/pprof"
"path/filepath"
"path"
"strconv"
"strings"
"sync"
Expand Down Expand Up @@ -588,16 +588,16 @@ func (entry *GrpcEntry) Bootstrap(ctx context.Context) {
// 15: pprof
if entry.IsPProfEnabled() {
entry.HttpMux.HandleFunc(entry.PProfEntry.Path, pprof.Index)
entry.HttpMux.HandleFunc(filepath.Join(entry.PProfEntry.Path, "cmdline"), pprof.Cmdline)
entry.HttpMux.HandleFunc(filepath.Join(entry.PProfEntry.Path, "profile"), pprof.Profile)
entry.HttpMux.HandleFunc(filepath.Join(entry.PProfEntry.Path, "symbol"), pprof.Symbol)
entry.HttpMux.HandleFunc(filepath.Join(entry.PProfEntry.Path, "trace"), pprof.Trace)
entry.HttpMux.HandleFunc(filepath.Join(entry.PProfEntry.Path, "allocs"), pprof.Handler("allocs").ServeHTTP)
entry.HttpMux.HandleFunc(filepath.Join(entry.PProfEntry.Path, "block"), pprof.Handler("block").ServeHTTP)
entry.HttpMux.HandleFunc(filepath.Join(entry.PProfEntry.Path, "goroutine"), pprof.Handler("goroutine").ServeHTTP)
entry.HttpMux.HandleFunc(filepath.Join(entry.PProfEntry.Path, "heap"), pprof.Handler("heap").ServeHTTP)
entry.HttpMux.HandleFunc(filepath.Join(entry.PProfEntry.Path, "mutex"), pprof.Handler("mutex").ServeHTTP)
entry.HttpMux.HandleFunc(filepath.Join(entry.PProfEntry.Path, "threadcreate"), pprof.Handler("threadcreate").ServeHTTP)
entry.HttpMux.HandleFunc(path.Join(entry.PProfEntry.Path, "cmdline"), pprof.Cmdline)
entry.HttpMux.HandleFunc(path.Join(entry.PProfEntry.Path, "profile"), pprof.Profile)
entry.HttpMux.HandleFunc(path.Join(entry.PProfEntry.Path, "symbol"), pprof.Symbol)
entry.HttpMux.HandleFunc(path.Join(entry.PProfEntry.Path, "trace"), pprof.Trace)
entry.HttpMux.HandleFunc(path.Join(entry.PProfEntry.Path, "allocs"), pprof.Handler("allocs").ServeHTTP)
entry.HttpMux.HandleFunc(path.Join(entry.PProfEntry.Path, "block"), pprof.Handler("block").ServeHTTP)
entry.HttpMux.HandleFunc(path.Join(entry.PProfEntry.Path, "goroutine"), pprof.Handler("goroutine").ServeHTTP)
entry.HttpMux.HandleFunc(path.Join(entry.PProfEntry.Path, "heap"), pprof.Handler("heap").ServeHTTP)
entry.HttpMux.HandleFunc(path.Join(entry.PProfEntry.Path, "mutex"), pprof.Handler("mutex").ServeHTTP)
entry.HttpMux.HandleFunc(path.Join(entry.PProfEntry.Path, "threadcreate"), pprof.Handler("threadcreate").ServeHTTP)
}

// 16: Create http server
Expand Down
4 changes: 2 additions & 2 deletions go.mod
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
module github.com/rookie-ninja/rk-grpc/v2

go 1.17
go 1.18

require (
github.com/golang-jwt/jwt/v4 v4.4.2
github.com/grpc-ecosystem/grpc-gateway/v2 v2.12.0
github.com/improbable-eng/grpc-web v0.15.0
github.com/prometheus/client_golang v1.13.0
github.com/rookie-ninja/rk-entry/v2 v2.2.11
github.com/rookie-ninja/rk-entry/v2 v2.2.13
github.com/rookie-ninja/rk-logger v1.2.12
github.com/rookie-ninja/rk-query v1.2.14
github.com/soheilhy/cmux v0.1.5
Expand Down
Loading

0 comments on commit 84fdf9a

Please sign in to comment.