-
Notifications
You must be signed in to change notification settings - Fork 1k
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
Mono support #62
Comments
Noob question: What are the steps for accomplishing this? I've used Mono on OS X systems before but I'm not sure how to go about ensuring Mono compatibility with a library written from the ground-up in Visual Studio. |
We have to ler this one wait, there is a bug in concurrentqueue on mono. There is a fix for it but dont know when they release it. Other than that, it does seem to run on mono. |
https://bugzilla.xamarin.com/show_bug.cgi?id=18182 There is also some issue with remoting on mono, it doesn't load the transports. |
Got it. That's a bummer, but Mono support is probably outside the scope of Milestone 1 for the time being. I'm wholly supportive of doing it in the near future though. |
This is apparently patched in mono 3.2.7, the latest installer for windows is however 3.2.3.. |
There is a 3.2.7 installer for Windows here: http://www.go-mono.com/mono-downloads/download.html |
The actual download points to 3.2.3, or am I missing something? |
Right you are |
Got a pro-tip from Greg Young, they have a local copy of the ConcurrentQueue in their codebase. |
I have a Debian install with a freshly compiled 3.4 that I can run the tests on in the next day or two. |
Ok, Building is not going so well so far with Fake. I'm running debian stable and the fsharp package is not available, so I'm attempting to build it from sources, without success. I do have a linux build.sh which so far appears to do the right thing, though, just that Fake needs fsharpi to do its magic. |
Using Fake.Boot seems to be a problem here. Fake.Boot uses a part of NuGet.Core which references WeakEventManager. In Mono, WeakEventManager is mostly a bunch of Two questions: 1) Are we set on Fake, and 2) should I build elsewhere and just run the tests in Mono for now? |
Hey guys, I know I'm new to the party, but I would like to assist with this and I seem to mostly be talking to myself. I've got a WeakEventManager implementation done now that NuGet will work with, but it's not really a release worthy solution to patch that for everyone's Mono builds that need to work with this. Would it be acceptable to create make script parallel to the fake build? The docs mention a Rake script also, but I don't see it in the current source. |
Hi @mattnischan So the Rake script is gone - I'll try to update that in the documentation. As for your suggestion:
|
@mattnischan btw, could you point out where in the documentation we mention the RAKE script? We've... expanded our docs a lot since I wrote that :p |
Made some progress with getting things to build using FAKE. I had to totally bypass Fake.Boot for the time being. However: CS0234: Actor/FSM.cs(4,14): The type or namespace name 'Claims' does not exist in the namespace 'System.Security'. Are you missing an assembly reference? After some research, it looks like Mono 3.4 doesn't have any of the ClaimsIdentity stuff at all. Taking a look at the source for 3.6 (which is finally out), it seems like some quick and dirty parts of it are working, which may be sufficient. I'm going to blow away my dev VM and start over with 3.6. In the meantime, the NuGet.targets for pacakge restore is quite old and definitely doesn't work with xbuild, so I'll put in a PR to update that as well as adding a build.mono.fsx that at least won't barf. |
@mattnischan the FSM actor shouldn't depend on claims at all - looks like that was some garbage that might have accidentally been ReSharper'd into the file by yours truly. I'll send a PR to remove it. |
removed Security.Claims header from FSM, which broke Mono buildper #62
@Aaronontheweb I pulled that change into my branch and we have build success! I started running the tests in Akka.Tests but I'm finding the tests are hanging the xunit runner about 30-45 tests in (at different points each run). I'm not sure if there are race conditions or if the xunit runner is not totally Mono safe yet, but I'll try and start tracking those answers down. |
…target under linux/mono for akkadotnet#62.
What version of mono are you using? torsdag 21 augusti 2014 skrev Matt Nischan [email protected]:
|
@mattnischan I think @HCanber found an issue with the XUnit test runner in general. some of our tests randomly hang as well. |
Ahh, ok. :) |
Verified on Mono 3.8.0 (under OSX) and on 3.2.8 (under raspberry pi). Hangs after "Starting remoting" message. I have a will to contribute, just need some fresh hints/directions :) |
@OlegZee Raspberry Pi - cool! Which example was it that hung on Mono? |
@Aaronontheweb I created my own sample based on this Balancing Workload Across Nodes with Akka 2 article. |
@OlegZee very cool! Just a heads up though, the FluentConfiguration you're using to configure your application is experimental and may not make it into the v1.0 release (although it's really cool to see someone using it!) So is it the Worker project's Here's something you could do that would really help: could you try cloning the Helios source and see if you can get this example to run on Mono? https://github.com/Aaronontheweb/helios/tree/master/samples/TimeService If it doesn't then the issue is probably that some of my socket code has some Windows-specific dependencies. |
@Aaronontheweb Worker Program starts, prints "Starting remoting" and keeps silence. So I'm going to look into helios. Thank you! |
@Aaronontheweb I forgot mbp at office so was playing mostly on windows and old macmini with no mono debugger. As I have no clue on what's going on inside Akka, I need a debugger to get better feeling of code, but my installation of Xamarin under Windows does start .NET debugger, runs code under MS's .NET, and the code runs fine. |
@Aaronontheweb does helios use |
Getting this running Worker.exe under Mono 3.8 OSX: Cause: System.Net.Sockets.SocketException: The requested address is not valid in this context |
@mattnischan I watched the same if I set wrong master path in .config file. Once config is ok, it just hangs. |
OK, I'm not familiar enough to know what is going on, but it seems to be hanging waiting for a Task result in Remoting.Start():
|
Some more details, In I do see a |
@rogeralsing the Helios Fibers use a @mattnischan @OlegZee so it sounds like the issue is that some part of the Can you confirm the following for me?
What this sounds like to me is an issue where either a network message is being dropped / never sent / never processed (the Also: if you have a website you can link me to that can help me figure out how to put together a debugging setup for Mono on Windows or OS X, I'd appreciate it! |
@Aaronontheweb If you've got OS X, just load up MonoDevelop and Mono 3.8 from the Mono websites. There's really not much more to it. |
@Aaronontheweb If I set a breakpoint in the protected constructor for It's hard for me to tell without knowing more about Helios whether or not the socket connection is successful. I will say that Occasionally when I pause debug after a hang, the call stack seems to indicate waiting on a |
@Aaronontheweb it depends on how you use it. If you initialize it with some other sort of backing store, then it should be safe. |
Well, I'm testing on Mono 3.8, and I think OlegZee was also. Mono 3.6 and above have the fix for ConcurrentQueue. |
Ok, all I found is pretty much clear without any debugging - something is wrong with transport initialization. Obviously it's hard to track the code flow and I give up. |
So this might be the culprit here: https://github.com/Aaronontheweb/helios/blob/master/src/Helios/Concurrency/Impl/DedicatedThreadPoolFiber.cs#L18
@mattnischan sounds like, as @rogeralsing described, that the infamous ConcurrentQueue bug might be rearing its head under the hood here - no? |
@Aaronontheweb I don't think so. As was mentioned previously, we're both testing on version of mono (3.6+) that don't suffer from the same race condition in |
I wonder if the |
No, remoting is only used when communicating with actors who have a non-local address. All local communication is still done in-memory. If the actor system itself is locking, it's probably not a transport / Helios issue - it's probably something inside the initialization steps for the |
@Aaronontheweb @mattnischan I replaced BlockingCollection to List with a couple locks + making snapshot before I figured out _blockingCollection.Add() is not called ever a single time. So BlockingCollection is not the showstopper here. As far as I understand transport is activated only after AssociationListenerPromise is raised but it never happens. As a result EndpointManager.Listens is never complete. |
related to #694 |
This works fine now. closing |
We need to ensure that Akka.NET works on mono.
The text was updated successfully, but these errors were encountered: