易老師不是說(shuō)了嗎?搞學(xué)問(wèn)的就需要求甚解.
我們算是搞學(xué)問(wèn)的吧
我也遇到了奇怪的問(wèn)題,我配置的log一句話也不出來(lái),log文件倒是建立了
如果樓上有解,能否給我點(diǎn)提示lazbean at hotmail dot com
@crazycy
nono,文章寫(xiě)到:
The issue of the failure of double-checked locking is not due to implementation bugs in JVMs but to the current Java platform memory model. The memory model allows what is known as "out-of-order writes" and is a prime reason why this idiom fails.
文章中說(shuō),基于java的內(nèi)存模型,DCL并不是最安全的.最安全的是餓漢 和懶漢.
當(dāng)然,懶漢很影響效率.