Quantcast

i need some help

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

i need some help

luzhujun@rd.netease.com
hi,
i need some help,our site cpu went hight yesterday,cause user cant visit,and i found full jstack log like this.

this is jstack log:

"server://10.168.32.115:7921-1009" daemon prio=10 tid=0x00002aaad03ac000 nid=0x65b runnable [0x00002aab01c9c000]
java.lang.Thread.State: RUNNABLE
at java.util.zip.ZipFile.open(Native Method)
at java.util.zip.ZipFile.<init>(ZipFile.java:127)
at java.util.zip.ZipFile.<init>(ZipFile.java:88)
at com.caucho.vfs.Jar.getZipFile(Jar.java:650)
at com.caucho.vfs.Jar.getZipEntryImpl(Jar.java:560)
at com.caucho.vfs.Jar.getZipEntry(Jar.java:540)
at com.caucho.vfs.Jar.exists(Jar.java:338)
at com.caucho.vfs.JarPath.exists(JarPath.java:146)
at com.caucho.loader.JarListLoader.getPath(JarListLoader.java:332)
at com.caucho.loader.Loader.getResource(Loader.java:142)
at com.caucho.loader.DynamicClassLoader.getResource(DynamicClassLoader.java:1816)
at java.lang.Class.getResource(Class.java:2074)
at freemarker.cache.ClassTemplateLoader.getURL(ClassTemplateLoader.java:149)
at freemarker.cache.URLTemplateLoader.findTemplateSource(URLTemplateLoader.java:74)
at freemarker.cache.MultiTemplateLoader.findTemplateSource(MultiTemplateLoader.java:113)
at freemarker.cache.TemplateCache.acquireTemplateSource(TemplateCache.java:628)
at freemarker.cache.TemplateCache.findTemplateSource(TemplateCache.java:604)
at freemarker.cache.TemplateCache.getTemplate(TemplateCache.java:260)
at freemarker.cache.TemplateCache.getTemplate(TemplateCache.java:205)
at freemarker.template.Configuration.getTemplate(Configuration.java:740)
at freemarker.core.Environment.getTemplateForInclusion(Environment.java:1694)
at freemarker.core.Include.accept(Include.java:159)
at freemarker.core.Environment.visit(Environment.java:265)
at freemarker.core.MixedContent.accept(MixedContent.java:93)
at freemarker.core.Environment.visit(Environment.java:265)
at freemarker.core.Environment.include(Environment.java:1712)
at freemarker.core.Include.accept(Include.java:172)
at freemarker.core.Environment.visitByHiddingParent(Environment.java:286)
at freemarker.core.IteratorBlock$Context.runLoop(IteratorBlock.java:193)
at freemarker.core.Environment.visitIteratorBlock(Environment.java:509)
at freemarker.core.IteratorBlock.accept(IteratorBlock.java:103)
at freemarker.core.Environment.visitByHiddingParent(Environment.java:286)
at freemarker.core.ConditionalBlock.accept(ConditionalBlock.java:86)
at freemarker.core.Environment.visit(Environment.java:265)
at freemarker.core.MixedContent.accept(MixedContent.java:93)
at freemarker.core.Environment.visitByHiddingParent(Environment.java:286)
at freemarker.core.ConditionalBlock.accept(ConditionalBlock.java:86)
at freemarker.core.Environment.visit(Environment.java:265)
at freemarker.core.MixedContent.accept(MixedContent.java:93)
at freemarker.core.Environment.visit(Environment.java:265)
at freemarker.core.Environment.include(Environment.java:1712)
at freemarker.core.Include.accept(Include.java:172)
at freemarker.core.Environment.visit(Environment.java:265)
at freemarker.core.MixedContent.accept(MixedContent.java:93)
at freemarker.core.Environment.visit(Environment.java:265)
at freemarker.core.Environment.process(Environment.java:243)
at freemarker.template.Template.process(Template.java:277)
at org.springframework.web.servlet.view.freemarker.FreeMarkerView.processTemplate(FreeMarkerView.java:366)
at org.springframework.web.servlet.view.freemarker.FreeMarkerView.doRender(FreeMarkerView.java:283)
at org.springframework.web.servlet.view.freemarker.FreeMarkerView.renderMergedTemplateModel(FreeMarkerView.java:233)
at org.springframework.web.servlet.view.AbstractTemplateView.renderMergedOutputModel(AbstractTemplateView.java:167)
at org.springframework.web.servlet.view.AbstractView.render(AbstractView.java:264)
at org.springframework.web.servlet.DispatcherServlet.render(DispatcherServlet.java:1208)
at org.springframework.web.servlet.DispatcherServlet.processDispatchResult(DispatcherServlet.java:992)
at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:939)
at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:856)
at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:953)
at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:844)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:119)
at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:829)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:96)
at com.caucho.server.dispatch.ServletFilterChain.doFilter(ServletFilterChain.java:109)



------------------------------------------------------------------------------

_______________________________________________
FreeMarker-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/freemarker-user
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: i need some help

