摘要:
Date dNow = new Date(); //当前时间 Date dBefore = new Date(); Calendar calendar = Calendar.getInstance(); //得到日历 calendar.setTime(dNow);//把当前时间赋给日历 calendar.add(Calendar.DAY_OF_MONTH, -100); //设置为前一天 dBefore = calendar.getTime(); //得到前一天的时间 SimpleDateFormat sdf=new SimpleDateFormat("yyyy-MM-dd HH.. 阅读全文
摘要:
这几天研究了一个tomcat与内存的关系,先写一篇关于如何查看Tomcat内存的情况,稍后继续续写其他关于Tomcat的博客。 1. Tomcat6中没有设置任何默认用户,因而需要手动往Tomcat6的conf文件夹下的tomcat-users.xml文件中添加用户。 如:<role rolename="manager"/> <user username="tomcat" password="tomcat" roles="manager"/> 注:添加完需要重启Tomcat6。 2. 访问h 阅读全文