Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove gRPC code previously used for the xpring SDK & enable gRPC on localhost by default #4272

Closed
wants to merge 3 commits into from
Closed
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 0 additions & 4 deletions Builds/CMake/RippledCore.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -641,7 +641,6 @@ target_sources (rippled PRIVATE
src/ripple/rpc/handlers/WalletPropose.cpp
src/ripple/rpc/impl/DeliveredAmount.cpp
src/ripple/rpc/impl/Handler.cpp
src/ripple/rpc/impl/GRPCHelpers.cpp
src/ripple/rpc/impl/LegacyPathFind.cpp
src/ripple/rpc/impl/RPCHandler.cpp
src/ripple/rpc/impl/RPCHelpers.cpp
Expand Down Expand Up @@ -946,7 +945,6 @@ if (tests)
src/test/rpc/DepositAuthorized_test.cpp
src/test/rpc/DeliveredAmount_test.cpp
src/test/rpc/Feature_test.cpp
src/test/rpc/Fee_test.cpp
src/test/rpc/GatewayBalances_test.cpp
src/test/rpc/GetCounts_test.cpp
src/test/rpc/JSONRPC_test.cpp
Expand All @@ -969,12 +967,10 @@ if (tests)
src/test/rpc/ServerInfo_test.cpp
src/test/rpc/ShardArchiveHandler_test.cpp
src/test/rpc/Status_test.cpp
src/test/rpc/Submit_test.cpp
src/test/rpc/Subscribe_test.cpp
src/test/rpc/Transaction_test.cpp
src/test/rpc/TransactionEntry_test.cpp
src/test/rpc/TransactionHistory_test.cpp
src/test/rpc/Tx_test.cpp
src/test/rpc/ValidatorInfo_test.cpp
src/test/rpc/ValidatorRPC_test.cpp
src/test/rpc/Version_test.cpp
Expand Down
8 changes: 4 additions & 4 deletions cfg/rippled-example.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -1629,10 +1629,10 @@ ip = 127.0.0.1
admin = 127.0.0.1
protocol = ws

#[port_grpc]
#port = 50051
#ip = 0.0.0.0
#secure_gateway = 127.0.0.1
[port_grpc]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why are we uncommenting this in the rippled-example.cfg. Do we want gRPC to be enabled by default?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We talked about this in the huddle. I asked if we could uncomment this by default, and the agreement was yes if the xpring sdk code was removed.

port = 50051
ip = 127.0.0.1
secure_gateway = 127.0.0.1

#[port_ws_public]
#port = 6005
Expand Down
88 changes: 0 additions & 88 deletions src/ripple/app/main/GRPCServer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -590,94 +590,6 @@ GRPCServerImpl::setupListeners()
requests.push_back(std::move(callData));
};

{
using cd = CallData<
org::xrpl::rpc::v1::GetFeeRequest,
org::xrpl::rpc::v1::GetFeeResponse>;

addToRequests(std::make_shared<cd>(
service_,
*cq_,
app_,
&org::xrpl::rpc::v1::XRPLedgerAPIService::AsyncService::
RequestGetFee,
doFeeGrpc,
&org::xrpl::rpc::v1::XRPLedgerAPIService::Stub::GetFee,
RPC::NEEDS_CURRENT_LEDGER,
Resource::feeReferenceRPC,
secureGatewayIPs_));
}
{
using cd = CallData<
org::xrpl::rpc::v1::GetAccountInfoRequest,
org::xrpl::rpc::v1::GetAccountInfoResponse>;

addToRequests(std::make_shared<cd>(
service_,
*cq_,
app_,
&org::xrpl::rpc::v1::XRPLedgerAPIService::AsyncService::
RequestGetAccountInfo,
doAccountInfoGrpc,
&org::xrpl::rpc::v1::XRPLedgerAPIService::Stub::GetAccountInfo,
RPC::NO_CONDITION,
Resource::feeReferenceRPC,
secureGatewayIPs_));
}
{
using cd = CallData<
org::xrpl::rpc::v1::GetTransactionRequest,
org::xrpl::rpc::v1::GetTransactionResponse>;

addToRequests(std::make_shared<cd>(
service_,
*cq_,
app_,
&org::xrpl::rpc::v1::XRPLedgerAPIService::AsyncService::
RequestGetTransaction,
doTxGrpc,
&org::xrpl::rpc::v1::XRPLedgerAPIService::Stub::GetTransaction,
RPC::NEEDS_NETWORK_CONNECTION,
Resource::feeReferenceRPC,
secureGatewayIPs_));
}
{
using cd = CallData<
org::xrpl::rpc::v1::SubmitTransactionRequest,
org::xrpl::rpc::v1::SubmitTransactionResponse>;

addToRequests(std::make_shared<cd>(
service_,
*cq_,
app_,
&org::xrpl::rpc::v1::XRPLedgerAPIService::AsyncService::
RequestSubmitTransaction,
doSubmitGrpc,
&org::xrpl::rpc::v1::XRPLedgerAPIService::Stub::SubmitTransaction,
RPC::NEEDS_CURRENT_LEDGER,
Resource::feeMediumBurdenRPC,
secureGatewayIPs_));
}

{
using cd = CallData<
org::xrpl::rpc::v1::GetAccountTransactionHistoryRequest,
org::xrpl::rpc::v1::GetAccountTransactionHistoryResponse>;

addToRequests(std::make_shared<cd>(
service_,
*cq_,
app_,
&org::xrpl::rpc::v1::XRPLedgerAPIService::AsyncService::
RequestGetAccountTransactionHistory,
doAccountTxGrpc,
&org::xrpl::rpc::v1::XRPLedgerAPIService::Stub::
GetAccountTransactionHistory,
RPC::NO_CONDITION,
Resource::feeMediumBurdenRPC,
secureGatewayIPs_));
}

{
using cd = CallData<
org::xrpl::rpc::v1::GetLedgerRequest,
Expand Down
2 changes: 0 additions & 2 deletions src/ripple/app/reporting/P2pProxy.h
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,6 @@ needCurrentOrClosed(Request& request)
{
// These are the only gRPC requests that specify a ledger
if constexpr (
std::is_same<Request, org::xrpl::rpc::v1::GetAccountInfoRequest>::
value ||
std::is_same<Request, org::xrpl::rpc::v1::GetLedgerRequest>::value ||
std::is_same<Request, org::xrpl::rpc::v1::GetLedgerDataRequest>::
value ||
Expand Down
14 changes: 0 additions & 14 deletions src/ripple/proto/org/xrpl/rpc/v1/account.proto

This file was deleted.

48 changes: 0 additions & 48 deletions src/ripple/proto/org/xrpl/rpc/v1/amount.proto

This file was deleted.

Loading