The validation testing framework supports test configurations where a test manager controls one or more test controllers running on remote target systems. This is the usual configuration, where the test manager and its user interface run in the Eclipse workbench, and the test runs in an OSGi runtime running on a separate JVM, possibly on another system.
Remote and distributed testing provides the following advantages:
The validation testing framework supports pluggable remote access of test controllers from the test manager, and an implementation is provided that using Java Remote Method Invocation for remote access. The following diagram shows a configuration where a test manager on a host system runs a test script that executes a specific test on two remote target systems concurrently.
The test script in this example specifies the execution of a test action on two different
controllers. The optional controller attribute of the <test> and
<configuration> elements is an optional attribute that specifies the remote test controller
that will receive the request to execute a test. When the controller attribute is omitted, the default value ""
is assumed, designating the default controller.
The test manager does not interpret the value of the controller attribute, but
delegates controller resolution to controller locater services that have been installed.
This allows for configuration-dependent resolution and for multiple implementations of the remote connection.
The test manager uses the following algorithm to resolve the controller:
Remote Method Invocation (RMI), a Java Technology that has been part of Java SE platform since the beginning, is a standard technology for distributed Java applications with a relatively low overhead. The RMI protocol makes Java objects available on remote systems via remote interfaces, using TCP/IP and object serialization for sending remote references and other objects over a network. For target systems not capable of running Java SE, add-on implementations of the RMI may exist. For example, IBM provides RMI as an optional package (implementing the JSR-66 RMIOP specification) that can be installed in the J9 runtime of the WebSphere Everyplace environments.
The following diagram shows the components of the Validation Testing Framework in a remote configuration using RMI.
Note that remote objects (called stubs in RMI) will be exported from both host and target system. A test controller running on the target is exported as remote object so that the central test manager can access it, and the test run listener and synchronization interfaces running on the host are exported as remote objects so that the target systems can use them to call back to. This is illustrated in the following class diagram.
The org.eclipse.soda.dk.testcontroller.remote.rmi project provides example launch
configurations and a test script for running the TestAgentTest on a remote runtime.
The example test script, testcontroller.remote.rmi.target.xml, configures and runs a test agent
on a remote runtime, as shown in the following diagram.
To run this example using the test manager in the Eclipse workbench, perform the following steps:
To run this example using the test manager web-based interface running remotely, perform the following steps:
Notes:
testcontroller.registry.port property, defined as system property or in esc.properties,
can be used to override the default port number. In case the default port is not used,
the port can be specified as controller="host:port" in the XML script.InetAddress.getLocalHost() must return an IP address at which the
target system can be reached from the host, and vice versa. The reason is that commonly
RMI implementations use this address in the remote stubs that are exchanged.Version 1.0 of the validation testing framework used a simplified test controller resolution algorithm that did not include the pluggable test controller locater service, but always required a proxy controller services to be created. This approach is still supported and is shown in the following diagram.
The following test script example configures a proxy controller on the host
runtime and uses it to create and run a test agent on a remote runtime.
Copyright © 2007 IBM. All Rights Reserved.