Skip to content

di-unipi-socc/chaos-echo-composer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Chaos Echo Composer

This repository contains the sources of a generator of Docker Compose files for running multiple instances of the Chaos Echo Service.

How to use the Composer

CLI

The Composer is a Maven project. After cloning the repository on your device, go in the cloned folder and issue

mvn clean install

to compile the project and obtain a runnable JAR (within the folder target). Docker Compose file for running multiple Chaos Echo Services can then be generated by issuing

java -jar target/chaos-echo-composer-1.jar <inputFile>

where inputFile is the path to a partial application specification, written accordingly to what presented in the following section.

Input files

The Composer takes as input partial application specification, written in simplified profile of the Docker Compose YAML metamodel.

The syntax for writing a partial application specification is the following:

services:
  <service_1_name>: <service_1_object>
  <service_2_name>: <service_2_object>
  ...
  <service_N_name>: <service_N_object>

where each service_object can be left empty if nothing is to be specified on the corresponding service, or it should be structured as follows:

    environment:
      TIMEOUT: <number>
      PICK_PERCENTAGE: <number>
      FAIL_PERCENTAGE: <number>
    ports: <list_of_port_numbers>
    depends_on: <list_of_service_names>

where:

  • environment enables specifying the environment variables needed to tailor the behaviour of the specified Chaos Echo Service,
  • ports enables providing a list of port numbers where to expose the specified service, and
  • environment enables listing the backend services invoked by the specified service to emulate the processing of an incoming request.

Note that each of the above objects is optional. If environment is not specified, or if any of the inner variables is not set, the Composer will fill it with default values (see Composer.java).

Examples of input files

Examples of partial specifications that can be provided as input to the Composer are available in the data/examples folder.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages