自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(22)
  • 资源 (2)
  • 收藏
  • 关注

原创 LifecycleProcessor not initialized - call 'refresh' before invoking lifecycle methods via the contex

activemq 启动报错:LifecycleProcessor not initialized - call 'refresh' before invoking lifecycle methods via the context解决: linux 主机名有问题去掉特殊符号后重启。

2018-10-31 14:57:47 1214

原创 ERROR 1044 (42000): Access denied for user

问题:          安装完mysql后,执行mysql -u root             update user set host = '%' where host = 'localhost' and user = 'root';          服务器无法连接mysql 和外网无法连接到mysql。解决方案:         查看root账户下是否有grant权...

2018-10-30 22:03:32 299

原创 jenkins重启项目丢失

问题主要是jenkins重启后之前的配置路径丢失解决办法,修改jenkins   web.xml 中  HUDSON_HOME 的value系统默认在/root/.jenkins 

2018-08-24 16:39:08 6916

原创 spring boot session 共享

pom 在pom中添加所用到的依赖。 <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-redis</artifactId> </dependency> <dependenc

2016-11-24 14:08:35 876

原创 springboot 拦截器配置

实现拦截器后,在springboot中需要一个配置类,继承WebMvcConfigurerAdapter 实现,LoginInterceptor为实现的登陆拦截器。@Configurationpublic class ServletInterceptor extends WebMvcConfigurerAdapter { /** * 配置拦截器 * 注意扫描包路径!!

2016-10-24 14:56:29 543

原创 Springboot 404 500错误页面处理

以下方法 Spring-Boot 1.4.x 以上试用,具体看文档。springboot文档@Componentpublic class OpenApiErrorViewResolver implements ErrorViewResolver { @Override public ModelAndView resolveErrorView(HttpServletRequest

2016-10-24 14:37:45 833

原创 springboot maven filter写入properties文件

提示 springboot 不支持原来的properties文件表示把原来${}改成@@,示例如下所示。[email protected]@[email protected]@

2016-10-20 13:44:30 1581 1

原创 springboot RestTemplate 注入

springboot是无法自动注入RestTemplate ,但是springCloud可以自动注入,这样子我们要 在初始化springboot配置类中注入RestTemplate ,这样子在其他class中 @Autowired RestTemplate restUtil就不会有问题了,代码示例如下所示。@EnableAutoConfiguration@ComponentScan(basePa

2016-10-20 11:38:24 8596

原创 springboot副本集mongoDB

pom 在pom文件引入相关的jar包 <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-data-mongodb</artifactId> </dependency>注意:一定不要在pom中引入mo

2016-10-19 17:28:49 3713

原创 springBoot tomcat启动

Application configuration class:@ComponentScan(basePackages = "test")@EnableAutoConfigurationpublic class ServletInitializer extends SpringBootServletInitializer { @Override protected Spring

2016-09-21 18:23:15 2406

原创 轮播图简单实现

二 图片的滚动<!-- 每一行轮播图片站位一个DIV--> <div id="rollImage3" style="display: block;"> <a href="$!shopRenovationMap.get('44').chainUrl" target="_blank"> <img src="$!imageServerAddr$!shop

2016-06-02 14:58:25 362

原创 http接口调用

一httpclient调用http接口public static String sendRequest(String url, Map<String, String> paras) { try { HttpClient httpClient = new HttpClient(); PostMethod httpPost = new PostMethod(url); if (nu

2016-06-02 14:55:57 592

原创 webservice动态调用

一 cxf public static void main(String[] args) { String params[] = {"GXF003", "{'param':'This is the demo for WS calling Java method.'}"}; JaxWsDynamicClientFactory dcf = JaxWsDynamicClientFactory.n

2016-06-02 14:53:27 512

原创 linux常用命令

//服务器远程拷贝 scp tomcat-cas-spcf-jq.tar [email protected]:/usr/local //压缩 tar -zcvf tomcat-cas-spcf-jq.tar ./tomcat-cas-spcf-jq2 //解压 tar -zxvf //复权 chmod -R 777 //进程查看 ps -ef|grep tomcat //删除

2016-06-02 14:49:10 345

原创 jsonp

ajax请求: 前端一$.ajax({ url:martVar + "/freightTemplate/queryById", dataType:"jsonp", //jsonp:"callback",//不指定,系统随机生成 data:{

2016-06-02 14:46:31 383

原创 JS跨域获取cookies

1. 通过$.getScript跨域获得cookies前端代码$.getScript('$siteDomain/ssoApi?'+Math.random(),function(){ console.log(" username:" + userCookie.uname); alert(userCookie.uname);})后台代码@ResponseBody@RequestMap

2016-06-02 14:41:29 1684

原创 CAS 集群

使用nginx-sticky实现CAS集群 参考文档http://www.ttlsa.com/nginx/nginx-modules-nginx-sticky-module/ 简介:这种方法实现CAS集群是当应用请求通过nginx转发到认证中心时候,会在客服端cookie中存入一个md5码,nginx通过这个md5码对应后后台的CAS上,以后所有的认证服务都会在同一台CAS上。 1. ngi

2016-06-02 14:24:15 480

原创 redisDB

package org.jasig.cas.util;import javax.annotation.Resource;import org.jasig.cas.ticket.Ticket;import org.springframework.data.redis.core.RedisTemplate;import org.springframework.stereotype.Component

2016-06-02 13:43:22 277

原创 redis 主从复制

Spring 版本兼容性问题 3.2.5master 主redis默认配置就可以。 redis.conf 直接写:port 63792.slave 修改redis.conf配置 port 6379 slaveof 10.6.60.166 6379 主redis地址 配置 sentinel.conf 如下: port 26379 sentinel monitor mymas

2016-06-02 11:47:30 348

原创 zookeeper简单集群

安装zookeeper修改zoo.conf 配置dataDir路径 在data目录下创建myid标识zookeeper是第几个 按照我的配置是server.1,我的当前zookeeper id应该标志为1 直接vi 创建myid文件写入1便可。 在配置dubbo服务注册zookeeper地址的时候可以直接用逗号隔开多个zookeeper地址,实现对zookeeper的集群。

2016-06-02 11:37:27 397

原创 bootstrap Table 后台交互

bootstrap Table 后台交互tableth对应的字段和实体相对应,bootstrap能自动封装。<div id="applyLog" style="z-index: 1000000019; display: none; width: 750px; height: 300px; overflow: auto; position: absolute; left: 50%; margin

2016-05-31 15:19:08 10341

原创 剖析mysql查询

剖析mysql查询使用SHOW PROFILE开启 mysql>set profiling =1 默认是关闭show profiles 查看所有临时表记录show profile for query 1 1是要详细查看的queryId

2016-05-31 15:00:08 396

Json转换工具

StringToJson

2016-08-22

fastdfs_client_v1.24

fastdfs_client_v1.24

2016-07-05

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除