Skip to content

curtis18/yii2-swoft-rpc

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 

Repository files navigation

Swoft JSON RCP Client (TCP) for Yii2

Install

  • composer command
composer require curtis18/yii2-swoft-rpc

Usage

  • Please make sure Swoft RPC Server created before using this extension in Yii2.
use yii\Swoft\JsonRpc\Client;

public function actionRpcTest()
{
    $rpc = new Client("tcp://127.0.0.1:8001", \App\Rpc\Lib\TestInterface::class, "1.7");
    $result = $rpc->echoRpc("Hello World");
    echo $result;
}

Resources

LICENSE

The Component is open-sourced software licensed under the Apache license.

About

Swoft JSON RCP Client (TCP) for Yii2

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Languages