ShahriyarR / MySQL-AutoXtraBackup

MySQL-AutoXtraBackup commandline tool written in Python 3 based on Percona XtraBackup
https://autoxtrabackup.azepug.az/
MIT License
141 stars 79 forks source link

add controller for API, modify OpenAPI doc #426

Closed Turall closed 3 years ago

ShahriyarR commented 3 years ago

@Turall Thanks for PR. Could you please explain the purpose of PR in plain English just for convenience? :+1:

Turall commented 3 years ago

@ShahriyarR I removed the controller logic from the main.py file. Because main.py is not intended for this. For API routers, I created a controller.py file and registered it in the main.py file. This approach is more straightforward. I changed the OpenApi schema so that the documentation shows what the endpoints are for.

Turall commented 3 years ago

@ShahriyarR additionally added 2 events in the main.py file, when the program starts and when it finishes its work

ShahriyarR commented 3 years ago

@Turall Thanks for such great improvements :) Merging)