Skip to content

Redirect stdio - #1

Open
fabianfreyer wants to merge 2 commits into
masterfrom
stdout_redirection
Open

Redirect stdio#1
fabianfreyer wants to merge 2 commits into
masterfrom
stdout_redirection

Conversation

@fabianfreyer

Copy link
Copy Markdown
Contributor

No description provided.

@codecov

codecov Bot commented Nov 15, 2017

Copy link
Copy Markdown

Codecov Report

Merging #1 into master will increase coverage by 1.82%.
The diff coverage is 80.55%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master       #1      +/-   ##
==========================================
+ Coverage   76.04%   77.87%   +1.82%     
==========================================
  Files           2        2              
  Lines         167      235      +68     
==========================================
+ Hits          127      183      +56     
- Misses         40       52      +12
Impacted Files Coverage Δ
src/process.rs 74.05% <80.55%> (+6.27%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 60e8d2d...dc28227. Read the comment docs.

@fabianfreyer fabianfreyer left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

After fubarnetes/fubarnetes#1 is solved, we should really use some other form of IPC rather than native mpsc.

Comment thread src/process.rs
if let Some(ref mut stdout) = p.stdout_reader {
for line in stdout.lines() {
info!("{:?}", line)
p.stdout_sender

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

After fubarnetes/fubarnetes#1 is solved, this should ideally be some PUB/SUB or similar message queue.

Comment thread src/process.rs
if let Some(ref mut stdin) = p.stdin_writer {
if let Ok(input) = p.stdin_receiver.try_recv() {
info!("received: {}", input);
stdin.write_all(input.as_bytes())

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And this probably a PULL or equivalent.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant