Thursday, January 10, 2008

[ANN] JFreeChart Eastwood Servlet Plugin

I just finished the plugin for JFreeChart's Eastwood Servlet. You can find more information about Eastwood project here.

Basically it's a Google Chart API clone using JFreeChart. Well calling it clone may be an understatement as this is a really cool project.

Anyway I have applied for a plugin developer account and so I hope to be able to upload to the repository soon, and in the meanwhile you can find the plugin here.

For a quick test, once installed open this page, http://localhost:8080/app/plugins/eastwood-chart-0.1/test.gsp. You should see the actual graphs produced from Google Chart on the left and the Eastwood charts on the right side.

(Charts produced by Google Chart on left and Eastwood charts on right)

**UPDATES: File has been uploaded to the plugin repository. You can now install by the usual "grails install-plugin eastwood-chart". For more information go to the plugin page,


Anonymous said...

i've had a deployment issue on tomcat 6.0.16, the "chart" servlet element was duplicated in web.xml, so context startup was not possible :

I fixed it this way in (MyApp\plugins\eastwood-chart-0.1\EastwoodChartGrailsPlugin.groovy):

def doWithWebDescriptor = { xml ->
def servletElement = xml.'servlet'
def servletMapElement = xml.'servlet-mapping'

servletElement[servletElement.size() - 1] + {
'servlet' {

servletMapElement[servletMapElement.size() - 1] + {
'servlet-mapping' {

Seymour Cakes said...

Hi there, thanks for the patch but that problem has been long time back even thought it's still marked as version 0.1.

I just checked out a clean copy of the plugin to confirm the patch has been in. I think you might have got an old copy?

Anonymous said...

Hi there,

Plugin is great, thanks!

One thing though: in EastwoodChartTagLib.groovy you have the following:

String url = grailsAttributes.getApplicationUri(request)
out << "img src=\"${url}chart?"

That url isn't always correct, esp. in the case where we're running with no app context. ie. http://host/controller/action rather than http://host/myapp/controller/action.

Also, certain google API features don't seem to work like shapeRangeFill (chm).