Skip to content

Commit cc4bd46

Browse files
authored
Remove APIs deprecated since v 4.4.0 (apache#6722)
The deprecated APIs are not supposed to stay around for ever. The purpose of deprecation is to eventually remove.
1 parent e65787a commit cc4bd46

File tree

1 file changed

+1
-37
lines changed

1 file changed

+1
-37
lines changed

arrow-flight/src/utils.rs

+1-37
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,7 @@
1717

1818
//! Utilities to assist with reading and writing Arrow data as Flight messages
1919
20-
use crate::{FlightData, IpcMessage, SchemaAsIpc, SchemaResult};
21-
use bytes::Bytes;
20+
use crate::{FlightData, SchemaAsIpc};
2221
use std::collections::HashMap;
2322
use std::sync::Arc;
2423

@@ -104,41 +103,6 @@ pub fn flight_data_to_arrow_batch(
104103
})?
105104
}
106105

107-
/// Convert a `Schema` to `SchemaResult` by converting to an IPC message
108-
#[deprecated(
109-
since = "4.4.0",
110-
note = "Use From trait, e.g.: SchemaAsIpc::new(schema, options).try_into()"
111-
)]
112-
pub fn flight_schema_from_arrow_schema(
113-
schema: &Schema,
114-
options: &IpcWriteOptions,
115-
) -> Result<SchemaResult, ArrowError> {
116-
SchemaAsIpc::new(schema, options).try_into()
117-
}
118-
119-
/// Convert a `Schema` to `FlightData` by converting to an IPC message
120-
#[deprecated(
121-
since = "4.4.0",
122-
note = "Use From trait, e.g.: SchemaAsIpc::new(schema, options).into()"
123-
)]
124-
pub fn flight_data_from_arrow_schema(schema: &Schema, options: &IpcWriteOptions) -> FlightData {
125-
SchemaAsIpc::new(schema, options).into()
126-
}
127-
128-
/// Convert a `Schema` to bytes in the format expected in `FlightInfo.schema`
129-
#[deprecated(
130-
since = "4.4.0",
131-
note = "Use TryFrom trait, e.g.: SchemaAsIpc::new(schema, options).try_into()"
132-
)]
133-
pub fn ipc_message_from_arrow_schema(
134-
schema: &Schema,
135-
options: &IpcWriteOptions,
136-
) -> Result<Bytes, ArrowError> {
137-
let message = SchemaAsIpc::new(schema, options).try_into()?;
138-
let IpcMessage(vals) = message;
139-
Ok(vals)
140-
}
141-
142106
/// Convert `RecordBatch`es to wire protocol `FlightData`s
143107
pub fn batches_to_flight_data(
144108
schema: &Schema,

0 commit comments

Comments
 (0)