<p dir="auto"><strong><a href="https://jira.spring.io/secure/ViewProfile.jspa?name=adam.causey" rel="nofollow">Adam Causey</a></strong> opened <strong><a href="https://jira.spring.io/browse/SPR-7959?redirect=false" rel="nofollow">SPR-7959</a></strong> and commented</p>
<p dir="auto">The class org.springframework.web.servlet.view.document.AbstractPdfView references the iText PDF library using the package com.lowagie.<strong>.  The most recent version of iText uses the package com.itextpdf.</strong> instead of com.lowagie.</p>
<p dir="auto">The current workaround is to use an older version of iText, but it would be nice to have this updated.</p>
<p dir="auto">Thanks.</p>
<hr>
<p dir="auto"><strong>Affects:</strong> 3.0.5</p>
<p dir="auto"><strong>Issue Links:</strong></p>
<ul dir="auto">
<li><a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="398106558" data-permission-text="Title is private" data-url="https://github.com/spring-projects/spring-framework/issues/12083" data-hovercard-type="issue" data-hovercard-url="/spring-projects/spring-framework/issues/12083/hovercard" href="https://github.com/spring-projects/spring-framework/issues/12083">#12083</a> Update the AbstractPdfView class to point to the renamed itextpdf package names (<em><strong>"is duplicated by"</strong></em>)</li>
</ul>
<p dir="auto">1 votes, 4 watchers</p>
<p dir="auto"><strong><a href="https://jira.spring.io/secure/ViewProfile.jspa?name=leok" rel="nofollow">Leo Kim</a></strong> opened <strong><a href="https://jira.spring.io/browse/SPR-5360?redirect=false" rel="nofollow">SPR-5360</a></strong> and commented</p>
<p dir="auto">I actually wrote to the Wicket mailing list initially about this:<br>
<a href="http://www.nabble.com/SpringBeanLocator-and-%40SpringBean-performance-issue-td20964687.html" rel="nofollow">http://www.nabble.com/SpringBeanLocator-and-%40SpringBean-performance-issue-td20964687.html</a></p>
<p dir="auto">and they suggest that this is a deeper Spring issue. Basically, I'm using Wicket's <code class="notranslate">@SpringBean</code> annotation to inject beans throughout our webapp. When we load tested the app, we found threads blocking for extended periods at this particular point:</p>
<p dir="auto">Object blocked: 145.133 ms, Object wait: 0 ms, CPU wait: 2.118 ms, I/O wait: 9.017 ms, CPU: 73.847 ms</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="* org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton (DefaultSingletonBeanRegistry.java:180, bci=22, server compiler)
      o blocked on java.util.concurrent.ConcurrentHashMap (0x000000cd67f9d170)
* org.springframework.beans.factory.support.AbstractBeanFactory.isTypeMatch (AbstractBeanFactory.java:415, bci=41, server compiler)
* org.springframework.beans.factory.support.DefaultListableBeanFactory.getBeanNamesForType (DefaultListableBeanFactory.java:223, bci=142, server compiler)
* org.springframework.beans.factory.support.DefaultListableBeanFactory.getBeanNamesForType (DefaultListableBeanFactory.java:202, bci=4, server compiler)
* org.springframework.context.support.AbstractApplicationContext.getBeanNamesForType (AbstractApplicationContext.java:933, bci=5, server compiler)
* org.springframework.beans.factory.BeanFactoryUtils.beanNamesForTypeIncludingAncestors (BeanFactoryUtils.java:143, bci=8, server compiler)
* org.apache.wicket.spring.SpringBeanLocator.getBeanNameOfClass (SpringBeanLocator.java:104, bci=2, server compiler)
* org.apache.wicket.spring.SpringBeanLocator.getBeanName (SpringBeanLocator.java:192, bci=29, server compiler)
* org.apache.wicket.spring.SpringBeanLocator.isSingletonBean (SpringBeanLocator.java:133, bci=13, server compiler)
* org.apache.wicket.spring.injection.annot.AnnotProxyFieldValueFactory.getFieldValue (AnnotProxyFieldValueFactory.java:90, bci=46, server compiler)
* org.apache.wicket.injection.Injector.inject (Injector.java:108, bci=87, server compiler)
* org.apache.wicket.injection.ConfigurableInjector.inject (ConfigurableInjector.java:39, bci=6, server compiler)
* org.apache.wicket.injection.ComponentInjector.onInstantiation (ComponentInjector.java:52, bci=5, server compiler)
* org.apache.wicket.Application.notifyComponentInstantiationListeners (Application.java:974, bci=20, server compiler)
* org.apache.wicket.Component.&lt;init&gt; (Component.java:873, bci=35, server compiler)
* org.apache.wicket.MarkupContainer.&lt;init&gt; (MarkupContainer.java:105, bci=2, server compiler)
* org.apache.wicket.markup.html.WebMarkupContainer.&lt;init&gt; (WebMarkupContainer.java:39, bci=2, server compiler)
* org.apache.wicket.markup.html.WebMarkupContainerWithAssociatedMarkup.&lt;init&gt; (WebMarkupContainerWithAssociatedMarkup.java:42, bci=2, server compiler)
* org.apache.wicket.markup.html.panel.Panel.&lt;init&gt; (Panel.java:76, bci=2, server compiler)"><pre class="notranslate"><code class="notranslate">* org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton (DefaultSingletonBeanRegistry.java:180, bci=22, server compiler)
      o blocked on java.util.concurrent.ConcurrentHashMap (0x000000cd67f9d170)
