Follow Slashdot blog updates by subscribing to our blog RSS feed


Forgot your password?
Slashdot Deals: Deal of the Day - 6 month subscription of Pandora One at 46% off. ×

Submission + - The four promises of Actor Based Programming for telco software (

neutrino38 writes: The Actor Model is a theoritical computation model which aims is to improve concurrent computing. In essence, Actors are 'processes' that can receive, process and send messages to other Actors. This is a computation model that is not based on shared memory and opposes the traditionnal shared memory, locking and multithreading model. In terms of hardware architecture, the multithreaded model aims at powerful servers few CPUs and shared memory whereas the actor model aims for concurrent processing on many computers cooperating through reliable networks links.

To my profane eyes, there are little theoritical differences between object model and actor model. But I am no academics and the intent here is to throw some practical views on the possible benefits that programmers can draw from actor based programming.

One has to admit that the original vision of many computers cooperating through networks did not materialize yet. The dominant model is a cloud of powerful cooperating servers providing online services to smart terminals through network. Multithreaded programming is the mainstream way of developping server side software.

However, there are some trends in computing that may be game changers. These are:
  • the 'cloud' or flexible computing where server-side applications are hosted on virtual machines Multiple 'instances' of the same application can be created on demand to cope with load surge. Context information is shared through add-ons such as memcached or databases. Advanced realtime web applications such as facebook use message and notifications and look like good candidate of actor based implementations.
  • the Internet of Thing where multiple devices with low processing power coordinates over a local area network and through the Internet. Again, this matches nicely with actor model purposes.
  • finally, server side applications such as HTTP servers are put under pressure by growing users bases. The 10K user problem well documented for web servers, occurs in any big server-side application. Adding more processors to cope with load does improve performance linearly as processes or threads spend more and more time to wait for locks when accessing critical ressources. The actor model provides a 'lock free' alternative that can overcome this issue.

Several programming frameworks and languages provides very good ways to implement actor based software. Three of them come in mind:

  • Erlang, a language developped by Ericsson and open sourced or Elixir that provides a friendlier language syntax but produce bytcode that is compatible with Erlang VM.
  • Scala a language that produces java compatible bytcode. It is used in the famous Minecraft game
  • The C++ Actor Framework brings the actor model into native code.

Erlang and Scala merge functional programming with actor model and that has a solid consequence: developpers can only assign variables once and cannot change the value. The only way to change a variable is to send a new messsage (or to call a function) with new arguments. This is a radical way to prevent any use of memory sharing but this breaks most of the classical programming techniques: loops needs to be implemented by recursive function calls or can be replaced with more functional equivalents.

Let's focus now on server side application development, especially in telecommunication field where protocol exchange is the main purpose. Intuitively the actor model fits perfectly . However the majority of telecommunication apps are still developped in classical C/C++ with scripting languages or in Java (SIP servlet). But Actors make four important promises:

  1. I shall not fail: Telco applications should always be on. With the OTP framework, Erlang provides a radical way to recover. If an actor detects an error condition, it can crash and be restarted. Dependant actors will be nicely notified about the restart. Application can partially crash and restart limiting the impact to a single user. Erlang also supports code replacement without application stop. I did not test it first hand but if proved, this is a tremendous advantage in telco business.
  2. I will not block: by design, actor model is lock free. This remove one of the worst nightmare of any server side application developpement.
  3. I can scale: actor model breaks downs a piece of software into a set of coordinated actors that do not share any memory. They exchange messages transparently and therefore can be very easily spread on several hardware system. Traditionnal approach implies communication context sharing that was never fully scalable.
  4. I am a finite state machine: That concept is not enough understood while it is central to build robust and resilient telecommunication applications. actor model is about exchanging message. The actor framework provides a natural way to map messages into function calls and implement FSM easily.

So ... why the telecom world is not rushing to embrace actor based programming ?

Its because it requires major cultural changes and telco world is a bit conservative.

  • Software needs to be entirely redesigned into actors that are simple and pipelined.
  • Developpers need to give up any use of shared memory to store a "communication context".
  • no more control on lock and threading
  • Langages such as Erlang and even C++ Actor framework uses a syntax that is so different from procedural approach that the learning curve is very steep. Almost hostile.

All this is much more radical than moving from init scripts to systemd on Linux. And this transition is costly: training developers, software redesign and reimplementation.

Is it worth it ? That is a question we are asking ourselves

Comment Re: pilots once they start flying their unmanned.. (Score 1) 187

Imagine if RC cars were a relatively new thing.. and people started attaching cameras to them and driving them on the freeway around emergency responders.

There are already laws in place to punish anyone doing such a thing. Just like there already are for flying model airplanes in the way of real aircraft.

Comment Re:Infringing on the freedom of the press (Score 1) 187

Because vehicle registration like that is a state-level activity, not a federal activity. And congress, in the 2012 FRMA law, explicitly fended the FAA off from doing some of this stuff. But the Obama administration is trying yet another counter-constitutional end-run by acting at the DoT level instead of the FAA level, and the task force is recommending that EVERY RC FLYING ANYTHING, including a kid's 9-ounce fixed wing toy plane, make that kid subject to federal registration and fines if he doesn't. Yeah, 9 ounces. 250 grams. Are you paying attention?

Comment Re:Unbelievable (Score 1) 570

A wall built for one purpose will work just as fine for the other. Just like surveillance systems built to catch terrorists will work perfectly fine to keep tabs on you, too.

Really? Have you been hearing a lot about how the areas of the US/Mexican border that are actually fenced off and have been for years are being used to prevent dissident US citizens from fleeing their oppressive country into Mexico? Please, do go on. Can't wait for the links you can't provide because you're being completely disingenuous and you know it.

Comment Re:Godwin (Score 1) 570

a list of the worst things that have happened in the recorded history of the world, the USA's enslavement of black people would be right up near the top of the list

But not the European enslavement of black people? Or the enslavement of black people by OTHER black people that predated any European enslavement of black people? Or the still ongoing enslavement of black people by other black people (and Arabs, etc) that's happening right now? Your focus on the "USA's" enslavement (as if that institution wasn't in place for a couple of European-controlled centuries in North America and in Europe before there even was a USA) is pure drivel, and you know it. And then your fake ignorance of the intellectual and eventually physical civil war that erupted over and led to the practice of ending slavery - a cause to which untold thousands of white Americans gave their lives - that's a pretty tall order of disingenuous cherry picking on your part.

I would put helping poor people first

That would be nice. The first thing to do would be to stop voting for the people who have been conducting their "war on poverty" for decades, and who have done nothing but create a multi-generational ocean of people dependent on the vast bureaucracy and spending that that effort has ginned up. You want to see fewer people in poverty? Stop rewarding multiple births in single-parent households where absent fathers and disinterested mothers create rudderless, illiterate, unskilled, and often drug-addicted, violent kids even in areas where their cities spend enough per child on education to put three other kids through top quality private schools in any other place. The problem you're talking about, shy of true mental illness, isn't about resources. It's about local culture. Period. If you really think that you need to fix that, you have to take kids out of that environment and raise them away from it. Are you ready to make that case? Ready to take kids from their toxic neighborhoods and homes so they don't repeat the cycle of ignorance and a criminal world view? No? Then what sort of "help" did you have in mind, specifically? Give them more stuff? Spend more than $10,000 per student per year on school?

Wait. I know. We should rid their neighborhoods of the crime that plagues those places, so they can pursue a more constructive life. How should we do that? Perhaps make sure that the local criminal gangs aren't staffed up with members that cycle repeatedly through the legal system and return to commit the same crimes over and over again? Nope, can't do that, because that involved police, and we all know that police are now officially evil, and locking up violent gang members is officially racist. Looking forward to your specific suggestions, and explanations as to why they've never been tried before or have never worked before, but will now, because of how you're suggesting them.

Comment Re:Nope again. Now you're just making shit up. (Score 1) 570

Yes, and the entire conversation was with a gaggle of reporters who had been talking about the current events (Syrian refugee) situation in particular, and you're barely hearing the FIRST reporter's simultaneous questions. He (Trump) presumed everyone was still talking about the topic du jour, the refugee issue and the need to track them better than Europe has been doing. The ONLY person to suggest a "Muslim database" was a reporter throwing things into the multi-reporter scrum. If you really think that the way that was answered indicates some policy urge on his part to do what the reporter dreamed up, then you're just trolling.

Again, I am NOT a Trump supporter. I don't want him in office. But I know disingenuous faux outrage when I hear it. If the lefty media and blogosphere types really think that was something to be uptight about, then their disinterest in holding Obama, Clinton, Biden, Kerry, Reid, Pelosi and other notable Democrat figures responsible for some truly, truly stellar BS, non-sequitors, irrationalities, and outright deliberate repeated lies is ... well, a pretty predictable display of typical lefty hypocrisy. Or, would you link to your same armchair psychology analysis of some of those deliberate deceptions from people in office on the left? Please? Thank you for being intellectually honest and doing so.

Comment Re:Godwin (Score 1) 570

What makes you think you know anything about my party affiliation or lack of it? Your own rah-rah is showing.

And no, both parties are NOT equally bad in this regard. The vast majority of conservatives (who have plenty of cultural problems in the bus along with them, in the form of die-hard religious types, to be sure) are uniformly opposed to expanding government power over your personal daily life. They're not the ones trying to tell you what size drink cup you can buy, which medical services you must pay for (but only from these government-partnered sources!), which of the new 8,000 (!) new regulations issued every year may or may not make you a criminal this year while doing the same things you did last year, etc. The general disposition of the two parties is significantly different when it comes to the role of government in every day life.

When someone does something stupid, the republican's first instinct is to say, "What kind of upbringing did that person have, that they thought that was acceptable behavior?" while the democrat's immediate take on it is, "What kind of additional tax should we charge in order to fund a government program and new government employees and bureaucracy in order to attempt to control that behavior, or at least treat it as a new source of revenue?"

Comment Re:Unbelievable (Score 1) 570

Talked to a Ukrainian once. The stated reason for the wall was to keep out Western spies.

Yeah, that's why they machine-gunned families trying to climb over it in desperate attempts to escape from East Germany's little slice of Soviet hell on earth.

No, it wasn't about western spies. It was about "brain drain" - the loss of the educated, industrious, Germans who didn't want to live under socialist compulsion and control.

Comment Re:Nope. (Score 1) 570

All of the assailants they've identified so far are European nationals. There's plenty of evidence that they're trying to make it _look_ like the attacks were carried out by agents they sneaked in with the refugees, but the evidence so far on the actual attackers is that they didn't come in with the refugees.

So, just to be clear, what you're talking about is the Greek and French governments both lying about fingerprints taken just weeks ago during a border crossing in Greece and then found on the bodies of the attackers in Paris?

Comment Re:Nope. (Score 1) 570

"There should be a lot of systems, beyond databases" and "signing up at different places" when asked about signing people up at mosques.

Which is him talking about tracking refugees newly admitted to the country. Just like we're ALREADY DOING, just not very well, because we lose track of people and can't figure out what they're doing. Like, you know, the half a dozen Bosnian Muslim refugees who were let in, and then ended up working directly to finance foreign militants. Those are people who went through what the administration is describing as a completely thorough vetting process. Which it's not. Not even close. More tracking and scrutiny IS appropriate, since we're dealing with groups like IS who are boasting of their long term plans to make use of refugee movement, and just used it to send to mass killers into Paris (were you paying attention?).

Nobody is putting words in his mouth.

Except, you, through deliberate mis-characterization.

talks in thought-terminating cliches but he clearly understood those questions and replied to them in his poorly thought through manner

I'm not a fan of his communication style, his thought process, or his habit of rambling. But I'm much less of a fan of people who deliberate ignore the context in which something is said to score lazy rhetorical points with low-information audiences. You are deliberately ignoring the fact that he was in a loud room talking to two reporters at the same time. He didn't bring up the topic in question, and certainly didn't "endorse" a muslim-tracking database. He was talking about tracking new immigrants, especially those from places that have just a week ago served up phony refugees that just slaughtered 130 people (not to trouble you with the actual context or anything).

Comment Re:Checklist (Score 1) 570

How did the rest of Christians answer for this?

Who said they had to "answer for it?" He was promptly dealt with by the legal system, not sheltered and funded by fellow medieval-minded theocratic thugs and their financiers. Are you really so unable to see the distinction?

as a resident of the country that has deliberately targeted two hospitals for bombings in as many months

Oh, NOW I get it. You didn't say that the conversation was supposed to be without any sort of context, and was supposed to not take into account things like local police calling in for air strikes because they're being shot at by people who have taken up positions in the hospital. I didn't realize that the conversation was supposed to be about an alternate universe where militant Islamists don't deliberately set up shop in dense neighborhoods, in the parking lot of hospitals, in mosques, schools, former churches, and the like. Since you're talking about non-real situations, what else can we talk about? Is Jar-Jar Binks a good guy, or a bad guy in your pretend world?

Comment Re:Unbelievable (Score 2) 570

So he's going to skip the whole pinning stars on peoples' chests and go straight to building the Berlin wall, and this somehow makes what he is saying OK?

Really? Please point to a single quote where is he advocating the building of a wall to keep people from fleeing the country. You're confused. That's a leftist thing. The socialists are the ones that, given enough power, do things like wall up Berlin to prevent people from leaving their collectivist paradise, or jail people from attempting to leave the socialist paradise that is Cuba. If you can't muster the energy necessary to understand the difference between keeping people from illegally walking INTO your country, vs. using force to prevent them from fleeing from collectivist tyranny, then please don't do anything reckless like voting.

Comment Re:Godwin (Score 1) 570

You are living in denial.

And then you say: "Donald Trump has endorsed setting up a database of Muslims" ... which is you denying the truth, because he said no such thing. A reporter said that in the middle of a conversation with a second reporter. Listen to the segment, as if you were a person who has any sort of intellectual honesty, and see who really said what.

there are multiple instances of Trump supporters violently attacking Hispanic Americans

Specific links, please, to show that you aren't also just BSing about that, as well. While you're at it, shall we look for links to coverage of "hispanics" (who are you talking about, exactly?) being violent? No? Would that take the fun out of your rant?

Don't you see where this is all headed?

Yes, it's probably headed to even MORE shrill lefty lying and distortions. It might even result in no immediate reduction in the rampant crime and murder that's ongoing in a some cities that have been run for decades by liberal legislatures and administrations.

Fascism is already here

You're still foggy on the meaning of that word, aren't you?

Comment Re:Godwin (Score 1, Insightful) 570

I have not seen any Democrats proposing anything that even comes close to the things coming out of the Republican party.

Haven't been on a college campus in the last few years? No?

From the Republicans we see religious tests, attempts to deny rights to specific religions, and now a national registry of Muslims of the exact same sort that Hitler used against the Jews.

You mean the "religious test" that current administration routinely applies when considering refugee status, but which the leader of the House explicitly said would be part of no legislation to come from that body? And that "national registry of Muslims" that a reporter conjured up out of thin air, that one? Please cite the language used by "the republicans" as they propose such a thing. Be specific.

it's only one side of the American political spectrum that's pushing for all-out fascism

You don't actually know what word means, do you? The only party that's all about heavy-handed centralized government power and crony corruption is the Democrat party. They love that stuff.

To do two things at once is to do neither. -- Publilius Syrus