header
Main Menu
Home
Eviware Store
Downloads
Products
News
Forum
Search
FAQs
Customer Area
Support
Documentation
Tutorials
CookBook
Downloads
Forum
Login Form
Welcome, Guest. Please login or register.
September 06, 2008, 07:27:44 pm
Username: Password:
Login with username, password and session length

Forgot your password?
 
How do I change log file location (soapui.log soapui-errors.log)
Welcome, Guest. Please login or register.
September 06, 2008, 07:27:44 pm
Home Help Search Login Register
News: The Forums are up! Welcome to eviware.

+  Eviware Forum
|-+  General Category
| |-+  eviware general
| | |-+  How do I change log file location (soapui.log soapui-errors.log)
« previous next »
Pages: [1] Print
Author Topic: How do I change log file location (soapui.log soapui-errors.log)  (Read 900 times)
Peter McCann
Newbie
*
Posts: 2


« on: March 03, 2008, 07:52:09 pm »

HI,
  I'm using Soapui-2.0 on a RH Linux box, I'm a build engineer calling Ant from Hudson (sort of like cruise control but better imho) . i'm exec-ing a script to call a modified version of testrunner.sh and have hacked testrunner.sh to run with the following flags -a -j -h $host -f $resultsdir $xmlfile. The problem I have is the log files (soapui.log and soapui-errors.log) are being written to the ANT parent directory. I can probably change the location to SOAPUI_HOME by doing a chdir to SOAPUI_HOME in my script, However that would put all the log files from every build there.

I've been reading about soapui-log4j.xml , and soapui.properties  but I can't find any examples of either, and have exactly zero experience writing log4j.xml files.

I would like to have a way to write the log files to a results directory that gets clobbered before every run.

Thanks in advance for any help
Pete


Logged
omatzura
Administrator
Hero Member
*****
Posts: 1,210


« Reply #1 on: March 04, 2008, 12:33:04 am »

Hi Pete,

you can modify the soapui-log4j.xml file in the soapui-2.0.2.jar and put the modified file into the soapui\bin folder. Change the FILE and ERRORFILE appenders File parameter to the desired location.

Hope this helps!

regards,

/Ole
eviware.com
Logged
Peter McCann
Newbie
*
Posts: 2


« Reply #2 on: March 04, 2008, 06:50:40 pm »

Thank you this works.

I was able to set it as a variable. I added an additional flag to testrunner.sh

soapui_log_dir=$4

then passed it to to java.

java -Dsoapui.properties=soapui.properties -
Dsoapui.log.dir=${soapui_log_dir}
-cp $SOAPUI_CLASSPATH com.eviware.soapui.tools.SoapUITestCaseRunner $options

This allows me to define the log dir on the fly from my ant task that kicks off the soap ui tests.

In the soapui-log4j.xml file I changed the lines you suggested to
    <param name="File" value="${soapui.log.dir}/soapui.log"/>
    <param name="File" value="${soapui.log.dir}/soapui-errors.log"/>





Logged
omatzura
Administrator
Hero Member
*****
Posts: 1,210


« Reply #3 on: March 04, 2008, 09:48:30 pm »

Hi!

cool! Thanks for sharing!

regards,

/Ole
eviware.com
Logged
Pages: [1] Print 
« previous next »
Jump to:  


Login with username, password and session length

Powered by MySQL Powered by PHP Powered by SMF 1.1.2 | SMF © 2006-2007, Simple Machines LLC Valid XHTML 1.0! Valid CSS!
header header
header
header