db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mayuresh Nirhali <Mayuresh.Nirh...@Sun.COM>
Subject Re: enabling tracing info while running tests
Date Mon, 17 Jul 2006 16:55:47 GMT
Knut Anders Hatlen wrote:

>Mayuresh Nirhali <Mayuresh.Nirhali@Sun.COM> writes:
>
>  
>
>>Hello,
>>
>>I am trying to get tracing info for a test run in standalone
>>manner. The test runs fine, but I do not see the traceFile being
>>created.
>>
>>The command I use is as below,
>>
>>
>>java -cp $CLASSPATH -Dframework=DerbyNetClient
>>-DtestSpecialProps=derby.infolog.append=true^derby.drda.traceFile=./trace.out^derby.drda.traceLevel=org.apache.derby.jdbc.ClientDataSource.TRACE_PROTOCOL_FLOWS
>>org.apache.derbyTesting.functionTests.harness.RunTest
>>jdbcapi/parameterMapping.java
>>
>>Is there anything that I am missing ??
>>
>>What is the best way to generate tracing data for tests ??
>>    
>>
>
>Hi Mayuresh,
>
>derby.drda.traceFile should be passed to the network server process,
>but I'm not sure whether testSpecialProps does that. By the way, I
>don't think there is a derby.drda.traceFile property, but there is a
>derby.drda.traceDirectory.
>
>What I usually do when I need server-side tracing of a test, is
>starting the network server with the required parameters before
>running the test. Since a server is already running, the test harness
>won't start a new one.
>  
>
I tried following but didn't get the trace file.

java -cp $CLASSPATH -Djvmflags=derby.drda.traceFile=trace.out 
org.apache.derby.drda.NetworkServerControl start

i also tried derby.drda.traceDirectory instead in the above command, but 
no luck.
Could you please post your command for my reference ??

any docs/twiki for more info on debugging ??

>To enable client-side tracing, you need to modify the connection
>URL. For parameterMapping.java, I think you can do that by adding
>"ij.database=jdbc:derby:wombat;create=true;traceFile=trace.out" to
>parameterMapping_app.properties.
>
>  
>
I created a new file in tests/jdbcapi directory, 
parameterMapping_derby.properties and added following 2 lines,
derby.drda.traceFile=trace.out
derby.drda.traceAll=true

and ran the test in DerbyNetClient mode (w/o starting server 
separately), the test has been running for almost 20 mins now, could it 
be this slow ??

Mayuresh


Mime
View raw message