hbase-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stephen Boesch <java...@gmail.com>
Subject Re: Logging for HBase tests
Date Fri, 14 Nov 2014 21:15:32 GMT
I still have not been able to locate the testing logs output.  There are no
new directories/files created under the hbase distro directory at the time
the test is run, or under hbase-server.  The hbase book does not mention
this either.   http://hbase.apache.org/0.94/book/hbase.tests.html

The command line is the same as mentioned earlier:

mvn -Dmaven.surefire.debug="-Xdebug
-Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=5005 -Xnoagent
-Djava.compiler=NONE" test
-Dtest=TestTableSnapshotInputFormat#testInitTableSnapshotMapperJobConfig
-Dlog4j.configuration=file:$HBASE_HOME/hbase-server/src/test/resources/log4j.properties

2014-11-13 17:18 GMT-08:00 Stephen Boesch <javadba@gmail.com>:

> Hi Ted,
> as mentioned in that SOF post   (a) breakpoints are not respected when
> launched inside IJ (but they ARE respected when launching mvn command line)
>  and (b) logging is not working in both IJ and command line
>
> 2014-11-13 17:13 GMT-08:00 Ted Yu <yuzhihong@gmail.com>:
>
> TestTableSnapshotInputFormat is a unit test which you can run from your IDE
>> directly.
>>
>> BTW there was a typo in the command line below w.r.t. the test name.
>>
>> Cheers
>>
>> On Thu, Nov 13, 2014 at 4:57 PM, Stephen Boesch <javadba@gmail.com>
>> wrote:
>>
>> > How can logging be enabled/viewed when launching the hbase tests via
>> > command line maven?
>> >
>> > Given the following mvn command, I am able to set breakpoints within an
>> IDE
>> > (intellij):
>> >
>> > mvn -Dmaven.surefire.debug="-Xdebug
>> > -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=5005 -Xnoagent
>> > -Djava.compiler=NONE" test
>> > -Dtest=TestTleSnapshotInputFormat#testInitTableSnapshotMapperJobConfig
>> >
>> >
>> > However, there is no stdout/stderr or log4j output anywhere.
>> >
>> > The only output is the following (Note there an exception deep inside a
>> > create table test but the details are not displayed!)
>> >
>> > Listening for transport dt_socket at address: 5005
>> > Running org.apache.hadoop.hbase.mapred.TestTableSnapshotInputFormat
>> > 2014-11-13 16:40:27.560 java[47177:2496198] Unable to load realm info
>> from
>> > SCDynamicStore
>> > Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 178.141
>> sec
>> > <<< FAILURE!
>> >
>> > Note: the hbase-server/src/test/resources/log4j.properties has settings
>> > that are friendly to printing plenty of logging messages. But why are
>> the
>> > messages not generated?
>> >
>> > # Define some default values that can be overridden by system properties
>> > hbase.root.logger=INFO,console
>> > hbase.log.dir=.
>> > hbase.log.file=hbase.log
>> > ..
>> > # Logging Threshold
>> > log4j.threshhold=ALL
>> > ..
>> > log4j.logger.org.apache.hadoop.hbase=DEBUG
>> >
>> >
>> > BTW I also have a related post also on StackOverflow - this one focuses
>> > more on starting/debugging a test within the Intellij IDE:
>> >
>> >
>> >
>> http://stackoverflow.com/questions/26920330/logging-and-debugging-using-maven-within-intellij
>> >
>>
>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message