I am deploying a .WAR file on Tomcat v5.5. I want to start a stream when starting a war file. So I am thinking about using Startup Servlet for this. But I do not know very well the servlet / start servlets. Can you guys tell me a little about how to do this? Any descriptive links on these issues would also be greatly appreciated. :)
You can use javax.servlet.ServletContextListenerand configure it in web.xml, for example:
javax.servlet.ServletContextListener
web.xml
<listener> <listener-class> com.mycompany.Listener </listener-class> </listener>
SerletContextListener - , . , ( ) .
SerletContextListener
<load-on-startup>1</load-on-startup>
, , . init init. , URL .
Source: https://habr.com/ru/post/1763026/More articles:ASP Classic - convert base64binary string to byte array - asp-classicHow to protect my home key if my application is active? (Screensaver, Lockscreen) - androidhow to change highlight color in list control in mfc - c ++Join two lists in Java - javaFind classes in Jar - javafailed to set gems using `sudo` - ruby | fooobar.comразработка функции пригодности в генетическом алгоритме - genetic-algorithmTo save recorded video - iphoneIn Scala 2.8, how do I access a substring by its length and starting index? - stringWhy the need for binding in this context - c #All Articles