Commit Graph

378 Commits

Author SHA1 Message Date
Michael Stack 66e545adf0 HBASE-598 Loggging, no .log file; all goes into .out
git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@649938 13f79535-47bb-0310-9956-ffa450edef68
2008-04-20 15:40:07 +00:00
Jim Kellerman 5af9719de3 HBASE-10 HRegionServer hangs upon exit due to DFSClient Exception
git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@649373 13f79535-47bb-0310-9956-ffa450edef68
2008-04-18 05:32:23 +00:00
Michael Stack 373761483f HBASE-532 Odd interaction between HRegion.get, HRegion.deleteAll and compactions
git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@648850 13f79535-47bb-0310-9956-ffa450edef68
2008-04-16 21:07:32 +00:00
Michael Stack 9ad3122021 HBASE-582 HBase 554 forgot to clear results on each iteration caused by a filter
git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@648798 13f79535-47bb-0310-9956-ffa450edef68
2008-04-16 19:23:41 +00:00
Jim Kellerman baa84cb4a1 HBASE-575 master dies with stack overflow error if rootdir isn't qualified
git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@648427 13f79535-47bb-0310-9956-ffa450edef68
2008-04-15 21:45:28 +00:00
Michael Stack 863ac0c605 HBASE-559 MR example job to count table rows
git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@648422 13f79535-47bb-0310-9956-ffa450edef68
2008-04-15 21:39:20 +00:00
Michael Stack 82901024c9 HBASE-12 when hbase regionserver restarts, it says "impossible state for createLease()"
git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@648110 13f79535-47bb-0310-9956-ffa450edef68
2008-04-15 03:36:39 +00:00
Jim Kellerman 9a80650d97 HBASE-11 Unexpected exits corrupt DFS
git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@648030 13f79535-47bb-0310-9956-ffa450edef68
2008-04-14 22:07:11 +00:00
Michael Stack 73f126dbe9 HBASE-573 HBase does not read hadoop-*.xml for dfs configuration after moving out hadoop/contrib
git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@647989 13f79535-47bb-0310-9956-ffa450edef68
2008-04-14 20:33:03 +00:00
Jim Kellerman bc4b9b2c1c Update CHANGES.txt - bug fix was listed in wrong section
git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@647963 13f79535-47bb-0310-9956-ffa450edef68
2008-04-14 19:36:44 +00:00
Michael Stack 1475f271cf HBASE-574 HBase does not load hadoop native libs
git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@647959 13f79535-47bb-0310-9956-ffa450edef68
2008-04-14 19:34:11 +00:00
Jim Kellerman 278bd7e772 NPE getting scanner
git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@647953 13f79535-47bb-0310-9956-ffa450edef68
2008-04-14 19:27:17 +00:00
Bryan Duxbury fd202765c9 HBASE-523 package-level javadoc should have example client
-updated docs

git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@646105 13f79535-47bb-0310-9956-ffa450edef68
2008-04-08 22:22:45 +00:00
Bryan Duxbury efce1b3d09 HBASE-521 Improve client scanner interface
-Removed HScannerInterface and HInternalScannerInterface
-Created new interfaces Scanner for clients and InternalScanner for internal consumers
-Internal and client scanners no longer share common interface
-Client scanner's next() method and iterables are in RowResults
-Updated tests and internal consumers to use Scanner in place of HScannerInterface
-HTable obtainScanner(*) are now renamed getScanner(*)
-Tests have ScannerIncommon to turn Scanners into InternalScanners for some tests
-Fixed a bug in HMaster that was eating TableExistsExceptions (unrelated)
-Updated TableInputFormat to provide RowResults instead of MapWritables
-Updated TableOutputFormat to take BatchUpdates instead of MapWritables
-Updated TableMap, TableReduce, and friends to correctly hook up to new input/output formats

