`
zhushidan100
  • 浏览: 29772 次
  • 性别: Icon_minigender_1
  • 来自: 成都
社区版块
存档分类
最新评论
文章列表
java.rmi.ConnectException: Connection refused to host: 127.0.0.1; nested exception is: java.net.ConnectException: Connection refused   最近在做ehcache的分布式(RMI)缓存的时候发现这个异常,折腾了好一会儿   看官方解释: 写道 Essentially, this java call: InetAddress.getLocalHost();always returns the loopback address, which is ...
Ehcache 缓存过期时间的说明:     timeToIdleSeconds="3" timeToLiveSeconds="5"     timeToIdleSeconds指缓存元素空闲的时间,如果从最后一次访问这个元素到当前时间差超出这个值则此元素会失效   timeToLiveSeconds指缓存元素的生存时间,从创建到死亡的时间长度   当然上面的参数是在没有设置缓存永不过期的前提下有效;    
最近做SEO优化,要求返回正确的Content-Language; response.setHeader("Content-Language", "ja");//这个设置没用,这个值跟操作系统有关  于是在nginx重写这个值,简略配置如下;   环境 :http://localhost/french;http://localhost/japanese........等;     location /{ proxy_hide_header 'Content-Language'; #隐藏掉之前的值 if ($re ...
网上很多人的授权都有问题的,特别是因为对于IP那个地方没有用引号.....大部分人COPY的吧..特留此笔记   用root本地账户登录mysql,增加新用户 insert into mysql.user(Host,User,Password) values('%','admin','abc123');--增加admin的账户(密码abc123),此账户可以从任何IP访问,但不包括localhost(version:5.5.9),version:5.7.1 % 也包括localhost的访问 insert into mysql.user(Host,User,Password) val ...
  在用ehcache做搜索的时候,cache不能存放于非内存上(缓存初始化失败),至v 2.5.2,ehcache还没有实现非内存搜索,因此在做缓存的时候不能flush,此方法会将缓存写入硬盘,因此会使缓存丢失. CacheManager cachemanager = CacheManager.getInstance(); Cache cache = cachemanager.getCache("andCache"); Attribute<String> attribute = cache.getSearchAttribute(" ...
  Properties prop = new Properties(); prop.setProperty("charSet", "GB2312"); conn = DriverManager.getConnection(url, prop);  应用是UTF-8的编码.  
package com.hsqldb.dbfilter; import java.io.FileInputStream; import java.io.FileNotFoundException; import java.io.IOException; import java.util.Properties; import javax.servlet.ServletContextEvent; import javax.servlet.ServletContextListener; import org.hsqldb.Server; public class ...
1.创建CA的私钥 1.创建CA的私钥 执行以下命令opensslgenrsa -des3 -out mykey/ca.key 1024   ( mykey/  当前目录下的mykey目录,事先要建立好)接下来会提示你输入密码. 2.创建CA证书 (
SSL:tomcat  server.xml配置     <!-- SSL --> <Connector port="8443" maxHttpHeaderSize="8192" SSLEnabled="true" maxThreads="150" minSpareThreads="25" maxSpareThreads="75" enableLo ...
<!-- 服务端代码: --> <jaxws:endpoint id="userWebService" implementor="#userServiceImpl" address="/userservice"> <jaxws:inInterceptors> <bean class="org.apache.cxf.interceptor.LoggingInInterceptor"></bean> <bean cla ...
Global site tag (gtag.js) - Google Analytics