-
Notifications
You must be signed in to change notification settings - Fork 161
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鈥檒l occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update eject example to something more robust #616
Comments
@mcollina what are your thoughts about that? |
I would move the close-with-grace setup inside the listen callback instead. |
could you explain more why? |
Ah sorry, I think I misunderstood your example. I don't think close-with-grace should be within a plugin or a callback, but rather at the top level, installed after the server has been setup. It's a property of the global application and not of the server, and you can install only one. Therefore, you should put that into the "main" of your application outside of all plugins. |
Prerequisites
馃殌 Feature Proposal
Change the eject file example to validate everything before running the server and make use of the
.ready()
function.Motivation
What made me think of this approach are:
plugins
and are not loaded inside correctly inside Fastify.Example
The text was updated successfully, but these errors were encountered: