MCPcopy Create free account
hub / github.com/apache/arrow / GetFlightInfoStatement

Method GetFlightInfoStatement

c_glib/arrow-flight-sql-glib/server.cpp:591–613  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

589 ~Server() override = default;
590
591 arrow::Result<std::unique_ptr<arrow::flight::FlightInfo>>
592 GetFlightInfoStatement(const arrow::flight::ServerCallContext &context,
593 const arrow::flight::sql::StatementQuery &command,
594 const arrow::flight::FlightDescriptor &descriptor) override
595 {
596 auto gacontext = gaflight_server_call_context_new_raw(&context);
597 auto gacommand = gaflightsql_statement_query_new_raw(&command);
598 auto gadescriptor = gaflight_descriptor_new_raw(&descriptor);
599 GError *gerror = nullptr;
600 auto gainfo = gaflightsql_server_get_flight_info_statement(gaserver_,
601 gacontext,
602 gacommand,
603 gadescriptor,
604 &gerror);
605 g_object_unref(gadescriptor);
606 g_object_unref(gacommand);
607 g_object_unref(gacontext);
608 if (gerror) {
609 auto context = "[flight-sql-server][get-flight-info-statement]";
610 return garrow_error_to_status(gerror, arrow::StatusCode::UnknownError, context);
611 }
612 return std::make_unique<arrow::flight::FlightInfo>(*gaflight_info_get_raw(gainfo));
613 }
614
615 arrow::Result<std::unique_ptr<arrow::flight::FlightDataStream>>
616 DoGetStatement(const arrow::flight::ServerCallContext &context,

Callers

nothing calls this directly

Tested by

no test coverage detected