https://github.com/oatpp/example-async-api
Example project how-to use oatpp asynchronous API.
https://github.com/oatpp/example-async-api
asynchronous-api cpp oatpp
Last synced: about 1 month ago
JSON representation
Example project how-to use oatpp asynchronous API.
- Host: GitHub
- URL: https://github.com/oatpp/example-async-api
- Owner: oatpp
- License: apache-2.0
- Created: 2019-01-30T01:21:59.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2024-04-22T21:25:35.000Z (about 1 year ago)
- Last Synced: 2025-04-21T03:25:35.014Z (about 2 months ago)
- Topics: asynchronous-api, cpp, oatpp
- Language: C++
- Homepage: https://oatpp.io/
- Size: 25.4 KB
- Stars: 18
- Watchers: 3
- Forks: 14
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Async API Example [](https://dev.azure.com/lganzzzo/lganzzzo/_build?definitionId=16&branchName=master)
Example project how-to use oat++ (AKA oatpp) asynchronous API.
See more:
- [Oat++ Website](https://oatpp.io/)
- [Oat++ Github Repository](https://github.com/oatpp/oatpp)
- [Get Started](https://oatpp.io/docs/start)## Overview
### Project layout
```
|- CMakeLists.txt // projects CMakeLists.txt
|- src/
| |
| |- controller/ // Folder containing controller where all endpoints are declared
| |- dto/ // DTOs are declared here
| |- AppComponent.hpp // Service config
| |- App.cpp // main() is here
|
|- test/ // test folder
|- utility/install-oatpp-modules.sh // utility script to install required oatpp-modules.
```---
### Build and Run
#### Using CMake
**Requires**
- `oatpp` module installed. You may run `utility/install-oatpp-modules.sh`
script to install required oatpp modules.```
$ mkdir build && cd build
$ cmake ..
$ make
$ ./example-async-api-exe # - run application.```
#### In Docker
```
$ docker build -t example-async-api .
$ docker run -p 8000:8000 -t example-async-api
```## Read More
- [Simple API vs Async API](https://oatpp.io/docs/simple-vs-async/)
- [Async](https://oatpp.io/docs/async/)
- [Oatpp-Coroutines](https://oatpp.io/docs/oatpp-coroutines/)
- [ENDPOINT_ASYNC](https://oatpp.io/docs/components/api-controller/#endpoint-async-specifics)