Skip to content

Commit 74a5790

Browse files

File tree

5 files changed

+3
-25
lines changed

5 files changed

+3
-25
lines changed

app/consumer-democracy/app.go

+1-5
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ import (
1515
"github.com/cosmos/cosmos-sdk/baseapp"
1616
"github.com/cosmos/cosmos-sdk/client"
1717
"github.com/cosmos/cosmos-sdk/client/grpc/tmservice"
18-
"github.com/cosmos/cosmos-sdk/client/rpc"
1918
"github.com/cosmos/cosmos-sdk/codec"
2019
"github.com/cosmos/cosmos-sdk/codec/types"
2120
"github.com/cosmos/cosmos-sdk/server/api"
@@ -573,7 +572,6 @@ func New(
573572
)
574573

575574
app.MM.RegisterInvariants(&app.CrisisKeeper)
576-
app.MM.RegisterRoutes(app.Router(), app.QueryRouter(), encodingConfig.Amino)
577575

578576
app.configurator = module.NewConfigurator(app.appCodec, app.MsgServiceRouter(), app.GRPCQueryRouter())
579577
app.MM.RegisterServices(app.configurator)
@@ -871,14 +869,12 @@ func (app *App) GetTxConfig() client.TxConfig {
871869
// API server.
872870
func (app *App) RegisterAPIRoutes(apiSvr *api.Server, apiConfig config.APIConfig) {
873871
clientCtx := apiSvr.ClientCtx
874-
rpc.RegisterRoutes(clientCtx, apiSvr.Router)
875872
// Register new tx routes from grpc-gateway.
876873
authtx.RegisterGRPCGatewayRoutes(clientCtx, apiSvr.GRPCGatewayRouter)
877874
// Register new tendermint queries routes from grpc-gateway.
878875
tmservice.RegisterGRPCGatewayRoutes(clientCtx, apiSvr.GRPCGatewayRouter)
879876

880-
// Register legacy and grpc-gateway routes for all modules.
881-
ModuleBasics.RegisterRESTRoutes(clientCtx, apiSvr.Router)
877+
// Register grpc-gateway routes for all modules.
882878
ModuleBasics.RegisterGRPCGatewayRoutes(clientCtx, apiSvr.GRPCGatewayRouter)
883879

884880
// register swagger API from root so that other applications can override easily

app/consumer/app.go

+1-5
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@ import (
1717
"github.com/cosmos/cosmos-sdk/baseapp"
1818
"github.com/cosmos/cosmos-sdk/client"
1919
"github.com/cosmos/cosmos-sdk/client/grpc/tmservice"
20-
"github.com/cosmos/cosmos-sdk/client/rpc"
2120
"github.com/cosmos/cosmos-sdk/codec"
2221
"github.com/cosmos/cosmos-sdk/codec/types"
2322
"github.com/cosmos/cosmos-sdk/server/api"
@@ -459,7 +458,6 @@ func New(
459458
)
460459

461460
app.MM.RegisterInvariants(&app.CrisisKeeper)
462-
app.MM.RegisterRoutes(app.Router(), app.QueryRouter(), encodingConfig.Amino)
463461

464462
app.configurator = module.NewConfigurator(app.appCodec, app.MsgServiceRouter(), app.GRPCQueryRouter())
465463
app.MM.RegisterServices(app.configurator)
@@ -702,14 +700,12 @@ func (app *App) GetTxConfig() client.TxConfig {
702700
// API server.
703701
func (app *App) RegisterAPIRoutes(apiSvr *api.Server, apiConfig config.APIConfig) {
704702
clientCtx := apiSvr.ClientCtx
705-
rpc.RegisterRoutes(clientCtx, apiSvr.Router)
706703
// Register new tx routes from grpc-gateway.
707704
authtx.RegisterGRPCGatewayRoutes(clientCtx, apiSvr.GRPCGatewayRouter)
708705
// Register new tendermint queries routes from grpc-gateway.
709706
tmservice.RegisterGRPCGatewayRoutes(clientCtx, apiSvr.GRPCGatewayRouter)
710707

711-
// Register legacy and grpc-gateway routes for all modules.
712-
ModuleBasics.RegisterRESTRoutes(clientCtx, apiSvr.Router)
708+
// Register grpc-gateway routes for all modules.
713709
ModuleBasics.RegisterGRPCGatewayRoutes(clientCtx, apiSvr.GRPCGatewayRouter)
714710

715711
// register swagger API from root so that other applications can override easily

app/provider/app.go

+1-5
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ import (
1414
"github.com/cosmos/cosmos-sdk/baseapp"
1515
"github.com/cosmos/cosmos-sdk/client"
1616
"github.com/cosmos/cosmos-sdk/client/grpc/tmservice"
17-
"github.com/cosmos/cosmos-sdk/client/rpc"
1817
"github.com/cosmos/cosmos-sdk/codec"
1918
"github.com/cosmos/cosmos-sdk/codec/types"
2019
"github.com/cosmos/cosmos-sdk/server/api"
@@ -563,7 +562,6 @@ func New(
563562
)
564563

565564
app.MM.RegisterInvariants(&app.CrisisKeeper)
566-
app.MM.RegisterRoutes(app.Router(), app.QueryRouter(), encodingConfig.Amino)
567565

568566
app.configurator = module.NewConfigurator(app.appCodec, app.MsgServiceRouter(), app.GRPCQueryRouter())
569567
app.MM.RegisterServices(app.configurator)
@@ -809,14 +807,12 @@ func (app *App) GetTxConfig() client.TxConfig {
809807
// API server.
810808
func (app *App) RegisterAPIRoutes(apiSvr *api.Server, apiConfig config.APIConfig) {
811809
clientCtx := apiSvr.ClientCtx
812-
rpc.RegisterRoutes(clientCtx, apiSvr.Router)
813810
// Register new tx routes from grpc-gateway.
814811
authtx.RegisterGRPCGatewayRoutes(clientCtx, apiSvr.GRPCGatewayRouter)
815812
// Register new tendermint queries routes from grpc-gateway.
816813
tmservice.RegisterGRPCGatewayRoutes(clientCtx, apiSvr.GRPCGatewayRouter)
817814

818-
// Register legacy and grpc-gateway routes for all modules.
819-
ModuleBasics.RegisterRESTRoutes(clientCtx, apiSvr.Router)
815+
// Register grpc-gateway routes for all modules.
820816
ModuleBasics.RegisterGRPCGatewayRoutes(clientCtx, apiSvr.GRPCGatewayRouter)
821817

822818
// register swagger API from root so that other applications can override easily

x/ccv/consumer/module.go

-5
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ import (
66
"fmt"
77

88
abci "github.com/cometbft/cometbft/abci/types"
9-
"github.com/gorilla/mux"
109
"github.com/grpc-ecosystem/grpc-gateway/runtime"
1110
"github.com/spf13/cobra"
1211

@@ -64,10 +63,6 @@ func (AppModuleBasic) ValidateGenesis(cdc codec.JSONCodec, config client.TxEncod
6463
return data.Validate()
6564
}
6665

67-
// RegisterRESTRoutes implements AppModuleBasic interface
68-
func (AppModuleBasic) RegisterRESTRoutes(clientCtx client.Context, rtr *mux.Router) {
69-
}
70-
7166
// RegisterGRPCGatewayRoutes registers the gRPC Gateway routes for the ibc-consumer module.
7267
func (AppModuleBasic) RegisterGRPCGatewayRoutes(clientCtx client.Context, mux *runtime.ServeMux) {
7368
err := consumertypes.RegisterQueryHandlerClient(context.Background(), mux, consumertypes.NewQueryClient(clientCtx))

x/ccv/provider/module.go

-5
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@ import (
1616
"github.com/cosmos/interchain-security/x/ccv/provider/client/cli"
1717
"github.com/cosmos/interchain-security/x/ccv/provider/keeper"
1818
providertypes "github.com/cosmos/interchain-security/x/ccv/provider/types"
19-
"github.com/gorilla/mux"
2019
"github.com/grpc-ecosystem/grpc-gateway/runtime"
2120
"github.com/spf13/cobra"
2221
)
@@ -61,10 +60,6 @@ func (AppModuleBasic) ValidateGenesis(cdc codec.JSONCodec, config client.TxEncod
6160
return data.Validate()
6261
}
6362

64-
// RegisterRESTRoutes implements AppModuleBasic interface
65-
func (AppModuleBasic) RegisterRESTRoutes(clientCtx client.Context, rtr *mux.Router) {
66-
}
67-
6863
// RegisterGRPCGatewayRoutes registers the gRPC Gateway routes for the ibc-provider module.
6964
func (AppModuleBasic) RegisterGRPCGatewayRoutes(clientCtx client.Context, mux *runtime.ServeMux) {
7065
err := providertypes.RegisterQueryHandlerClient(context.Background(), mux, providertypes.NewQueryClient(clientCtx))

0 commit comments

Comments
 (0)