University of Sheffield

Anthony J H Simons, MA PhD

Senior Lecturer in Computer Science
University Computer Science Testing Group Space Tech Europe Industry

Undergraduate Projects, 2017-18

Schedule Introduction Description Survey/Analysis Dissertation Poster Session Last Year
Project Code Project Description Student

AJHS-UG-2

Code Generation for Cloud Services

The goal of this project is to generate working code for software services, to be deployed in the cloud, from model descriptions of these services. The project will use Java software tools developed for the EU Broker@Cloud project, which include the service models we will use, and a code-generation framework.

A software service can be thought of as a kind of extended finite state machine (EFSM). It exists in a number of states, in which subsets of its operations are enabled or disabled. The transitions of the state machine indicate how different service operations take the service from one state to the next state. Each operation possibly has inputs, outputs and also may have number of different branches, triggered by different conditions. An operation may also read or write to memory variables, which store extra information about the state of the service (memory is what extends the basic FSM). All of this is represented by an XML model specification language, which can be unmarshalled (parsed) as a strongly-typed Java tree, representing the service model.

The model has a code-generation interface that follows the Visitor Design Pattern for generating code. Whereas in the past, this has been used to generate tests to execute cloud services implemented by hand, in the current project, the aim is to generate the services directly from the models. To help you visualize what generated services should look like, there are several examples of services, implemented as "plain old Java objects" (POJOs) supplied as part of the existing software package. These examples follow the State Design Pattern, to represent a service in each of its states. Your task will be to generate as much of this as you can, from the model specification. If POJO generation is successful, then you may also attempt to generate the Java code for JAX-WS or JAX-RS web services, which each follow a different Java standard. Eventually, you may be able to specify a service model, then generate and deploy the working service to the cloud automatically. This project will suit any student with strong Java programming skills. Familiarity with Java EE will be useful.

Mr Bing Tao

AJHS-UG-3

The XML Olympics: Benchmarking Java XML Toolkits

This project aims to benchmark different Java implementations of toolkits for processing XML, and produce a research paper at the end. The project is styled like the Olympic Games in which there are different events in which different tools may compete (tools may be able to compete in one or more events, but not every tool in every event).

The Java tools to be compared may include the standard DOM, SAX and StaX tools offered in the JAXP extension to Java; and other tools that process XML document models in Java, such as JDOM and Dom4J, tools that bind XML to Java classes, such as JAXB and XStream, tools that perform XPath search such as Jaxen and Java XPath, and Sheffield's own contender JAST (Java Abstract Syntax Trees) , which does all of these. The kinds of event will include: (for DOM-trees) speed of reading, speed of writing, volume of data stored in memory; (for Java binding) speed of marshalling, speed of unmarshalling; (for XPath searching) XPath coverage, speed of searching; and (for usability) degree of configuration required; and ease of use. The project will require setting up careful timed experiments, using advice from Java micro-benchmarking research. All software will be developed in Java.

Mr Manh Tri Nguyen

AJHS-UG-4

The CatWalk Software Unit Testing Tool for Java

This project aims to build a software unit testing tool for Java that follows the equivalence-partition testing method (also known as category-partition testing). In this approach, the test engine seeks to find inputs that trigger different branches of the code that exhibit qualitatively different responses in the outputs. One or more tests are retained for each found partition of each tested method.

The project could be supplied with Java source code, or compiled Java bytecode, as input and will generate tests in a format acceptable to the JUnit testing framework as output. If compiled class-files are supplied for testing, the tool will discover the public method API using Java reflection, in a manner similar to Sheffield's own Lazy Systematic Unit Testing tool JWalk ; otherwise if source code is provided, the tool will parse the source code. State-space search will be used to find suitable inputs to trigger different behaviours, and particular inputs for methods will be logged when these trigger a qualitatively different response from test examples, as inspired by the paper: Benchmarking effectiveness for object-oriented unit testing . All software will be developed in Java.

Mr Tomasz Jurewicz