Boost logo

Boost :

Subject: Re: [boost] RFC - Updated MapReduce library
From: Craig Henderson (cdm.henderson_at_[hidden])
Date: 2009-08-09 12:37:20


> > My point is that if it is an
> > instance of a functor, then the developer may be tempted to presume a
> state
> > of the object and store instance data. This is invalid as the map
> task
> > object is created, used and then destroyed. Any attempt to share data
> > between map objects breaks the MapReduce design and scalability
> properties
> > (which need to be preserved for loyalty to the MapReduce paradigm and
> for
> > future multi-machine scalability).
> >
> Well that's a problem with any kind of functor anyway. There is the
> same
> problem with Boost.Thread where you should be aware of the internal
> copy
> of the functor object etc...
>
> Just document what happens with the functor I guess.

But my static method interface solves the problem. Is that not better than
documenting a side-effect?

Regards
-- Craig


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk