Function checkStatus
has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
public function checkStatus()
{
$args = getopt('s:');
if(isset($args['s'])) {
Missing class import via use statement (line '56', column '20').
$app = new \Group\App\App();
Missing class import via use statement (line '63', column '25').
$classMap = new Group\Common\ClassMap();
Missing class import via use statement (line '32', column '23').
$server = new HproseSwooleServer($server);
The method checkStatus() contains an exit expression.
exit;
Avoid unused local variables such as '$file'.
$file = array_pop($parts);
Each class must be in a namespace of at least one level (a top-level vendor name)
class RpcKernal
The property $server_type is not named in camelCase.
class RpcKernal
{
protected $server_type;
protected $server;
The parameter $server_type is not named in camelCase.
public function __construct($server_type)
{
$this->server_type = $server_type;
$this->config = require(__ROOT__."config/rpc.php");
$this->cacheDir = $this->config['cache_dir'];
Blank line found at start of control structure
if(isset($args['s'])) {
Line indented incorrectly; expected at least 12 spaces, found 11
$server->add(new $class[0],'',$class[1]);
Whitespace found at end of line
{
No space found after comma in function call
$server->add(new $class[0],'',$class[1]);
Whitespace found at end of line
{
No space found after comma in function call
$server->add(new $class[0],'',$class[1]);
Expected 1 space after IF keyword; 0 found
if(isset($args['s'])) {
The variable $server_type is not named in camelCase.
public function init()
{
$this->checkStatus();
$pid = posix_getpid();
The variable $server_type is not named in camelCase.
public function init()
{
$this->checkStatus();
$pid = posix_getpid();
The variable $server_type is not named in camelCase.
public function init()
{
$this->checkStatus();
$pid = posix_getpid();
The variable $server_type is not named in camelCase.
public function __construct($server_type)
{
$this->server_type = $server_type;
$this->config = require(__ROOT__."config/rpc.php");
$this->cacheDir = $this->config['cache_dir'];
There are no issues that match your filters.