这个数字是说在这个webapp加载的时候加载类的顺序
0是第一个,然后递增如果你有一个类要在一启动就加载就可以把这个数字设置最小

解决方案 »

  1.   

    有个英文版的解释:
    The load-on-startup element indicates that this servlet should be loaded (instantiated and have its init() called) on the startup of the web application. The optional contents of these element must be an integer indicating the order in which the servlet should be loaded. If the value is a negative integer, or the element is not present, the container is free to load the servlet whenever it chooses.  If the value is a positive integer or 0, the container must load and initialize the servlet as the application is deployed. The container must guarantee that servlets ed with lower integers are loaded before servlets ed with higher integers. The container may choose the order of loading of servlets with the same load-on-start-up value.