html – ERROR errors.GrailsExceptionResolver – ConcurrentModificationException在处理请求时发生:

前端之家收集整理的这篇文章主要介绍了html – ERROR errors.GrailsExceptionResolver – ConcurrentModificationException在处理请求时发生:前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。
我有一个Grails 2.4.5 GSP页面加载两个iFrame:
<iframe scrolling="no"
            src="${createLink(controller:'admin',action:'page1',id: serviceCard.id)}"></iframe>
<iframe scrolling="no"
            src="${createLink(controller:'admin',action:'page2',id: serviceCard.id)}"></iframe>

每次重新加载之后,我有以下问题.请注意,这不会一直发生.

在我的GSP上,我看到错误500.控制台显示以下错误

2015-08-01 21:41:11,530 [http-nio-8080-exec-3] ERROR errors.GrailsExceptionResolver  - ConcurrentModificationException occurred when processing request: [GET] /test/adminServiceCard/previewCard/4b6dc4730fd3acd80a
Stacktrace follows:
Message: Error processing GroovyPageView: Error executing tag <asset:stylesheet>: null
    Line | Method
->>  527 | doFilter         in /grails-app/views/adminServiceCard/previewCard.gsp
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 
Caused by GrailsTagException: Error executing tag <asset:stylesheet>: null
->>    6 | doCall           in /grails-app/views/adminServiceCard/previewCard.gsp
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 
Caused by ConcurrentModificationException: null
->> 1456 | sort             in java.util.ArrayList
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 
|    175 | sort             in java.util.Collections
|    145 | fileNameWithoutExtensionFromArtefact in asset.pipeline.AssetHelper
|     99 | loadRequiresForTree in asset.pipeline.DirectiveProcessor
|     76 | getFlattenedRequireList in     ''
|     83 | getDependencyList in asset.pipeline.AssetPipeline
|     79 | doCall . . . . . in asset.pipeline.grails.AssetsTagLib$_closure2
|      6 | doCall           in Users_mg_Documents_Grails_GGTS3_6_3_test_grails_app_views_adminServiceCard_previewCard_gsp$_run_closure1
|     10 | run . . . . . .  in Users_mg_Documents_Grails_GGTS3_6_3_test_grails_app_views_adminServiceCard_previewCard_gsp
|    198 | doFilter         in grails.plugin.cache.web.filter.PageFragmentCachingFilter
|     63 | doFilter . . . . in grails.plugin.cache.web.filter.AbstractFilter
|     53 | doFilter         in grails.plugin.springsecurity.web.filter.GrailsAnonymousAuthenticationFilter
|     62 | doFilter . . . . in grails.plugin.springsecurity.web.authentication.logout.MutablelogoutFilter
|     46 | doFilterInternal in org.grails.jaxrs.web.JaxrsFilter
|   1142 | runWorker . . .  in java.util.concurrent.ThreadPoolExecutor
|    617 | run              in java.util.concurrent.ThreadPoolExecutor$Worker
^    745 | run . . . . . .  in java.lang.Thread

编辑:这是adminServiceCardpreview_gsp.groovy.gsp的内容

import org.codehaus.groovy.grails.plugins.Metadata.GrailsPlugin
import org.codehaus.groovy.grails.web.pages.GroovyPage
import org.codehaus.groovy.grails.web.taglib.*
import org.codehaus.groovy.grails.web.taglib.exceptions.GrailsTagException
import org.springframework.web.util.*
import grails.util.GrailsUtil

class gsp_majestella_adminServiceCardpreview_gsp extends GroovyPage {
public String getGroovyPageFileName() { "/WEB-INF/grails-app/views/adminServiceCard/preview.gsp" }
public Object run() {
Writer out = getOut()
Writer expressionOut = getExpressionOut()
registerSitemeshPreprocessMode()
printHtmlPart(0)
createTagBody(1,{->
printHtmlPart(1)
invokeTag('javascript','g',5,['library':("jquery"),'plugin':("jquery")],-1)
printHtmlPart(1)
invokeTag('stylesheet','asset',7,['src':("perfect-scrollbar/perfect-scrollbar.min.css")],-1)
printHtmlPart(2)
invokeTag('javascript',8,['src':("perfect-scrollbar/perfect-scrollbar.jquery.min.js")],9,['src':("jquery.cycle.all.js")],11,['src':("preview.css")],-1)
printHtmlPart(3)
})
invokeTag('captureHead','sitemesh',13,[:],1)
printHtmlPart(4)
createTagBody(1,{->
printHtmlPart(5)
if(true && (showCard == true)) {
printHtmlPart(6)
if(true && (serviceCard.imageItems)) {
printHtmlPart(7)
expressionOut.print(createLink(controller:'image',action:'getImage',id:serviceCard.imageItems[0].id,absolute:true))
printHtmlPart(8)
}
printHtmlPart(9)
expressionOut.print(serviceCard?.title)
printHtmlPart(10)
expressionOut.print(serviceCard?.company?.name)
printHtmlPart(11)
}
printHtmlPart(12)
if(true && (showDetail == true)) {
printHtmlPart(13)
loop:{
int i = 0
for( imageItem in (serviceCard.imageItems) ) {
printHtmlPart(14)
expressionOut.print(createLink(controller:'image',id:imageItem.id,absolute:true))
printHtmlPart(15)
i++
}
}
printHtmlPart(16)
expressionOut.print(raw(serviceCard.description))
printHtmlPart(17)
}
printHtmlPart(18)
})
invokeTag('captureBody',116,1)
printHtmlPart(19)
}
public static final Map JSP_TAGS = new HashMap()
protected void init() {
    this.jspTags = JSP_TAGS
}
public static final String CONTENT_TYPE = 'text/html;charset=UTF-8'
public static final long LAST_MODIFIED = 1438521220000L
public static final String EXPRESSION_CODEC = 'html'
public static final String STATIC_CODEC = 'none'
public static final String OUT_CODEC = 'none'
public static final String TAGLIB_CODEC = 'none'
}

如何解决这个问题?

解决方法

这个错误看起来很像 this one从资产管道.

您应该删除previewCard.gsp中的所有// = require,然后通过它导致错误.

原文链接:https://www.f2er.com/html/224787.html

猜你在找的HTML相关文章