Skip to content

Commit

Permalink
Format
Browse files Browse the repository at this point in the history
  • Loading branch information
kou committed Jun 24, 2023
1 parent 7eb5aca commit 2df8da8
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 8 deletions.
7 changes: 4 additions & 3 deletions cpp/src/arrow/flight/client.h
Original file line number Diff line number Diff line change
Expand Up @@ -253,9 +253,10 @@ class ARROW_FLIGHT_EXPORT FlightClient {
/// \param[in] options Per-RPC options
/// \param[in] request The CancelFlightInfoRequest
/// \return Arrow result with a CancelFlightInfoResult
arrow::Result<CancelFlightInfoResult> CancelFlightInfo(const FlightCallOptions& options,
const CancelFlightInfoRequest& request);
arrow::Result<CancelFlightInfoResult> CancelFlightInfo(const CancelFlightInfoRequest& request) {
arrow::Result<CancelFlightInfoResult> CancelFlightInfo(
const FlightCallOptions& options, const CancelFlightInfoRequest& request);
arrow::Result<CancelFlightInfoResult> CancelFlightInfo(
const CancelFlightInfoRequest& request) {
return CancelFlightInfo({}, request);
}

Expand Down
4 changes: 2 additions & 2 deletions cpp/src/arrow/flight/integration_tests/test_integration.cc
Original file line number Diff line number Diff line change
Expand Up @@ -502,8 +502,8 @@ class ExpirationTimeServer : public FlightServerBase {
std::unique_ptr<ResultStream>* result_stream) override {
std::vector<Result> results;
if (action.type == ActionType::kCancelFlightInfo.type) {
ARROW_ASSIGN_OR_RAISE(auto request,
CancelFlightInfoRequest::Deserialize(std::string_view(*action.body)));
ARROW_ASSIGN_OR_RAISE(auto request, CancelFlightInfoRequest::Deserialize(
std::string_view(*action.body)));
auto cancel_status = CancelStatus::kUnspecified;
for (const auto& endpoint : request.info->endpoints()) {
auto index_result = ExtractIndexFromTicket(endpoint.ticket.ticket);
Expand Down
3 changes: 2 additions & 1 deletion cpp/src/arrow/flight/sql/server.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1088,7 +1088,8 @@ arrow::Result<CancelResult> FlightSqlServerBase::CancelQuery(
const ServerCallContext& context, const ActionCancelQueryRequest& request) {
CancelFlightInfoRequest cancel_flight_info_request;
cancel_flight_info_request.info = std::make_unique<FlightInfo>(*request.info);
ARROW_ASSIGN_OR_RAISE(auto result, CancelFlightInfo(context, cancel_flight_info_request));
ARROW_ASSIGN_OR_RAISE(auto result,
CancelFlightInfo(context, cancel_flight_info_request));
return static_cast<CancelResult>(result.status);
}

Expand Down
3 changes: 1 addition & 2 deletions cpp/src/arrow/flight/types.h
Original file line number Diff line number Diff line change
Expand Up @@ -715,8 +715,7 @@ struct ARROW_FLIGHT_EXPORT CancelFlightInfoRequest {
arrow::Result<std::string> SerializeToString() const;

/// \brief Deserialize this message from its wire-format representation.
static arrow::Result<CancelFlightInfoRequest> Deserialize(
std::string_view serialized);
static arrow::Result<CancelFlightInfoRequest> Deserialize(std::string_view serialized);
};

/// \brief An iterator to FlightInfo instances returned by ListFlights.
Expand Down

0 comments on commit 2df8da8

Please sign in to comment.