No.  Bags are written with the explicit assumption that once reading begins, 
there will never be another write to the bag.  This simplifies a lot of the 
code in the bags as far as spilling.

Alan.

On Feb 13, 2012, at 6:19 PM, Jonathan Coveney wrote:

> I feel like the answer is that it is not safe, but I'd like to make sure.
> IE is the following ok, and if it is not, why not?
> 
> public DataBag exec(Tuple input) throws IOException {
>  DataBag bag = (DataBag)input.get(0);
>  long index=0;
>  for (Tuple tuple : bag) {
>    tuple.append(index++);
>  }
>  return bag;
> }
> 
> Appreciate the guidance.

Reply via email to