Skip to content
New issue

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

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

Already on GitHub? # to your account

refactor: replace console with midway logger #2461

Merged
merged 1 commit into from
Jul 16, 2019

Conversation

alvinhui
Copy link
Collaborator

midway logger stores logs to local files and send logs to remote.

@alvinhui alvinhui requested a review from chenbin92 July 16, 2019 01:11
@alvinhui alvinhui self-assigned this Jul 16, 2019
const { componentName } = params;
const routerConfigAST = this.getRouterConfigAST();
const data = await this.getAll();
const data = await this.getAll(undefined, ctx);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. 看两处调用参数都是 undefined,在定义的时候可以不传?
  2. getAll 接口一般情况下应该也不会有参数的

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这里主要是为了保持接口的一致性,现在所有的 module.method 接受的参数都是:

methond: (params: any, ctx: IContext)

我觉得这个接口规则是好的,所以这里也就没有打破这个规则。

@chenbin92 chenbin92 merged commit 9affc55 into iceworks/release-3.0.0-beta.5 Jul 16, 2019
@delete-merged-branch delete-merged-branch bot deleted the iceworks/server-logger branch July 16, 2019 05:54
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants