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

Allow disabling default logging in fastboot-app-server #890

Merged
merged 2 commits into from
Mar 21, 2022

Conversation

jurgenwerk
Copy link
Contributor

@jurgenwerk jurgenwerk commented Mar 15, 2022

This PR adds a log boolean option to the FastBootAppServer constructor so that we can disable the default logger when using a custom logging function in fastboot-server.js.

By default, fastboot-app-server will output request logs like this:

2022-03-09T15:40:47-06:00: 2022-03-09T21:40:47.716Z 200 OK /
2022-03-09T15:43:16-06:00: 2022-03-09T21:43:16.147Z 200 OK /users/123

We need more control over logs (to provide extra info in deployed environments) so we decided to add our own logging middleware, but now the default logger is making noise and would prefer to disable it.

In the fastboot-express-middleware there's already a line that prevents logging in case a false log option is provided. This PR passes this option to the fastboot-express-middleware.

@ef4
Copy link
Contributor

ef4 commented Mar 21, 2022

Thanks, published as 3.3.0.

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

Successfully merging this pull request may close these issues.

None yet

2 participants