TransformationToolContest / ttc2018liveContest

The repository for the TTC 2018 Live Contest
MIT License
4 stars 15 forks source link

The TTC 2018 Social Media Case

Build status

Case description

The docs/2018_TTC_Live.pdf file contains the case description.

Prerequisites

Setup

The graph models are stored in the models directory. For sizes larger than 512, the files are zipped so make sure you unzip the required sizes first. For example, run:

cd models
unzip 1024.zip
cd ..

Regenerating CSV change sets

CSV change sets are generated based on the XMI (EMF) models. The instructions for regenerating the CSVs are detailed in the SQL solution's README.

Solution Prerequisites

Add your prerequisites here!

Using the framework

The scripts directory contains the run.py script. At a first glance, invoke it without any arguments so that the solution will be built, benchmarked, running times visualized and the results compared to the reference solution's. One might fine tune the script for the following purposes:

The config directory contains the configuration for the scripts:

Setting the heap size

By default, Java tools run with a heap size - both minimum (Xms) and maximum (Xmx) - of 6 GB. This can be set to «HEAP» GB with the following script (using ag).

ag 'Xm(s|x)[0-9]+G' -l0 | xargs -0 sed -i -r 's/Xm(s|x)[0-9]+G/Xm\1«HEAP»G/g'

Running the benchmark

The script runs the benchmark for the given number of runs, for the specified tools and change sequences.

The benchmark results are stored in a CSV file. The header for the CSV file is stored in the output/header.csv file.

Reporting and visualization

Make sure you read the README.md file in the reporting directory and install all the requirements for R.

Implementing the benchmark for a new tool

To implement a tool, you need to create a new directory in the solutions directory and give it a suitable name.

Running the benchmark with Docker

Instructions for running the benchmark starting with a fresh Ubuntu 20.04 VM.

Initialize server

In case of cloud virtual machines (e.g. Amazon EC2, Azure), first create a file system and mount it. Example, assuming the /dev/nvme1n1 device mounting to /mnt/data:

sudo mkfs.ext4 /dev/nvme1n1
sudo mount /dev/nvme1n1 /mnt/data

Docker

On Ubuntu 20.04, the Docker version installed from apt is sufficient. If you wish to install the latest Docker, follow the official installation instructions.

Install Docker with apt:

sudo apt update && sudo apt install -y docker

Configure Docker to run without sudo:

sudo gpasswd -a $USER docker
newgrp docker

Change Docker's storage location by editing /etc/docker/daemon.json:

sudo vim /etc/docker/daemon.json

Set the data-root of Docker (where the containers are stored) to a location with ample space (e.g. the newly mounted disk): Assuming your storage is /mnt/data, use the following configuration:

{
  "data-root": "/mnt/data"
}

Restart Docker:

sudo service docker restart

Images

The Docker images are defined in the docker directory as Dockerfile-$TAG, e.g. Dockerfile-java11 contains the Docker image for running tool using Java 11.

The tools supported by each image are defined in the config directory in the config/config-$TAG.json file.

Building and running the images

:warning: Do not unzip the 1024.zip file.

Run ./docker.sh to list other available options.

Software versions

To get the exact versions of software, use:

lsb_release -d
docker --version
# show commit used for building the images
docker/ls-images.sh --runnable | xargs -n1 -I{} docker run --rm ftsrg/ttc2018:{} cat README.md
docker run --rm ftsrg/ttc2018:java8 java -version
docker run --rm ftsrg/ttc2018:java11 java -version
docker run --rm ftsrg/ttc2018:net31 dotnet --info