[jboss-user] [Performance Tuning] - Re: Trying to increase performance, doesn't seem to be CPU o
PeterJ
do-not-reply at jboss.com
Thu Jul 24 19:01:30 EDT 2008
jamicide, are you sure you need 3GB of heap? Graphing the results should help you determine that. No sense using more memory that what you need.
tsmets, I wrote a simple Java app that uses a regular expression to gather the verbose:gc data and convert it to a CSV file. I then read the CSV file into a spreadsheet app (Excel or OpenOffice.org Calc) and use its graphing features to chart the results.
Here is my Java app:
import java.io.*;
| import java.util.regex.*;
| public class Analyzer {
| public static void main(String[] args) throws Exception {
| InputStream fin = new FileInputStream(args[0]);
| int iSize = fin.available();
| byte mvIn[] = new byte[iSize];
| fin.read(mvIn, 0, iSize);
| fin.close();
| String strText = new String(mvIn);
| PrintStream fout = new PrintStream
| (new FileOutputStream(args[0] + ".csv"));
| fout.println("Before,After,Seconds");
| Pattern p = Pattern.compile
| ("\\[(?:Full |)GC (\\d*)K->(\\d*)K\\(\\d*K\\), ([\\d.]*) secs\\]");
| Matcher m = p.matcher(strText);
| while (m.find())
| fout.println(m.group(1) + "," + m.group(2) + "," + m.group(3));
| fout.close();
| }
| }
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4166528#4166528
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4166528
More information about the jboss-user
mailing list