There is no such thing really in 0.20.6. I suppose you could do a pre-scan of the table entries up in .META. and if you couldn't find the region with the empty end key, then you'd know the table wasn't on line. There is nothing in 0.90.0 either but in 0.90.0 there is a notion of 'is_enabling' and we could set this flag up in zk while the table is coming online. Your client could poll for is_enabled. St.Ack
On Thu, Jan 6, 2011 at 3:12 PM, Nanheng Wu <[email protected]> wrote: > Yes, it only seconds. Just for several seconds I can see the table in > the HBase UI but when I clicked through it I got an error about no > entries were found in the .META. table. I guess it's not too bad since > it's only a few seconds but a mechanism to know for sure when all the > entries are loaded in .META. would be very helpful. > > On Thu, Jan 6, 2011 at 2:42 PM, Stack <[email protected]> wrote: >> On Thu, Jan 6, 2011 at 10:17 AM, Nanheng Wu <[email protected]> wrote: >>> Thanks for the answer Todd. I realized that I was making my life >>> harder by using the low level record writer directly. Instead I just >>> made the mapper output a <ImmutableBytesWriteable, KeyValue> pair and >>> set the output format to HFileOutputFormat. It works really great! I >>> have a follow up question, after I run the loadtable.rb script it >>> looks a little while before the table is actually ready to be queried. >>> Is there a way to programmatically test if the table is "ready"? I am >>> using hbase-0.20.6. Thanks! >>> >> >> What is taking the time? Is it that there are a bunch of a regions >> and they don't come on atomically but rather one at a time. When you >> say 'while' in the above, you are talking about seconds, right? >> (IIRC, all loadtable is doing is adding entries to .META. -- though it >> may also be moving files into place). >> >> St.Ack >> >
