Return-Path: Delivered-To: apmail-cocoon-dev-archive@www.apache.org Received: (qmail 36855 invoked from network); 3 Apr 2007 19:41:54 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 3 Apr 2007 19:41:54 -0000 Received: (qmail 45953 invoked by uid 500); 3 Apr 2007 19:42:01 -0000 Delivered-To: apmail-cocoon-dev-archive@cocoon.apache.org Received: (qmail 45732 invoked by uid 500); 3 Apr 2007 19:42:00 -0000 Mailing-List: contact dev-help@cocoon.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: Reply-To: dev@cocoon.apache.org List-Id: Delivered-To: mailing list dev@cocoon.apache.org Received: (qmail 45721 invoked by uid 99); 3 Apr 2007 19:42:00 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 03 Apr 2007 12:42:00 -0700 X-ASF-Spam-Status: No, hits=-100.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO brutus.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 03 Apr 2007 12:41:52 -0700 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 613E8714045 for ; Tue, 3 Apr 2007 12:41:32 -0700 (PDT) Message-ID: <2027965.1175629292315.JavaMail.jira@brutus> Date: Tue, 3 Apr 2007 12:41:32 -0700 (PDT) From: "Alexander Klimetschek (JIRA)" To: dev@cocoon.apache.org Subject: [jira] Created: (COCOON-2036) Handle circular dependencies in servlet connections MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org Handle circular dependencies in servlet connections --------------------------------------------------- Key: COCOON-2036 URL: https://issues.apache.org/jira/browse/COCOON-2036 Project: Cocoon Issue Type: Bug Components: - Servlet service framework Affects Versions: 2.2-dev (Current SVN) Reporter: Alexander Klimetschek Circular dependencies in servlet connections lead to a Spring exception [1] in [2] that does not provide any help. The previous implementation (block:) did allow circular dependencies because they were not handled by spring but by custom code. Solution would be either to allow them (probably difficult to implement with spring) or, if not, to provide a helpful warning message, that skips this problem. The latter could be a check for embeddedServlet==null and, if not, throw an exception saying "you might have a circular dependency in ". --- [1]: The exception is thrown after ServletFactoryBean.getObject() tries to create a proxy for the embeddedServlet, which is null in the case of a circular dependency (one of the circle endpoints is created, but the other will be null). Caused by: org.springframework.aop.framework.AopConfigException: Can't proxy null object at org.springframework.aop.framework.ProxyFactory.(ProxyFactory.java:49) at org.apache.cocoon.servletservice.spring.ServletFactoryBean.getObject(ServletFactoryBean.java:194) at org.springframework.beans.factory.support.AbstractBeanFactory.getObjectFromFactoryBean(AbstractBeanFactory.java:1211) [2]: public Object getObject() throws Exception { ProxyFactory proxyFactory = new ProxyFactory(this.embeddedServlet); proxyFactory.addAdvice(new ServiceInterceptor()); if (this.mountPath != null) { proxyFactory.addAdvisor(new MountableMixinAdvisor()); } proxyFactory.addAdvisor(new ServletServiceContextMixinAdvisor()); return proxyFactory.getProxy(); } -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.