concurrency Questions

8

Solved

I need to generate a unique numeric ID to attach to an incoming request. This ID is used only temporarily to track the request and will be discarded once the request has completed processing. This ...
Amyotonia asked 28/9, 2011 at 0:8

2

Solved

I have been playing around with Goroutines, Channels and WaitGroup today and I am finally starting to understand the concept, after just been reading about it for a while. My problem is that I am...
Nagana asked 28/11, 2019 at 19:59

9

Does SQLite3 safely handle concurrent access by multiple processes reading/writing from the same DB? Are there any platform exceptions to that?
Philanthropist asked 30/10, 2010 at 21:33

3

Solved

While researching the use of Table Hints, I came across these two questions: Which lock hints should I use (T-SQL)? What effect does HOLDLOCK have on UPDLOCK? Answers to both questions say that...
Starch asked 21/10, 2011 at 0:12

2

I understand that we're to use context propagation to get the parent traceids and spans created as children of each other, but my publisher is using headers (nats not http) My message broker uses h...
Attract asked 16/12, 2021 at 11:13

2

I am trying to implement a reliable queue with multiple writers and a multiple readers using postgres database. How to avoid missing rows when a queue reader scans a table then in-progress transact...
Hallie asked 5/10, 2015 at 10:54

7

Solved

Anecdotally, I've found that a lot of programmers mistakenly believe that "lock-free" simply means "concurrent programming without mutexes". Usually, there's also a correlated misunderstanding that...
Unsearchable asked 27/8, 2017 at 16:50

2

I am trying to evaluate Google Apps Script (GAS) as one of the component in my overall SaaS. But, I see there is quota limits. https://developers.google.com/apps-script/guides/services/quotas#curre...

2

I am facing this issue for the past 1 week and I am just confused about this. Keeping it short and simple to explain the problem. We have an in memory Model which stores values like budget etc.Now...
Intitule asked 18/8, 2017 at 11:24

6

I need to keep making many requests to about 150 APIs, on different servers. I work with trading, where time is crucial. I cannot waste 1 millisecond. The solution and problems I found were these: ...
Popup asked 20/7, 2019 at 15:50

3

Solved

I know that we wait with await and execute a task without need to wait with async let, but I can't understand the difference between these two calls: async let resultA = myAsyncFunc() async let res...
Debark asked 8/3, 2024 at 7:32

11

Solved

HashSet is based on HashMap. If we look at HashSet<E> implementation, everything is been managed under HashMap<E,Object>. <E> is used as a key of HashMap. And we know that Hash...
Bainbridge asked 9/8, 2011 at 7:14

18

GNU bash, version 1.14.7(1) I have a script is called "abc.sh" I have to check this from abc.sh script only... inside it I have written following statement status=`ps -efww | grep -w "abc.sh" | g...
Daley asked 29/5, 2013 at 7:25

3

Solved

I have web application, in which I have used Spring framework. For the concurrent session control I have use spring feature where only 1 logged in session will be maintained for 1 user as soon as t...
Phare asked 26/4, 2012 at 6:30

2

Solved

Please find the code: Task{ let value = await doSomething() } I tried using DispatchQueue, but how to guarantee if UI updates should be done on main thread. Task{ DispatchQueue.main.async{ let ...
Cosecant asked 13/4, 2023 at 3:44

2

Solved

I'm a go-newbie, so please be gentle. So I've been using mutexes in some of my code for a couple weeks now. I understand the concept behind it: lock access to a certain resource, interact with it...
Shuttering asked 22/6, 2019 at 21:39

4

Solved

I have a slice that contains work to be done, and a slice that will contain the results when everything is done. The following is a sketch of my general process: var results = make([]Result, len(j...
Republicanism asked 17/4, 2018 at 13:23

19

Solved

When writing multithreaded applications, one of the most common problems experienced is race conditions. My questions to the community are: What is the race condition? How do you detect them? How ...

7

Solved

I'm unable to debug one error myself. I'm running python 3.8.12 inside docker image on Fedora release 35 (Thirty Five) and I'm unable to spawn threads from python. It's required for boto3 transfer ...
Orthicon asked 23/11, 2021 at 20:23

8

Solved

Is there any advantage of using java.util.concurrent.CountdownLatch instead of java.util.concurrent.Semaphore? As far as I can tell the following fragments are almost equivalent: 1. Semaphor...
Marasmus asked 8/10, 2008 at 18:25

8

Solved

I know that CompletableFuture design does not control its execution with interruptions, but I suppose some of you might have this problem. CompletableFutures are very good way to compose async exec...
Cornstalk asked 12/3, 2015 at 15:27

3

The documentation for asyncio gives two examples for how to print "Hello World" every two seconds: https://docs.python.org/3/library/asyncio-eventloop.html#asyncio-hello-world-callback https://docs...
Princely asked 9/10, 2014 at 5:3

2

Solved

Is there a data structure similar to ConcurrentDictionary<TKey,TValue> and Interlocked.Exchange<T>(...) that would allow you atomically to set a new value and retrieve the old value ass...
Yezd asked 17/1, 2024 at 22:16

11

Solved

I have code which implements a "lock handler" for arbitrary keys. Given a key, it ensures that only one thread at a time can process that(or equals) key (which here means calling the externalSystem...
Boony asked 27/1, 2017 at 16:13

4

Solved

Here are two potential workflows I would like to perform in a web application. Variation 1 user sends request server reads data server modifies data server saves modified data Variation 2: u...
Across asked 28/8, 2011 at 20:51

© 2022 - 2025 — McMap. All rights reserved.