Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Listen on all interfaces #23

Merged
merged 6 commits into from
Dec 20, 2019

Conversation

ebroto
Copy link
Collaborator

@ebroto ebroto commented Dec 10, 2019

The parameter "-i" is now optional and we listen on all interfaces by default.
The interface is shown in the connections table.

I've changed the read timeout for the datalink channel from 1 ns to 2 ms because I realized (before the changes) that we were using quite some CPU there. In my computer it went from taking consistently over 10% of one CPU to ~2%. I think it should be enough to handle the traffic and to keep the application responsive to the "quit" key. Let me know if you find it appropriate!

Closes #16

Copy link
Owner

@imsnif imsnif left a comment

Choose a reason for hiding this comment

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

Hey @ebroto - really great work as usual! Just a couple of minor issues and I'd be excited to go forward and merge this.

src/main.rs Show resolved Hide resolved
src/main.rs Show resolved Hide resolved
src/network/utilization.rs Outdated Show resolved Hide resolved
src/display/ui_state.rs Show resolved Hide resolved
@imsnif
Copy link
Owner

imsnif commented Dec 15, 2019

Also, forgot to mention, the timeout increase works great for me too and I'm very happy about the CPU performance - so thanks, let's go with this.

Copy link
Owner

@imsnif imsnif left a comment

Choose a reason for hiding this comment

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

Hey, just one more thing with the break syntax and we're good to go with this.

src/main.rs Show resolved Hide resolved
src/main.rs Show resolved Hide resolved
src/network/utilization.rs Outdated Show resolved Hide resolved
@ebroto ebroto force-pushed the feature/listen-on-all-interfaces branch from 13fd853 to 6436b7d Compare December 20, 2019 19:35
@ebroto
Copy link
Collaborator Author

ebroto commented Dec 20, 2019

Got caught by clippy in the CI, happy that it works :)

On it

@imsnif
Copy link
Owner

imsnif commented Dec 20, 2019

Cool - so I think this is good to merge once the tests pass. Definitely good to know the new CI stuff is working. :)

Feel free to merge, I'll publish to the various outlets over the weekend (at some point I'll have to automate this).

@ebroto ebroto merged commit b150bf3 into imsnif:master Dec 20, 2019
@ebroto ebroto deleted the feature/listen-on-all-interfaces branch December 20, 2019 20:28
@imsnif
Copy link
Owner

imsnif commented Dec 22, 2019

Hey @ebroto - I'm in the process of releasing 0.5.0 right now and it mainly includes your work. I'd like to announce it on twitter so it gets a little exposure: do you use twitter? I'd very much like to give you credit. :)

@ebroto
Copy link
Collaborator Author

ebroto commented Dec 22, 2019

Thanks!! I appreciate the intention but I'm not on twitter. I usually read the subreddit but mainly lurking, so a mention would be more than enough :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Listen on all interfaces
2 participants