Search found 6 matches

by Developer Dude
Tue Sep 30, 2008 3:21 pm
Forum: JFreeChart
Topic: Memory Leak?
Replies: 12
Views: 14939

In one application I worked on we had a synch manager framework that used weak references to help keep different views aware of changes to various entities that a view might be displaying. For example, an editor might allow the user to change or delete an entity that was opened as a node from a tree...
by Developer Dude
Tue Sep 30, 2008 12:41 am
Forum: JFreeChart
Topic: Crude scaling benchmarks of JFreeChart - YMMV
Replies: 2
Views: 5147

You should also notice: Within JFreeReport when exporting PDFs, we do not generate buffered images (as this is ugly for printing); we generate Vector-images instead. AFAIK, JasperReports does the same. That's good to know. I had come across an example of the difference between the two and it is qui...
by Developer Dude
Mon Sep 29, 2008 9:33 pm
Forum: JFreeChart
Topic: Crude scaling benchmarks of JFreeChart - YMMV
Replies: 2
Views: 5147

Crude scaling benchmarks of JFreeChart - YMMV

I am assessing a number of reporting and charting frameworks. Since JFreeChart and JFreeReports are used in at least one of these (Jasper) I was interested to see how they scaled. The application would be generating tens of thousands of reports each night, each with at least one graphic (pie chart o...
by Developer Dude
Mon Sep 29, 2008 8:47 pm
Forum: JFreeChart
Topic: Memory Leak?
Replies: 12
Views: 14939

Well, if you hold a reference to the same dataset instance all the time, then you will run into trouble. But for reporting needs, you usually create a new dataset based on data from a database or so each time you run a report. And if you have a long running global object, then well, you may have to...
by Developer Dude
Mon Sep 29, 2008 8:25 pm
Forum: JFreeChart
Topic: Memory Leak?
Replies: 12
Views: 14939

...and neither object is garbage collected even though both objects have no other references - they hold a reference to each other. That's not true, the garbage collector is "smart" enough to detect such cycles and remove the objects. I mispoke: there isn't a cycle; the chart doesn't have a referen...
by Developer Dude
Mon Sep 29, 2008 6:06 pm
Forum: JFreeChart
Topic: Memory Leak?
Replies: 12
Views: 14939

I took a look into the source code for XYPlot and saw what was happening when I called setDataSet(null); and it looked like it was removing change listeners. So I tried the following code and it fixed it just the same as running setDataSet(null); if(chart != null && chart.getXYPlot().getDataset() !...