futures-cpupool
An implementation of thread pools which hand out futures to the results of the computation on the threads themselves.
0.1.8
15M downloads/mo
#2466 most downloaded on crates.io
alexcrichton/futures-rs
What this package is like to depend on
Last release 9 years ago
no release in 18 months
Release timing varies
gaps range from 3 weeks to 6 months
Nearly every release is documented
notes for 8 of 8 stable releases
1 version withdrawn
withdrawn after publishing
10 years old
9 releases · first in 2016
0 releases in the last 12 months
see the full history below
Release timeline
9 releases · Aug 2016 to Jan 2018Releases
latest 9-
0.1.802 Jan 2018Release notes
Open source →- Fix some race conditions in the
Sharedimplementation - Add
Stream::take_while - Fix an unwrap in
stream::futures_unordered - Generalize
Stream::for_each - Add
Stream::chain - Add
stream::repeat - Relax
&mut selfto&selfinUnboundedSender::send
- Fix some race conditions in the
-
0.1.712 Oct 2017Release notes
Open source →- Add a
Future::sharedmethod for creating a future that can be shared amongst threads by cloning the future itself. All derivative futures will resolve to the same value once the original future has been resolved. - Add a
FutureFromtrait for future-based conversion - Fix a wakeup bug in
Receiver::close - Add
future::poll_fnfor quickly adapting aPoll-based function to a future. - Add an
Eitherenum with two branches to easily create one future type based on two different futures created on two branches of control flow. - Remove the
'staticbound onUnpark - Optimize
send_allandforwardto send as many items as possible before callingpoll_complete. - Unify the return types of the
ok,err, andresultfuture to assist returning different varieties in different branches of a function. - Add
CpuFuture::forgetto allow the computation to continue running after a drop. - Add a
stream::futures_unorderedcombinator to turn a list of futures into a stream representing their order of completion.
- Add a
-
0.1.614 Sep 2017 -
0.1.521 Mar 2017 -
0.1.415 Mar 2017Release notes
Open source →This is quite a large release relative to the previous point releases! As with all 0.1 releases, this release should be fully compatible with the 0.1.3 release. If any incompatibilities are discovered please file an issue!
The largest changes in 0.1.4 are the addition of a
Sinktrait coupled with a reorganization of this crate. Note that all old locations for types/traits still exist, they're just deprecated and tagged with#[doc(hidden)].The new
Sinktrait is used to represent types which can periodically over time accept items, but may take some time to fully process the item before another can be accepted. Essentially, a sink is the opposite of a stream. This trait will then be used in the tokio-core crate to implement simple framing by modeling I/O streams as both a stream and a sink of frames.The organization of this crate is to now have three primary submodules,
future,stream, andsink. The traits as well as all combinator types are defined in these submodules. The traits and types likeAsyncandPollare then reexported at the top of the crate for convenient usage. It should be a relatively rare occasion that the modules themselves are reached into.Finally, the 0.1.4 release comes with a new module,
sync, in the futures crate. This is intended to be the home of a suite of futures-aware synchronization primitives. Currently this is inhabited with aoneshotmodule (the oldoneshotfunction), ampscmodule for a new multi-producer single-consumer channel, and aBiLocktype which represents sharing ownership of one value between two consumers. This module may expand over time with more types like a mutex, rwlock, spsc channel, etc.Notable deprecations in the 0.1.4 release that will be deleted in an eventual 0.2 release:
- The
TaskRctype is now deprecated in favor ofBiLockor otherwiseArcsharing. - All future combinators should be accessed through the
futuremodule, not the top-level of the crate. - The
OneshotandCompletetypes are now replaced with thesync::oneshotmodule. - Some old names like
collectare deprecated in favor of more appropriately named versions likejoin_all - The
finishedconstructor is nowok. - The
failedconstructor is nowerr. - The
doneconstructor is nowresult.
As always, please report bugs to https://github.com/rust-lang-nursery/futures-rs and we always love feedback! If you've got situations we don't cover, combinators you'd like to see, or slow code, please let us know!
Full changelog:
- Improve scalability of
buffer_unorderedcombinator - Fix a memory ordering bug in oneshot
- Add a new trait,
Sink - Reorganize the crate into three primary modules
- Add a new
syncmodule for synchronization primitives - Add a
BiLocksync primitive for two-way sharing - Deprecate
TaskRc - Rename
collecttojoin_all - Use a small vec in
Eventsfor improved clone performance - Add
Stream::selectfor selecting items from two streams likemergebut requiring the same types. - Add
stream::unfoldconstructor - Add a
sync::mpscmodule with a futures-aware multi-producer single-consumer queue. Both bounded (with backpressure) and unbounded (no backpressure) variants are provided. - Renamed
failed,finished, anddonecombinators toerr,ok, andresult. - Add
Stream::forwardto send all items to a sink, likeSink::send_all - Add
Stream::splitfor streams which are both sinks and streams to have separate ownership of the stream/sink halves - Improve
join_allwith concurrency
- The
-
0.1.312 Feb 2017Release notes
Open source →- Rewrite
oneshotfor efficiency and removing allocations on send/recv - Errors are passed through in
Stream::takeandStream::skip - Add a
select_okcombinator to pick the first of a list that succeeds - Remove the unnecessary
SelectAllNexttypedef - Add
Stream::chunksfor receiving chunks of data - Rewrite
stream::channelfor efficiency, correctness, and removing allocations - Remove
Send + 'staticbounds on thestream::Emptytype
- Rewrite
-
0.1.204 Oct 2016Release notes
Open source →- Fixed a bug in drop of
FutureSender - Expose the channel
SendErrortype - Add
Future::into_streamto convert to a single-element stream - Add
Future::flatten_to_streamto convert a future of a stream to a stream - impl Debug for SendError
- Add stream::once for a one element stream
- Accept IntoIterator in stream::iter
- Add
Stream::catch_unwind
- Fixed a bug in drop of
-
0.1.110 Sep 2016 -
0.1.001 Aug 2016 withdrawnNothing published for this version