HBASE-567   Reused BatchUpdate instances accumulate BatchOperations
- Fix to BatchUpdate that allows correct reuse of BatchUpdate instances (readFields didn't clear BatchOperation map)
- Update TestSerialization to prove above is fixed


git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@646104 13f79535-47bb-0310-9956-ffa450edef68
2008-04-08 22:17:51 +00:00
Jim Kellerman 53563c5586 HBASE-554 filters generate StackOverflowException - fix typo other commit went to 544
git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@646033 13f79535-47bb-0310-9956-ffa450edef68
2008-04-08 18:59:06 +00:00
Jim Kellerman 6410feb071 HBASE-544 filters generate StackOverflowException
git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@646031 13f79535-47bb-0310-9956-ffa450edef68
2008-04-08 18:56:36 +00:00
Bryan Duxbury 49e0eaf8d9 HBASE-512 Add configuration for global aggregate memcache size
-Refactored Flusher slightly, added reclaimMemcacheMemory method
-HRegionServer calls reclaimMemcacheMemory during batchUpdates
-Added TestGlobalMemcacheLimit to verify new functionality 
-Added new config parameter defaults to hbase-default.xml

git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@645740 13f79535-47bb-0310-9956-ffa450edef68
2008-04-08 00:09:20 +00:00
Jim Kellerman 7813444a9b HBASE-564 Don't do a cache flush if there are zero entries in the cache.
git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@645690 13f79535-47bb-0310-9956-ffa450edef68
2008-04-07 21:08:48 +00:00
Jim Kellerman 2da5e018af HBASE-507 Use Callable pattern to sleep between retries
git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@645014 13f79535-47bb-0310-9956-ffa450edef68
2008-04-05 02:15:34 +00:00
Jim Kellerman 9c3fba564c HBASE-563 TestRowFilterAfterWrite erroneously sets master address to 0.0.0.0:60100 rather than relying on conf
git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@644948 13f79535-47bb-0310-9956-ffa450edef68
2008-04-04 21:55:47 +00:00
Jim Kellerman 1e3705f750 HBASE-541 Update hadoop jars.
git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@644905 13f79535-47bb-0310-9956-ffa450edef68
2008-04-04 20:48:46 +00:00
Bryan Duxbury 9ea7aec67d HBASE-452 "region offline" should throw IOException, not IllegalStateException
-HConnectionManager#locateRegionInMeta no longer throws ISE, instead throws new RegionOfflineException
-Removed duplicated code for catching exceptions for retries

git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@644854 13f79535-47bb-0310-9956-ffa450edef68
2008-04-04 19:44:46 +00:00
Bryan Duxbury bb8dce00f2 HBASE-557 HTable.getRow() should receive RowResult objects
-Updated HRegionInterface, HRegionServer, HRegion, HStore to provide RowResults as the return of getRow methods
-Updated HTable to expect RowResult objects
-Updated ThriftServer to expect RowResults
-Cleaned up HConnectionManager's interaction with region servers

git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@644828 13f79535-47bb-0310-9956-ffa450edef68
2008-04-04 19:13:56 +00:00
Bryan Duxbury 0c3d5abbc8 HBASE-544 Purge startUpdate from all internal code and test cases
Removes startUpdate calls from all but a few places. TestBatchUpdate and TestMultipleUpdates both stay the same, but TMU will be removed when startUpdate is. Parts of TBU will also be whacked when we remove the deprecated methods. HTable still has its startUpdate methods.

Changed the Incommon interface to remove the startUpdate, put, delete, and commit methods, and made a new commit(BatchUpdate).

git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@644811 13f79535-47bb-0310-9956-ffa450edef68
2008-04-04 18:22:56 +00:00
Michael Stack 589a407f0c HBASE-561 HBase package does not include LICENSE.txt nor build.xml
git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@644536 13f79535-47bb-0310-9956-ffa450edef68
2008-04-03 22:39:46 +00:00
Bryan Duxbury 228fd03bac HBASE-71 [hbase] Master should rebalance region assignments periodically
git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@644441 13f79535-47bb-0310-9956-ffa450edef68
2008-04-03 19:03:59 +00:00
Jim Kellerman 6e225dd7f1 HBASE-469 Streamline HStore startup and compactions
HMerge, HRegionServer

- changes that reflect changes to HRegion, CompactSplitThread and Flusher methods

ServerManager

- Return zero length array to region server if it is exiting or quiesced and Master is not yet ready to shut down.

QueueEntry

- removed. no longer used.

CompactSplitThread

- make compactionQueue a queue of HRegion.
- Add Set<HRegion> so we can quickly determine if a region is in the queue. BlockingQueue.contains() does a linear scan of the queue.
- Add a lock and interruptPolitely methods so that compactions/splits in progress are not interrupted.
- Don't add a region to the queue if it is already present.

Flusher

- change queue from DelayQueue to BlockingQueue, with HRegion entries instead of QueueEntry.
- Add Set<HRegion> to quickly determine if a region is already in the queue to avoid linear scan of BlockingQueue.contains().
- Only put regions in the queue for optional cache flush if the last time they were flushed is older than now - optionalFlushInterval.
- Only add regions to the queue if it is not already present.

HRegion

- don't request a cache flush if one has already been requested.
- Add setLastFlushTime so flusher can set it once it has queued an optional flush.
- Replace largestHStore with getLargestHStoreSize: returns long instead of HStoreSize object.
- Add midKey as parameter to splitRegion.
- Reorder start of splitRegion so it doesn't do any work before validating parameters.
- Remove needsSplit and compactIfNeeded - no longer needed.
- compactStores now returns midKey if split is needed.
- snapshotMemcaches now sets flushRequested to false and sets lastFlushTime to now.
- update does not request a cache flush if one has already been requested.
- Override equals and hashCode so HRegions can be stored in a HashSet.

HStore

- loadHStoreFiles now computes max sequence id and the initial size of the store.
- Add getter for family.
- internalCacheFlush updates store size, and logs both size of cache flush and resulting map file size (with debug logging enabled).
- Remove needsCompaction and hasReferences - no longer needed.
- compact() returns midKey if store needs to be split.
- compact() does all checking before actually starting a compaction.
- If store size is greater than desiredMaxFileSize, compact returns the midKey for the store regardless of whether a compaction was actually done.
- Added more synchronization in completeCompaction while iterating over storeFiles.
- completeCompaction computes new store size.
- New method checkSplit replaces method size. Returns midKey if store needs to be split and can be split.

HStoreSize

- removed. No longer needed.

HBaseTestCase

- only set fs if it has not already been set by a subclass.

TestTableIndex, TestTableMapReduce

- call FSUtil.deleteFully to clean up cruft left in local fs, by MapReduce


git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@643761 13f79535-47bb-0310-9956-ffa450edef68
2008-04-02 06:58:26 +00:00
Michael Stack 92a8e04b85 git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@643621 13f79535-47bb-0310-9956-ffa450edef68 2008-04-01 22:12:23 +00:00
Michael Stack 6c124cd285 HBASE-548 Tool to online single region
M    branches/0.1/src/java/org/apache/hadoop/hbase/util/MetaUtils.java
M    trunk/src/java/org/apache/hadoop/hbase/util/MetaUtils.java
    (changeOnlineStatus): Added.



git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@643486 13f79535-47bb-0310-9956-ffa450edef68
2008-04-01 17:52:46 +00:00
Michael Stack f15048d4d0 HBASE-505 Region assignments should never time out so long as the region
server reports that it is processing the open request

This is patch reviewed with Jim but with the number of edits between
reports made into a configurable.

Have the HRegionServer pass down a Progressable implementation down into
Region and then down int Store where edits are replayed. Call progress
after every couple of thousand edits.

M src/java/org/apache/hadoop/hbase/HStore.java
  Take a Progessable in the constructor. Call it when applying edits.
M src/java/org/apache/hadoop/hbase/HMaster.java
  Update commment around MSG_REPORT_PROCESS_OPEN so its expected
  that we can get more than one of these messages during a region open.
M src/java/org/apache/hadoop/hbase/HRegion.java
  New constructor that takes a Progressable. Pass it to Stores on construction.
M src/java/org/apache/hadoop/hbase/HRegionServer.java
  On open of a region, pass in a Progressable that adds a
MSG_REPORT_PROCESS_OPEN every time its called.


git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@643223 13f79535-47bb-0310-9956-ffa450edef68
2008-04-01 00:09:25 +00:00
Michael Stack 198a156334 HBASE-551 Master stuck splitting server logs in shutdown loop;
on eachiteration, edits are aggregated up into the millions
M src/java/org/apache/hadoop/hbase/HLog.java
    (splitLog): If an exception processing a split, catch it.
    In finally, close and delete the split. Don't try retrying.
    While in some circumstance, we might recover, its also
    likely that we just get same exception again. If so, and
    multiple files, we'll just accumulate edits until the
    kingdom comes.


git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@643142 13f79535-47bb-0310-9956-ffa450edef68
2008-03-31 20:47:47 +00:00
Michael Stack 1197d65839 HBASE-550 EOF trying to read reconstruction log stops region deployment
M CHANGES.txt
    Fix mis-committed changelog.


git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@643113 13f79535-47bb-0310-9956-ffa450edef68
2008-03-31 19:34:09 +00:00
Michael Stack 53a6abfe6e HBASE-550 EOF trying to read reconstruction log stops region deployment
M  src/java/org/apache/hadoop/hbase/HStore.java
    (Constructor) If an exception out of reconstructionLog method, log it and
    keep going.  Presumption is that its result of a lack of HADOOP--1700.
    (reconstructionLog): Check for empty log file.


git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@643110 13f79535-47bb-0310-9956-ffa450edef68
2008-03-31 19:26:47 +00:00
Michael Stack 46ff7775f6 HBASE-534 Double-assignment at SPLIT-time
git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@640625 13f79535-47bb-0310-9956-ffa450edef68
2008-03-24 22:42:14 +00:00
Bryan Duxbury 65d961ae78 HBASE-536 Remove MiniDFS startup from MiniHBaseCluster
-Changed MiniHBaseCluster to not start up a MiniDFS
-Changed HBaseClusterTestCase to do the work of starting up a MiniDFS.
-Added pre and post setup method to HBaseClusterTestCase so you can control what happen before MiniHBaseCluster is booted up
-Converted AbstractMergeTestCase to be a HBaseClusterTestCase
-Converted any test that used a raw MIniDFS or MiniHBaseCluster to use HBaseClusterTestCase instead
-Split TestTimestamp into two tests - one for clientside (now in o.a.h.h.client) and one for serverside (o.a.h.h.regionserver)
-Merged in Stack's changes to make bin/hbase have hadoop jars first on the classpath
-Updated PerformanceEvaluation (in --miniCluster mode) to start up a DFS first
-Fixed a bug in BaseScanner that would have allowed NPEs to be generated


git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@640526 13f79535-47bb-0310-9956-ffa450edef68
2008-03-24 19:13:56 +00:00
Jim Kellerman aabe9f09a9 HBASE-476 RegexpRowFilter behaves incorectly when there are multiple store files (Clint Morgan via Jim Kellerman)
HBASE-527   RegexpRowFilter does not work when there are columns from multiple families (Clint Morgan via Jim Kellerman)


git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@640106 13f79535-47bb-0310-9956-ffa450edef68
2008-03-22 22:35:36 +00:00
Jim Kellerman e7b705a808 HBASE-537 Wait for hdfs to exit safe mode
git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@639858 13f79535-47bb-0310-9956-ffa450edef68
2008-03-21 21:31:23 +00:00
Jim Kellerman a9d8d51663 HBASE-531 Merge tool won't merge two overlapping regions (port HBASE-483 to trunk) (See HBASE-483 for list of changes)
git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@639775 13f79535-47bb-0310-9956-ffa450edef68
2008-03-21 19:46:34 +00:00
Michael Stack 9fa72c0177 HBASE-526 Add documentation src and build to the 0.1 branch
Second part of documentation commit.


git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@638612 13f79535-47bb-0310-9956-ffa450edef68
2008-03-18 22:32:14 +00:00
Bryan Duxbury feb4f2d2b6 HBASE-528 table 'does not exist' when it does
-Changed HStore and Memcache methods for computing closest row at or before
-Added more test cases for verifying this functionality
-Simplified the getClosestRowBefore interface so that it does not take timestamps
-Noted that getClosestRowBefore is assumed to work correctly ONLY on tables where updates are always with ascending timestamps (method is still not a part of HTable interface, so not available to clients)

git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@638598 13f79535-47bb-0310-9956-ffa450edef68
2008-03-18 21:48:22 +00:00
Bryan Duxbury f66e157e5e HBASE-529 RegionServer needs to recover if datanode goes down
-HLog will now try to reopen the log twice on append failure before taking the region server down

git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@638597 13f79535-47bb-0310-9956-ffa450edef68
2008-03-18 21:44:02 +00:00
Bryan Duxbury ea1ac1f75c HBASE-524 Problems with getFull
-Added new test case to exercise the problems
-Fixed getFull implementation in HStore and Memcache

git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@638525 13f79535-47bb-0310-9956-ffa450edef68
2008-03-18 19:34:33 +00:00
Bryan Duxbury f8fc7bdd77 HBASE-525 HTable.getRow(Text) does not work
-Fixed broken set initialization in HRegionServer

git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@638150 13f79535-47bb-0310-9956-ffa450edef68
2008-03-18 00:13:23 +00:00
Bryan Duxbury 37cf8a8cfb HBASE-506 When an exception has to escape ServerCallable due to exhausted retries, show all the exceptions that lead to this situation
-Updated ServerCallable to track a list of exceptions and report them all when the process runs out of retries

git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@637474 13f79535-47bb-0310-9956-ffa450edef68
2008-03-15 21:15:45 +00:00
Michael Stack 9a40223445 HBASE-515 At least double default timeouts between regionserver and master
git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@637179 13f79535-47bb-0310-9956-ffa450edef68
2008-03-14 17:47:49 +00:00
Jim Kellerman 5d4ed8436d HBASE-516 HStoreFile.finalKey does not update the final key if it is not the top region of a split region
Modified HStoreFile$HalfMapFileReader.finalKey

git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@637002 13f79535-47bb-0310-9956-ffa450edef68
2008-03-14 05:57:54 +00:00
Michael Stack c1f974bbee HBASE-501 Empty region server address in info:server entry and a startcode of -1 in .META.
M conf/hbase-default.xml
Add hbase.hbasemaster.maxregionopen property.
M src/java/org/apache/hadoop/hbase/HStore.java
Change way we log. Do way less. Just emit sums of edits applied
and skipped rather than individual edits.
M src/java/org/apache/hadoop/hbase/HRegionServer.java
Make sleeper instance a local rather than data member.
(reportForDuty): Take a sleeper instance.
(run): Removed redundant wrap of a 'for' by a 'while'.
(constructor): If IOE, do not offline the region. Seen to be
an overreaction.
M src/java/org/apache/hadoop/hbase/HLog.java
Don't output map of all files being cleaned everytime a new
entry is added; instead just log new entry. Remove emission
of every 10k edits.
M src/java/org/apache/hadoop/hbase/HMaster.java
Up default for maxregionopen. Was seeing that playing edits
could take a long time (mostly because we used log every
edit) but no harm in this being longer. On REPORT_CLOSE,
emit region info, not just region so can see the properties
(W/o, made it hard to figure who was responsible for offlining).
Add logging of attempt # in shutdown processing.
Add logging of state flags passed to the close region. Helps
debugging. Also in close offline ONLY if we are NOT reassigning
the region (jimk find).
M src/java/org/apache/hadoop/hbase/util/Sleeper.java
Add logging of extraordinary sleeps or calculated periods
(suspicion is that we're sleeping way longer on loaded machies
and the regionserver appears hung).


git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@636849 13f79535-47bb-0310-9956-ffa450edef68
2008-03-13 19:37:21 +00:00
Bryan Duxbury 8c815c72f4 HBASE-443 Move internal classes out of HStore
-Moved out classes Memcache, StoreFileScanner, MapFileCompactionReader, and HStoreScanner, and interface CompactionReader
-Updated TestHMemcache to use the correct type declaration.

git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@636815 13f79535-47bb-0310-9956-ffa450edef68
2008-03-13 18:06:08 +00:00
Jim Kellerman 9057e559a1 HBASE-27 hregioninfo cell empty in meta table
Summary of changes:

HMaster:

- When a row has an empty HRegionInfo (info:regioninfo), log it with the row name and and the other keys still in the row.

- Log the number of rows with empty HRegionInfo

- Delete the rows

- Make RowMap inner class static, change methods to have package scope to avoid synthetic accessors.

- Provide row name to getHRegionInfo so it can issue better log messages

- add method deleteEmptyMetaRows to remove rows with empty HRegionInfo

HRegion

- change removeRegionFromMETA to use deleteAll rather than using a BatchUpdate containing deletes for each cell.

TestEmptyMetaInfo

- new test case



git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@636589 13f79535-47bb-0310-9956-ffa450edef68
2008-03-13 00:33:13 +00:00
Bryan Duxbury 6fb7767fc6 HBASE-40 [hbase] Add a method of getting multiple (but not all) cells for a row at once
-new override of getRow added to the whole stack
-test for new override added to TestGet2

git-svn-id: https://svn.apache.org/repos/asf/hadoop/hbase/trunk@636415 13f79535-47bb-0310-9956-ffa450edef68
2008-03-12 16:58:10 +00:00