Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
canifa_note
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Vũ Hoàng Anh
canifa_note
Commits
0f4e5857
Unverified
Commit
0f4e5857
authored
Oct 27, 2023
by
Athurg Gooth
Committed by
GitHub
Oct 27, 2023
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
chore: remove gRPC listener (#2456)
Disable gRPC listener
parent
76d955a6
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
14 deletions
+0
-14
server.go
server/server.go
+0
-14
No files found.
server/server.go
View file @
0f4e5857
...
...
@@ -4,7 +4,6 @@ import (
"context"
"encoding/json"
"fmt"
"net"
"net/http"
"strings"
"time"
...
...
@@ -14,11 +13,9 @@ import (
"github.com/labstack/echo/v4/middleware"
"github.com/pkg/errors"
echoSwagger
"github.com/swaggo/echo-swagger"
"go.uber.org/zap"
apiv1
"github.com/usememos/memos/api/v1"
apiv2
"github.com/usememos/memos/api/v2"
"github.com/usememos/memos/internal/log"
"github.com/usememos/memos/plugin/telegram"
"github.com/usememos/memos/server/integration"
"github.com/usememos/memos/server/profile"
...
...
@@ -122,17 +119,6 @@ func (s *Server) Start(ctx context.Context) error {
go
s
.
telegramBot
.
Start
(
ctx
)
go
s
.
backupRunner
.
Run
(
ctx
)
// Start gRPC server.
listen
,
err
:=
net
.
Listen
(
"tcp"
,
fmt
.
Sprintf
(
"%s:%d"
,
s
.
Profile
.
Addr
,
s
.
Profile
.
Port
+
1
))
if
err
!=
nil
{
return
err
}
go
func
()
{
if
err
:=
s
.
apiV2Service
.
GetGRPCServer
()
.
Serve
(
listen
);
err
!=
nil
{
log
.
Error
(
"grpc server listen error"
,
zap
.
Error
(
err
))
}
}()
metric
.
Enqueue
(
"server start"
)
return
s
.
e
.
Start
(
fmt
.
Sprintf
(
"%s:%d"
,
s
.
Profile
.
Addr
,
s
.
Profile
.
Port
))
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment