-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch master of github.com:openswoole/openswoole into master
- Loading branch information
Showing
28 changed files
with
33 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,7 @@ | |
* @link https://openswoole.com | ||
* @contact [email protected] | ||
*/ | ||
|
||
namespace OpenSwoole\GRPC; | ||
|
||
use OpenSwoole\GRPC\Exception\GRPCException; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,7 @@ | |
* @link https://openswoole.com | ||
* @contact [email protected] | ||
*/ | ||
|
||
namespace OpenSwoole\GRPC; | ||
|
||
use OpenSwoole\Coroutine; | ||
|
@@ -92,9 +93,6 @@ public function close() | |
|
||
/** | ||
* Send message to remote endpoint, either end the stream or not depending on $mode of the client | ||
* @param mixed $method | ||
* @param mixed $message | ||
* @param mixed $type | ||
*/ | ||
public function send($method, $message, $type = 'proto') | ||
{ | ||
|
@@ -116,8 +114,6 @@ public function send($method, $message, $type = 'proto') | |
|
||
/** | ||
* Receive the data from a stream in the established connection based on streamId. | ||
* @param mixed $streamId | ||
* @param mixed $timeout | ||
*/ | ||
public function recv($streamId, $timeout = -1) | ||
{ | ||
|
@@ -126,9 +122,6 @@ public function recv($streamId, $timeout = -1) | |
|
||
/** | ||
* Push message to the remote endpoint, used in client side streaming mode. | ||
* @param mixed $streamId | ||
* @param mixed $message | ||
* @param mixed $type | ||
* @param bool $end | ||
*/ | ||
public function push($streamId, $message, $type = 'proto', $end = false) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,7 @@ | |
* @link https://openswoole.com | ||
* @contact [email protected] | ||
*/ | ||
|
||
namespace OpenSwoole\GRPC; | ||
|
||
final class ClientFactory | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,7 @@ | |
* @link https://openswoole.com | ||
* @contact [email protected] | ||
*/ | ||
|
||
namespace OpenSwoole\GRPC; | ||
|
||
interface ClientInterface | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,7 @@ | |
* @link https://openswoole.com | ||
* @contact [email protected] | ||
*/ | ||
|
||
namespace OpenSwoole\GRPC; | ||
|
||
use co; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,7 @@ | |
* @link https://openswoole.com | ||
* @contact [email protected] | ||
*/ | ||
|
||
namespace OpenSwoole\GRPC; | ||
|
||
final class Constant | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,7 @@ | |
* @link https://openswoole.com | ||
* @contact [email protected] | ||
*/ | ||
|
||
namespace OpenSwoole\GRPC; | ||
|
||
use ArrayAccess; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,7 @@ | |
* @link https://openswoole.com | ||
* @contact [email protected] | ||
*/ | ||
|
||
namespace OpenSwoole\GRPC; | ||
|
||
interface ContextInterface | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,8 +6,7 @@ | |
* @link https://openswoole.com | ||
* @contact [email protected] | ||
*/ | ||
|
||
namespace OpenSwoole\GRPC\Exception; | ||
|
||
class ClientException extends GRPCException | ||
{ | ||
} | ||
class ClientException extends GRPCException {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,7 @@ | |
* @link https://openswoole.com | ||
* @contact [email protected] | ||
*/ | ||
|
||
namespace OpenSwoole\GRPC\Exception; | ||
|
||
use OpenSwoole\GRPC\Status; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,7 @@ | |
* @link https://openswoole.com | ||
* @contact [email protected] | ||
*/ | ||
|
||
namespace OpenSwoole\GRPC\Exception; | ||
|
||
use OpenSwoole\GRPC\Status; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,7 @@ | |
* @link https://openswoole.com | ||
* @contact [email protected] | ||
*/ | ||
|
||
namespace OpenSwoole\GRPC\Exception; | ||
|
||
use OpenSwoole\GRPC\Status; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,7 @@ | |
* @link https://openswoole.com | ||
* @contact [email protected] | ||
*/ | ||
|
||
namespace OpenSwoole\GRPC\Exception; | ||
|
||
use OpenSwoole\GRPC\Status; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,7 @@ | |
* @link https://openswoole.com | ||
* @contact [email protected] | ||
*/ | ||
|
||
namespace OpenSwoole\GRPC\Exception; | ||
|
||
use OpenSwoole\GRPC\Status; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,7 @@ | |
* @link https://openswoole.com | ||
* @contact [email protected] | ||
*/ | ||
|
||
namespace OpenSwoole\GRPC; | ||
|
||
final class Message implements MessageInterface | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,8 +6,7 @@ | |
* @link https://openswoole.com | ||
* @contact [email protected] | ||
*/ | ||
|
||
namespace OpenSwoole\GRPC; | ||
|
||
interface MessageInterface | ||
{ | ||
} | ||
interface MessageInterface {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,7 @@ | |
* @link https://openswoole.com | ||
* @contact [email protected] | ||
*/ | ||
|
||
namespace OpenSwoole\GRPC\Middleware; | ||
|
||
use OpenSwoole\Constant; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,8 +6,7 @@ | |
* @link https://openswoole.com | ||
* @contact [email protected] | ||
*/ | ||
|
||
namespace OpenSwoole\GRPC\Middleware; | ||
|
||
interface MiddlewareInterface | ||
{ | ||
} | ||
interface MiddlewareInterface {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,7 @@ | |
* @link https://openswoole.com | ||
* @contact [email protected] | ||
*/ | ||
|
||
namespace OpenSwoole\GRPC\Middleware; | ||
|
||
use OpenSwoole\GRPC\Constant; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,7 @@ | |
* @link https://openswoole.com | ||
* @contact [email protected] | ||
*/ | ||
|
||
namespace OpenSwoole\GRPC\Middleware; | ||
|
||
use OpenSwoole\GRPC\MessageInterface; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,7 @@ | |
* @link https://openswoole.com | ||
* @contact [email protected] | ||
*/ | ||
|
||
namespace OpenSwoole\GRPC\Middleware; | ||
|
||
use OpenSwoole\GRPC\MessageInterface; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,7 @@ | |
* @link https://openswoole.com | ||
* @contact [email protected] | ||
*/ | ||
|
||
namespace OpenSwoole\GRPC; | ||
|
||
final class Request implements MessageInterface | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,8 +6,7 @@ | |
* @link https://openswoole.com | ||
* @contact [email protected] | ||
*/ | ||
|
||
namespace OpenSwoole\GRPC; | ||
|
||
interface RequestHandlerInterface | ||
{ | ||
} | ||
interface RequestHandlerInterface {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,7 @@ | |
* @link https://openswoole.com | ||
* @contact [email protected] | ||
*/ | ||
|
||
namespace OpenSwoole\GRPC; | ||
|
||
final class Response implements MessageInterface | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,7 @@ | |
* @link https://openswoole.com | ||
* @contact [email protected] | ||
*/ | ||
|
||
namespace OpenSwoole\GRPC; | ||
|
||
use Closure; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,7 @@ | |
* @link https://openswoole.com | ||
* @contact [email protected] | ||
*/ | ||
|
||
namespace OpenSwoole\GRPC; | ||
|
||
use Exception; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,8 +6,7 @@ | |
* @link https://openswoole.com | ||
* @contact [email protected] | ||
*/ | ||
|
||
namespace OpenSwoole\GRPC; | ||
|
||
interface ServiceInterface | ||
{ | ||
} | ||
interface ServiceInterface {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,7 @@ | |
* @link https://openswoole.com | ||
* @contact [email protected] | ||
*/ | ||
|
||
namespace OpenSwoole\GRPC; | ||
|
||
final class Status | ||
|