v0.4.0 #210
Xuanwo
started this conversation in
Announcements
v0.4.0
#210
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
What's Changed
Full Changelog: v0.3.0...v0.4.0
Refer to Upgrade
From v0.3 to v0.4section for more upgrade details.From v0.3 to v0.4
OpenDAL introduces many breaking changes in v0.4.
Object::reader() is not
AsyncSeekanymoreSince v0.4,
Object::reader()will returnimpl BytesReadinstead ofReaderthat implementsAsyncReadandAsyncSeek. Users who wantAsyncSeekplease wrapped withopendal::io_util::seekable_read:Use RangeBounds instead
Since v0.4, the following APIs will be removed.
Object::limited_reader(size: u64)Object::offset_reader(offset: u64)Object::range_reader(offset: u64, size: u64)Instead, OpenDAL is providing a more general
range_readerpowered byRangeBounds:Users can use their familiar rust range syntax:
Return io::Result instead
Since v0.4, all functions in OpenDAL will return
std::io::Resultinstead.Please check via
std::io::ErrorKinddirectly:Removing Credential
Since v0.4,
Credentialhas been removed, please use the API provided byBuilderdirectly.Write returns
BytesWriterinsteadSince v0.4,
Accessor::writewill return aBytesWriterinstead accepting aBoxedAsyncReader.Along with this change, the old
Writerhas been replaced by a new set of write functions:Users can write into an object more easily:
io_utilreplacesreadersSince v0.4, mod
io_utilwill replacereaders. Inio_utils, OpenDAL provides helpful functions like:into_reader: ConvertBytesStreamintoBytesReadinto_sink: ConvertBytesWriteintoBytesSinkinto_stream: ConvertBytesReadintoBytesStreaminto_writer: ConvertBytesSinkintoBytesWriteobserve_read: Add callback forBytesReaderobserve_write: Add callback forBytesWriteNew type alias
For better naming, types that OpenDAL returns have been renamed:
AsyncRead + Unpin + Send=>BytesReadBoxedAsyncReader=>BytesReaderAsyncWrite + Unpin + Send=>BytesWriteBoxedAsyncWriter=>BytesWriterObjectStream=>ObjectStreamerThis discussion was created from the release v0.4.0.
Beta Was this translation helpful? Give feedback.
All reactions