Pages Navigation Menu

Coding is much easier than you think

Setting Up Preferences in your SOAPUI

 
In this tutorial, let’s see how to setup preferences and save your preferences available in SOAPUI open source version and Pro version.
 
** Update – Complete SoapUi Tutorials now available here
 
Step by step explanation of all the preferences is explained below.

Step 1: To go to Preferences window, click on File –>  Preferences or you can just press Ctrl+Alt+P key as shown in the image below.

Choose file preferences

 

Step 2: This will open the SOAPUI Preferences window as shown below.

SOAPUI Opensource version:

SOAPUI beta Preferences

 

SOAPUI Pro version:

SOAPUI pro preferences

 

Some of the tabs in both SOAPUI open source and Pro versions are common. The tabs in preferences window are explained below.

1. HTTP Settings tab:

Set properties specific to HTTP protocol (protocol version, User-Agent header, request and response compression etc.).

Http preferences

 

OptionDescription
HTTP VersionSelects the HTTP version
User-Agent HeaderSets the HTTP User-Agent Header. If none is specified the default HttpClient header is used
Request CompressionSelects the request compression type
Response CompressionIndicates if compressed responses from hosts are accepted
Disable Response DecompressionDisables decompression of compressed responses
Close connections after requestDisables HTTP Keep-Alives by requesting to close the HTTP connection after each request. This will have a negative impact on performance but may give more realistic values during load testing
Chunking ThresholdUsing content-chunking for requests larger than threshols, blank to disable
Authenticate PreemptivelySend Authentication headers with each request without first receiving an authentication challenge. This is a potential security hazard but will improve performance since only one request will be required for authenticated endpoints instead of two
Expect-ContinueAdds Expect-Continue header to outgoing request.
Preencoded EndpointsDo not URL-encode endpoints, set this if your endpoint URLs are already URL-encoded (containing for example %20 or %3A)
Bind AddressThe local address to bind to when sending requests, can be overridden on a request level (with the corresponding request property) and on a system level by setting the soapui.bind.address system variable.
Include request in time takenIncludes the time it took to write the request in time-taken
Include response in time takenIncludes the time it took to read the response body in time-taken
Socket TimeoutThe socket timeout for HTTP requests in milliseconds
Max Response SizeThe maximum number of bytes to read from a response (0 = unlimited)
Max Connections Per HostThe maximum number of simultaneous connections to a specific host. Increase this value if you are running LoadTests with more than 500 threads on a particular host.
Max Total ConnectionsThe total maximum number of connections. Increase this value if you are running LoadTests with more than 2000 threads.
Leave MockEngineWill leave the MockEngine running even when all MockServices have stopped resulting in much faster startup-times for new MockServices and 404 errors when trying to call a stopped MockService (instead of connection failure)
Enable Mock HTTP LogLogs wire content of all mock requests. Selecting this option will degrade Mock Engine performance marginally and may require restart to enable or disable.

2. Proxy settings tab:

Define proxy server (host, port, username, password and excludes). Also this is where user specify whether proxy is in use or not.

OptionDescription
Proxy HostThe HTTP Proxy host to use
Proxy PortThe HTTP Proxy port to use
Proxy UsernameThe username sent for proxy authentications
Proxy PasswordThe password sent for proxy authentications
ExcludesA comma-separated list of hosts to exclude, for example “127.0.0.1:8080, myserver.com” will not use a proxy for 127.0.0.1 on port 8080 and myserver.com on any port.
Enable proxyFlag indicating if supplied proxy properties should be enabled, i.e. if proxy should be used

3.SSL Setting tab:

Define keystore, and Mock service SSL parameters.

Proxy preferences

 

OptionDescription
KeyStorePath to the keyStore to use when locating client certificates
KeyStore passwordthe keyStore password
Enable Mock SSLEnables SSL support for MockServices
Mock PortThe port for SSL connections
Mock KeyStoreThe keystore to use for SSL certificates
Mock PasswordThe keystore password
Mock Key PasswordThe default keys password
Mock TrustStoreThe truststore to use (optional)
Mock TrustStore PasswordThe truststore password
Client AuthenticationIndicates if client authentication is required

 

4.  WSDL Settings Tab:

Define WSDL specific properties.

wsdl preferences

 

OptionDescription
Cache WSDLsTurns on and off caching of WSDL’s
Sample ValuesGenerates example values in requests when creating from schema
Type CommentGenerates comments with type information in new requests
Include OptionalAlways includes optional elements in generated requests
Pretty PrintPretty prints response messages in response editor
Attachment PartsGenerates part-elements in request messages for mime-attachments in RPC messages (required by some ws-stacks)
No Content-Type ValidationDoes not validate the content-type of a mime-attachment against the type(s) specified in the SOAP-Binding
Schema DirectorySpecifies a directory containing schema (.xsd) files that should be automatically added when parsing or validating wsdl or requests. Changing the contents of this directory requires a restart.
Name with BindingTells SoapUI to name imported interfaces with the name of their corresponding soap/http binding, and not with their portType. This ensures that WSDL containing bindings for both SOAP 1.1 and SOAP 1.2 will get unique names during import. This setting defaults to true.
Excluded TypesA list of XML-Schema types and global elements in the form of name@namespace which will be used when generating sample requests and responses and input forms in the SoapUI Pro Form editor. By default the XML-Schema root element is added since it is quite common in .NET services and generates a sample xml fragment of about 300 kb!.

5. UI Settings Tab:

