Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

nano 自定义进程无效 #66

Closed
limFun opened this issue Sep 25, 2023 · 2 comments
Closed

nano 自定义进程无效 #66

limFun opened this issue Sep 25, 2023 · 2 comments

Comments

@limFun
Copy link

limFun commented Sep 25, 2023

用的是master分支,直接运行demo代码。等半天都没任何动作,不知道是哪个环节出了问题,就是不动。composer包都是最新的

微信截图_20230925172336

@xuanyanwow
Copy link
Member

xuanyanwow commented Oct 8, 2023

旧版本没有默认enable process 启动,需要手动setEnable一下

$app->addProcess(function(){
    while (true) {
        sleep(1);
        $this->container->get(StdoutLoggerInterface::class)->info('Processing...');
    }
})->setName('nano-process')->setNums(1)->setEnable(true);

@xuanyanwow
Copy link
Member

Fixed #67

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants