ContextLoader
//
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by Fernflower decompiler)
// package com.neusoft.unieap.core.listener; import com.neusoft.unieap.core.protection.ProtectionConfig;
import com.neusoft.unieap.core.protection.custom.CustomCheck;
import com.neusoft.unieap.core.validation.i18n.I18nGlobalContext;
import java.io.File;
import javax.servlet.ServletContext;
import org.springframework.web.context.ConfigurableWebApplicationContext; public class ContextLoader extends org.springframework.web.context.ContextLoader {
public ContextLoader() {
} protected void customizeContext(ServletContext servletContext, ConfigurableWebApplicationContext applicationContext) {
String licensePath = File.separator + "WEB-INF" + File.separator + "conf" + File.separator + "unieap" + File.separator + "license";
System.out.println("我是licensePath============="+licensePath);
I18nGlobalContext.getInstance().setServletContext(servletContext);
ProtectionConfig.filePath = applicationContext.getServletContext().getRealPath(licensePath);
System.out.println("ProtectionConfig.filePath============="+ProtectionConfig.filePath);
CustomCheck.getInstance().check(false);
}
}
ContextLoader的更多相关文章
- 解决log4j:WARN No appenders could be found for logger (org.springframework.web.context.ContextLoader)警告信息的问题
spring项目经常在启动tomcat时报如下警告信息: log4j:WARN No appenders could be found for logger (org.springframework. ...
- Log4j使用教程 log4:WARN No appenders could be found for logger (org.springframework.web.context.ContextLoader).
1.Logger类 通过Logger类的静态方法Logger.getRootLogger得到RootLogger.所有其他的loggers是通过静态方法Logger.getLogger来实例化并获取的 ...
- [ERROR][org.springframework.web.context.ContextLoader][main] Context initialization failed org.sprin
做一个SSH为基础框架的webapp小DEMO,复制了一把以前可以跑的代码,竟发现无法初始化数据源,报错如下: [ERROR][org.springframework.web.context.Cont ...
- Spring源码情操陶冶-ContextLoader
前言-阅读源码有利于陶冶情操,本文承接前文Spring源码情操陶冶-ContextLoaderListener 静态代码块内容 ContextLoader在被主动调用的时候,会执行其的一个静态块,代码 ...
- log4j:WARN No appenders could be found for logger (org.springframework.web.context.ContextLoader).
一.异常描述: log4j:WARN No appenders could be found for logger (org.springframework.web.context.ContextLo ...
- ContextLoader,ContextLoaderListener解读
一.ServletContext 有 addListener(..) 方法,也有创建的方法 createListener(Class<T> c) . 有addFilter(..) 方法,也 ...
- idea出现Error configuring application listener of class org.springframework.web.context.ContextLoader
在IDEA中写spring mvc时出现Error configuring application listener of class org.springframework.web.context. ...
- maven ClassNotFoundException: org.springframework.web.context.ContextLoader
信息: Starting Servlet Engine: Apache Tomcat/6.0.32 2012-3-31 9:39:40 org.apache.catalina.core.Standar ...
- 关于解决java.lang.ClassNotFoundException: org.springframework.web.context.ContextLoader问题
解决方案: 其实是你的jar文件没有同步发布到自己项目的lib目录中 (如果是用Maven进行构建的话) 可以试试 下面的办法 –rebuild下project就可以了 项目点击右键 点击 Prope ...
随机推荐
- saiku数据实现实时更新
(1) # vim saiku-server/tomcat/webapps/ROOT/js/saiku/Settings.yaml 将 LOCALSTORAGE_EXPIRATION: 3600000 ...
- ThinkCMF5.1虚拟机下安装的问题,已成功
官方的解决方案:https://www.kancloud.cn/thinkcmf/faq/1197179 按它的提示,发现阿里云的虚拟主机htdoc同级的目录没有上传权限. 只能把“ThinkCMF文 ...
- mysql占用磁盘IO过高的解决办法
一.现象 最近发现Mysql服务器磁盘IO一直很高 [root@push-- ~]# iostat -k -d -x Linux -.el7.x86_64 (push--) 2019年07月05日 _ ...
- 如何在Linux下安装Tomcat
上篇文章写到了Linux下安装JDK1.8,这篇文章详细阐述一下 如何在Linux下安装Tomcat!!!有啥问题可以留言,博主每天都会看博客的. 准备步骤和方法和以前一样,博主用的工具是XShell ...
- React 错误处理(componentDidCatch)
前言 看react 文档突然发现有这个 错误处理函数,好像是17年9月出的,这个真的绝了可以帮助我们捕捉错误咯 React 16 将提供一个内置函数 componentDidCatch,如果 rend ...
- CodeForces-1167C
链接: https://vjudge.net/problem/CodeForces-1167C 题意: In some social network, there are n users commun ...
- Struts 2 实现Action的几种方式_java - JAVA
文章来源:嗨学网 敏而好学论坛www.piaodoo.com 欢迎大家相互学习 Action用于处理用户的请求,因此也被称为业务控制器.每个Action类就是一个工作单元,Struts 2框架负责将用 ...
- spark的accumulator值保存在哪里?
答案:保存在driver端.因此需要对收集的信息的规模要加以控制,不宜过大.避免 driver端的outofmemory问题!!!
- 4. ClustrixDB CLX命令详解
Clustrix提供了一个名为clx的实用程序来管理其分布式ClustrixDB数据库. 命令在 /opt/clustrix/bin/ 下面 sudo su - clxm 用户即可使用 clx hel ...
- mybatis config 配置设置说明
<!– 配置设置 –> 2. <settings> 3. <!– 配置全局性 cache 的 ( 开 / 关) defau ...