jira.codehaus.org

  • Log In Access more options
    • Online Help
    • Keyboard Shortcuts
    • About JIRA
    • JIRA Credits
    • What?s New
  • Dashboards Access more options (Alt+d)
  • Projects Access more options (Alt+p)
  • Issues Access more options (Alt+i)
  • Sonar
  • SONAR-169

Can not generate charts on Linux

  • Log In
  • Views
    • XML
    • Word
    • Printable

Details

  • Type: Bug Bug
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Fixed
  • Affects Version/s: 1.0.2
  • Fix Version/s: 1.2
  • Component/s: None
  • Labels:
    None

Description

Request from Christophe Lallement on the mailing-list :

I'm testing sonar and i have an error whith (JFreeChart), full trace is available at end of mail
I run sonar 1.0.2 on linux AS4 with JDK 1.6. All works fine exept for graph widget.
I check my sonar installtion and found JFreeChar here:
> find . -name "jfree*"
./lib/sonar-web/app/models/service/jfreechart.rb
./lib/sonar-web/WEB-INF/lib/jfreechart-1.0.7.jar

Full trace:

2008.02.11 10:24:12 ERROR rails.sonar -

NativeException (java.lang.NoClassDefFoundError: Could not initialize class org.jfree.chart.JFreeChart):
HistoryChart.java:112:in `ch.hortis.sonar.web.charts.HistoryChart.getChartImage'
BaseChart.java:100:in `ch.hortis.sonar.web.charts.BaseChart.exportChartAsPNG'
BaseChart.java:106:in `ch.hortis.sonar.web.charts.BaseChart.exportChartAsPNG'
NativeMethodAccessorImpl.java:-2:in `sun.reflect.NativeMethodAccessorImpl.invoke0'
NativeMethodAccessorImpl.java:39:in `sun.reflect.NativeMethodAccessorImpl.invoke'
DelegatingMethodAccessorImpl.java:25:in `sun.reflect.DelegatingMethodAccessorImpl.invoke'
Method.java:597:in `java.lang.reflect.Method.invoke'
JavaMethod.java:196:in `org.jruby.javasupport.JavaMethod.invokeWithExceptionHandling'
JavaMethod.java:172:in `org.jruby.javasupport.JavaMethod.invoke'
JavaClass.java:439:in `org.jruby.javasupport.JavaClass$InstanceMethodInvoker.execute'
SimpleCallbackMethod.java:81:in `org.jruby.internal.runtime.methods.SimpleCallbackMethod.call'
EvaluationState.java:571:in `org.jruby.evaluator.EvaluationState.callNode'
EvaluationState.java:207:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:2199:in `org.jruby.evaluator.EvaluationState.setupArgs'
EvaluationState.java:1008:in `org.jruby.evaluator.EvaluationState.fCallNode'
EvaluationState.java:253:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:164:in `org.jruby.evaluator.EvaluationState.eval'
DefaultMethod.java:142:in `org.jruby.internal.runtime.methods.DefaultMethod.internalCall'
DynamicMethod.java:79:in `org.jruby.internal.runtime.methods.DynamicMethod.call'
EvaluationState.java:1025:in `org.jruby.evaluator.EvaluationState.fCallNode'
EvaluationState.java:253:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:533:in `org.jruby.evaluator.EvaluationState.blockNode'
EvaluationState.java:201:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:164:in `org.jruby.evaluator.EvaluationState.eval'
DefaultMethod.java:142:in `org.jruby.internal.runtime.methods.DefaultMethod.internalCall'
DynamicMethod.java:79:in `org.jruby.internal.runtime.methods.DynamicMethod.call'
EvaluationState.java:571:in `org.jruby.evaluator.EvaluationState.callNode'
EvaluationState.java:207:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:1236:in `org.jruby.evaluator.EvaluationState.localAsgnNode'
EvaluationState.java:286:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:533:in `org.jruby.evaluator.EvaluationState.blockNode'
EvaluationState.java:201:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:164:in `org.jruby.evaluator.EvaluationState.eval'
DefaultMethod.java:142:in `org.jruby.internal.runtime.methods.DefaultMethod.internalCall'
DynamicMethod.java:79:in `org.jruby.internal.runtime.methods.DynamicMethod.call'
RubyObject.java:575:in `org.jruby.RubyObject.callMethod'
RubyObject.java:462:in `org.jruby.RubyObject.callMethod'
RubyObject.java:1396:in `org.jruby.RubyObject.send'
null:-1:in `org.jruby.RubyObjectInvokersendxx1.call'
InvocationCallback.java:49:in `org.jruby.runtime.callback.InvocationCallback.execute'
FullFunctionCallbackMethod.java:78:in `org.jruby.internal.runtime.methods.FullFunctionCallbackMethod.internalCall'
DynamicMethod.java:79:in `org.jruby.internal.runtime.methods.DynamicMethod.call'
EvaluationState.java:1025:in `org.jruby.evaluator.EvaluationState.fCallNode'
EvaluationState.java:253:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:533:in `org.jruby.evaluator.EvaluationState.blockNode'
EvaluationState.java:201:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:164:in `org.jruby.evaluator.EvaluationState.eval'
DefaultMethod.java:142:in `org.jruby.internal.runtime.methods.DefaultMethod.internalCall'
DynamicMethod.java:79:in `org.jruby.internal.runtime.methods.DynamicMethod.call'
AliasMethod.java:71:in `org.jruby.internal.runtime.methods.AliasMethod.call'
EvaluationState.java:1760:in `org.jruby.evaluator.EvaluationState.vcallNode'
EvaluationState.java:382:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:1464:in `org.jruby.evaluator.EvaluationState.orNode'
EvaluationState.java:339:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:1589:in `org.jruby.evaluator.EvaluationState.returnNode'
EvaluationState.java:354:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:533:in `org.jruby.evaluator.EvaluationState.blockNode'
EvaluationState.java:201:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:164:in `org.jruby.evaluator.EvaluationState.eval'
DefaultMethod.java:142:in `org.jruby.internal.runtime.methods.DefaultMethod.internalCall'
DynamicMethod.java:79:in `org.jruby.internal.runtime.methods.DynamicMethod.call'
EvaluationState.java:1025:in `org.jruby.evaluator.EvaluationState.fCallNode'
EvaluationState.java:253:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:164:in `org.jruby.evaluator.EvaluationState.eval'
DefaultMethod.java:142:in `org.jruby.internal.runtime.methods.DefaultMethod.internalCall'
DynamicMethod.java:79:in `org.jruby.internal.runtime.methods.DynamicMethod.call'
AliasMethod.java:71:in `org.jruby.internal.runtime.methods.AliasMethod.call'
AliasMethod.java:71:in `org.jruby.internal.runtime.methods.AliasMethod.call'
EvaluationState.java:1760:in `org.jruby.evaluator.EvaluationState.vcallNode'
EvaluationState.java:382:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:164:in `org.jruby.evaluator.EvaluationState.eval'
Block.java:220:in `org.jruby.runtime.Block.yield'
EvaluationState.java:1832:in `org.jruby.evaluator.EvaluationState.yieldNode'
EvaluationState.java:391:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:533:in `org.jruby.evaluator.EvaluationState.blockNode'
EvaluationState.java:201:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:164:in `org.jruby.evaluator.EvaluationState.eval'
DefaultMethod.java:142:in `org.jruby.internal.runtime.methods.DefaultMethod.internalCall'
DynamicMethod.java:79:in `org.jruby.internal.runtime.methods.DynamicMethod.call'
WrapperMethod.java:61:in `org.jruby.internal.runtime.methods.WrapperMethod.call'
EvaluationState.java:583:in `org.jruby.evaluator.EvaluationState.callNode'
EvaluationState.java:207:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:550:in `org.jruby.evaluator.EvaluationState.callNode'
EvaluationState.java:207:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:439:in `org.jruby.evaluator.EvaluationState.arrayNode'
EvaluationState.java:190:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:550:in `org.jruby.evaluator.EvaluationState.callNode'
EvaluationState.java:207:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:1236:in `org.jruby.evaluator.EvaluationState.localAsgnNode'
EvaluationState.java:286:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:533:in `org.jruby.evaluator.EvaluationState.blockNode'
EvaluationState.java:201:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:164:in `org.jruby.evaluator.EvaluationState.eval'
DefaultMethod.java:142:in `org.jruby.internal.runtime.methods.DefaultMethod.internalCall'
DynamicMethod.java:79:in `org.jruby.internal.runtime.methods.DynamicMethod.call'
AliasMethod.java:71:in `org.jruby.internal.runtime.methods.AliasMethod.call'
AliasMethod.java:71:in `org.jruby.internal.runtime.methods.AliasMethod.call'
EvaluationState.java:1760:in `org.jruby.evaluator.EvaluationState.vcallNode'
EvaluationState.java:382:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:1520:in `org.jruby.evaluator.EvaluationState.rescueNode'
EvaluationState.java:350:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:164:in `org.jruby.evaluator.EvaluationState.eval'
DefaultMethod.java:142:in `org.jruby.internal.runtime.methods.DefaultMethod.internalCall'
DynamicMethod.java:79:in `org.jruby.internal.runtime.methods.DynamicMethod.call'
AliasMethod.java:71:in `org.jruby.internal.runtime.methods.AliasMethod.call'
RubyObject.java:575:in `org.jruby.RubyObject.callMethod'
RubyObject.java:462:in `org.jruby.RubyObject.callMethod'
RubyObject.java:1396:in `org.jruby.RubyObject.send'
null:-1:in `org.jruby.RubyObjectInvokersendxx1.call'
InvocationCallback.java:49:in `org.jruby.runtime.callback.InvocationCallback.execute'
FullFunctionCallbackMethod.java:78:in `org.jruby.internal.runtime.methods.FullFunctionCallbackMethod.internalCall'
DynamicMethod.java:79:in `org.jruby.internal.runtime.methods.DynamicMethod.call'
EvaluationState.java:1025:in `org.jruby.evaluator.EvaluationState.fCallNode'
EvaluationState.java:253:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:533:in `org.jruby.evaluator.EvaluationState.blockNode'
EvaluationState.java:201:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:985:in `org.jruby.evaluator.EvaluationState.ensureNode'
EvaluationState.java:247:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:164:in `org.jruby.evaluator.EvaluationState.eval'
DefaultMethod.java:142:in `org.jruby.internal.runtime.methods.DefaultMethod.internalCall'
DynamicMethod.java:79:in `org.jruby.internal.runtime.methods.DynamicMethod.call'
AliasMethod.java:71:in `org.jruby.internal.runtime.methods.AliasMethod.call'
EvaluationState.java:1025:in `org.jruby.evaluator.EvaluationState.fCallNode'
EvaluationState.java:253:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:533:in `org.jruby.evaluator.EvaluationState.blockNode'
EvaluationState.java:201:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:164:in `org.jruby.evaluator.EvaluationState.eval'
DefaultMethod.java:142:in `org.jruby.internal.runtime.methods.DefaultMethod.internalCall'
DynamicMethod.java:79:in `org.jruby.internal.runtime.methods.DynamicMethod.call'
AliasMethod.java:71:in `org.jruby.internal.runtime.methods.AliasMethod.call'
AliasMethod.java:71:in `org.jruby.internal.runtime.methods.AliasMethod.call'
EvaluationState.java:1025:in `org.jruby.evaluator.EvaluationState.fCallNode'
EvaluationState.java:253:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:533:in `org.jruby.evaluator.EvaluationState.blockNode'
EvaluationState.java:201:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:164:in `org.jruby.evaluator.EvaluationState.eval'
DefaultMethod.java:142:in `org.jruby.internal.runtime.methods.DefaultMethod.internalCall'
DynamicMethod.java:79:in `org.jruby.internal.runtime.methods.DynamicMethod.call'
AliasMethod.java:71:in `org.jruby.internal.runtime.methods.AliasMethod.call'
EvaluationState.java:571:in `org.jruby.evaluator.EvaluationState.callNode'
EvaluationState.java:207:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:164:in `org.jruby.evaluator.EvaluationState.eval'
DefaultMethod.java:142:in `org.jruby.internal.runtime.methods.DefaultMethod.internalCall'
DynamicMethod.java:79:in `org.jruby.internal.runtime.methods.DynamicMethod.call'
EvaluationState.java:571:in `org.jruby.evaluator.EvaluationState.callNode'
EvaluationState.java:207:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:550:in `org.jruby.evaluator.EvaluationState.callNode'
EvaluationState.java:207:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:533:in `org.jruby.evaluator.EvaluationState.blockNode'
EvaluationState.java:201:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:533:in `org.jruby.evaluator.EvaluationState.blockNode'
EvaluationState.java:201:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:1520:in `org.jruby.evaluator.EvaluationState.rescueNode'
EvaluationState.java:350:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:985:in `org.jruby.evaluator.EvaluationState.ensureNode'
EvaluationState.java:247:in `org.jruby.evaluator.EvaluationState.evalInternal'
EvaluationState.java:164:in `org.jruby.evaluator.EvaluationState.eval'
DefaultMethod.java:142:in `org.jruby.internal.runtime.methods.DefaultMethod.internalCall'
DynamicMethod.java:79:in `org.jruby.internal.runtime.methods.DynamicMethod.call'
RubyObject.java:575:in `org.jruby.RubyObject.callMethod'
RubyObject.java:445:in `org.jruby.RubyObject.callMethod'
RailsServlet.java:99:in `org.jruby.webapp.RailsServlet.dispatchRequest'
RailsServlet.java:58:in `org.jruby.webapp.RailsServlet.serviceRequest'
RailsServlet.java:42:in `org.jruby.webapp.RailsServlet.service'
HttpServlet.java:820:in `javax.servlet.http.HttpServlet.service'
ServletHolder.java:487:in `org.mortbay.jetty.servlet.ServletHolder.handle'
ServletHandler.java:362:in `org.mortbay.jetty.servlet.ServletHandler.handle'
SecurityHandler.java:216:in `org.mortbay.jetty.security.SecurityHandler.handle'
SessionHandler.java:181:in `org.mortbay.jetty.servlet.SessionHandler.handle'
ContextHandler.java:712:in `org.mortbay.jetty.handler.ContextHandler.handle'
WebAppContext.java:405:in `org.mortbay.jetty.webapp.WebAppContext.handle'
HandlerCollection.java:114:in `org.mortbay.jetty.handler.HandlerCollection.handle'
HandlerWrapper.java:139:in `org.mortbay.jetty.handler.HandlerWrapper.handle'
Server.java:313:in `org.mortbay.jetty.Server.handle'
HttpConnection.java:506:in `org.mortbay.jetty.HttpConnection.handleRequest'
HttpConnection.java:830:in `org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete'
HttpParser.java:514:in `org.mortbay.jetty.HttpParser.parseNext'
HttpParser.java:211:in `org.mortbay.jetty.HttpParser.parseAvailable'
HttpConnection.java:381:in `org.mortbay.jetty.HttpConnection.handle'
SelectChannelEndPoint.java:396:in `org.mortbay.io.nio.SelectChannelEndPoint.run'
BoundedThreadPool.java:442:in `org.mortbay.thread.BoundedThreadPool$PoolThread.run'
/app/models/service/jfreechart.rb:105:in `rules_compliance_history_chart'
/app/controllers/chart_controller.rb:68:in `rules_compliance_history_chart'
/export/home/frtdevrep/maven/sonar/lib/sonar-web/WEB-INF/gems/gems/actionpack-1.13.3/lib/action_controller/base.rb:1095:in `send'
/export/home/frtdevrep/maven/sonar/lib/sonar-web/WEB-INF/gems/gems/actionpack-1.13.3/lib/action_controller/base.rb:1095:in `perform_action'
/export/home/frtdevrep/maven/sonar/lib/sonar-web/WEB-INF/gems/gems/actionpack-1.13.3/lib/action_controller/filters.rb:632:in `call_filter'
/export/home/frtdevrep/maven/sonar/lib/sonar-web/WEB-INF/gems/gems/actionpack-1.13.3/lib/action_controller/filters.rb:619:in `perform_action_with_filters'
/export/home/frtdevrep/maven/sonar/lib/sonar-web/WEB-INF/gems/gems/actionpack-1.13.3/lib/action_controller/benchmarking.rb:66:in `perform_action_with_benchmark'
/export/home/frtdevrep/maven/sonar/lib/sonar-web/WEB-INF/gems/gems/actionpack-1.13.3/lib/action_controller/rescue.rb:83:in `measure'
/export/home/frtdevrep/maven/sonar/lib/sonar-web/WEB-INF/gems/gems/actionpack-1.13.3/lib/action_controller/benchmarking.rb:66:in `perform_action_with_benchmark'
/export/home/frtdevrep/maven/sonar/lib/sonar-web/WEB-INF/gems/gems/actionpack-1.13.3/lib/action_controller/rescue.rb:83:in `perform_action_with_rescue'
/export/home/frtdevrep/maven/sonar/lib/sonar-web/WEB-INF/gems/gems/actionpack-1.13.3/lib/action_controller/base.rb:430:in `send'
/export/home/frtdevrep/maven/sonar/lib/sonar-web/WEB-INF/gems/gems/actionpack-1.13.3/lib/action_controller/base.rb:430:in `process'
/export/home/frtdevrep/maven/sonar/lib/sonar-web/WEB-INF/gems/gems/actionpack-1.13.3/lib/action_controller/filters.rb:624:in `process_with_filters'
/export/home/frtdevrep/maven/sonar/lib/sonar-web/WEB-INF/gems/gems/actionpack-1.13.3/lib/action_controller/session_management.rb:114:in `process_with_session_management_support'
/export/home/frtdevrep/maven/sonar/lib/sonar-web/WEB-INF/gems/gems/actionpack-1.13.3/lib/action_controller/base.rb:330:in `process'
/export/home/frtdevrep/maven/sonar/lib/sonar-web/WEB-INF/gems/gems/rails-1.2.3/lib/dispatcher.rb:41:in `dispatch'

Activity

Ascending order - Click to sort in descending order
  • All
  • Comments
  • Work Log
  • History
  • Activity
Hide
Permalink
Christophe Lallement added a comment - 11/Feb/08 4:33 AM

Test without success on jre 1.5.0_10

Christophe.

Show
Christophe Lallement added a comment - 11/Feb/08 4:33 AM Test without success on jre 1.5.0_10 Christophe.
Hide
Permalink
Simon Brandhof added a comment - 11/Feb/08 11:45 AM

Which JDK distribution do you use ? Sun / IBM / BEA ... ? Did you override the default parameters from wrapper.conf ?

Show
Simon Brandhof added a comment - 11/Feb/08 11:45 AM Which JDK distribution do you use ? Sun / IBM / BEA ... ? Did you override the default parameters from wrapper.conf ?
Hide
Permalink
Simon Brandhof added a comment - 19/Feb/08 9:56 AM

We experience problems to execute Java applications from the 64bits JVM installed on our virtualized linux (ubuntu 7). The ticket is postponed to 1.1.1 or 1.2 release.

Show
Simon Brandhof added a comment - 19/Feb/08 9:56 AM We experience problems to execute Java applications from the 64bits JVM installed on our virtualized linux (ubuntu 7). The ticket is postponed to 1.1.1 or 1.2 release.
Hide
Permalink
Christophe Lallement added a comment - 17/Mar/08 4:51 AM

Hi Simon

Just to say that all works fine after our 1.1 migration.
Picture / Chart are now displayed, i think the pb was coming from JVM option -Djava.awt.headless=true (we add it only since 1.1)

Regards
Christophe

PS: We do not use a 64b platforme.

Show
Christophe Lallement added a comment - 17/Mar/08 4:51 AM Hi Simon Just to say that all works fine after our 1.1 migration. Picture / Chart are now displayed, i think the pb was coming from JVM option -Djava.awt.headless=true (we add it only since 1.1) Regards Christophe PS: We do not use a 64b platforme.
Hide
Permalink
Simon Brandhof added a comment - 18/Mar/08 1:18 PM

OK, the issue title is updated without the 64bits mention.
The parameter -Djava.awt.headless=true is added to wrapper.conf.
Thanks for your help.

Show
Simon Brandhof added a comment - 18/Mar/08 1:18 PM OK, the issue title is updated without the 64bits mention. The parameter -Djava.awt.headless=true is added to wrapper.conf. Thanks for your help.
Hide
Permalink
Ben Lidgey added a comment - 28/Apr/10 3:59 AM

It is probably worth updating the documentation to make sure the java.awt.headless=true option is added to servlet container config too. We run Sonar in Tomcat which didn't have that setting, so the charts still failed to be created until I added it to the Tomcat options and restarted Tomcat.

I couldn't see anything on http://www.sonarsource.org/support/documentation/ and child pages.

Show
Ben Lidgey added a comment - 28/Apr/10 3:59 AM It is probably worth updating the documentation to make sure the java.awt.headless=true option is added to servlet container config too. We run Sonar in Tomcat which didn't have that setting, so the charts still failed to be created until I added it to the Tomcat options and restarted Tomcat. I couldn't see anything on http://www.sonarsource.org/support/documentation/ and child pages.

People

  • Assignee:
    Simon Brandhof
    Reporter:
    Simon Brandhof
Vote (1)
Watch (1)

Dates

  • Created:
    11/Feb/08 3:41 AM
    Updated:
    28/Apr/10 3:59 AM
    Resolved:
    18/Mar/08 1:18 PM
  • Atlassian JIRA (v5.0.4#731-sha1:3aa7374)
  • Report a problem
  • Powered by a free Atlassian JIRA open source license for Codehaus. Try JIRA - bug tracking software for your team.