v0.27.0 #1326
Xuanwo
started this conversation in
Announcements
v0.27.0
#1326
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.
-
Upgrade to v0.27
In v0.27, we refactored our
listrelated logic and addedscansupport. So makePagerandBlockingPagerassociated types inAccessortoo!pub trait Accessor: Send + Sync + Debug + Unpin + 'static { type Reader: output::Read; type BlockingReader: output::BlockingRead; + type Pager: output::Page; + type BlockingPager: output::BlockingPage; }User defined layers
Due to this change, all layers implementation should be changed. If there is not changed over pager, they can by changed like the following:
impl<A: Accessor> LayeredAccessor for MyAccessor<A> { type Inner = A; type Reader = MyReader<A::Reader>; type BlockingReader = MyReader<A::BlockingReader>; + type Pager = A::Pager; + type BlockingPager = A::BlockingPager; + async fn list(&self, path: &str, args: OpList) -> Result<(RpList, Self::Pager)> { + self.inner.list(path, args).await + } + async fn scan(&self, path: &str, args: OpScan) -> Result<(RpScan, Self::Pager)> { + self.inner.scan(path, args).await + } + fn blocking_list(&self, path: &str, args: OpList) -> Result<(RpList, Self::BlockingPager)> { + self.inner.blocking_list(path, args) + } + fn blocking_scan(&self, path: &str, args: OpScan) -> Result<(RpScan, Self::BlockingPager)> { + self.inner.blocking_scan(path, args) + } }Usage of ops
To reduce the understanding overhead, we move all
OpXxxintoopendal::opsnow. User may need to change:Usage of RetryLayer
backonis the implementation detail of ourRetryLayer, so we hide it from our public API. Users ofRetryLayerneed to change the code like:What's Changed
New Contributors
Full Changelog: v0.26.2...v0.27.0
This discussion was created from the release v0.27.0.
Beta Was this translation helpful? Give feedback.
All reactions