Description
Problem:
In most classes, the Log and LogFactory are statically declared (example AxisServlet). This causes the Log to be discovered and loaded during the class loading, which can be expensive.
If Axis2 is embedded, the wrong Log may be calculated (i.e. it may get the Log associated with the static loading versus the Log associated with the application's classloader).
Solution:
Adding a OnDemandLogger object will defer the Log construction until the Log is needed. This solution was proposed by Nikhil Thaker and Muhammad Sadiq.