免费视频淫片aa毛片_日韩高清在线亚洲专区vr_日韩大片免费观看视频播放_亚洲欧美国产精品完整版

打開APP
userphoto
未登錄

開通VIP,暢享免費(fèi)電子書等14項(xiàng)超值服

開通VIP
JavaBeans Introspector的官方說(shuō)明

Listener that flushes the JDK's JavaBeans Introspector cache on web app shutdown. Register this listener in your web.xml to guarantee proper release of the web application class loader and its loaded classes.

If the JavaBeans Introspector has been used to analyzeapplication classes, the system-level Introspector cache will hold ahard reference to those classes. Consequently, those classes and theweb application class loader will not be garbage-collected on web appshutdown! This listener performs proper cleanup, to allow for garbage collection to take effect.

Unfortunately, the only way to clean up the Introspector is to flushthe entire cache, as there is no way to specifically determine theapplication's classes referenced there. This will remove cachedintrospection results for all other applications in the server too.

Note that this listener is not necessary when using Spring'sbeans infrastructure within the application, as Spring's ownintrospection results cache will immediately flush an analyzed classfrom the JavaBeans Introspector cache and only hold a cache within theapplication's own ClassLoader. Although Spring itself does notcreate JDK Introspector leaks, note that this listener shouldnevertheless be used in scenarios where the Spring framework classesthemselves reside in a 'common' ClassLoader (such as the systemClassLoader). In such a scenario, this listener will properly clean up Spring's introspection cache.

Application classes hardly ever need to use the JavaBeansIntrospector directly, so are normally not the cause of Introspectorresource leaks. Rather, many libraries and frameworks do not clean upthe Introspector: e.g. Struts and Quartz.

Note that a single such Introspector leak will cause the entire webapp class loader to not get garbage collected! This has the consequencethat you will see all the application's static class resources (likesingletons) around after web app shutdown, which is not the fault ofthose classes!

This listener should be registered as the first one in web.xml, before any application listeners such as Spring's ContextLoaderListener. This allows the listener to take full effect at the right time of the lifecycle.

本站僅提供存儲(chǔ)服務(wù),所有內(nèi)容均由用戶發(fā)布,如發(fā)現(xiàn)有害或侵權(quán)內(nèi)容,請(qǐng)點(diǎn)擊舉報(bào)。
打開APP,閱讀全文并永久保存 查看更多類似文章
猜你喜歡
類似文章
Struts Spring Hibernate內(nèi)存泄漏查找與處理-Spring-Java ...
加入ehcache后,系統(tǒng)出現(xiàn)內(nèi)存泄漏,解決辦法
webwork+spring最簡(jiǎn)單的集成
IntrospectorCleanupListener作用
Java中的Listener 監(jiān)聽器
Spring配置中的“classpath:”與"classpath*:"的區(qū)別研究(轉(zhuǎn))
更多類似文章 >>
生活服務(wù)
分享 收藏 導(dǎo)長(zhǎng)圖 關(guān)注 下載文章
綁定賬號(hào)成功
后續(xù)可登錄賬號(hào)暢享VIP特權(quán)!
如果VIP功能使用有故障,
可點(diǎn)擊這里聯(lián)系客服!

聯(lián)系客服