TestCase4j Server

General

The TestCase4j Server package should be used whenever you want to allow remote operations for the test case container. Interfaces to the server are based on the concept of invokers and protocols. An invoker defines an interface point in the server, accessible to remote clients, e.g. a Java server socket or a RMI invoker. An invoker is most often coupled with a protocol implementation, defining a protocol shared by the server and client.

TestCase4j Server is extendable with respect to invokers and protocols, providing a flexible way of adding custom implementations for remote clients. TestCase4j Server comes with a server socket invoker and the NRTCEProtocol.

The server is configurable with two XML files:

Overview

Below is a overview presentation of TestCase4j Server as it is shipped out-of-the-box.

TestCase4jServer.png

Invokers

An invoker defines a remote interface for clients to the server. Invokers are implemented in Java and you may add custom invokers.

Once a client request is accepted by an invoker, it is forwarded to the invoker's protocol implementation (if available) for further processing. The protocol then processes the request and returns a response, which the invoker sends back in an invoker-specific fashion to the requesting client.

Each invoker got exactly one protocol implementation attached to it.

TestCase4j Server comes with the following invokers:

  • Socket invoker - simple text protocol over TCP/IP sockets

More information about available invokers can be found here.

Protocols

A protocol is a definition of how a client and the server communicate with each other. Protocols are implemented in Java and you may add custom protocols.

Client requests are handed over to the protocol implementation by the protocol's invoker. Protocols are responsible for parsing the request and to take the appropriate action, e.g. execute a test case in the container, etc. Upon completion the protocol is responsible for returning a formatted response to the invoker, which sends it back to the requesting client.

TestCase4j Server comes with the following protocol implementations:

More information about available protocols can be found here.

Server configuration

Upon server start-up, the server is configured according to the server configuration file. This file defines available invokers, their implementation class and invoker parameters, available protocols, their implementation class and protocols parameters, and also a mapping between invoker and protocol.

A DTD and examples for the server configuration can be found here.

Test case configuration

See TestCase4j Core for more information about test case configuration.

Unless otherwise stated, the content of this page is licensed under GNU Free Documentation License.