generated from Sithas/conan_template
Добавление nodiscard
This commit is contained in:
@@ -1,10 +1,6 @@
|
|||||||
# TODO:
|
# TODO:
|
||||||
|
|
||||||
- ~~Сделать реальные исполнители(executors) для регистрации, авторизации, логаута~~
|
- ~~Сделать реальные исполнители(executors) для регистрации, авторизации, логаута~~
|
||||||
- Посмотреть по поводу блокировок или тред пулла при использовании базы
|
|
||||||
- Посмотреть пулл соединений(Object pool) при использовании базы данных(посмотреть api MySQL-Connector)
|
|
||||||
- Посмотреть, что дает MySQL, какие там есть возможность
|
|
||||||
- Посмотреть и подумать, что лучше - корутины или многопоточность?
|
|
||||||
- ~~Покрыть тестами класс User и AuthRegistrationExecutor~~
|
- ~~Покрыть тестами класс User и AuthRegistrationExecutor~~
|
||||||
- ~~Добавить clang-format(через CLion)~~
|
- ~~Добавить clang-format(через CLion)~~
|
||||||
- ~~Перевести GetByUUID GetByLogin на const ref/string_view в IUserDAO - также не vector, а span(погуглить)~~ - span не применим
|
- ~~Перевести GetByUUID GetByLogin на const ref/string_view в IUserDAO - также не vector, а span(погуглить)~~ - span не применим
|
||||||
@@ -18,14 +14,31 @@
|
|||||||
- ~~Покрыть логами~~
|
- ~~Покрыть логами~~
|
||||||
- ~~Сделать один класс исключений, имеющих метод HTTP code - код и сообщение записывать уже в ловушке~~
|
- ~~Сделать один класс исключений, имеющих метод HTTP code - код и сообщение записывать уже в ловушке~~
|
||||||
- ~~Сделать интеграционный тест по ручкам~~
|
- ~~Сделать интеграционный тест по ручкам~~
|
||||||
- UseCase'ы по работе с личным кабинетом
|
|
||||||
- Научиться поднимать базы данных под каждый тест - научиться Docker - docker-compose - а если тест что-то должен заполнить, то он заполняет в самом начале()
|
|
||||||
- Возможно, сделать тесты на CI/CD - приоритет - низкий
|
|
||||||
- ~~Заменить internal_server_error на bad_request и перепроверить коды ошибок~~
|
- ~~Заменить internal_server_error на bad_request и перепроверить коды ошибок~~
|
||||||
- ~~Создание и удаление вспомогательных классов должно быть вынесено в фикстуру~~
|
- ~~Создание и удаление вспомогательных классов должно быть вынесено в фикстуру~~
|
||||||
- ~~К следующему занятию сделать ручку из кейса 3 + восстановить фикстуры из тестов~~
|
- ~~К следующему занятию сделать ручку из кейса 3 + восстановить фикстуры из тестов~~
|
||||||
|
- Посмотреть по поводу блокировок или тред пулла при использовании базы
|
||||||
|
- Посмотреть пулл соединений(Object pool) при использовании базы данных(посмотреть api MySQL-Connector)
|
||||||
|
- Посмотреть и подумать, что лучше - корутины или многопоточность?
|
||||||
|
- UseCase'ы по работе с личным кабинетом
|
||||||
|
- Научиться поднимать базы данных под каждый тест - научиться Docker - docker-compose - а если тест что-то должен заполнить, то он заполняет в самом начале()
|
||||||
|
- Возможно, сделать тесты на CI/CD - приоритет - низкий
|
||||||
|
- Найти слабые места в C++ -- std::forward, universal reference, просмотреть про decltype(почитать статьи)
|
||||||
|
- Написать фронтенд для MVP
|
||||||
|
- Разобрать decltype и auto по статье
|
||||||
|
До 27.01.2026
|
||||||
|
- Подобрать сервер по параметрам. Использовать linux.
|
||||||
|
- Перевести string на string_view
|
||||||
- Попробовать nodiscard к executoru
|
- Попробовать nodiscard к executoru
|
||||||
- Найти слабые места в C++ -- std::forward, universal reference
|
- Добить 2 ручки
|
||||||
|
- Сделать тесты для ручек
|
||||||
|
|
||||||
|
# План
|
||||||
|
1)Добить бэкенд(2 ручки) (до февраля)
|
||||||
|
2)Сделать деплой(до марта)
|
||||||
|
3)Сделать фронтенд для MVP
|
||||||
|
4)Делаем веб-чат и роль доктора
|
||||||
|
5)Читать книгу Мейерса "Эффективный и современный C++" до ???
|
||||||
|
|
||||||
# UseCase'ы приложения:
|
# UseCase'ы приложения:
|
||||||
|
|
||||||
|
|||||||
@@ -30,7 +30,7 @@ public:
|
|||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
boost::beast::http::response<ResponseType> operator ()(
|
[[nodiscard]] boost::beast::http::response<ResponseType> operator ()(
|
||||||
boost::beast::http::request<Body, boost::beast::http::basic_fields<Allocator>>&& req
|
boost::beast::http::request<Body, boost::beast::http::basic_fields<Allocator>>&& req
|
||||||
) override
|
) override
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -23,7 +23,7 @@ public:
|
|||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
boost::beast::http::response<ResponseType> operator ()(
|
[[nodiscard]] boost::beast::http::response<ResponseType> operator ()(
|
||||||
boost::beast::http::request<Body, boost::beast::http::basic_fields<Allocator>>&& req
|
boost::beast::http::request<Body, boost::beast::http::basic_fields<Allocator>>&& req
|
||||||
) override
|
) override
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -24,7 +24,7 @@ public:
|
|||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
boost::beast::http::response<ResponseType> operator ()(
|
[[nodiscard]] boost::beast::http::response<ResponseType> operator ()(
|
||||||
boost::beast::http::request<Body, boost::beast::http::basic_fields<Allocator>>&& req
|
boost::beast::http::request<Body, boost::beast::http::basic_fields<Allocator>>&& req
|
||||||
) override
|
) override
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -30,7 +30,7 @@ public:
|
|||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
boost::beast::http::response<ResponseType> operator ()(
|
[[nodiscard]] boost::beast::http::response<ResponseType> operator ()(
|
||||||
boost::beast::http::request<Body, boost::beast::http::basic_fields<Allocator>>&& req
|
boost::beast::http::request<Body, boost::beast::http::basic_fields<Allocator>>&& req
|
||||||
) override
|
) override
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -29,7 +29,7 @@ public:
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
boost::beast::http::response<ResponseType> operator ()(
|
[[nodiscard]] boost::beast::http::response<ResponseType> operator ()(
|
||||||
boost::beast::http::request<Body, boost::beast::http::basic_fields<Allocator>>&& req
|
boost::beast::http::request<Body, boost::beast::http::basic_fields<Allocator>>&& req
|
||||||
) override
|
) override
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -29,7 +29,7 @@ public:
|
|||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
boost::beast::http::response<ResponseType> operator ()(
|
[[nodiscard]] boost::beast::http::response<ResponseType> operator ()(
|
||||||
boost::beast::http::request<Body, boost::beast::http::basic_fields<Allocator>>&& req
|
boost::beast::http::request<Body, boost::beast::http::basic_fields<Allocator>>&& req
|
||||||
) override
|
) override
|
||||||
{
|
{
|
||||||
@@ -71,7 +71,7 @@ public:
|
|||||||
value response_body;
|
value response_body;
|
||||||
|
|
||||||
response_body.emplace_object();
|
response_body.emplace_object();
|
||||||
response_body.as_object().emplace("user_treatment_schemes", toJSONArray(schemes));
|
response_body.as_object().emplace("user_treatment_schemes", ToJSONArray(schemes));
|
||||||
|
|
||||||
res.body() = serialize(response_body);
|
res.body() = serialize(response_body);
|
||||||
res.set(http::field::content_type, "application/json");
|
res.set(http::field::content_type, "application/json");
|
||||||
@@ -99,7 +99,7 @@ private:
|
|||||||
return scheme_json;
|
return scheme_json;
|
||||||
}
|
}
|
||||||
|
|
||||||
boost::json::array toJSONArray(const std::vector<user_treatment_scheme_dto>& schemes)
|
boost::json::array ToJSONArray(const std::vector<user_treatment_scheme_dto>& schemes)
|
||||||
{
|
{
|
||||||
using namespace boost;
|
using namespace boost;
|
||||||
using namespace boost::json;
|
using namespace boost::json;
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ template <class Body, class Allocator, class ResponseType>
|
|||||||
class IExecutor
|
class IExecutor
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
virtual boost::beast::http::response<ResponseType> operator ()(
|
[[nodiscard]] virtual boost::beast::http::response<ResponseType> operator ()(
|
||||||
boost::beast::http::request<Body, boost::beast::http::basic_fields<Allocator>>&& req
|
boost::beast::http::request<Body, boost::beast::http::basic_fields<Allocator>>&& req
|
||||||
) = 0;
|
) = 0;
|
||||||
virtual ~IExecutor() = default;
|
virtual ~IExecutor() = default;
|
||||||
|
|||||||
@@ -29,7 +29,7 @@ public:
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
boost::beast::http::response<ResponseType> operator ()(
|
[[nodiscard]] boost::beast::http::response<ResponseType> operator ()(
|
||||||
boost::beast::http::request<Body, boost::beast::http::basic_fields<Allocator>>&& req
|
boost::beast::http::request<Body, boost::beast::http::basic_fields<Allocator>>&& req
|
||||||
) override
|
) override
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -29,7 +29,7 @@ public:
|
|||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
boost::beast::http::response<ResponseType> operator ()(
|
[[nodiscard]] boost::beast::http::response<ResponseType> operator ()(
|
||||||
boost::beast::http::request<Body, boost::beast::http::basic_fields<Allocator>>&& req
|
boost::beast::http::request<Body, boost::beast::http::basic_fields<Allocator>>&& req
|
||||||
) override
|
) override
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user