about daemons and IPC

S

sdistefano

Hey people!
For the first time I'm doing a client/server application, and I'm
really confused with IPC stuff.

I read the fastest method is shared memory, but I tryed mmap and found
it tedious for the amount of data I'm handling (which is 30K at most,
but mmap seems to get tedious for anything bigger than a boolean... am
I missing something?)

Then I found many solutions for forked processes (like posh), but
that's not what I need right now.

Any suggestions?
 
P

Paul Rubin

For the first time I'm doing a client/server application, and I'm
really confused with IPC stuff.

Client-server applications are traditionally done with sockets.
I read the fastest method is shared memory, but I tryed mmap and found
it tedious for the amount of data I'm handling (which is 30K at most,
but mmap seems to get tedious for anything bigger than a boolean... am
I missing something?)

Mmap is missing any kind of locks, semaphores, etc. There was an shm
module that included this stuff but I don't know what's happened to it.
It's really unfortunate that it was never included with Python.
 
G

Gabriel Genellina

At said:
Hey people!
For the first time I'm doing a client/server application, and I'm
really confused with IPC stuff.

I read the fastest method is shared memory, but I tryed mmap and found
it tedious for the amount of data I'm handling (which is 30K at most,
but mmap seems to get tedious for anything bigger than a boolean... am
I missing something?)

I'm a bit confused - you mean client/server running both on the same
machine, right? Else, shared memory is of no use.
Sockets are used, usually, but depends on your needs.
Then I found many solutions for forked processes (like posh), but
that's not what I need right now.

Perhaps you can tell what you are trying to do...?


Gabriel Genellina
Softlab SRL





__________________________________________________
Preguntá. Respondé. Descubrí.
Todo lo que querías saber, y lo que ni imaginabas,
está en Yahoo! Respuestas (Beta).
¡Probalo ya!
http://www.yahoo.com.ar/respuestas
 
F

flupke

(e-mail address removed) schreef:
Hey people!
For the first time I'm doing a client/server application, and I'm
really confused with IPC stuff.

I read the fastest method is shared memory, but I tryed mmap and found
it tedious for the amount of data I'm handling (which is 30K at most,
but mmap seems to get tedious for anything bigger than a boolean... am
I missing something?)

Then I found many solutions for forked processes (like posh), but
that's not what I need right now.

Any suggestions?

You can also use RPC or even use a framework to do that for you like
Twisted. I like both approaches because they simplify communications.
For Twisted you have the initial investement in getting to know it but
it's also a lot more versatile
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,582
Members
45,057
Latest member
KetoBeezACVGummies

Latest Threads

Top