Skip to content

Commit

Permalink
fix: fix comment
Browse files Browse the repository at this point in the history
  • Loading branch information
DrmagicE committed Dec 19, 2020
1 parent 699218d commit 67c5578
Show file tree
Hide file tree
Showing 13 changed files with 48 additions and 53 deletions.
2 changes: 1 addition & 1 deletion plugin/admin/admin.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ func New(config config.Config) (server.Plugin, error) {

var log *zap.Logger

// GRPCGatewayRegister provides the ability to let other plugin to share the gRPC and HTTP server.
// GRPCGatewayRegister provides the ability to share the gRPC and HTTP server to other plugins.
type GRPCGatewayRegister interface {
GRPCRegister
HTTPRegister
Expand Down
5 changes: 2 additions & 3 deletions plugin/admin/client.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 6 additions & 5 deletions plugin/admin/client_grpc.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 2 additions & 3 deletions plugin/admin/publish.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 2 additions & 3 deletions plugin/admin/publish_grpc.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions plugin/admin/subscription.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ func (s *subscriptionService) mustEmbedUnimplementedSubscriptionServiceServer()
return
}

// List lists subIndexer in the broker.
// List lists subscriptions in the broker.
func (s *subscriptionService) List(ctx context.Context, req *ListSubscriptionRequest) (*ListSubscriptionResponse, error) {
page, pageSize := GetPage(req.Page, req.PageSize)
subs, total, err := s.a.store.GetSubscriptions(page, pageSize)
Expand All @@ -36,7 +36,7 @@ func (s *subscriptionService) List(ctx context.Context, req *ListSubscriptionReq
}, nil
}

// Filter filters subIndexer with the request params.
// Filter filters subscriptions with the request params.
// Paging is not supported, and the results are not sorted in any way.
// Using huge req.Limit can impact performance.
func (s *subscriptionService) Filter(ctx context.Context, req *FilterSubscriptionRequest) (resp *FilterSubscriptionResponse, err error) {
Expand Down Expand Up @@ -120,7 +120,7 @@ func (s *subscriptionService) Filter(ctx context.Context, req *FilterSubscriptio
return resp, nil
}

// Subscribe makes subIndexer for the given client.
// Subscribe makes subscriptions for the given client.
func (s *subscriptionService) Subscribe(ctx context.Context, req *SubscribeRequest) (resp *SubscribeResponse, err error) {
if req.ClientId == "" {
return nil, ErrInvalidArgument("client_id", "cannot be empty")
Expand Down
29 changes: 14 additions & 15 deletions plugin/admin/subscription.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion plugin/admin/subscription.pb.gw.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

17 changes: 8 additions & 9 deletions plugin/admin/subscription_grpc.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions plugin/admin/swagger/client.swagger.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"paths": {
"/v1/clients": {
"get": {
"summary": "lists clients",
"summary": "List clients",
"operationId": "List",
"responses": {
"200": {
Expand Down Expand Up @@ -52,7 +52,7 @@
},
"/v1/clients/{client_id}": {
"get": {
"summary": "Get the client for given client id.",
"summary": "Get the client for given client id.\nReturn NotFound error when client not found.",
"operationId": "Get",
"responses": {
"200": {
Expand Down Expand Up @@ -81,7 +81,7 @@
]
},
"delete": {
"summary": "disconnect the client for given client id.",
"summary": "Disconnect the client for given client id.",
"operationId": "Delete",
"responses": {
"200": {
Expand Down
2 changes: 1 addition & 1 deletion plugin/admin/swagger/publish.swagger.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"paths": {
"/v1/publish": {
"post": {
"summary": "publish message to broker",
"summary": "Publish message to broker",
"operationId": "Publish",
"responses": {
"200": {
Expand Down
8 changes: 4 additions & 4 deletions plugin/admin/swagger/subscription.swagger.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"paths": {
"/v1/filter_subscriptions": {
"get": {
"summary": "filter subscriptions, paging is not supported in this api.",
"summary": "Filter subscriptions, paging is not supported in this API.",
"operationId": "Filter",
"responses": {
"200": {
Expand Down Expand Up @@ -80,7 +80,7 @@
},
"/v1/subscribe": {
"post": {
"summary": "subscribe topics for the client.",
"summary": "Subscribe topics for the client.",
"operationId": "Subscribe",
"responses": {
"200": {
Expand Down Expand Up @@ -113,7 +113,7 @@
},
"/v1/subscriptions": {
"get": {
"summary": "list subscriptions.",
"summary": "List subscriptions.",
"operationId": "List",
"responses": {
"200": {
Expand Down Expand Up @@ -152,7 +152,7 @@
},
"/v1/unsubscribe": {
"post": {
"summary": "unsubscribe topics for the client.",
"summary": "Unsubscribe topics for the client.",
"operationId": "Unsubscribe",
"responses": {
"200": {
Expand Down
3 changes: 1 addition & 2 deletions server/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -857,8 +857,7 @@ func (srv *server) init(opts ...Options) (err error) {
return fmt.Errorf("topic alias manager : %s not found", srv.config.TopicAliasManager.Type)
}

err = srv.loadPlugins()
return err
return srv.loadPlugins()
}

// Init initialises the options.
Expand Down

0 comments on commit 67c5578

Please sign in to comment.