filmov
tv
58 What is load on startup? |Adv Java Servlet Programming Tutorial | adv java servlet tutorial

Показать описание
#What #is #load #on #startup? #adv java #Advance #Java #Servlet #Programming #Tutorial
- The load-on-startup value is a positive integer which specifies the servlets loaded order as per your business logic or what suites your application.
- The container must guarantee that servlets with lower values are loaded before servlets with higher values.
- When the servlet is loaded by container, its init(ServletConfig) method is called. You can do the following in the init(-) method:
- You can perform initialisation of the application, such as creating database connection, parsing a settings file or reading data from network to preloading data into memory.
- If load-on-startup is negative integer or the element is not presented then servlets will be loaded when the container decides it needs to be loaded
- Typically on it's first access. This is suitable for servlets that don't need to perform special initialisation.
- The load-on-startup value is a positive integer which specifies the servlets loaded order as per your business logic or what suites your application.
- The container must guarantee that servlets with lower values are loaded before servlets with higher values.
- When the servlet is loaded by container, its init(ServletConfig) method is called. You can do the following in the init(-) method:
- You can perform initialisation of the application, such as creating database connection, parsing a settings file or reading data from network to preloading data into memory.
- If load-on-startup is negative integer or the element is not presented then servlets will be loaded when the container decides it needs to be loaded
- Typically on it's first access. This is suitable for servlets that don't need to perform special initialisation.