common variable in a more than one process ?

P

Pokkai Dokkai

is there any way to access a common variable in more than one processes
which are created in ruby ?

or

can we access a global variable or class variable into more than one
processes..
 
R

Robert Klemme

is there any way to access a common variable in more than one processes
which are created in ruby ?

or

can we access a global variable or class variable into more than one
processes..

Depends on the usage. For values that change often you could use DRb.

Cheers

robert
 
M

Marcin Raczkowski

You can set variables before fork.

but if you want to change them you should probably check SystemVIPC (on
inux and cygwin) or drb
 

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,999
Messages
2,570,243
Members
46,836
Latest member
login dogas

Latest Threads

Top