Define user interface properties (backup, autosave, look & feel, items ordering in a tree, tooltips visibility, garbage collection interval etc.).

UI Preferences

 

OptionDescription
Close ProjectsCloses all projects at startup for improved startup-time and less memory consumption.
Order ProjectsSorts Projects in alphabetical order in the navigator.
Order ServicesSorts Services in alphabetical order in the navigator.
Order RequestsSorts Requests in alphabetical order in the navigator.
Show DescriptionsShow description content when available
Save Projects On ExitAutomatically save all projects on exit.
Create BackupCreates a backup copy of a projects project-file before saving.
Backup FolderThe folder where to save backups, if relative or empty the folder is relative to the project files folder
Auto Save IntervalSets a project auto save interval (in minutes). If set over 0, SoapUI will automatically save all projects that have no running tests (both Functional and Load) at the specified interval
Desktop TypeSelects which desktop layout to use. SoapUI Pro adds a Tabbed Desktop as an alternative to the default layout. Changing this setting will be applied when closing the preferences dialog.

6. Editor Settings Tab:

Set various editor properties like font, line numbers visibility, request and response validation etc.

Editor preferences

 

OptionDescription
Editor FontThe font to be used by all XML Editors. The “Select Font” button opens a dialog for selecting the desired font and size.
XML Line NumbersShows line-numbers by default in all XML-Editors (use Alt-L in editors to toggle).
Groovy Line NumbersShows line-numbers by default in all Groovy-Editors (use Alt-L in editors to toggle).
Disable auto-resizeDisables automatic resizing of request/response editors.
Tabbed Request viewSets the tab-layout as the default layout for request/response editors.
Validate RequestsTurns on automatic validation of requests before they are submitted from a request editor. The validation performed is the same as when pressing Alt-V in the editor.
Abort on InvalidEnabled in conjunction with “Validate Requests”, if selected any requests that fail validation will not be submitted.
Validate ResponsesTurns on automatic validation of response messages when they are received in a response editor. The validation performed is the same as when pressing Alt-V in the editor.

7.  Tools Tab:

Define external tools executables. To run tools from the Tools main application menu, their executables must be defined here.

Tools Preferences

 

OptionDescription
JBossWS wstoolsLocation of JBossWS wstools
JAX-RPC WSCompileLocation of JAX-RPC wscompile
JAX-WS WSImportLocation of JAX-WS wsimport
Axis 1.XLocation of Axis 1.X
Axis 2.XLocation of Axis 2.X
.NET 2.0 wsdl.exeLocation of .NET 2.0 wsdl.exe
XFire 1.XLocation of XFire 1.X
CXF 2.XLocation of CXF 2.X

 

8. WS-I Settings Tab:

Define WS-I tools properties.

WS-I preferences

 

OptionDescription
VerboseSets verbose output of WS-I tools
Results TypeSets which results to show in the generated report
Message EntryShows message entries in report
Failure MessageIncludes defined failure messages in report
Assertion DescriptionIncludes description of each test assertion in report
Tool LocationLocal path to installed WS-I test tools
Show LogShows Log window when running WS-I tools
Output FolderIf specified, generated HTML reports will automatically be exported to this folder, which is required when running ws-i validation from the command-line or one of the Maven plug-ins

9.  Global Properties :

Define custom global application properties.

OptionDescription
Enable OverrideEnables overriding of any property-reference with global properties

10. Global Security Settings Tab

Define password for shadowing proxy password in settings file.

OptionDescription
PasswordPassword for shadowing proxy password in settings file

 

11.  WS-A Settings

Define parameters related to web services addressing.

OptionDescription
Soap Action Overrides WS-S ActionIf present in the WSDL soap action overrides wsa:Action

12.  loadUI Settings Tab

Define path to loadUI and integration ports.

OptionDescription
loadUI.bat(.sh) folderPath to loadUI executable

13.  Web Recording Settings Tab

Define request headers to exclude during web recording.

OptionDescription
Excluded headersRequest headers to exclude from recording

14.  SoapUI Pro Tab

Set SoapUI Pro specific properties.

OptionDescription
Default Request EditorSets the default Message Editor to use when a Request is opened
Default Response EditorSets the default Message Editor to use when a Response is received
Outline Editor LimitDefines the maximum size of messages to handle in the outline editor; since the outline editor consumes a large amount of memory, setting a limit related to one€™s own memory settings is encouraged
Form Editor LimitDefines the maximum size of messages to handle in the form editor; since the form editor consumes a large amount of memory, setting a limit related to one’s own memory settings is encouraged
Table Inspector ColumnsSets the maximum number of columns displayed by the Table Inspector (due to performance reasons).
Script LibraryPart to folder containing groovy object scripts that should be globaly available
Disable ReportingDisable reporting to preserve memory
Complete Error LogsLogs complete messages to reports on errors
Custom Report LibraryPath to folder containing custom jasper templates or reports

15.  Coverage Settings Tab

Enable or disable autopreparation of coverage reports.

OptionDescription
Auto PrepareAutomatically prepares for Coverage calculation when opening a window containing Coverage content.

16. Code Templates Tab

Define code templates.

OptionDescription
AddAdds new template
DeleteRemoves selected template
RestoreRestores templates to default settings

17. JDBC Drivers Properties Tab

Declare jdbc drivers and their connection string patterns.

OptionDescription
Adds a driver to the driver list
Removes selected driver from the driver list
Loads driver values from an external file
Reloads default driver settings