Application with communication between process

Hello

I would like to create an application with communication between processes,
application tightly coupled, have you please an idea about an API or
a tool that allows me to generate such application?

Thank you so much

in which language u want to create application?

1 Like

in C

Thank you

Have a look at ZeroMQ. It's flexible and while you should still understand the underlying transport mechanism (sockets etc.) it will save you a lot of time.

The Intelligent Transport Layer - zeromq

2 Likes

in a search I saw the Posix API socket, have you an idea about this API?
thank you so much

I would assume that it meant that the programme made use of the POSIX versions of bind(), listen(), accept(), connect(), receive(), etc. calls.

1 Like

ZeroMQ, as suggested by agama, is surely a good tool, but I'd like to ask a question first: what exactly do you want to do and in which environment should it take place?

Inter-process communication (IPC) is a wide field and for some purposes a simple semaphor is enough while for others one needs shared memory, sockets and whatnot.

Without understanding what exactly you are trying to achieve it is hard to suggest anything.

I hope this helps.

bakunin

1 Like

Thank you very much for help

My problem is: I want to create an application strongly coupled (with inter-process communication) in C to do it's checkpoint, I have to saved the state of the process and also the state of communication channel..

Thank you so much

Sorry, to ask again, but: what do you want to do - or, to phrase it differently, what is the application supposed to do?

OK, it should be "strongly coupled", i have understood that, but: what is it to do that needs strong coupling? "to do its checkpoint" as you said is not understandable for me (and probably for the others here too).

I can understand if you don't want to disclose your ideas but in this case you should be aware that our help will be of very limited value if of any value at all.

bakunin

1 Like

Thank you very much for your answers
I'm sorry if I have not explained my problem well

I want do the checkpoint of an application strongly coupled
that is my goal(developping a tool that does the checkpoint of
this application)

As a first step:I have to create such application ,that's why i ask about an api which let me to have such application

Thank you so much for help

OK, maybe I am a bit slow, but i haven't understood what you mean the first time and i don't understand it now.

If i get you correctly you want to write an application. When this program comes to a certain point of its execution you want other applications (parallel running instances of the same application?) be aware of that fact. Is that correct?

If so, then a simple semaphore file would suffice, yes? You simply create this file and query its existence from the other instances you run. This would be a "passive" (polling) approach.

The "active" variant would be that the application doesn't set a flag (the file) and wait for other instances to become aware of its existence, but actively notify the other instances. You could use a signal for this. When the program gets to the certain point it will work through a list of PIDs with the programs to notify and send every one of them a certain signal (issue kill -l on your system for a list of supported signals, see the man page of sigaction() for how to install POISX-compliant signal handlers).

I hope this helps.

bakunin

1 Like

Thank you for your help
I want to write an application strongly coupled to each x seconds I save the state of this application on a storage medium for in case of failure of a node I restart the application from a checkpoint et not from the begining
As a first step: I have to create Such application (application strongly coupled), that's why i ask about an api Which let me To Have Such application

Thank you soooo much