public static synchronized IReportEngine getBirtEngine(ServletContext sc) {
if (reportEngine == null) {
LOG.info("开始初始化报表引擎");
long start=System.currentTimeMillis();
float total=(float)Runtime.getRuntime().totalMemory()/1000000;
EngineConfig config = new EngineConfig();
config.getAppContext().put(EngineConstants.APPCONTEXT_CLASSLOADER_KEY, BirtReportEngine.class.getClassLoader());
config.setEngineHome("");
IPlatformContext context = new PlatformServletContext(sc);
config.setPlatformContext(context);
try {
Platform.startup(config);
} catch (BirtException e) {
LOG.error("BIRT启动失败",e);