![](https://img-blog.csdnimg.cn/20201014180756916.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
java
lean1252
擅长站点的快速开发
展开
-
文件下载相关代码
1 添加apache commons-io包 [code="java"] protected void download(String fileName, String fileExtension, InputStream stream) throws Exception { HttpServletRequest request = getRequest(); HttpServle...原创 2010-07-16 12:06:29 · 97 阅读 · 0 评论 -
代码分享链接帮java code
[code="java"] package com.asflex.utils; import java.io.UnsupportedEncodingException; import java.net.URLEncoder; import java.util.HashMap; import java.util.Iterator; import java.util.Map; ...原创 2011-04-28 14:48:31 · 151 阅读 · 0 评论 -
(转)Fatal JVM Crash - 'java.lang.OutOfMemoryError .. Out of Swap Space?'
Symptoms Confluence (and other applications running on the JVM) become unavailable. Files with names like hs_err_pid123456.log may be created in the application server's bin directory (wherever y...原创 2013-12-13 22:22:12 · 368 阅读 · 0 评论 -
JConsole远程连接参数配置
[quote]1.在java opt下添加如下内容:[/quote] [color=red][b]如果是无须验证添加[/b][/color] [code="java"] JAVA_OPTS="$JAVA_OPTS -Dcom.sun.management.jmxremote.port=12345" JAVA_OPTS="$JAVA_OPTS -Dcom.sun.management.jm...原创 2013-12-17 16:14:32 · 315 阅读 · 0 评论 -
java替换指定url里的参数值
[quote]java解析替换[/quote] [code="java"] public static String replaceAccessToken(String url, String name, String accessToken) { if(StringUtils.isNotBlank(url) && StringUtils.isNotBlank(accessToken))...原创 2014-01-09 18:54:22 · 2214 阅读 · 0 评论 -
httpclient https请求
[code="java"] import java.io.IOException; import java.io.UnsupportedEncodingException; import java.util.Iterator; import java.util.List; import java.util.Map; import java.util.Map.Entry; ...2014-03-28 19:27:20 · 182 阅读 · 0 评论 -
牺牲cpu减少fullgc暂停时间vm参数配置
[code="java"]-Xms4096m -Xmx4096m -XX:PermSize=256m -XX:NewSize=384m -XX:NewRatio=4 -XX:+UseParNewGC -XX:ParallelGCThreads=4 -XX:+UseConcMarkSweepGC -XX:+CMSParallelRemarkEnabled -XX:CMSInitiatingOcc...原创 2013-11-04 20:26:18 · 160 阅读 · 0 评论