[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

Fork me !

Alex Nedelcu

6/13/2006 2:11:00 AM

Hi,

can anyone give me a producer / consumer example written using forked
processes ?

I am new to the world of Linux and its process model, and I couldn't
understand how 2 processes can communicate between each other.

I found the example for IO.pipe
<http://www.ruby-doc.org/core/classes/IO.html#M..., but it is too
simple, and I really don't know how I can transform that into something
more complex.

Please help a newbie in distress :-)

6 Answers

Alex Nedelcu

6/13/2006 3:11:00 PM

0

wow ... not a single answer.
this list used to be a lot more active ... what the hell happened ?
something wrong with my question ?

Alex Nedelcu wrote:
> Hi,
>
> can anyone give me a producer / consumer example written using forked
> processes ?
>
> I am new to the world of Linux and its process model, and I couldn't
> understand how 2 processes can communicate between each other.
>
> I found the example for IO.pipe
> <http://www.ruby-doc.org/core/classes/IO.html#M..., but it is too
> simple, and I really don't know how I can transform that into something
> more complex.
>
> Please help a newbie in distress :-)

Robert Klemme

6/13/2006 7:57:00 PM

0

Alex Nedelcu wrote:
> wow ... not a single answer.
> this list used to be a lot more active ... what the hell happened ?
> something wrong with my question ?

Don't forget that the gateway is down and the number of readers likely
has decreased since then.

Producer consumer isn't too hard. And there are several ways to tackle
it. A simple way is to use DRb and use fork with block form. Maybe you
should be a bit more specific with your question to get better answers.
I believe also that there is plenty of documentation on the web - at
least about the general pattern.

Kind regards

robert

Alex Nedelcu

6/13/2006 10:44:00 PM

0

The gateway is still down ? That sucks.
Do you know when it will be back up ?
This is hurting the Ruby community.


Thank you for the hint to DRb ... that was usefull :)



Robert Klemme wrote:
> Alex Nedelcu wrote:
> > wow ... not a single answer.
> > this list used to be a lot more active ... what the hell happened ?
> > something wrong with my question ?
>
> Don't forget that the gateway is down and the number of readers likely
> has decreased since then.
>
> Producer consumer isn't too hard. And there are several ways to tackle
> it. A simple way is to use DRb and use fork with block form. Maybe you
> should be a bit more specific with your question to get better answers.
> I believe also that there is plenty of documentation on the web - at
> least about the general pattern.
>
> Kind regards
>
> robert

Dave Burt

6/14/2006 7:05:00 AM

0

Alex Nedelcu wrote:
> The gateway is still down ? That sucks.
> Do you know when it will be back up ?
> This is hurting the Ruby community.

I think you're mistaken -- most of the Ruby community's just not here,
it's at ruby-talk.

James Edward Gray II may be restoring the gateway in the next week or
two, or may be unable to, in which case it will remain nonexistent until
someone picks it up.

Note that you can join the ruby-talk mailing list easily by sending mail
to ruby-talk-ctl@ruby-lang.org with the body:

subscribe Your-First-Name Your-Last-Name

(Obviously, replace the two slugs with your actual names.)

Cheers,
Dave

Alex Nedelcu

6/14/2006 2:30:00 PM

0

OK, thank you for the tip :)

.... please forgive my newbie impressions.


Dave Burt wrote:
> I think you're mistaken -- most of the Ruby community's just not here,
> it's at ruby-talk.
>
> Cheers,
> Dave

Ray Tayek

6/14/2006 7:31:00 PM

0

In article <1150164654.193457.260490@u72g2000cwu.googlegroups.com>,
bellarchitects@gmail.com says...
> ... can anyone give me a producer / consumer example written using forked
> ... processes ?

http://www.rubycentral.com/book/tut_th...