https://github.com/userver-framework/mongo_grpc_service_template
[Deprecated: use userver-create-service instead!] Template of a C++ service that uses userver framework with gRPC and Mongo. Build, test and CI scripts ready
https://github.com/userver-framework/mongo_grpc_service_template
Last synced: 7 months ago
JSON representation
[Deprecated: use userver-create-service instead!] Template of a C++ service that uses userver framework with gRPC and Mongo. Build, test and CI scripts ready
- Host: GitHub
- URL: https://github.com/userver-framework/mongo_grpc_service_template
- Owner: userver-framework
- Created: 2024-12-28T15:20:42.000Z (about 1 year ago)
- Default Branch: develop
- Last Pushed: 2025-04-11T16:26:43.000Z (9 months ago)
- Last Synced: 2025-06-02T01:15:52.956Z (7 months ago)
- Language: C++
- Homepage:
- Size: 35.2 KB
- Stars: 2
- Watchers: 4
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
**This repository is for userver v2.8 or older versions. For newer versions of userver please use
[userver-create-service](https://userver.tech/de/dab/md_en_2userver_2build_2build.html#autotoc_md177) script.**
# mongo_grpc_service_template
Template of a C++ service that uses [userver framework](https://github.com/userver-framework/userver) with MongoDB and gRPC.
## Download and Build
To create your own userver-based service follow the following steps:
1. Press the "Use this template button" at the top right of this GitHub page
2. Clone the service `git clone your-service-repo && cd your-service-repo && git submodule update --init`
3. Give a proper name to your service and replace all the occurrences of "service_template" string with that name
4. Feel free to tweak, adjust or fully rewrite the source code of your service.
## Makefile
`PRESET` is either `debug`, `release`, or if you've added custom presets in `CMakeUserPresets.json`, it
can also be `debug-custom`, `release-custom`.
* `make cmake-PRESET` - run cmake configure, update cmake options and source file lists
* `make build-PRESET` - build the service
* `make test-PRESET` - build the service and run all tests
* `make start-PRESET` - build the service, start it in testsuite environment and leave it running
* `make install-PRESET` - build the service and install it in directory set in environment `PREFIX`
* `make` or `make all` - build and run all tests in `debug` and `release` modes
* `make format` - reformat all C++ and Python sources
* `make dist-clean` - clean build files and cmake cache
* `make docker-COMMAND` - run `make COMMAND` in docker environment
* `make docker-clean-data` - stop docker containers
## License
The original template is distributed under the [Apache-2.0 License](https://github.com/userver-framework/userver/blob/develop/LICENSE)
and [CLA](https://github.com/userver-framework/userver/blob/develop/CONTRIBUTING.md). Services based on the template may change
the license and CLA.