Daniel Dekany
Hard to tell from this where the problem lies... What I see is that
you have #include inside a #list (or perhaps #foreach), and then you
have a template cache miss or has to do an up-to-date-check (you can
find out which be looking at the source code of the exact version,
which I don't know what is), so the #include actually has to do I/O. I
don't know if something inside the zip file reading stuck and that
eats CPU, or simply there are constant template cache misses and so
you repeat this relatively expensive operation a lot (as you are
inside a #list loop). You may check the "freemarker.cache" log
category with DEBUG level to see if caching works.


Thursday, June 4, 2015, 6:38:03 PM, [hidden email] wrote:

> hi,
> i need some help,our site cpu went hight yesterday,cause user cant
> visit,and i found full jstack log like this.
>
> this is jstack log:
>
> "server://10.168.32.115:7921-1009" daemon prio=10
> tid=0x00002aaad03ac000 nid=0x65b runnable [0x00002aab01c9c000]
> java.lang.Thread.State: RUNNABLE
> at java.util.zip.ZipFile.open(Native Method)
> at java.util.zip.ZipFile.<init>(ZipFile.java:127)
> at java.util.zip.ZipFile.<init>(ZipFile.java:88)
> at com.caucho.vfs.Jar.getZipFile(Jar.java:650)
> at com.caucho.vfs.Jar.getZipEntryImpl(Jar.java:560)
> at com.caucho.vfs.Jar.getZipEntry(Jar.java:540)
> at com.caucho.vfs.Jar.exists(Jar.java:338)
> at com.caucho.vfs.JarPath.exists(JarPath.java:146)
> at com.caucho.loader.JarListLoader.getPath(JarListLoader.java:332)
> at com.caucho.loader.Loader.getResource(Loader.java:142)
> at
> com.caucho.loader.DynamicClassLoader.getResource(DynamicClassLoader.java:1816)
> at java.lang.Class.getResource(Class.java:2074)
> at
> freemarker.cache.ClassTemplateLoader.getURL(ClassTemplateLoader.java:149)
> at
> freemarker.cache.URLTemplateLoader.findTemplateSource(URLTemplateLoader.java:74)
> at
> freemarker.cache.MultiTemplateLoader.findTemplateSource(MultiTemplateLoader.java:113)
> at
> freemarker.cache.TemplateCache.acquireTemplateSource(TemplateCache.java:628)
> at
> freemarker.cache.TemplateCache.findTemplateSource(TemplateCache.java:604)
> at freemarker.cache.TemplateCache.getTemplate(TemplateCache.java:260)
> at freemarker.cache.TemplateCache.getTemplate(TemplateCache.java:205)
> at
> freemarker.template.Configuration.getTemplate(Configuration.java:740)
> at
> freemarker.core.Environment.getTemplateForInclusion(Environment.java:1694)
> at freemarker.core.Include.accept(Include.java:159)
> at freemarker.core.Environment.visit(Environment.java:265)
> at freemarker.core.MixedContent.accept(MixedContent.java:93)
> at freemarker.core.Environment.visit(Environment.java:265)
> at freemarker.core.Environment.include(Environment.java:1712)
> at freemarker.core.Include.accept(Include.java:172)
> at
> freemarker.core.Environment.visitByHiddingParent(Environment.java:286)
> at
> freemarker.core.IteratorBlock$Context.runLoop(IteratorBlock.java:193)
> at
> freemarker.core.Environment.visitIteratorBlock(Environment.java:509)
> at freemarker.core.IteratorBlock.accept(IteratorBlock.java:103)
> at
> freemarker.core.Environment.visitByHiddingParent(Environment.java:286)
> at freemarker.core.ConditionalBlock.accept(ConditionalBlock.java:86)
> at freemarker.core.Environment.visit(Environment.java:265)
> at freemarker.core.MixedContent.accept(MixedContent.java:93)
> at
> freemarker.core.Environment.visitByHiddingParent(Environment.java:286)
> at freemarker.core.ConditionalBlock.accept(ConditionalBlock.java:86)
> at freemarker.core.Environment.visit(Environment.java:265)
> at freemarker.core.MixedContent.accept(MixedContent.java:93)
> at freemarker.core.Environment.visit(Environment.java:265)
> at freemarker.core.Environment.include(Environment.java:1712)
> at freemarker.core.Include.accept(Include.java:172)
> at freemarker.core.Environment.visit(Environment.java:265)
> at freemarker.core.MixedContent.accept(MixedContent.java:93)
> at freemarker.core.Environment.visit(Environment.java:265)
> at freemarker.core.Environment.process(Environment.java:243)
> at freemarker.template.Template.process(Template.java:277)
> at
> org.springframework.web.servlet.view.freemarker.FreeMarkerView.processTemplate(FreeMarkerView.java:366)
> at
> org.springframework.web.servlet.view.freemarker.FreeMarkerView.doRender(FreeMarkerView.java:283)
> at
> org.springframework.web.servlet.view.freemarker.FreeMarkerView.renderMergedTemplateModel(FreeMarkerView.java:233)
> at
> org.springframework.web.servlet.view.AbstractTemplateView.renderMergedOutputModel(AbstractTemplateView.java:167)
> at
> org.springframework.web.servlet.view.AbstractView.render(AbstractView.java:264)
> at
> org.springframework.web.servlet.DispatcherServlet.render(DispatcherServlet.java:1208)
> at
> org.springframework.web.servlet.DispatcherServlet.processDispatchResult(DispatcherServlet.java:992)
> at
> org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:939)
> at
> org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:856)
> at
> org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:953)
> at
> org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:844)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:119)
> at
> org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:829)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:96)
> at
> com.caucho.server.dispatch.ServletFilterChain.doFilter(ServletFilterChain.java:109)
>
> [hidden email]

--
Thanks,
 Daniel Dekany


------------------------------------------------------------------------------
_______________________________________________
FreeMarker-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/freemarker-user
Loading...