Lucio Franco
29e417c257
tokio: Add io copy, read, and write ( #1187 )
2019-06-25 16:51:49 -04:00
Ivan Petkov
9df1140340
signal: factor out event delivery into its own module to share between Unix and Windows ( #1174 )
...
Today the Unix and Windows implementations have similar yet differing
implementations of hooking into OS events and propagating them to any
listening futures. Rather than re-implement the same behavior two
different ways, we should factor out any commonality into a shared
module and keep the Unix/Windows modules focused solely on OS
integrations.
Reusing the same implementation across OS versions also allows for more
consistent behavior between platforms, which also makes squashing bugs
much easier.
This change introduces the `registry` module which handles creating and
initializing a global map of signals/events and their registered
listeners. Each OS specific module is expected to implement the OS hooks
which delegate to invoking the registry module's methods for
distributing the event notifications.
# Use registry module for Windows implementation
Note this still uses the same architecture as previously: a driver task
is spawned by the first registered event, and that task is responsible
for delivering any events to registered futures. (If that first event
loop goes away, all events will deadlock). A solution to this issue will
be explored at a later time.
2019-06-25 13:07:59 -07:00
Lucio Franco
e2b4bdb647
sync: Add LockFuture for Lock ( #1184 )
2019-06-25 10:42:35 -07:00
Ivan Petkov
c6defbce4b
process: Move files to their own directory
2019-06-24 17:31:47 -07:00
Ivan Petkov
b7846a4e2f
process: Remove unneeded files
2019-06-24 17:31:00 -07:00
Ivan Petkov
cb8607a816
process: Update to 2018 edition
2019-06-24 17:29:33 -07:00
Ivan Petkov
27c15471c1
process: Run cargo fmt
2019-06-24 17:29:33 -07:00
Ivan Petkov
0ab25878bd
process: Update README
2019-06-24 17:29:32 -07:00
Eliza Weisman
448302c3d4
trace: Improve documentation ( #1148 )
2019-06-24 19:22:05 -05:00
Ivan Petkov
934a1467d4
process: Update CHANGELOG
2019-06-24 17:12:17 -07:00
Ivan Petkov
4d639e246b
process: Update Cargo.toml
2019-06-24 17:10:58 -07:00
Ivan Petkov
ff5381de8d
process: Update license files
2019-06-24 17:10:58 -07:00
Ivan Petkov
061452dc01
process: Delete flaky and (now) unused test
2019-06-24 17:10:58 -07:00
Ivan Petkov
a6b2682309
process: Bump to 0.2.4
2019-06-24 16:57:20 -07:00
Ivan Petkov
cf84a59e5a
process: Don't kill child on drop if already successfully killed
2019-06-24 16:57:20 -07:00
Ivan Petkov
e90e33d5df
process: Add unit tests for dropping killing dropped children
2019-06-24 16:57:20 -07:00
Ivan Petkov
fa5da27d98
process: Utilize a global orphan process queue to avoid leaks
2019-06-24 16:57:20 -07:00
Ivan Petkov
ecaa069f0f
process: Implement a queue for repeatedly attempting to reap orphaned processes
2019-06-24 16:57:20 -07:00
Ivan Petkov
fc15d7d4a4
process: Only pull in mio dependency on unix platforms
2019-06-24 16:57:20 -07:00
Ivan Petkov
a70a3b599a
process: ci: move cargo tool installation to after_success
2019-06-24 16:57:20 -07:00
Ivan Petkov
26faefcc34
process: ci: enable clippy checks as part of the build
2019-06-24 16:57:19 -07:00
Ivan Petkov
f16725ea9f
process: Fix clippy warnings
2019-06-24 16:57:19 -07:00
Ivan Petkov
caf43221b5
process: ci: fix cargo binary caching
2019-06-24 16:57:19 -07:00
Ivan Petkov
93680357dd
process: Fix drop_kills test when running on macOS with a single thread
2019-06-24 16:57:19 -07:00
Ivan Petkov
784d21ae31
process: Try pinning mio to 0.1.16
2019-06-24 16:57:19 -07:00
Ivan Petkov
0938ccfefd
process: ci: cache cargo tarpaulin build
2019-06-24 16:57:19 -07:00
Ivan Petkov
6fa2fdab44
process: Ensure all tests are run with an explicit timeout
2019-06-24 16:57:19 -07:00
Ivan Petkov
d0d13d0bd0
process: Change codecov comment behavior to default
2019-06-24 16:57:19 -07:00
Ivan Petkov
8a1777b800
process: Rename EventedReaper to Reaper
2019-06-24 16:57:18 -07:00
Ivan Petkov
42d0f53ddb
process: Optimize out the "reaped" flag
2019-06-24 16:57:18 -07:00
Ivan Petkov
db0c4147c8
process: Refactor Unix process handling
2019-06-24 16:57:18 -07:00
Ivan Petkov
10fd2afd18
process: Simplify child IO registration
2019-06-24 16:57:18 -07:00
Ivan Petkov
83a55601ef
process: Move src/unix.rs to src/unix/mod.rs
2019-06-24 16:57:18 -07:00
Ivan Petkov
b37120f61c
process: Update line-by-line doc example to be more flexible
2019-06-24 16:57:18 -07:00
Ivan Petkov
91dbf24cf4
process: Update min supported rust version as per the Tokio project policy
2019-06-24 16:57:18 -07:00
Ivan Petkov
c78fd6d6c5
process: Update Travis link from .org to .com
2019-06-24 16:57:18 -07:00
Ivan Petkov
025474dfbb
process: ci: Install cargo-tarpaulin *after* initial tests
2019-06-24 16:57:18 -07:00
Ivan Petkov
e7dfcf90fe
process: ci: Enable code coverage tracking via codecov.io
2019-06-24 16:57:17 -07:00
Ivan Petkov
ecdfe4c474
process: ci: collect code coverage info via cargo-tarpaulin
2019-06-24 16:57:17 -07:00
Ivan Petkov
37b4efb9e2
process: Bump version to 0.2.3
2019-06-24 16:57:17 -07:00
Ivan Petkov
c94f607f1b
process: Fix some test case deprecation warnings
2019-06-24 16:57:17 -07:00
Ivan Petkov
76438c9e70
process: Implement AsRawHandle for ChildStd{in, out, err} for parity
2019-06-24 16:57:17 -07:00
Yuya Nishihara
e0e9594f71
process: Implement AsRawFd for ChildStd* structs
2019-06-24 16:57:17 -07:00
Yuya Nishihara
3b43262a10
process: Implement AsRawFd for inner Fd<T> wrappers and use it instead of self.0
2019-06-24 16:57:17 -07:00
Ivan Petkov
5f18bf669f
process: Bump minimum supported rustc version to 1.26
2019-06-24 16:57:17 -07:00
Ivan Petkov
1581c8b475
process: Bump minimum required version of tokio-signal to 0.2.5
2019-06-24 16:57:16 -07:00
Ivan Petkov
d3b2efc815
process: Add regression test for signal starvation
2019-06-24 16:56:53 -07:00
Ivan Petkov
f7c4e3cd84
process: Bump min supported rustc version to 1.25
2019-06-24 16:56:53 -07:00
Ivan Petkov
329ad3324c
process: Bump to 0.2.2
2019-06-24 16:56:53 -07:00
Ivan Petkov
2b6695d25a
process: Update CHANGELOG
2019-06-24 16:56:53 -07:00