2009看你 牛不牛?java最新异常,google找了半天也没找到同样的,看谁能解决

win720520 2009-04-03 09:23:42
严重: Exception sending context initialized event to listener instance of class com.aljoin.oa.core.misc.EnterpriseWebListener
java.lang.RuntimeException: invalid configuration
at com.aljoin.oa.core.component.InitializeController.initializeConfiguration(InitializeController.java:132)
at com.aljoin.oa.core.component.InitializeController.execute(InitializeController.java:164)
at com.aljoin.oa.core.misc.WebListener.contextInitialized(WebListener.java:40)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3843)


EnterpriseWebListener类:
package com.aljoin.oa.core.misc;

import com.aljoin.oa.core.component.Config;
import com.aljoin.oa.core.version.EnterpriseProbationVersion;
import com.aljoin.oa.core.version.VersionFactory;

@SuppressWarnings("serial")
public class EnterpriseWebListener extends WebListener
{
public void setSystemVersion()
{
try
{
Config.setSystemVersion(VersionFactory.buildSystemVersion());
boolean isMessage = DogReader.getInstance().isHasDog();
if (!(Config.getSystemVersion() instanceof EnterpriseProbationVersion))
if (!(isMessage)) {
String checkTime = Config.getProperty("checkdog");
CheckDogRunner checkDog = new CheckDogRunner();
if ((checkTime == null) || (!(checkTime.equals(""))))
checkDog.setCheckTime(checkTime);
else
checkDog.setCheckTime("1:00");
Thread thread = new Thread(checkDog);
checkDog.setHundle(thread);
thread.start();
}
else
Config.getSystemVersion().setHasDog(false);
}
catch (Exception e) {
e.printStackTrace();
}
}
}


initializeConfiguration() 方法:


public static synchronized void initializeConfiguration() {
Properties prop = null;
try {
prop = new Properties();
InputStream is = Config.class.getResourceAsStream("/config.properties");

prop.load(is);
is.close();
Config.setProperties(prop);
} catch (Exception e) {
LOG.error(Config.class, e);
}
try
{
Configuration conf = new Configuration().configure();
boolean toLoad = Config.getAljoinContext().getInitParameter(
"ToLoadCustomTemplates").equalsIgnoreCase
("true");
if (toLoad)
TemplateLoader.factoryASPLoader(conf).addTemplates();
Config.setSystemFactory(conf.buildSessionFactory());
Config.setConfiguration(conf);
} catch (Throwable e) {
LOG.error("error configuring", e);
throw new RuntimeException(e.getMessage()); }
Config.setLoginManager(LoginManagerFactory.buildLoginPoolManager());
}


execute 方法是调用了initializeConfiguration() 方法


WebListener.java类的方法是调用execute 方法



快来看看谁解决了给谁加分




...全文
170 2 打赏 收藏 转发到动态 举报
写回复
用AI写文章
2 条回复
切换为时间正序
请发表友善的回复…
发表回复
win720520 2009-04-07
  • 打赏
  • 举报
回复
这个错误 有时候出现有时候不出现 你说JRE 指定的不对, 按你说 JAR 应该如何指定? 能描述下吗
sherry521 2009-04-03
  • 打赏
  • 举报
回复
是不是JRE指定的不对?
内容概要:本文介绍了一种基于双层优化的微电网系统规划设计方法,旨在通过Matlab代码实现,解决微电网在规划与运行中的多目标、多层次决策问题。该方法将优化过程分为上下两层:上层通常负责容量配置、设备选址等长期规划决策,下层则聚焦于能量管理、出力调度等短期运行优化,通过迭代交互实现全局最优。文中详细阐述了模型构建、约束条件设定、目标函数设计及求解算法实现流程,并提供了完整的Matlab代码供复现实验,有助于深入理解微电网系统的设计逻辑与优化机制。; 适合人群:具备一定电力系统基础知识和Matlab编程能力,从事新能源、微电网、综合能源系统等领域研究的研究生、科研人员及工程技术人员。; 使用场景及目标:① 学习和掌握双层优化理论在微电网规划设计中的具体应用;② 通过阅读和运行Matlab代码,复现并改进经典优化模型,用于学位论文、科研项目或实际工程方案设计;③ 深入理解微电网中分布式能源、储能与负荷的协同优化调度策略。; 阅读建议:此资源以Matlab代码实现为核心,强调理论与实践的结合。建议读者先理解双层优化的基本思想和数学模型,再结合代码逐行分析,重点关注变量定义、约束条件的代码转化以及主从问题间的迭代逻辑。鼓励在提供的代码基础上进行参数调整、场景扩展或算法改进,以深化学习效果。

81,111

社区成员

发帖
与我相关
我的任务
社区描述
Java Web 开发
社区管理员
  • Web 开发社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