Concurrency is a property of systems in which several processes are executing at the same time.

learn more… | top users | synonyms

0
votes
0answers
34 views

Is the happens-before a compositional consistency model?

Since the compositional definition to a consistency model is multiple objects (or the whole system) following such consistency model. This compositional characteristic exists in a group of objects ...
0
votes
1answer
18 views

Implementing distributed Semaphore for AWS workload

We have a messaging gateway in AWS (Amazon Cloud) that comprises of a number of nodes (Linux servers) responsible for receiving, routing, despatching and escalating messages (emails, SMS' and voice ...
0
votes
1answer
135 views

Is Akka a good solution for a concurrent pipeline/workflow problem?

Disclaimer: I am brand new to Akka and the concept of Actors/Event-Driven Architectures in general. I have to implement a fairly complex problem where users can configure a "concurrent pipeline": ...
0
votes
1answer
32 views

handling online payment for items with one quantity - design issue

I would like to implement a robust way to handle ecommerce payment for items with limited quantity, like for example exclusive paintings. Payment would ideally be accepted via PayPal and credit ...
0
votes
1answer
70 views

Locking database records

What I have right now: A table with lot of records. About 200 users can select a record according to some rules based on the data in each record. There is a high chance that 2 or more users will ...
24
votes
4answers
4k views

Should I stick with or abandon Python to deal with concurrency?

I have a 10K LOC project written in Django with quite a deal of Celery (RabbitMQ) for asynchronicity and background jobs where needed, and have come to the conclusion that parts of the system would ...
20
votes
4answers
2k views

What prevents a race condition on a lock?

I understand the basics of what data races are, and how locks/mutexes/semaphores help prevent them. But what happens if you have a "race condition" on the lock itself? For example, two different ...
2
votes
1answer
108 views

How to avoid oscillation by async event based systems?

Imagine a system where there are data sources which need to be kept in sync. A simple example is model - view data binding by MVC. Now I intend to describe these kind of systems with data sources and ...
2
votes
0answers
82 views

How can I make a universal construction more efficient?

A "universal construction" is a wrapper class for a sequential object that enables it to be linearized (a strong consistency condition for concurrent objects). For instance, here's an adapted ...
2
votes
1answer
115 views

Where to implement thread-safety logic for my queue data structure?

I will immediately confess that I do very little multithreading, so questions of style and organization in this domain a little fresh to me. I've written a data structure (in Python, if that matters) ...
0
votes
0answers
11 views

Is Resque appropriate for an evented application?

As the title says, is Resque appropriate for an evented application that requires a decent amount of speed? I'm working on a server application that emulates the default Minecraft server, and I was ...
16
votes
3answers
855 views

What is your thoughts about the Actor Model? [closed]

The Actor Model that is used by Erlang seem to be a very different way to do concurrent programming. What is your thoughts on the Actor Model? Will it be a popular solution for concurrency?
3
votes
1answer
146 views

Can the possibility of a data race be ignored in some cases? (while having concurrent threads) [duplicate]

I am programming a game engine as a hobby project, and I would like to separate physics and drawing into two separate threads. The position vectors of entities are subject to modifications by the ...
16
votes
3answers
3k views

Why not Green Threads?

Whilst I know questions on this have been covered already (e.g. http://stackoverflow.com/questions/5713142/green-threads-vs-non-green-threads), I don't feel like I've got a satisfactory answer. The ...
0
votes
0answers
50 views

Cache concurrency: ensuring latest version in cache

We have a data service app working on object graphs. We place some complex graphs in a (memory) caching tier as a single data item, so as to avoid the length of time to retrieve every individual data ...
11
votes
4answers
1k views

Functional Programming: right ideas about concurrency and state?

FP proponents have claimed that concurrency is easy because their paradigm avoids mutable state. I don't get it. Imagine we're creating a multiplayer dungeon crawl (a roguelike) using FP where we ...
8
votes
5answers
4k views

Real world usage of DelayQueue

What would be a real world usage of DelayQueue, what common problem it was designed to solve?
1
vote
2answers
223 views

Are all race conditions worth fixing? [closed]

I just wrote the following piece of code (in delphi): procedure Update(Value: Integer); begin // If the last update was yesterday, replace yesterday value if CompareDate(FLastUpdate,Now) <> ...
6
votes
4answers
4k views

Problems of multiple threads sharing/accessing the same data [closed]

I have been researching into when data is being accessed or shared by multiple threads within Java. And looking into the problems such as: Thread Interference Memory Consistency Deadlock Starvation ...
17
votes
4answers
3k views

Programs that claim they are not “multi-core” friendly

You see this phrase or similar kicked around from time to time, generally referring to a program that claims they were not designed to take full advantage of multi-core processors. This is common ...
0
votes
3answers
711 views

Super Fast File Storage Engine

I basically have one big gigantic table (about 1.000.000.000.000 records) in a database with these fields: id, block_id, record id is unique, block_id is not unique, it contains about 10k (max) ...
12
votes
1answer
247 views

What intermediate representations can be used to reason about concurrency?

I am trying to better understand what would be required for a compiler to be able to make intelligent choices regarding concurrency on behalf of the programmer. I realize that there are many difficult ...
6
votes
1answer
1k views

Are go-langs goroutine pools just green threads?

The commentator here offers the following criticism of green threads: I was initially sold on the N:M model as a means of having event driven programming without the callback hell. You can write ...
0
votes
3answers
161 views

If mutual exclusion is not implemented, how would we detect a race condition?

Suppose we are in a distributed environment, and mutual exclusion is not implemented yet. So how would we be able to detect race conditions? When I researched, use of non-blocking algorithms was ...
1
vote
1answer
153 views

Does Clojure borrow concurrency ideas from Haskell?

In code quarterly interview with Rich Hickey Michael Fogus hints that Clojure borrows a lot from Haskell: Fogus: As someone who only knows Haskell enough to read the papers, Clojure appears to be ...
1
vote
1answer
224 views

Editing files without race conditions?

I have a CSV file that needs to be edited by multiple processes at the same time. My question is, how can I do this without introducing race conditions? It's easy to write to the end of the file ...
9
votes
2answers
579 views

Is my description of the actor model right?

If I understood, the actor model is just like the object model, but with a few differences: EVERY object spawns it's own separate thread and its not a problem even when you have thousands of ...
12
votes
8answers
2k views

Why should I know concurrent programming?

Concurrent programming is quite difficult to me: even looking at a basic slide seems challenging to me. It seems so abstract. What are the benefits to knowing Concurrent programming concepts well? ...
11
votes
2answers
1k views

SQLite with two python processes accessing it: one reading, one writing

I'm developing a small system with two components: one polls data from an internet resource and translates it into sql data to persist it locally; the second one reads that sql data from the local ...
13
votes
3answers
7k views

UML Diagrams of Multi-Threaded Applications

For single-threaded applications I like to use class diagrams to get an overview of the architecture of that application. This type of diagram, however, hasn’t been very helpful when trying to ...
1
vote
1answer
179 views

How do I find a good middle way to make this library safe for concurrent operations

I've made a little library called SignalR.EventAggregatorProxy Before I push it into 1.0 state I need to fix so it works safely with concurrent operations. Easiest way is lock all operations but ...
9
votes
2answers
992 views

Is The Free Lunch Over? [closed]

In his famous The Free Lunch Is Over article from 2005, Herb Sutter predicted a Concurrent Programming Revolution as big as Object-Oriented Revolution. Has this revolution really happend in years 2005 ...
3
votes
1answer
303 views

What do goroutines, Ruby Fibers, etc. look like to the OS/Kernel?

In process concurrency and thread concurrency it's quite obvious how the kernel sees these as they map directly to real things that the kernel manages. When it comes to Golang goroutines and Ruby ...
31
votes
5answers
7k views

Is object pooling a deprecated technique?

I am very familiar with the concept of object pooling and I always try to use it as much as possible. Additionally I always thought that object pooling is the standard norm as I have observed that ...
0
votes
1answer
192 views

Handling or preventing conflicts in a multi-user system

I have a web application that is accessed by multiple users from different locations worldwide. Let's say I have an "edit" form for a specific document and two (or more) users are editing the document ...
0
votes
1answer
262 views

Apple Dispatch Queue vs Threads

I've heard a lot about apple's famous dispatch queues and the GCD but today was the first time I decided to understand exactly what is going on, so I started reading Concurrency Programming Guide and ...
7
votes
1answer
2k views

Erlang and Go concurrent programming, objective differences between CSP and Actors?

I was looking into concurrent programming in Erlang and Go programming languages. As per my finding they are used Actor model and CSP respectively. But still I am confused with what are the objective ...
5
votes
1answer
289 views

How can I benchmark concurrent key-value stores?

I have some concurrent key-value store implementations that are implemented with hash tables and search trees that I would like to compare. I would like to benchmark them with a real world application ...
6
votes
3answers
1k views

How many threads should access the file system at the same time?

We have a module in an application which stores data in multiple files and multilevel directories and access them from multiple threads (both reads and writes). The directory structure is based on a ...
9
votes
2answers
672 views

Uses of persistent data structures in non-functional languages

Languages that are purely functional or near-purely functional benefit from persistent data structures because they are immutable and fit well with the stateless style of functional programming. But ...
1
vote
3answers
2k views

How can I multiprocess my program?

I wrote a program which scrape internet sites. It is pretty straigtforward because it process link one by one. With the limiting factor of the internet speed, the process is rather slow. I wonder, ...
29
votes
16answers
6k views

Modern programming language with intuitive concurrent programming abstractions

I am interested in learning concurrent programming, focusing on the application/user level (not system programming). I am looking for a modern high level programming language that provides intuitive ...
8
votes
2answers
649 views

Would Task-based programming in C++ require new language standard features?

So I saw this video on Youtube with all these C++ masters on GoingNative 2012 : Interactive panel where everybody could ask the questions. This is the video I was talking about: GoingNative 2012 - ...
2
votes
3answers
787 views

What are the consequences of immutable classes with references to mutable classes?

I've recently begun adopting the best practice of designing my classes to be immutable per Effective Java [Bloch2008]. I have a series of interrelated questions about degrees of mutability and their ...
0
votes
3answers
470 views

Multiple threads and single output source

For the sake of an exercise, say you have an input file with a series of lines of text with the objective of reversing their respective character sequences. Now introduce 5 threads that will each do ...
10
votes
4answers
6k views

The difference between “concurrent” and “parallel” execution?

What is the difference between the terms concurrent and parallel execution? I've never quite been able to grasp the distinction. The tag defines concurrency as a manner of running two processes ...
18
votes
3answers
1k views

Why five dining philosophers?

I was wondering why the Dining philosophers problem is based on a five philosophers case. Why not four? I guess that we can observe all unpleasant issues that can occur when discussing five ...
11
votes
2answers
3k views

Are these advanced/unfair interview questions regarding Java concurrency? [closed]

Here are some questions I've recently asked interviewees who say they know Java concurrency: Explain the hazard of "memory visibility" - the way the JVM can reorder certain operations on variables ...
0
votes
2answers
178 views

How bad would it be to obtain a lock on every object?

Imagine a hypothetical programming environment that is largely like Java or .NET, i.e. object-oriented, garbage-collected, etc., but with one small change: Every time you call a method on an object, ...
4
votes
2answers
349 views

What is a good script language for writing server administration tasks? [closed]

I am administering hundreds of RHEL servers. There are many daily tasks to perform. Right now I am working with bash scripting and python. I was wondering if other languages such as Erlang, Lua, Ruby, ...