accumulo-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Josh Elser <josh.el...@gmail.com>
Subject Re: Write to table from Accumulo iterator
Date Sun, 27 Apr 2014 02:34:14 GMT
Sure, if you look at the interface on SortedKeyValueIterator, the only 
"lifecycle" type methods are init and deepCopy. In other words, you have 
some control over when to create a BatchWriter, but you don't know when 
Accumulo is going to tear down that iterator and stop using it.

You could always create/use/close a batchwriter in an iterator without 
issue; however, it'll be difficult to keep a single BatchWriter alive 
for the desired lifecycle.

In practice, Accumulo's lifecycle for a SKVI is either timeout related 
or related to how often the buffer of results between server and client 
fill. Normally, the case is when the buffer of results between server 
and client fills, Accumulo will tear down scan, and thus, your iterator.

On 4/26/14, 10:26 PM, BlackJack76 wrote:
> Josh,
>
> Thank you very much for thinking about this more.  I appreciate your
> feedback.
>
> You are probably much more familiar with Accumulo and the BatchWriters than
> I am.  As long as you open and properly close the BatchWriter in each
> iterator then where do you envision a leak would occur?  I think I am
> missing something.  Again, appreciate your insight.
>
>
>
> --
> View this message in context: http://apache-accumulo.1065345.n5.nabble.com/Write-to-table-from-Accumulo-iterator-tp9412p9430.html
> Sent from the Users mailing list archive at Nabble.com.
>

Mime
View raw message