What calls this method ?
What passes a reference of type ServletContextEvent to the above method and why ?
Container calls this method when your web app is deployed, provided that the listener is configured properly in the DD or via annotations. And it sends the ServletContextEvent object as an argument to this method for two reasons
1. To indicate that the event of context iniatilization has occured so that you can run some code before the rest of the app starts servicing a client.
2. To provide access to the ServletContext object via the getServletContext() method. Now you got your ServletContext object and you can do a lot of things with that. you can get context init params. you can obtain a Database connection and store it as an attribute in the context scope, so that the rest of the app can use it.