diff --git a/FlaskAPI/temp_image.jpeg b/FlaskAPI/temp_image.jpeg deleted file mode 100644 index 25783da..0000000 Binary files a/FlaskAPI/temp_image.jpeg and /dev/null differ diff --git a/docker-compose.yml b/docker-compose.yml index 6ec6e82..2f03ec0 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -37,4 +37,15 @@ services: limits: cpus: '1' memory: 1GB - + tcc-express: + image: tcc:express + container_name: tcc-express + build: ./tcc-express + restart: always + ports: + - "9084:9090" + deploy: + resources: + limits: + cpus: '1' + memory: 1GB diff --git a/scripts/common.py b/scripts/common.py index ba19864..6fcea30 100644 --- a/scripts/common.py +++ b/scripts/common.py @@ -2,12 +2,14 @@ FRAMEWORKS = [ ('Actix', 'tcc-actix'), ('ASP.NET', 'tcc-aspnet'), ('Flask', 'tcc-flask'), + ('Express', 'tcc-express'), ] ENDPOINTS = { 'Actix': 'http://localhost:9083', 'ASP.NET': 'http://localhost:9081', 'Flask': 'http://localhost:9082', + 'Express': 'http://localhost:9084', } BLUR_RADIUS = 5 diff --git a/scripts/graph.py b/scripts/graph.py index 297f98a..9731eaf 100644 --- a/scripts/graph.py +++ b/scripts/graph.py @@ -1,9 +1,9 @@ import numpy as np import matplotlib.pyplot as plt import os -from common import API_REQUESTS +from common import API_REQUESTS, FRAMEWORKS -FRAMEWORKS = ['Actix', 'ASP.NET', 'Flask'] +FRAMEWORKS = [f for f, _ in FRAMEWORKS] def plot_graph(x_data, y_data, title, x_label, y_label, filename): for i, framework in enumerate(FRAMEWORKS): @@ -116,11 +116,11 @@ if __name__ == '__main__': endpoints = [config[0] for config in API_REQUESTS] for endpoint_name in endpoints: - framework_name = 'Actix' + framework_name = 'ASP.NET' endpoint_file = endpoint_name.replace('/', '') - filename = f'data/resource_Actix_{endpoint_file}.csv' + filename = f'data/resource_ASP.NET_{endpoint_file}.csv' generate_resource_graph(filename, framework_name, endpoint_name) - filename = f'data/req_Actix_{endpoint_file}.csv' + filename = f'data/req_ASP.NET_{endpoint_file}.csv' generate_req_graph(filename, framework_name, endpoint_name)