2
我使用ContextLoaderListener
來推廣春季環境。 在此之前在web.xml我有我的自定義偵聽器pefrorms一些檢查。如果這些檢查失敗,我不希望Spring上下文啓動。如何防止ServletContextListener中發生異常的spring上下文加載?
如何防止Spring上下文加載,如果我有另一個偵聽器中的異常?
我會把一些屬性放在ServletContext中,但我不知道它是如何影響加載的spring ctx的。
這裏是非常類似的問題:Stop deployment when Exception occurs in ServletContextListener