Skip to content

Commit

Permalink
feat docs: update changelog and docs
Browse files Browse the repository at this point in the history
Tests: протестировано локально, на прод не влияет
commit_hash:8b7506fa1a5496d36be9902e083de21ccd3e4f54
  • Loading branch information
apolukhin committed Nov 8, 2024
1 parent 73056d8 commit d962088
Show file tree
Hide file tree
Showing 12 changed files with 35 additions and 13 deletions.
2 changes: 1 addition & 1 deletion clickhouse/include/userver/storages/clickhouse.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
///
/// @htmlonly <div class="bottom-nav"> @endhtmlonly
/// ⇦ @ref scripts/docs/en/userver/redis.md |
/// @ref scripts/docs/en/userver/development/stability.md ⇨
/// @ref scripts/docs/en/userver/libraries/s3api.md ⇨
/// @htmlonly </div> @endhtmlonly

USERVER_NAMESPACE_BEGIN
Expand Down
3 changes: 2 additions & 1 deletion core/src/logging/log_extra_test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,8 @@ TEST(LogExtra, DocsData) {
/// [Example using LogExtra]

/// [Example using stacktrace in log]
LOG_ERROR() << "Deadlock in ABC identified" << logging::LogExtra::Stacktrace();
// Outputs current stacktrace:
LOG_ERROR() << "Deadlock in ABC identified:" << logging::LogExtra::Stacktrace();
/// [Example using stacktrace in log]

// Check that logging LogExtra::Stacktrace and LogFlush don't require a
Expand Down
2 changes: 2 additions & 0 deletions samples/s3api/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ cmake_minimum_required(VERSION 3.14)
project(userver-samples-s3api CXX)

# /// [s3api]
# cmake
find_package(userver COMPONENTS core s3api REQUIRED)

add_library(${PROJECT_NAME}_objs OBJECT
Expand All @@ -15,6 +16,7 @@ add_executable(${PROJECT_NAME} main.cpp)
target_link_libraries(${PROJECT_NAME} ${PROJECT_NAME}_objs)

# /// [gtest]
# cmake
add_executable(${PROJECT_NAME}-unittest unittests/client_test.cpp)
target_link_libraries(${PROJECT_NAME}-unittest
${PROJECT_NAME}_objs
Expand Down
5 changes: 5 additions & 0 deletions scripts/docs/doxygen.conf
Original file line number Diff line number Diff line change
Expand Up @@ -191,6 +191,8 @@ STRIP_FROM_PATH = universal/include \
rabbitmq/include \
mysql/include \
ydb/include \
libraries/s3api/include \
libraries/grpc-reflection/include \
scripts/docs

# The STRIP_FROM_INC_PATH tag can be used to strip a user-defined part of the
Expand All @@ -217,6 +219,8 @@ STRIP_FROM_INC_PATH = universal/include \
rabbitmq/include \
mysq/include \
ydb/include \
libraries/s3api/include \
libraries/grpc-reflection/include \
scripts/docs

# If the SHORT_NAMES tag is set to YES, doxygen will generate much shorter (but
Expand Down Expand Up @@ -991,6 +995,7 @@ INPUT = CONTRIBUTING.md \
otlp/include \
testsuite/pytest_plugins/ \
docker-compose.yml \
libraries \
scripts/docker/

# This tag can be used to specify the character encoding of the source files
Expand Down
1 change: 1 addition & 0 deletions scripts/docs/en/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ are available at the
* @ref scripts/docs/en/userver/tutorial/digest_auth_postgres.md
* @ref scripts/docs/en/userver/tutorial/websocket_service.md
* @ref scripts/docs/en/userver/tutorial/multipart_service.md
* @ref scripts/docs/en/userver/tutorial/s3api.md
* @ref scripts/docs/en/userver/tutorial/json_to_yaml.md


Expand Down
2 changes: 1 addition & 1 deletion scripts/docs/en/userver/development/stability.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,5 +71,5 @@ There are tiers to differentiate technologies:
----------

@htmlonly <div class="bottom-nav"> @endhtmlonly
@ref clickhouse_driver | @ref scripts/docs/en/userver/driver_guide.md ⇨
@ref scripts/docs/en/userver/libraries/grpc-reflection.md | @ref scripts/docs/en/userver/driver_guide.md ⇨
@htmlonly </div> @endhtmlonly
7 changes: 4 additions & 3 deletions scripts/docs/en/userver/libraries/grpc-reflection.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,13 @@ replace all standard primitives with userver ones.
To be honest, usage is exceedingly simple:

1. Link with in your CMakeLists.txt
```
```cmake
find_package(userver COMPONENTS grpc grpc-reflection REQUIRED)
target_link_libraries(${PROJECT_NAME} userver::grpc-reflection)
```

2. Add component to your service
```
```cpp
#include <userver/grpc-reflection/reflection_service_component.hpp>


Expand All @@ -28,11 +28,12 @@ int main(int argc, char* argv[]) {
.Append<grpc_reflection::ReflectionServiceComponent>()
....
}
....
```
3. Add simple line to your config.yaml
Don't forget that grpc-reflection requires grpc
```
yaml
components_manager:
components:
grpc-reflection-service:
Expand Down
4 changes: 3 additions & 1 deletion scripts/docs/en/userver/publications.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,13 +37,15 @@
## Technologies overview
* 📖 Generic async engine implementation (ru): [Анатомия асинхронных фреймворков в С++ и других языках](https://habr.com/ru/company/yandex/blog/647853/)
* 🎥 Generic async engine implementation (ru): [Анатомия асинхронных движков](https://youtu.be/MiE22pTvnPs)
* 🎥 Mutex implementation in userver (ru): [Реализация мьютекса в userver](https://www.youtube.com/watch?v=myaEpjYyx3I)
* 🎥 Description of utils::FastPimpl, formats::parse::To and logging implementation (ru): [C++ трюки из Такси](https://youtu.be/_AkF8SpUV3k)
* 🎥 Description of utils::LazyPrvalue, utils::FixedArray, utils::TrivialBiMap, ODR-detection in PostgreSQL [C++ трюки из userver](https://www.youtube.com/watch?v=FcQC19CX-AY)
* 🎥 Description of cache::LruSet implementation and optimizations (ru): [Ещё чуть быстрее делаем свой контейнер](https://youtu.be/60XhYzkXu1M)
* 🎥 Monolyth vs. Microservices architecture and how userver works around their issues (ru):
* 🎥 Monolithic vs. Microservices architecture and how userver works around their issues (ru):
[Монолит vs Микросервисы, и Как эффективно работать с последними в C++](https://youtu.be/5QtAFKgS938)
* 📖 Retries, exponential backoff, jitter, rate limits, circuit breakers, deadline propagations and other
important features for stability (ru): [Хороший ретрай, плохой ретрай, или История одного падения](https://habr.com/ru/companies/yandex/articles/762678/)
* 📖 Dirty C++ tricks from userver and Boost (ru): [Грязные трюки C++ из userver и Boost](https://habr.com/ru/companies/yandex/articles/852244/)
* 📖 [Story of website design at Behance](https://www.behance.net/gallery/185906583/Userver-C)


Expand Down
6 changes: 4 additions & 2 deletions scripts/docs/en/userver/roadmap_and_changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,12 @@ Changelog news also go to the

### Release v2.5

* Added S3 API client s3api::Client. More docs to come soon. Many thanks to
* Added @ref scripts/docs/en/userver/libraries/s3api.md "S3 API client s3api::Client". Many thanks to
[v-for-vandal](https://github.com/v-for-vandal) for the work!
* Added gRPC reflection library. More docs to come soon. Many thanks to
* Added @ref scripts/docs/en/userver/libraries/grpc-reflection.md "gRPC reflection library". Many thanks to
[v-for-vandal](https://github.com/v-for-vandal) for the work!
* Added @ref kill_switches "Kill Switch" functionality. Many thanks to
[Aksenov Anton](https://github.com/Dangerio) for the work!
* @ref scripts/docs/en/userver/congestion_control.md "Congestion Control" turned on by default.
* Initial work towards embedding GDB pretty-printers to userver binaries.
* Mongo now has the full functionality for diagnostics out-of-the box, without mongo-c library patches.
Expand Down
2 changes: 1 addition & 1 deletion scripts/docs/en/userver/tutorial/json_to_yaml.md
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ See the full example at:
----------

@htmlonly <div class="bottom-nav"> @endhtmlonly
@ref scripts/docs/en/userver/tutorial/multipart_service.md | @ref scripts/docs/en/userver/component_system.md ⇨
@ref scripts/docs/en/userver/tutorial/s3api.md | @ref scripts/docs/en/userver/component_system.md ⇨
@htmlonly </div> @endhtmlonly


Expand Down
2 changes: 1 addition & 1 deletion scripts/docs/en/userver/tutorial/multipart_service.md
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ See the full example at:
----------

@htmlonly <div class="bottom-nav"> @endhtmlonly
@ref scripts/docs/en/userver/tutorial/websocket_service.md | @ref scripts/docs/en/userver/tutorial/json_to_yaml.md ⇨
@ref scripts/docs/en/userver/tutorial/websocket_service.md | @ref scripts/docs/en/userver/tutorial/s3api.md ⇨
@htmlonly </div> @endhtmlonly


Expand Down
12 changes: 10 additions & 2 deletions scripts/docs/en/userver/tutorial/s3api.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,9 @@ Here is usage example
## Testing

We provide google mock for client, that you can access by including header
```#include <userver/s3api/utest/client_gmock.hpp>```
```cpp
#include <userver/s3api/utest/client_gmock.hpp>
```

With this mock, you have full power of Google Mock at your fingertips:

Expand All @@ -48,7 +50,7 @@ To add tests to your project, add appropriate lines to CMakeLists.txt, like this

## Testsuite support

Testsuite module is provided as part of testsuite plugins and can be found here:
Testsuite module is provided as part of testsuite plugins and can be found at:

@ref testsuite/pytest_plugins/pytest_userver/plugins/s3api.py

Expand All @@ -66,8 +68,14 @@ See the full example at:

----------

@htmlonly <div class="bottom-nav"> @endhtmlonly
@ref scripts/docs/en/userver/tutorial/multipart_service.md | @ref scripts/docs/en/userver/tutorial/json_to_yaml.md ⇨
@htmlonly </div> @endhtmlonly

@example samples/s3api/src/s3api_client.hpp
@example samples/s3api/src/s3api_client.cpp
@example samples/s3api/unittests/client_test.cpp
@example samples/s3api/main.cpp
@example samples/s3api/CMakeLists.txt

@example testsuite/pytest_plugins/pytest_userver/plugins/s3api.py

0 comments on commit d962088

Please sign in to comment.