* org.springframework.beans.factory.support.AbstractBeanFactory.isTypeMatch (AbstractBeanFactory.java:415, bci=41, server compiler)
* org.springframework.beans.factory.support.DefaultListableBeanFactory.getBeanNamesForType (DefaultListableBeanFactory.java:223, bci=142, server compiler)
* org.springframework.beans.factory.support.DefaultListableBeanFactory.getBeanNamesForType (DefaultListableBeanFactory.java:202, bci=4, server compiler)
* org.springframework.context.support.AbstractApplicationContext.getBeanNamesForType (AbstractApplicationContext.java:933, bci=5, server compiler)
* org.springframework.beans.factory.BeanFactoryUtils.beanNamesForTypeIncludingAncestors (BeanFactoryUtils.java:143, bci=8, server compiler)
* org.apache.wicket.spring.SpringBeanLocator.getBeanNameOfClass (SpringBeanLocator.java:104, bci=2, server compiler)
* org.apache.wicket.spring.SpringBeanLocator.getBeanName (SpringBeanLocator.java:192, bci=29, server compiler)
* org.apache.wicket.spring.SpringBeanLocator.isSingletonBean (SpringBeanLocator.java:133, bci=13, server compiler)
* org.apache.wicket.spring.injection.annot.AnnotProxyFieldValueFactory.getFieldValue (AnnotProxyFieldValueFactory.java:90, bci=46, server compiler)
* org.apache.wicket.injection.Injector.inject (Injector.java:108, bci=87, server compiler)
* org.apache.wicket.injection.ConfigurableInjector.inject (ConfigurableInjector.java:39, bci=6, server compiler)
* org.apache.wicket.injection.ComponentInjector.onInstantiation (ComponentInjector.java:52, bci=5, server compiler)
* org.apache.wicket.Application.notifyComponentInstantiationListeners (Application.java:974, bci=20, server compiler)
* org.apache.wicket.Component.&lt;init&gt; (Component.java:873, bci=35, server compiler)
* org.apache.wicket.MarkupContainer.&lt;init&gt; (MarkupContainer.java:105, bci=2, server compiler)
* org.apache.wicket.markup.html.WebMarkupContainer.&lt;init&gt; (WebMarkupContainer.java:39, bci=2, server compiler)
* org.apache.wicket.markup.html.WebMarkupContainerWithAssociatedMarkup.&lt;init&gt; (WebMarkupContainerWithAssociatedMarkup.java:42, bci=2, server compiler)
* org.apache.wicket.markup.html.panel.Panel.&lt;init&gt; (Panel.java:76, bci=2, server compiler)
</code></pre></div>
<p dir="auto">[...snip...]</p>
<p dir="auto">We're able to hack around it in our code and avoid this bottleneck, which resulted in us getting 50-75% more requests per second. Looking at some of the Spring 3.0 code, it looks like this class has not changed much so we'll probably run into this problem when we upgrade. Is there a way to make this code path more concurrent? With Spring 3.0 using Java 5, it seems like the use of read/write locks might squeeze more concurrency out of these bean lookups.</p>
<hr>
<p dir="auto"><strong>Affects:</strong> 2.5.6</p>
<p dir="auto"><strong>Attachments:</strong></p>
<ul dir="auto">
<li><a href="https://jira.spring.io/secure/attachment/17089/NonBlockingWebApplicationContext.java" rel="nofollow">NonBlockingWebApplicationContext.java</a> (<em>4.05 kB</em>)</li>
</ul>
<p dir="auto"><strong>Issue Links:</strong></p>
<ul dir="auto">
<li><a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="398153593" data-permission-text="Title is private" data-url="https://github.com/spring-projects/spring-framework/issues/14452" data-hovercard-type="issue" data-hovercard-url="/spring-projects/spring-framework/issues/14452/hovercard" href="https://github.com/spring-projects/spring-framework/issues/14452">#14452</a> Non-singleton beans performance issue  (<em><strong>"duplicates"</strong></em>)</li>
<li><a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="398114987" data-permission-text="Title is private" data-url="https://github.com/spring-projects/spring-framework/issues/13410" data-hovercard-type="issue" data-hovercard-url="/spring-projects/spring-framework/issues/13410/hovercard" href="https://github.com/spring-projects/spring-framework/issues/13410">#13410</a> Parallel bean initialization during startup</li>
</ul>
<p dir="auto">10 votes, 14 watchers</p>