Hi. Thanks for your reply. I have found the source of the problem. We had to add this line to our configuration:
jetty.server.stopAtShutdown=true Without it Servlet.destroy() is not called. It seems to me that the default behavior should be the opposite, because calling Servlet.destroy() is what one expects from the servlet container, and not calling it looks like an optional optimization. Óscar On Wed, May 26, 2021 at 7:14 PM Simone Bordet <sbor...@webtide.com> wrote: > Hi, > > On Wed, May 26, 2021 at 6:21 PM Óscar Frías Barranco <ofr...@gmail.com> > wrote: > > > > Hello. > > > > We have migrated a webapp from Jetty 9.4 to Jetty 10 and it looks like > now the method destroy() is not being called when Jetty is stopped. > > > > Is this the expected behavior? > > > > How can we execute our shutdown code when Jetty is stopped? > > > > Thanks a lot for your help. > > If you refer to Servlet.destroy(), it should be called. > > If you have a reproducer, please open an issue at > https://github.com/eclipse/jetty.project/issues. > > -- > Simone Bordet > ---- > http://cometd.org > http://webtide.com > Developer advice, training, services and support > from the Jetty & CometD experts. > _______________________________________________ > jetty-users mailing list > jetty-users@eclipse.org > To unsubscribe from this list, visit > https://www.eclipse.org/mailman/listinfo/jetty-users >
_______________________________________________ jetty-users mailing list jetty-users@eclipse.org To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/jetty-users