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

Port MIO library to Solaris OS #1263

Closed
wants to merge 10 commits into from
Closed

Port MIO library to Solaris OS #1263

wants to merge 10 commits into from

Conversation

batrla
Copy link

@batrla batrla commented Jan 22, 2020

Solaris OS (unlike its fork Illumos) has no epoll(7) interface. The port of MIO
library to Solaris OS adds support of standard POSIX poll(2) interface and
implements edge-triggered semantic in a user-space.

Please review the code change, I'm willing to make updates if needed.
The PR fixes some minor defects I found.

Cargo test output is clean, no failure:

$ grep test\ result ~/tmp/x
test result: ok. 3 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out
test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out
test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out
test result: ok. 2 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out
test result: ok. 4 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out
test result: ok. 13 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out
test result: ok. 5 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out
test result: ok. 2 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out
test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out
test result: ok. 16 passed; 0 failed; 1 ignored; 0 measured; 0 filtered out
test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out
test result: ok. 11 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out
test result: ok. 14 passed; 0 failed; 5 ignored; 0 measured; 0 filtered out
test result: ok. 31 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out
test result: ok. 10 passed; 0 failed; 1 ignored; 0 measured; 0 filtered out
test result: ok. 7 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out
test result: ok. 10 passed; 0 failed; 3 ignored; 0 measured; 0 filtered out
test result: ok. 5 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out
test result: ok. 35 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out

Vita Batrla added 2 commits January 22, 2020 09:55
Solaris OS (unlike its fork Illumos) has no epoll(7) interface. The port of MIO
library to Solaris OS adds support of standard POSIX poll(2) interface and
implements edge-triggered semantic in a user-space.
@asomers
Copy link
Collaborator

asomers commented Jan 22, 2020

AFAIK there's no hosted CI solution for Oracle Solaris. So mio can't ever maintain this port. Nor should we, I think. Oracle has all but abandoned Solaris. How much unpaid effort should we put into supporting an abandoned, non-free OS?

@Thomasdezeeuw
Copy link
Collaborator

Thomasdezeeuw commented Jan 22, 2020

@psumbera was working on a Solaris port in #1152, could you provide us with a CI solution?

@psumbera psumbera mentioned this pull request Jan 22, 2020
@batrla
Copy link
Author

batrla commented Jan 22, 2020

AFAIK there's no hosted CI solution for Oracle Solaris. So mio can't
ever maintain this port.

The implementation uses poll(2) interface which is defined by POSIX, so
this port can be theoretically tested on any Unix based system. It should
work also on Linux (I haven't verified it yet). It's a matter of adding
configuration option / switch / feature in port code to fallback
from epoll/kqueue to poll(2) and ensuring it's OK.

Nor should we, I think. Oracle has all but abandoned Solaris. How much
unpaid effort should we put into supporting an abandoned, non-free OS?

As far as I know Oracle declares Solaris 11 OS is supported at least till
2031/2034 per support plan. Yes, it's non-free OS and I'm not
aware of free CI solution for it. On the other hand I'm willing
to add way to unit test the suggested fix on Linux.

@batrla
Copy link
Author

batrla commented Jan 23, 2020

I modified the code to automatically test MIO port to POSIX poll(2) on Linux pipeline in Azure, please see an update in CI tasks.

@Thomasdezeeuw
Copy link
Collaborator

I do think that running on the actual OS is a requirement for Mio to support it. I also don't want to support poll(2) on Linux so that route is a no-go for me.

@psumbera
Copy link
Contributor

What can we do to have Solaris in CI? Can we help with the setup?

@Thomasdezeeuw
Copy link
Collaborator

What we need is something/somewhere to run the Solaris OS. Can Solaris be virtualised somehow/somewhere (without cost to the maintainers of Mio)?

@psumbera
Copy link
Contributor

Oracle Solaris is available in Oracle cloud, or we can run eventually tests somewhere, plus it can be run in VirtualBox. But how to connect it to Github CI?

@Thomasdezeeuw
Copy link
Collaborator

@psumbera sorry for the late response. Maybe something like Jenkins (https://jenkins.io/solutions/github/) on a virtual machine on Oracle cloud would work?

@psumbera
Copy link
Contributor

psumbera commented Feb 4, 2020

Jenkins might be the solution. I wonder whether you need to have access to the machine or it's enough if we set it up for you. In any case we need to explore possibilities to get the machine first.

@Thomasdezeeuw
Copy link
Collaborator

@psumbera I don't think we need access to the machine. All we need to know is that the tests passed, so the output log and some kind of feedback to GitHub would suffice.

That would mean that if we find a Solaris specific problem we need to relay that to someone with access to a Solaris machine to debug it.

@batrla
Copy link
Author

batrla commented Feb 5, 2020

If there is a native Solaris CI, then I'll update the fix to use port_associate(3C) instead and take out poll(2) unless there's an interest to keep it. Event ports semantic is closer to what MIO does today and it simplifies the code change.

@Thomasdezeeuw
Copy link
Collaborator

@batrla changing to use port_associate(3c) sounds good to me, you can remove poll(2) as no other platforms will make use of it.

@Thomasdezeeuw
Copy link
Collaborator

This port still doesn't seem to have commitment to any maintainers, so I'm going to close this.

@psumbera
Copy link
Contributor

Following would hopefully resolve the issue too: #1602

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.

4 participants