| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Name | Name | Last commit date | ||
|---|---|---|---|---|
⚠️ RRv2 protoc-gen-php-grpc releases are here: https://github.com/roadrunner-server/roadrunner/releases ⚠️
⚠️ PHP Client for the RRv2 is here: https://github.com/spiral/roadrunner-grpc ⚠️
PHP-GRPC is an open-source (MIT) high-performance PHP GRPC server build at top of RoadRunner. Server support both PHP and Golang services running within one application.
For the RoadRunner v2, please use the RR-GRPC library.
Install rr-grpc and protoc-gen-php-grpc by building it or use pre-build binaries.
Define your service schema using proto file. You can scaffold protobuf classes and GRPC service interfaces using:
$ protoc --php_out=target-dir/ --php-grpc_out=target-dir/ sample.proto
Make sure to install protoc compiler and run composer require spiral/php-grpc first
Implement needed classes and create worker.php to invoke your services.
Place .rr.yaml (or any other format supported by viper configurator) into the root of your project. You can run your application now:
$ rr-grpc serve -v -d
To reset workers state:
$ rr-grpc grpc:reset
To show workers statistics:
$ rr-grpc grpc:workers -i
See example.
You can find more details regarding server configuration at RoadRunner Wiki.
MIT License (MIT). Please see LICENSE for more information. Maintained by SpiralScout.
| Back | FazBrowse Home | New Git URL |