Million of entries in logfile

Hey.

Can you tell me, what is responsible for this errors in the logfiles?

2015-02-26 10:38:56,391 http-bio-8080-exec-70072 ERROR info 638x3148734x1 k0wx6f 10.1.16.124,10.1.16.51 /rest/api/2/search [onresolve.jira.groovy.GroovyCustomField] javax.script.ScriptException: org.codehaus.groovy.runtime.typehandling.GroovyCastException: Cannot cast object 'DocumentIssueImpl[issueKey=IT-6698]' with class 'com.atlassian.jira.issue.DocumentIssueImpl' to class 'com.atlassian.jira.issue.MutableIssue'
2015-02-26 10:38:56,398 http-bio-8080-exec-70072 ERROR info 638x3148734x1 k0wx6f 10.1.16.124,10.1.16.51 /rest/api/2/search [onresolve.jira.groovy.GroovyCustomField] javax.script.ScriptException: org.codehaus.groovy.runtime.typehandling.GroovyCastException: Cannot cast object 'DocumentIssueImpl[issueKey=IT-6698]' with class 'com.atlassian.jira.issue.DocumentIssueImpl' to class 'com.atlassian.jira.issue.MutableIssue'
2015-02-26 10:38:56,421 http-bio-8080-exec-70149 ERROR PersonickB 638x3148762x2 x6zq90 10.0.0.216,10.1.16.51 /sr/jira.issueviews:searchrequest-xml/temp/SearchRequest.xml [onresolve.jira.groovy.GroovyCustomField] javax.script.ScriptException: org.codehaus.groovy.runtime.typehandling.GroovyCastException: Cannot cast object 'DocumentIssueImpl[issueKey=NT-1328]' with class 'com.atlassian.jira.issue.DocumentIssueImpl' to class 'com.atlassian.jira.issue.MutableIssue'

The logfile is growing 30 GB in 2 days.

2 answers

It is pretty simple to avoid this problem.  I didn't test this in a scripted field but in a validator I did something like this.

(where thisIssue =  a returned issue from the JQL query / com.atlassian.jira.issue.DocumentIssueImpl' )

MutableIssue mIssue = issueManager.getIssueObject(thisIssue.getId())

 

 

You need to be careful to load it from the database only if you actually need to... there will be a performance hit if you do this for many issues returned from your query.

0 vote

Check your script fields, looks like you have one that does a JQL query and attempts to cast it to a MutableIssue. If you just want to "solve" the problem then remove the script field.

Jamie, Even i am facing the same issue, is there any solution to avoid this error instead removing scripted field. Thanks, Vijay

Suggest an answer

Log in or Sign up to answer
How to earn badges on the Atlassian Community

How to earn badges on the Atlassian Community

Badges are a great way to show off community activity, whether you’re a newbie or a Champion.

Learn more
Community showcase
Published Tuesday in Marketplace Apps

If you’re an Atlassian app developer, you’ll want to know about Atlas Camp!

This September 6-7, hundreds of Atlassian App developers will flock to Barcelona Spain to build skills, discover product roadmaps, meet face-to-face with the Atlassian team, and learn how to extend t...

119 views 0 4
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you