synchronization Questions

4

Solved

When is it necessary to flush a file? I never do it because I call File.Close and I think that it is flushed automatically, isn't it?
Glaydsglaze asked 2/6, 2012 at 12:37

4

I'm trying to synchronize OpenLDAP and Active directory together. To do so I'm using a program called LSC-Project which is specified to do this sort of thing. I have configured the program the be...
Suiting asked 15/5, 2012 at 19:55

2

What exactly does the term synchronization primitive mean? For example: mutex, critical section, waitable timer, event, monitor, conditional variable, semaphore. Are all of them synchronization pri...

2

Solved

I am trying to understand the SynchronizedMap and I ran the below code. I get the below Output with an exception. According to my understanding the exception is caused when the get() methods are tr...
Briton asked 18/1, 2018 at 14:15

1

I was wondering where it would be best to ask about something like this, so I asked this question on Meta (https://meta.stackexchange.com/questions/304981) and was directed here, so here goes. I ...
Aristippus asked 24/12, 2017 at 0:22

5

Solved

I need the users to register to my website with login and password. basically i need to do the following 1.Connect android app with the database from a website. 2.Store some information into th...
Insipience asked 5/3, 2012 at 7:36

6

Solved

I am looking for quantitative estimates on clock offsets between VMs on Windows Azure - assuming that all VMs are hosted in the same datacenter. I am guesstimating that average clock offset between...
Palecek asked 26/5, 2011 at 13:5

3

Solved

Are there locks in Linux where the waiting queue is FIFO? This seems like such an obvious thing, and yet I just discovered that pthread mutexes aren't FIFO, and semaphores apparently aren't FIFO ei...
Participate asked 16/6, 2010 at 0:58

7

I have around 60 sockets and 20 threads and I want to make sure each thread works on different socket everytime so I don't want to share same socket between two threads at all. In my SocketManager...

1

Solved

Is to ok to combine all three variables into one struct? struct lock_struct { std::mutex mutex; std::conditional_variable cv; bool flag; }; Are there any hidden synchronization problems with ...
Filiate asked 4/12, 2017 at 10:20

3

Solved

I want to sync a local directory to a bucket in Google Cloud Storage. I want to copy the local files that do not exist remotely, skipping files that already exist both remote and local. Is this pos...
Sanferd asked 21/7, 2012 at 10:52

1

Solved

Let's say I have an opengl compute shader written in GLSL, executing on a NVidia Geforce 970. At the start of the shader, a single invocation writes to a "Shader Storage Buffer Object" (SSBO). I ...
Mathew asked 23/11, 2017 at 15:3

6

List<String> list = Collections.synchronizedList(new ArrayList<String>()); synchronized (list) { list.add("message"); } Is the block "synchronized (list){} " really need here ?
Statistics asked 27/2, 2012 at 16:8

7

I'm new to java. I'm little bit confused between Threadsafe and synchronized. Thread safe means that a method or class instance can be used by multiple threads at the same time without any problems...

2

First, I am aware that the mutexes are not considered async-safe normally. This question concerns the use of sigprocmask to make mutexes safe in a multithreaded program with async signals and signa...
Speckle asked 20/1, 2013 at 5:27

4

I have a code in which I am dealing with sockets and I need to make sure that I don't share same socket between two threads. In my below code, I have a background thread which runs every 60 s...

1

Solved

Does PHP provide a function to sleep in milliseconds? Right now, I'm doing something similar to this, as a workaround. $ms = 10000; $seconds = round($ms / 1000, 2); sleep($seconds); I'd l...
Outdate asked 2/11, 2017 at 3:29

1

I am running into the issue of what to do when a user does a delete, for example, while offline? I was considering using an addedQueue, modifiedQueue, and deletedQueue, and persisting them using NS...
Lapwing asked 27/10, 2016 at 19:4

4

Solved

I am using a boost::interpocess::scoped_lock using a named_mutex and a timeout; I am running in Linux OS. During one of my tests I had a crash: since then, everytime I try to run again the applica...

2

I have a requirement to sync local db data with central SQL server. The remote users (mostly around 10 people) will be using laptop which will host application and local db. The internet connection...

7

I want to know how to use synchronized blocks across classes. What I mean is, I want to have synchronized blocks in more than one class but they're all synchronizing on the same object. The only wa...
Sulla asked 16/7, 2014 at 2:2

0

This one is extension of Multiple nested request with scrapy . Asking because presented solution have flaws: 1. It iliminates asynchrony, thus heavily reducing scraping efficiency 2. Should excepti...
Primula asked 23/9, 2017 at 19:30

1

I have a client who has a very specific request for the app that requires two AVPlayers to be in sync. One video is for some content and the other one is for a presenter speaking about the content....
Crass asked 7/4, 2012 at 19:23

9

Solved

I have a Java Thread which exposes a property which other threads want to access: class MyThread extends Thread { private Foo foo; ... Foo getFoo() { return foo; } ... public void run() { ...

3

Solved

First a little context: I'm in the process of learning about threading in C++11 and for this purpose, I'm trying to build a small actor class, essentially (I left the exception handling and propaga...

© 2022 - 2024 — McMap. All rights reserved.