ipc

std::stringstream bugs?

I've got my own DLL which is being injected into another process. From the other process, the DLL sends IPC messages via boost::message_queue to my application. I'm using std::stringstream to construct the messages, as following: class Client { ... private: template <class T> void AddMessageParameter(const T &m) ...

What mechanism do PIPES use to "wake up" the recipient?

I have two questions is one here. On Windows, I am familiar with pipes and how they work. However, I am curious as to what mechanism the OS uses to notify the recipient thread of a message arrival. Does the thread "poll & sleep" continuously for data? Does the OS check to see if the thread is sleeping and wake it up? Or is there some o...

ssh is insisting on reading the password from the console rather than stdin.

This is what I'm doing: ssh_ = new Process(); ssh_.StartInfo.FileName = SshProvider; ssh_.StartInfo.Arguments = "-t -t " + Environment.UserName + "@" + serverName_; ssh_.StartInfo.UseShellExecute = false; ssh_.StartInfo.RedirectStandardInput = true; ssh_.StartInfo.RedirectStandardOutput = true; ssh_.StartInfo.RedirectStand...

IPC (inter process communication) between python and java

Hello, First, a little explanation of why I'm asking this question in the first place: I'm writing a python program (with a wxPython gui) that needs to call a Java AWT program from python and extract data from it. I have an in-process working solution on Windows. I also have an in-process solution on OSX so long as I run the Java app he...

C# IPC Recommendations and comparisons

I've been working in .net for a few years, and this is my first foray into IPC. I know of the various possibilities for doing IPC (Named Pipes, Remoting, Clipboard Managment, Win32API messaging), but I don't know whats "right for me". I plan on using the following setup: Site Object: This is the reason the ipc is needed. It will be ...

Can AsyncCallback use a non-static delegate?

I'm using .net remoting, with asynchronous function calls to handle the ipc of my current project. I'm running into an issue where I'd like the client to: ASynchronously request information Continue loading the GUI When the ASynchronous call is complete, load it into the gui I do this with the following code GetFileTextDelegat...

Calling .NET from Perl

I have a Perl script and needed to call a method that's in a .NET assembly. I found this technique but it's quite involved for a one-off Perl script so I didn't use it. I ended up writing a trivial .NET console app as a wrapper for the call I need and have my Perl script communicate with the wrapper, using Console.In / Console.Out / IP...

IPC solutions for Python processes on POSIX compliant system

Hi all, I have two Python processes that need to communicate with each other on POSIX complaint system, as an IPC I thought that using a named pipe would be the easiest solution, however since I'm new with Python I suspect there are more options available. Anyone care to make a recommendation, besides a named pipe? Thanks in advance, ...

C# Remoting IPC, how to test if remote application is running?

Good morning everyone! I'm doing a distributed application using .NET 4.0, C# and Remoting (IPC at the moment but that may change, Object is WellKnownObjectMode.Singleton). Upon startup of the client I'd like to test whether the server is up and running. What would be the best practice to implement this? Call any one method? Impleme...

Boost::Signals encapsulation over network

I am currently involved in the development of a software using distributed computing to detect different events. The current approach is : a dozen of threads are running simultaneously on different (physical) computers. Each event is assigned a number ; and every thread broadcasts its detected events to the other and filters the releva...

Named pipes - Problem with write() and read()

Hi, I am doing programming in C++, under LINUX. I have two independent processes. I should provide communication using named pipe. Reader: -creates FIFO using mkfifo - status = mkfifo(myFIFO, 0666) -opens the pipe using open - fifo = open (myFIFO,O_RDONLY) -reads from the pipe - num = read(fifo, temp, sizeof(temp)) Writer: -opens pi...

Receiving from message queues

I have successfully created the message queue by using the following command: msgIdHareTurtle = msgget(keyHareTurtle, 0644 | IPC_CREAT | O_NONBLOCK); Now I want to send the queue to some other process I used, msgsnd(msgIdHareTurtle, (struct msgbuf *)&bufHareTurtle, sizeof(int), IPC_NOWAIT); and I try to receive it in different...

Winsock structure to store path for IPC.

In unix the sockaddr_un structure exists to hold a path. Is there some windows equivalent. I've been looking all over the place and haven't found anything. ...

Named pipes: Many clients. How to be prudent with thread creation? Thread Pool?

Situation: I'm am using named pipes on Windows for IPC, using C++. The server creates a named pipe instance via CreateNamedPipe, and waits for clients to connect via ConnectNamedPipe. Everytime a client calls CreateFile to access the named pipe, the server creates a thread using CreateThread to service that client. After that, the ser...

IPC recommendation for "Dump-and-run" Client + "Take-It-Slow" Server

I am currently reading about IPC on Windows, and I would like to seek some opinions and recommendations for implementing the following system, which I think is probably quite typical! :) Clients generates in-memory data at a maximum rate of about 1kb/sec. Ideally, the IPC implementation allows clients to dump these data to a temporary d...

Can I/O completion port help with database instead of File writes?

I am reading up on IOCP, and from what I understand so far, the asynchronous writes only apply in the context of writing to Files. By "Files", I don't mean just disk file, but "File" type output devices on Windows. I am planning to somehow use IOCP in implementing a server that takes messages from clients and then writes those messages ...

GREF increasing / decreasing in multi-threaded service (aidl) - what does it mean?

I have an android activity and a service implemented using aidl. Works like a champ, I have a callback setup to pass some thread notifications back to the UI, and that appears to work fine, with the exception of lots of GREF has increased to 101, 201,301,401, 501.. etc, and GREF has decreased. I did some searching online and found that ...

pipe vs msg queue

what is the practical difference between message queues and a pipe in Linux? ...

How to perform inter-process(not thread) stream sharing with directshow?

Hi there I've succeeded to capture live video stream from my camera with directshow. But how can I share the stream to another process, any ideas? RGS! UPDATE Can illustrate with some code samples? ...

high-level IPC library needed

Hi, Suppose that we have four process A, B, C, and D. Usually, B-D send packets to A and get a reply from A. (The packet represents a simple command, so it is very small) However, sometimes, 'A' broadcasts an event, so that all of B-D should be notified. At first glance, My mind came up with 'dbus'. Unfortunately, we need a open so...